From 2fac0313566c78d62cc6d76fe35bf9ad10c24df7 Mon Sep 17 00:00:00 2001 From: "Ignacio R. Morelle" Date: Tue, 15 Jul 2014 19:53:13 -0400 Subject: [PATCH] preferences: Replace "Disable notifications" with "Desktop notifications" Because inverse-logic options are evil and this was the only one in the entire Preferences dialog anyway. --- changelog | 2 ++ data/advanced_preferences.cfg | 6 +++--- players_changelog | 2 ++ src/desktop/notifications.cpp | 2 +- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/changelog b/changelog index 6c2c7fbc30ef..5bb31b18666b 100644 --- a/changelog +++ b/changelog @@ -277,6 +277,8 @@ Version 1.13.0-dev: * Enabled action icons in the hotkey preferences dialog. * Fix bug #21717: "F5->reload wml tree" doesn't work in editor. * Fix bug #21298: Minimap shows invisible overlays + * Replaced "Disable notifications" in Preferences -> Advanced with a new + "Desktop notifications" option that defaults to enabled. Version 1.11.11: * Add-ons server: diff --git a/data/advanced_preferences.cfg b/data/advanced_preferences.cfg index 5680f969c4e7..3fafa8144344 100644 --- a/data/advanced_preferences.cfg +++ b/data/advanced_preferences.cfg @@ -116,10 +116,10 @@ [/advanced_preference] [advanced_preference] - field=disable_notifications - name= _ "Disable notifications" + field=desktop_notifications + name= _ "Desktop notifications" type=boolean - default=no + default=yes [/advanced_preference] [advanced_preference] diff --git a/players_changelog b/players_changelog index 8eb61a4e47be..c56c940e1c25 100644 --- a/players_changelog +++ b/players_changelog @@ -75,6 +75,8 @@ Version 1.13.0-dev: * Fix bug wherein "lobby sounds" advanced preference didn't do anything for the default lobby. * Fix bug wherein dbus notifications did not have a wesnoth icon * Fix bug wherein chat history synopses weren't working right in the dbus notifications + * Replaced "Disable notifications" in Preferences -> Advanced with a new + "Desktop notifications" option that defaults to enabled. Version 1.11.11: * Campaigns: diff --git a/src/desktop/notifications.cpp b/src/desktop/notifications.cpp index 54ba9b7426db..3a76d3b30f10 100644 --- a/src/desktop/notifications.cpp +++ b/src/desktop/notifications.cpp @@ -55,7 +55,7 @@ bool available() { return true; } void send(const std::string& owner, const std::string& message, type t) { - if (preferences::get("disable_notifications", false)) { return; } + if (!preferences::get("desktop_notifications", true)) { return; } Uint8 app_state = SDL_GetAppState();