diff options
-rwxr-xr-x[-rw-r--r--] | README.md | 0 | ||||
-rwxr-xr-x | data/com.lakoliu.Furtherance.gschema.xml | 2 | ||||
-rwxr-xr-x[-rw-r--r--] | data/screenshots/furtherance-screenshot-edit-task.png | bin | 33243 -> 33243 bytes | |||
-rwxr-xr-x[-rw-r--r--] | data/screenshots/furtherance-screenshot-main.png | bin | 73192 -> 73192 bytes | |||
-rwxr-xr-x[-rw-r--r--] | data/screenshots/furtherance-screenshot-settings.png | bin | 78671 -> 78671 bytes | |||
-rwxr-xr-x[-rw-r--r--] | data/screenshots/furtherance-screenshot-task-details.png | bin | 43610 -> 43610 bytes | |||
-rwxr-xr-x | src/application.rs | 16 | ||||
-rwxr-xr-x | src/ui/preferences_window.rs | 6 |
8 files changed, 9 insertions, 15 deletions
diff --git a/README.md b/README.md index cf4ab85..cf4ab85 100644..100755 --- a/README.md +++ b/README.md diff --git a/data/com.lakoliu.Furtherance.gschema.xml b/data/com.lakoliu.Furtherance.gschema.xml index 276c79b..a2d22ae 100755 --- a/data/com.lakoliu.Furtherance.gschema.xml +++ b/data/com.lakoliu.Furtherance.gschema.xml @@ -2,7 +2,7 @@ <schemalist gettext-domain="furtherance"> <schema id="com.lakoliu.Furtherance" path="/com/lakoliu/Furtherance/"> <key name="dark-mode" type="b"> - <default>true</default> + <default>false</default> </key> <key name="notify-of-idle" type="b"> <default>true</default> diff --git a/data/screenshots/furtherance-screenshot-edit-task.png b/data/screenshots/furtherance-screenshot-edit-task.png index d2f3223..d2f3223 100644..100755 --- a/data/screenshots/furtherance-screenshot-edit-task.png +++ b/data/screenshots/furtherance-screenshot-edit-task.png Binary files differdiff --git a/data/screenshots/furtherance-screenshot-main.png b/data/screenshots/furtherance-screenshot-main.png index cc9b5ae..cc9b5ae 100644..100755 --- a/data/screenshots/furtherance-screenshot-main.png +++ b/data/screenshots/furtherance-screenshot-main.png Binary files differdiff --git a/data/screenshots/furtherance-screenshot-settings.png b/data/screenshots/furtherance-screenshot-settings.png index 64d92a1..64d92a1 100644..100755 --- a/data/screenshots/furtherance-screenshot-settings.png +++ b/data/screenshots/furtherance-screenshot-settings.png Binary files differdiff --git a/data/screenshots/furtherance-screenshot-task-details.png b/data/screenshots/furtherance-screenshot-task-details.png index 5721244..5721244 100644..100755 --- a/data/screenshots/furtherance-screenshot-task-details.png +++ b/data/screenshots/furtherance-screenshot-task-details.png Binary files differdiff --git a/src/application.rs b/src/application.rs index 6d051ba..bc90642 100755 --- a/src/application.rs +++ b/src/application.rs @@ -28,9 +28,7 @@ mod imp { use super::*; #[derive(Debug, Default)] - pub struct FurtheranceApplication { - // pub settings: gio::Settings, - } + pub struct FurtheranceApplication {} #[glib::object_subclass] impl ObjectSubclass for FurtheranceApplication { @@ -115,16 +113,6 @@ impl FurtheranceApplication { } fn setup_application(&self) { - let app_id = config::APP_ID.trim_end_matches(".Devel"); - let settings = gio::Settings::new(app_id); - - settings.connect_changed( - Some("dark-mode"), - clone!(@weak self as app => move |_, _| { - app.update_light_dark(); - } - ), - ); self.update_light_dark() } @@ -197,7 +185,7 @@ impl FurtheranceApplication { } } - fn update_light_dark(&self) { + pub fn update_light_dark(&self) { let manager = adw::StyleManager::default(); if !manager.system_supports_color_schemes() { diff --git a/src/ui/preferences_window.rs b/src/ui/preferences_window.rs index 12e8c30..f871e31 100755 --- a/src/ui/preferences_window.rs +++ b/src/ui/preferences_window.rs @@ -22,6 +22,7 @@ use gtk::CompositeTemplate; use crate::settings_manager; use crate::ui::FurtheranceWindow; +use crate::FurtheranceApplication; mod imp { use super::*; @@ -156,6 +157,11 @@ impl FurPreferencesWindow { "active" ); + imp.dark_theme_switch.connect_active_notify(move |_|{ + let app = FurtheranceApplication::default(); + app.update_light_dark(); + }); + imp.limit_tasks_expander.connect_enable_expansion_notify(move |_|{ let window = FurtheranceWindow::default(); window.reset_history_box(); |