From 71ae5a6b673bc8943f048fed906751febfe585bd Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Sun, 26 Jan 2025 17:03:58 +1100 Subject: [PATCH] Use a simple menubar for addcards on macOS This makes initial-open and reopen behaviour consistent. Closes #3659 --- qt/aqt/addcards.py | 3 ++- qt/aqt/forms/addcards.ui | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/qt/aqt/addcards.py b/qt/aqt/addcards.py index 7d2504bbb..2aae316fb 100644 --- a/qt/aqt/addcards.py +++ b/qt/aqt/addcards.py @@ -57,7 +57,8 @@ class AddCards(QMainWindow): gui_hooks.operation_did_execute.append(self.on_operation_did_execute) restoreGeom(self, "add") gui_hooks.add_cards_did_init(self) - self.setMenuBar(None) + if not is_mac: + self.setMenuBar(None) self.show() def set_deck(self, deck_id: DeckId) -> None: diff --git a/qt/aqt/forms/addcards.ui b/qt/aqt/forms/addcards.ui index 50172015e..f682ebe09 100644 --- a/qt/aqt/forms/addcards.ui +++ b/qt/aqt/forms/addcards.ui @@ -91,6 +91,12 @@ 22 + + + qt_accel_edit + + +