Set menu roles in ui file.
This commit is contained in:
parent
a5c7a9b9c6
commit
e7461eb9a2
|
@ -222,6 +222,7 @@ MainWindow::MainWindow(
|
||||||
|
|
||||||
// Initialise the UI
|
// Initialise the UI
|
||||||
ui_->setupUi(this);
|
ui_->setupUi(this);
|
||||||
|
|
||||||
ui_->multi_loading_indicator->SetTaskManager(task_manager_);
|
ui_->multi_loading_indicator->SetTaskManager(task_manager_);
|
||||||
ui_->now_playing->SetCoverProviders(cover_providers_);
|
ui_->now_playing->SetCoverProviders(cover_providers_);
|
||||||
ui_->now_playing->SetLibraryBackend(library_->backend());
|
ui_->now_playing->SetLibraryBackend(library_->backend());
|
||||||
|
@ -599,15 +600,6 @@ MainWindow::MainWindow(
|
||||||
connect(check_updates, SIGNAL(triggered(bool)), SLOT(CheckForUpdates()));
|
connect(check_updates, SIGNAL(triggered(bool)), SLOT(CheckForUpdates()));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef Q_OS_DARWIN
|
|
||||||
// Force this menu to be the app "Preferences".
|
|
||||||
ui_->action_configure->setMenuRole(QAction::PreferencesRole);
|
|
||||||
// Force this menu to be the app "About".
|
|
||||||
ui_->action_about->setMenuRole(QAction::AboutRole);
|
|
||||||
// Force this menu to be the app "Quit".
|
|
||||||
ui_->action_quit->setMenuRole(QAction::QuitRole);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef Q_OS_WIN32
|
#ifdef Q_OS_WIN32
|
||||||
qLog(Debug) << "Creating sparkle updater";
|
qLog(Debug) << "Creating sparkle updater";
|
||||||
qtsparkle::Updater* updater = new qtsparkle::Updater(
|
qtsparkle::Updater* updater = new qtsparkle::Updater(
|
||||||
|
|
|
@ -418,7 +418,7 @@
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>1131</width>
|
<width>1131</width>
|
||||||
<height>23</height>
|
<height>22</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QMenu" name="menu_music">
|
<widget class="QMenu" name="menu_music">
|
||||||
|
@ -541,6 +541,9 @@
|
||||||
<property name="shortcut">
|
<property name="shortcut">
|
||||||
<string>Ctrl+Q</string>
|
<string>Ctrl+Q</string>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="menuRole">
|
||||||
|
<enum>QAction::QuitRole</enum>
|
||||||
|
</property>
|
||||||
</action>
|
</action>
|
||||||
<action name="action_stop_after_this_track">
|
<action name="action_stop_after_this_track">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -624,6 +627,9 @@
|
||||||
<property name="shortcut">
|
<property name="shortcut">
|
||||||
<string>Ctrl+P</string>
|
<string>Ctrl+P</string>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="menuRole">
|
||||||
|
<enum>QAction::PreferencesRole</enum>
|
||||||
|
</property>
|
||||||
</action>
|
</action>
|
||||||
<action name="action_about">
|
<action name="action_about">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -632,6 +638,9 @@
|
||||||
<property name="shortcut">
|
<property name="shortcut">
|
||||||
<string>F1</string>
|
<string>F1</string>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="menuRole">
|
||||||
|
<enum>QAction::AboutRole</enum>
|
||||||
|
</property>
|
||||||
</action>
|
</action>
|
||||||
<action name="action_shuffle">
|
<action name="action_shuffle">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -795,6 +804,9 @@
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>About Qt...</string>
|
<string>About Qt...</string>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="menuRole">
|
||||||
|
<enum>QAction::AboutQtRole</enum>
|
||||||
|
</property>
|
||||||
</action>
|
</action>
|
||||||
<action name="action_mute">
|
<action name="action_mute">
|
||||||
<property name="checkable">
|
<property name="checkable">
|
||||||
|
|
Loading…
Reference in New Issue