Skip to content

Commit

Permalink
workspace taskbars: Add button param to click command
Browse files Browse the repository at this point in the history
  • Loading branch information
pol-rivero committed Jan 27, 2025
1 parent 7b85411 commit 1a9f5ac
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/modules/hyprland/workspace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,8 @@ bool Workspace::handleClick(const GdkEventButton *event_button, WindowAddress co
if (event_button->type == GDK_BUTTON_PRESS) {
std::string command = std::regex_replace(m_workspaceManager.onClickWindow(),
std::regex("\\{address\\}"), "0x" + addr);
command = std::regex_replace(command, std::regex("\\{button\\}"),
std::to_string(event_button->button));
auto res = util::command::execNoRead(command);
if (res.exit_code != 0) {
spdlog::error("Failed to execute {}: {}", command, res.out);
Expand Down

0 comments on commit 1a9f5ac

Please # to comment.