theme: adapt to bread-theme's ThemeWatch return type

bread_theme:🐚:watch() now returns an opaque ThemeWatch (it re-arms
itself onto a new theme's directory when the active theme id changes,
rather than staying pinned to whichever directory was active at call
time) instead of a bare gio::FileMonitor. Update the stored handle's
type to match.
This commit is contained in:
Breadway 2026-08-25 16:18:43 +08:00
parent 6b15f24fb2
commit 02ed92ae9d

View file

@ -507,7 +507,11 @@ pub fn apply() {
} }
thread_local! { thread_local! {
static SHELL_THEME_MONITOR: RefCell<Option<gtk4::gio::FileMonitor>> = // `bread_theme::shell::ThemeWatch`, not a bare `gio::FileMonitor`: the
// watch now re-arms itself onto a new theme's directory when the active
// theme id changes underneath it (see that type's doc comment), so the
// handle we keep alive is opaque, not a single fixed monitor.
static SHELL_THEME_MONITOR: RefCell<Option<bread_theme::shell::ThemeWatch>> =
const { RefCell::new(None) }; const { RefCell::new(None) };
} }