[-]
[+]
|
Changed |
_service:tar_git:harbour-ambience-tohkbd2.changes
|
|
[-]
[+]
|
Changed |
_service:tar_git:harbour-ambience-tohkbd2.spec
^
|
|
[-]
[+]
|
Changed |
_service
^
|
@@ -6,7 +6,7 @@
<service name="tar_git">
<param name="url">https://github.com/kimmoli/tohkbd2.git</param>
<param name="branch">master</param>
- <param name="revision">607d44347e1b3084d89af1f191bf0b71e98251b7</param>
+ <param name="revision">ede2c0ac53416c2db98e1d5411029d6e78ebb69c</param>
<param name="token"/>
<param name="debian">N</param>
<param name="dumb">N</param>
|
[-]
[+]
|
Changed |
_service:tar_git:harbour-ambience-tohkbd2-0.5.21.tar.bz2/daemon/src/defaultSettings.h
^
|
@@ -37,5 +37,6 @@
#define ACTION_RESTART_LIPSTICK_REMORSE "restart-lipstick-remorse"
#define VERBOSE_MODE_ENABLED false
+#define SHOW_NOTIFICATIONS true
#endif // DEFAULTSSETTINGS_H
|
[-]
[+]
|
Changed |
_service:tar_git:harbour-ambience-tohkbd2-0.5.21.tar.bz2/daemon/src/tohkeyboard.cpp
^
|
@@ -420,7 +420,8 @@
if (__prev_keypadPresence != keypadIsPresent)
{
- tohkbd2user->showKeyboardConnectionNotification(keypadIsPresent);
+ if (settingsMap.value("showNotifications").toBool())
+ tohkbd2user->showKeyboardConnectionNotification(keypadIsPresent);
emit keyboardConnectedChanged(keypadIsPresent);
emitKeypadSlideEvent(keypadIsPresent);
@@ -1150,6 +1151,7 @@
settingsMap.insert("forceBacklightOn", settings.value("forceBacklightOn", FORCE_BACKLIGHT_ON).toBool());
settingsMap.insert("turnDisplayOffWhenRemoved", settings.value("turnDisplayOffWhenRemoved", TURN_DISPLAY_OFF_WHEN_REMOVED).toBool());
settingsMap.insert("keepDisplayOnWhenConnected", settings.value("keepDisplayOnWhenConnected", KEEP_DISPLAY_ON_WHEN_CONNECTED).toBool());
+ settingsMap.insert("showNotifications", settings.value("showNotifications", SHOW_NOTIFICATIONS).toBool());
settings.endGroup();
}
|
[-]
[+]
|
Changed |
_service:tar_git:harbour-ambience-tohkbd2-0.5.21.tar.bz2/settings-ui/i18n/engineering_en.ts
^
|
@@ -413,5 +413,20 @@
<extracomment>section header for changelog</extracomment>
<translation type="unfinished"></translation>
</message>
+ <message id="showNotifications-sw">
+ <source>Show notifications</source>
+ <extracomment>Show notifications of keyboard attachment/removal</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message id="showNotifications-desc">
+ <source>Show notifications when keyboard is attached or removed. If disabled, other notifications for errors and screenshot are still shown.</source>
+ <extracomment>showNotifications switch description</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
+ <message id="notifications-sect-header">
+ <source>Notifications</source>
+ <extracomment>Section header for notifications settings</extracomment>
+ <translation type="unfinished"></translation>
+ </message>
</context>
</TS>
|
[-]
[+]
|
Changed |
_service:tar_git:harbour-ambience-tohkbd2-0.5.21.tar.bz2/settings-ui/qml/pages/GeneralSettings.qml
^
|
@@ -307,6 +307,24 @@
SectionHeader
{
+ //: Section header for notifications settings
+ //% "Notifications"
+ text: qsTrId("notifications-sect-header")
+ }
+ TextSwitch
+ {
+ //: Show notifications of keyboard attachment/removal
+ //% "Show notifications"
+ text: qsTrId("showNotifications-sw")
+ //: showNotifications switch description
+ //% "Show notifications when keyboard is attached or removed. If disabled, other notifications for errors and screenshot are still shown."
+ description: qsTrId("showNotifications-desc")
+ onCheckedChanged: if (checked !== settings["showNotifications"]) settingsui.setSetting("showNotifications", checked)
+ width: parent.width - 2*Theme.paddingLarge
+ Component.onCompleted: checked = settings["showNotifications"]
+ }
+ SectionHeader
+ {
//: Section header for Debug settings
//% "Debug"
text: qsTrId("debug-sect-header")
|
[-]
[+]
|
Changed |
_service:tar_git:harbour-ambience-tohkbd2-0.5.21.tar.bz2/settings-ui/src/settingsui.cpp
^
|
@@ -167,6 +167,7 @@
map.insert("turnDisplayOffWhenRemoved", settings.value("turnDisplayOffWhenRemoved", TURN_DISPLAY_OFF_WHEN_REMOVED).toBool());
map.insert("keepDisplayOnWhenConnected", settings.value("keepDisplayOnWhenConnected", KEEP_DISPLAY_ON_WHEN_CONNECTED).toBool());
map.insert("verboseMode", settings.value("verboseMode", VERBOSE_MODE_ENABLED).toBool());
+ map.insert("showNotifications", settings.value("showNotifications", SHOW_NOTIFICATIONS).toBool());
settings.endGroup();
QString layout = QString(tohkbd2user->getActivePhysicalLayout());
@@ -272,6 +273,7 @@
setSetting("verboseMode", VERBOSE_MODE_ENABLED);
setSetting("turnDisplayOffWhenRemoved", TURN_DISPLAY_OFF_WHEN_REMOVED);
setSetting("keepDisplayOnWhenConnected", KEEP_DISPLAY_ON_WHEN_CONNECTED);
+ setSetting("showNotifications", SHOW_NOTIFICATIONS);
QThread::msleep(200);
|