From 61c0d1828b939a2ffc777dc654e4f87c11557fa4 Mon Sep 17 00:00:00 2001 From: AKArien Date: Sat, 16 May 2026 18:05:05 +0200 Subject: [PATCH] =?UTF-8?q?panel=C2=A0:=20mixer=C2=A0:=20fix=20styles=20an?= =?UTF-8?q?d=20options=20for=20rename=20in=20fea9448?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/panel/panel.cpp | 6 +++--- src/panel/widgets/mixer/mixer-control.cpp | 12 ++++++------ src/panel/widgets/mixer/mixer-control.hpp | 2 +- src/panel/widgets/mixer/mixer.cpp | 12 ++++++------ src/panel/widgets/mixer/mixer.hpp | 14 +++++++------- 5 files changed, 23 insertions(+), 23 deletions(-) diff --git a/src/panel/panel.cpp b/src/panel/panel.cpp index dbcdafde..80d8ab91 100644 --- a/src/panel/panel.cpp +++ b/src/panel/panel.cpp @@ -240,7 +240,7 @@ class WayfirePanel::impl #endif } - if (name == "wp-mixer") + if (name == "mixer") { #ifdef HAVE_WIREPLUMBER return Widget(new WayfireMixer()); @@ -596,8 +596,8 @@ void WayfirePanelApp::on_activate() {"panel/battery_icon_size", ".battery image"}, {"panel/network_icon_size", ".network"}, {"panel/volume_icon_size", ".volume"}, - {"panel/wp_icon_size", ".mixer"}, - {"panel/wp_popup_icon_size", ".mute-toggle, .default-button"}, + {"panel/mixer_icon_size", ".mixer"}, + {"panel/mixer_popup_icon_size", ".mute-toggle, .default-button"}, {"panel/notifications_icon_size", ".notification-center "}, {"panel/tray_icon_size", ".tray-button"} }; diff --git a/src/panel/widgets/mixer/mixer-control.cpp b/src/panel/widgets/mixer/mixer-control.cpp index c625a290..25c271b3 100644 --- a/src/panel/widgets/mixer/mixer-control.cpp +++ b/src/panel/widgets/mixer/mixer-control.cpp @@ -29,7 +29,7 @@ void MixerControl::init() // build layout - add_css_class("wp-mixer-control"); + add_css_class("mixer-control"); button.set_child(volume_icon); button.add_css_class("mute-toggle"); button.add_css_class("widget-icon"); @@ -161,7 +161,7 @@ double MixerControl::get_scale_target_value() // attaches elements to the grid at the appropriate place void MixerControl::update_icons_pos() { - static WfOption icons_on_left{"panel/wp_icons_on_left"}; + static WfOption icons_on_left{"panel/mixer_icons_on_left"}; if (icons_on_left) { @@ -179,8 +179,8 @@ void MixerControl::update_icons_pos() void MixerControl::update_gestures() { // the setting says that it is for quick target, but let’s have all the muting consistent - static WfOption str_wp_right_click_action{"panel/wp_right_click_action"}; - static WfOption str_wp_middle_click_action{"panel/wp_middle_click_action"}; + static WfOption str_wp_right_click_action{"panel/mixer_right_click_action"}; + static WfOption str_wp_middle_click_action{"panel/mixer_middle_click_action"}; auto mute_action = [&] (int count, double x, double y) @@ -224,7 +224,7 @@ MixerControlDevice::~MixerControlDevice() void MixerControlDevice::init() { - add_css_class("wp-mixer-control"); + add_css_class("mixer-control"); default_btn.add_css_class("default-button"); default_btn.add_css_class("widget-icon"); default_btn.add_css_class("flat"); @@ -268,7 +268,7 @@ void MixerControlDevice::set_def_status_no_callbk(bool state) void MixerControlDevice::update_icons_pos() { MixerControl::update_icons_pos(); - static WfOption icons_on_left{"panel/wp_icons_on_left"}; + static WfOption icons_on_left{"panel/mixer_icons_on_left"}; if (icons_on_left) { diff --git a/src/panel/widgets/mixer/mixer-control.hpp b/src/panel/widgets/mixer/mixer-control.hpp index 5ad49a0f..a1e9b4d2 100644 --- a/src/panel/widgets/mixer/mixer-control.hpp +++ b/src/panel/widgets/mixer/mixer-control.hpp @@ -22,7 +22,7 @@ class MixerControl : public Gtk::Grid std::vector signals; void update_gestures(); virtual void update_icons_pos(); - WfOption slider_length{"panel/wp_slider_length"}; + WfOption slider_length{"panel/mixer_slider_length"}; public: MixerControl(WpPipewireObject *obj, WayfireMixer *parent_widget); diff --git a/src/panel/widgets/mixer/mixer.cpp b/src/panel/widgets/mixer/mixer.cpp index a60bd2dd..89e1e8fc 100644 --- a/src/panel/widgets/mixer/mixer.cpp +++ b/src/panel/widgets/mixer/mixer.cpp @@ -45,10 +45,10 @@ void WayfireMixer::reload_config() master_box.set_orientation(stack_categories ? Gtk::Orientation::VERTICAL : Gtk::Orientation::HORIZONTAL); // big matching operation - static WfOption str_quick_target_choice{"panel/wp_quick_target_choice"}; - static WfOption str_wp_left_click_action{"panel/wp_left_click_action"}; - static WfOption str_wp_right_click_action{"panel/wp_right_click_action"}; - static WfOption str_wp_middle_click_action{"panel/wp_middle_click_action"}; + static WfOption str_quick_target_choice{"panel/mixer_quick_target_choice"}; + static WfOption str_wp_left_click_action{"panel/mixer_left_click_action"}; + static WfOption str_wp_right_click_action{"panel/mixer_right_click_action"}; + static WfOption str_wp_middle_click_action{"panel/mixer_middle_click_action"}; if (str_quick_target_choice.value() == "last_change") { @@ -221,7 +221,7 @@ void WayfireMixer::init(Gtk::Box *container) button = std::make_unique("panel"); button->add_css_class("widget-icon"); - button->add_css_class("wp-mixer"); + button->add_css_class("mixer"); button->add_css_class("flat"); button->get_children()[0]->add_css_class("flat"); button->set_child(main_image); @@ -235,7 +235,7 @@ void WayfireMixer::init(Gtk::Box *container) popover = button->get_popover(); popover->set_child(master_box); popover->set_autohide(false); - popover->add_css_class("wp-mixer-popover"); + popover->add_css_class("mixer-popover"); // scroll to change volume of the object targetted by the quick_target widget auto scroll_gesture = Gtk::EventControllerScroll::create(); diff --git a/src/panel/widgets/mixer/mixer.hpp b/src/panel/widgets/mixer/mixer.hpp index 7f3b67ba..fec78d07 100644 --- a/src/panel/widgets/mixer/mixer.hpp +++ b/src/panel/widgets/mixer/mixer.hpp @@ -28,9 +28,9 @@ class WayfireMixer : public WayfireWidget Gtk::Image main_image; - WfOption spacing{"panel/wp_spacing"}; - WfOption stack_categories{"panel/wp_stack_categories"}; - WfOption timeout{"panel/wp_popup_timeout"}; + WfOption spacing{"panel/mixer_spacing"}; + WfOption stack_categories{"panel/mixer_stack_categories"}; + WfOption timeout{"panel/mixer_popup_timeout"}; void on_volume_value_changed(); bool on_popover_timeout(int timer); @@ -50,9 +50,9 @@ class WayfireMixer : public WayfireWidget public: - WfOption scroll_sensitivity{"panel/wp_scroll_sensitivity"}; - WfOption invert_scroll{"panel/wp_invert_scroll"}; - WfOption popup_on_change{"panel/wp_popup_on_change"}; + WfOption scroll_sensitivity{"panel/mixer_scroll_sensitivity"}; + WfOption invert_scroll{"panel/mixer_invert_scroll"}; + WfOption popup_on_change{"panel/mixer_popup_on_change"}; std::unique_ptr button; Gtk::Popover *popover; @@ -60,7 +60,7 @@ class WayfireMixer : public WayfireWidget /* * the "quick_target" is the representation of the audio channel that shows it’s volume * level on the widget icon and is concerned by the quick actions. - * configured by panel/wp_quick_target_choice. idea: add pinning? + * configured by panel/mixer_quick_target_choice. idea: add pinning? */ QuickTargetChoice quick_target_choice; std::unique_ptr quick_target;