mirror of
https://github.com/NinjaCheetah/NUSGet.git
synced 2026-02-27 23:25:29 -05:00
Keep "About NUSGet" and "About Qt" under the application menu on macOS
Defined menu roles for those items so that Qt knows they belong under "NUSGet" when on macOS. This worked automatically somehow in English, but when loading a localization they'd be relocated to "Help" like they are on Windows and Linux. They'll now stay in the correct place for all languages.
This commit is contained in:
@@ -35,9 +35,11 @@ class Ui_MainWindow(object):
|
||||
self.actionAbout.setObjectName(u"actionAbout")
|
||||
icon = QIcon(QIcon.fromTheme(QIcon.ThemeIcon.HelpAbout))
|
||||
self.actionAbout.setIcon(icon)
|
||||
self.actionAbout.setMenuRole(QAction.MenuRole.ApplicationSpecificRole)
|
||||
self.actionAbout_Qt = QAction(MainWindow)
|
||||
self.actionAbout_Qt.setObjectName(u"actionAbout_Qt")
|
||||
self.actionAbout_Qt.setIcon(icon)
|
||||
self.actionAbout_Qt.setMenuRole(QAction.MenuRole.ApplicationSpecificRole)
|
||||
self.centralwidget = QWidget(MainWindow)
|
||||
self.centralwidget.setObjectName(u"centralwidget")
|
||||
self.horizontalLayout_3 = QHBoxLayout(self.centralwidget)
|
||||
@@ -332,7 +334,7 @@ class Ui_MainWindow(object):
|
||||
|
||||
def retranslateUi(self, MainWindow):
|
||||
MainWindow.setWindowTitle(QCoreApplication.translate("MainWindow", u"MainWindow", None))
|
||||
self.actionAbout.setText(QCoreApplication.translate("MainWindow", u"About", None))
|
||||
self.actionAbout.setText(QCoreApplication.translate("MainWindow", u"About NUSGet", None))
|
||||
self.actionAbout_Qt.setText(QCoreApplication.translate("MainWindow", u"About Qt", None))
|
||||
self.tree_filter_input.setPlaceholderText(QCoreApplication.translate("MainWindow", u"Search", None))
|
||||
self.tree_filter_reset_btn.setText(QCoreApplication.translate("MainWindow", u"Clear", None))
|
||||
|
||||
@@ -461,7 +461,10 @@ li.checked::marker { content: "\2612"; }
|
||||
<iconset theme="QIcon::ThemeIcon::HelpAbout"/>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>About</string>
|
||||
<string>About NUSGet</string>
|
||||
</property>
|
||||
<property name="menuRole">
|
||||
<enum>QAction::MenuRole::ApplicationSpecificRole</enum>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionAbout_Qt">
|
||||
@@ -471,6 +474,9 @@ li.checked::marker { content: "\2612"; }
|
||||
<property name="text">
|
||||
<string>About Qt</string>
|
||||
</property>
|
||||
<property name="menuRole">
|
||||
<enum>QAction::MenuRole::ApplicationSpecificRole</enum>
|
||||
</property>
|
||||
</action>
|
||||
</widget>
|
||||
<customwidgets>
|
||||
|
||||
Reference in New Issue
Block a user