2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-09-05 09:05:14 +00:00

Allow creating desktop part of multi-theme.

This commit is contained in:
John Preston
2019-09-05 13:51:36 +03:00
parent 79106e0c01
commit 4951eeac98
24 changed files with 300 additions and 233 deletions

View File

@@ -523,11 +523,11 @@ void Options::addEmptyOption() {
Core::InstallEventFilter(field, [=](not_null<QEvent*> event) {
if (event->type() != QEvent::KeyPress
|| !field->getLastText().isEmpty()) {
return false;
return Core::EventFilter::Result::Continue;
}
const auto key = static_cast<QKeyEvent*>(event.get())->key();
if (key != Qt::Key_Backspace) {
return false;
return Core::EventFilter::Result::Continue;
}
const auto index = findField(field);
@@ -536,7 +536,7 @@ void Options::addEmptyOption() {
} else {
_backspaceInFront.fire({});
}
return true;
return Core::EventFilter::Result::Cancel;
});
_list.back().removeClicks(