mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-09-05 17:06:03 +00:00
hiding, not destroying window on close on OS X, fixed app event filter
This commit is contained in:
@@ -57,15 +57,8 @@ namespace {
|
||||
QKeyEvent *ev = static_cast<QKeyEvent*>(e);
|
||||
if (cPlatform() == dbipMac || cPlatform() == dbipMacOld) {
|
||||
if (ev->key() == Qt::Key_W && (ev->modifiers() & Qt::ControlModifier)) {
|
||||
if (cWorkMode() == dbiwmTrayOnly || cWorkMode() == dbiwmWindowAndTray) {
|
||||
App::wnd()->minimizeToTray();
|
||||
return true;
|
||||
} else {
|
||||
App::wnd()->hide();
|
||||
App::wnd()->updateIsActive(cOfflineBlurTimeout());
|
||||
App::wnd()->updateGlobalMenu();
|
||||
return true;
|
||||
}
|
||||
Ui::hideWindowNoQuit();
|
||||
return true;
|
||||
} else if (ev->key() == Qt::Key_M && (ev->modifiers() & Qt::ControlModifier)) {
|
||||
App::wnd()->setWindowState(Qt::WindowMinimized);
|
||||
return true;
|
||||
|
Reference in New Issue
Block a user