From 323aab4aa8c04e48e54c91c9133678333e5f6846 Mon Sep 17 00:00:00 2001 From: dashie Date: Mon, 11 Dec 2023 12:57:11 +0000 Subject: [PATCH] feat: Set volume as default --- src/components/window/reset_window.rs | 34 +++++++++++++-------------- 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/src/components/window/reset_window.rs b/src/components/window/reset_window.rs index d1bdd34..5da09e5 100644 --- a/src/components/window/reset_window.rs +++ b/src/components/window/reset_window.rs @@ -23,14 +23,7 @@ unsafe impl Sync for ReSetWindow {} impl ReSetWindow { pub fn new(app: &Application) -> Self { - let obj: Self = Object::builder().property("application", app).build(); - let imp = obj.imp(); - (HANDLE_HOME)( - imp.listeners.clone(), - imp.reset_main.get(), - imp.position.clone(), - ); - obj + Object::builder().property("application", app).build() } pub fn setup_callback(&self) { @@ -219,16 +212,21 @@ impl ReSetWindow { // ), // ]; - // sidebarEntries.push(( - // SidebarEntry::new( - // "Peripherals", - // "preferences-system-devices-symbolic", - // Categories::Peripherals, - // false, - // HANDLE_PERIPHERALS_CLICK, - // ), - // peripheralsList, - // )); + // let home = SidebarEntry::new( + // "Home", + // "preferences-system-devices-symbolic", + // Categories::Peripherals, + // false, + // HANDLE_VOLUME_CLICK, + // ); + // + // sidebar_entries.push((home, Vec::new())); + + (HANDLE_VOLUME_CLICK)( + self_imp.listeners.clone(), + self_imp.reset_main.clone(), + self_imp.position.clone(), + ); self_imp .reset_sidebar_list