fix urgent window icons
This commit is contained in:
@@ -99,8 +99,8 @@ void TrayIconWidget::on_secondary_released(int /*n_press*/, double x,
|
||||
return;
|
||||
}
|
||||
|
||||
pendingX = x;
|
||||
pendingY = y;
|
||||
pendingX = x;
|
||||
pendingY = y;
|
||||
menuPopupPending = true;
|
||||
try_popup();
|
||||
}
|
||||
@@ -125,7 +125,7 @@ bool TrayIconWidget::ensure_menu() {
|
||||
|
||||
const auto &layout = *layoutOpt;
|
||||
|
||||
auto menu = Gio::Menu::create();
|
||||
auto menu = Gio::Menu::create();
|
||||
auto actions = Gio::SimpleActionGroup::create();
|
||||
|
||||
populate_menu_items(layout.children, menu, actions);
|
||||
@@ -138,7 +138,7 @@ bool TrayIconWidget::ensure_menu() {
|
||||
return false;
|
||||
}
|
||||
|
||||
menuModel = menu;
|
||||
menuModel = menu;
|
||||
menuActions = actions;
|
||||
|
||||
if (!menuPopover) {
|
||||
|
||||
@@ -52,7 +52,7 @@ void VolumeWidget::update() {
|
||||
std::regex r_number(R"((\d+(?:\.\d+)?))");
|
||||
|
||||
std::string text = out;
|
||||
int percent = -1;
|
||||
int percent = -1;
|
||||
|
||||
if (std::regex_search(text, m, r_percent)) {
|
||||
percent = static_cast<int>(std::round(std::stod(m[1].str())));
|
||||
|
||||
@@ -54,7 +54,7 @@ void WorkspaceIndicator::on_workspace_update() {
|
||||
|
||||
void WorkspaceIndicator::on_monitor_update() { rebuild(); }
|
||||
|
||||
void WorkspaceIndicator::refreshLabel(Gtk::Label *label, HyprlandService::WorkspaceState state) {
|
||||
void WorkspaceIndicator::refreshLabel(Gtk::Label *label, HyprlandService::WorkspaceState state) {
|
||||
label->remove_css_class("workspace-pill-active");
|
||||
label->remove_css_class("workspace-pill-focused");
|
||||
label->remove_css_class("workspace-pill-urgent");
|
||||
@@ -82,7 +82,6 @@ void WorkspaceIndicator::rebuild() {
|
||||
HyprlandService::Monitor *mon = service.getMonitorById(this->monitorId);
|
||||
|
||||
for (auto [id, workspaceState] : mon->workspaceStates) {
|
||||
assert(id > 0);
|
||||
Gtk::Label *label = workspaceLabels[id];
|
||||
this->refreshLabel(label, *workspaceState);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user