mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 05:37:17 +02:00
Start adding notifications [DNP]
This commit is contained in:
parent
b191ad866f
commit
d54739cfc2
1 changed files with 8 additions and 2 deletions
|
@ -49,6 +49,7 @@
|
||||||
#include "AmbientOcclusionEffect.h"
|
#include "AmbientOcclusionEffect.h"
|
||||||
#include "RenderShadowTask.h"
|
#include "RenderShadowTask.h"
|
||||||
|
|
||||||
|
#include "scripting/SettingsScriptingInterface.h"
|
||||||
#if defined(Q_OS_MAC) || defined(Q_OS_WIN)
|
#if defined(Q_OS_MAC) || defined(Q_OS_WIN)
|
||||||
#include "SpeechRecognizer.h"
|
#include "SpeechRecognizer.h"
|
||||||
#endif
|
#endif
|
||||||
|
@ -266,10 +267,15 @@ Menu::Menu() {
|
||||||
// Settings > Notifications
|
// Settings > Notifications
|
||||||
MenuWrapper * notificationsMenu = settingsMenu->addMenu("Notifications"); //This was in notifications.js. The menu needs to be moved here.
|
MenuWrapper * notificationsMenu = settingsMenu->addMenu("Notifications"); //This was in notifications.js. The menu needs to be moved here.
|
||||||
|
|
||||||
//TODO: Hookup notification actions below.
|
//TODO: Hookup notification actions below.
|
||||||
// Settings > Notifications > Play Notification Sounds
|
// Settings > Notifications > Play Notification Sounds
|
||||||
|
SettingsScriptingInterface* settings = SettingsScriptingInterface::getInstance();
|
||||||
addActionToQMenuAndActionHash(notificationsMenu, "Play Notification Sounds");
|
addActionToQMenuAndActionHash(notificationsMenu, "Play Notification Sounds");
|
||||||
|
action = addCheckableActionToQMenuAndActionHash(notificationsMenu, "Play Notification Sounds", 0,
|
||||||
|
settings->getValue("play_notification_sounds_type_0"));
|
||||||
|
connect(action, &QAction::triggered, [action] {
|
||||||
|
qApp->setDesktopTabletBecomesToolbarSetting(action->isChecked());
|
||||||
|
});
|
||||||
notificationsMenu->addSeparator();
|
notificationsMenu->addSeparator();
|
||||||
|
|
||||||
// Settings > Notifications > Play Sounds for:
|
// Settings > Notifications > Play Sounds for:
|
||||||
|
|
Loading…
Reference in a new issue