Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/panel/panel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ class WayfirePanel::impl
#endif
}

if (name == "wp-mixer")
if (name == "mixer")
{
#ifdef HAVE_WIREPLUMBER
return Widget(new WayfireMixer());
Expand Down Expand Up @@ -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"}
};
Expand Down
12 changes: 6 additions & 6 deletions src/panel/widgets/mixer/mixer-control.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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");
Expand Down Expand Up @@ -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<bool> icons_on_left{"panel/wp_icons_on_left"};
static WfOption<bool> icons_on_left{"panel/mixer_icons_on_left"};

if (icons_on_left)
{
Expand All @@ -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<std::string> str_wp_right_click_action{"panel/wp_right_click_action"};
static WfOption<std::string> str_wp_middle_click_action{"panel/wp_middle_click_action"};
static WfOption<std::string> str_wp_right_click_action{"panel/mixer_right_click_action"};
static WfOption<std::string> str_wp_middle_click_action{"panel/mixer_middle_click_action"};

auto mute_action =
[&] (int count, double x, double y)
Expand Down Expand Up @@ -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");
Expand Down Expand Up @@ -268,7 +268,7 @@ void MixerControlDevice::set_def_status_no_callbk(bool state)
void MixerControlDevice::update_icons_pos()
{
MixerControl::update_icons_pos();
static WfOption<bool> icons_on_left{"panel/wp_icons_on_left"};
static WfOption<bool> icons_on_left{"panel/mixer_icons_on_left"};

if (icons_on_left)
{
Expand Down
2 changes: 1 addition & 1 deletion src/panel/widgets/mixer/mixer-control.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class MixerControl : public Gtk::Grid
std::vector<sigc::connection> signals;
void update_gestures();
virtual void update_icons_pos();
WfOption<int> slider_length{"panel/wp_slider_length"};
WfOption<int> slider_length{"panel/mixer_slider_length"};

public:
MixerControl(WpPipewireObject *obj, WayfireMixer *parent_widget);
Expand Down
12 changes: 6 additions & 6 deletions src/panel/widgets/mixer/mixer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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<std::string> str_quick_target_choice{"panel/wp_quick_target_choice"};
static WfOption<std::string> str_wp_left_click_action{"panel/wp_left_click_action"};
static WfOption<std::string> str_wp_right_click_action{"panel/wp_right_click_action"};
static WfOption<std::string> str_wp_middle_click_action{"panel/wp_middle_click_action"};
static WfOption<std::string> str_quick_target_choice{"panel/mixer_quick_target_choice"};
static WfOption<std::string> str_wp_left_click_action{"panel/mixer_left_click_action"};
static WfOption<std::string> str_wp_right_click_action{"panel/mixer_right_click_action"};
static WfOption<std::string> str_wp_middle_click_action{"panel/mixer_middle_click_action"};

if (str_quick_target_choice.value() == "last_change")
{
Expand Down Expand Up @@ -221,7 +221,7 @@ void WayfireMixer::init(Gtk::Box *container)

button = std::make_unique<WayfireMenuButton>("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);
Expand All @@ -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();
Expand Down
14 changes: 7 additions & 7 deletions src/panel/widgets/mixer/mixer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ class WayfireMixer : public WayfireWidget

Gtk::Image main_image;

WfOption<int> spacing{"panel/wp_spacing"};
WfOption<bool> stack_categories{"panel/wp_stack_categories"};
WfOption<double> timeout{"panel/wp_popup_timeout"};
WfOption<int> spacing{"panel/mixer_spacing"};
WfOption<bool> stack_categories{"panel/mixer_stack_categories"};
WfOption<double> timeout{"panel/mixer_popup_timeout"};

void on_volume_value_changed();
bool on_popover_timeout(int timer);
Expand All @@ -50,17 +50,17 @@ class WayfireMixer : public WayfireWidget

public:

WfOption<double> scroll_sensitivity{"panel/wp_scroll_sensitivity"};
WfOption<bool> invert_scroll{"panel/wp_invert_scroll"};
WfOption<bool> popup_on_change{"panel/wp_popup_on_change"};
WfOption<double> scroll_sensitivity{"panel/mixer_scroll_sensitivity"};
WfOption<bool> invert_scroll{"panel/mixer_invert_scroll"};
WfOption<bool> popup_on_change{"panel/mixer_popup_on_change"};

std::unique_ptr<WayfireMenuButton> button;
Gtk::Popover *popover;

/*
* 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<MixerControl> quick_target;
Expand Down
Loading