mirror of https://github.com/procxx/kepka.git
Scroll to cursor after template replacement.
This commit is contained in:
parent
ecce1edded
commit
d3a261de89
|
@ -797,6 +797,7 @@ void HistoryWidget::supportInitAutocomplete() {
|
||||||
void HistoryWidget::supportInsertText(const QString &text) {
|
void HistoryWidget::supportInsertText(const QString &text) {
|
||||||
_field->setFocus();
|
_field->setFocus();
|
||||||
_field->textCursor().insertText(text);
|
_field->textCursor().insertText(text);
|
||||||
|
_field->ensureCursorVisible();
|
||||||
}
|
}
|
||||||
|
|
||||||
void HistoryWidget::supportShareContact(Support::Contact contact) {
|
void HistoryWidget::supportShareContact(Support::Contact contact) {
|
||||||
|
|
|
@ -2464,6 +2464,10 @@ void InputField::clearFocus() {
|
||||||
_inner->clearFocus();
|
_inner->clearFocus();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void InputField::ensureCursorVisible() {
|
||||||
|
_inner->ensureCursorVisible();
|
||||||
|
}
|
||||||
|
|
||||||
not_null<QTextEdit*> InputField::rawTextEdit() {
|
not_null<QTextEdit*> InputField::rawTextEdit() {
|
||||||
return _inner.get();
|
return _inner.get();
|
||||||
}
|
}
|
||||||
|
|
|
@ -284,6 +284,7 @@ public:
|
||||||
bool hasFocus() const;
|
bool hasFocus() const;
|
||||||
void setFocus();
|
void setFocus();
|
||||||
void clearFocus();
|
void clearFocus();
|
||||||
|
void ensureCursorVisible();
|
||||||
not_null<QTextEdit*> rawTextEdit();
|
not_null<QTextEdit*> rawTextEdit();
|
||||||
not_null<const QTextEdit*> rawTextEdit() const;
|
not_null<const QTextEdit*> rawTextEdit() const;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue