mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-09-01 23:25:15 +00:00
Pass modifiers inside InputField submitted signal.
Also use non-MOC connections for all InputFields. Also use Ctrl/Cmd + Enter to submit fast share box. Fixes #4769.
This commit is contained in:
@@ -194,13 +194,9 @@ void EditCaptionBox::prepare() {
|
||||
addButton(langFactory(lng_cancel), [this] { closeBox(); });
|
||||
|
||||
updateBoxSize();
|
||||
connect(_field, &Ui::InputField::submitted, this, [this] { save(); });
|
||||
connect(_field, &Ui::InputField::cancelled, this, [this] {
|
||||
closeBox();
|
||||
});
|
||||
connect(_field, &Ui::InputField::resized, this, [this] {
|
||||
captionResized();
|
||||
});
|
||||
connect(_field, &Ui::InputField::submitted, [=] { save(); });
|
||||
connect(_field, &Ui::InputField::cancelled, [=] { closeBox(); });
|
||||
connect(_field, &Ui::InputField::resized, [=] { captionResized(); });
|
||||
|
||||
auto cursor = _field->textCursor();
|
||||
cursor.movePosition(QTextCursor::End);
|
||||
|
Reference in New Issue
Block a user