aboutsummaryrefslogtreecommitdiff
path: root/include/swaybar
diff options
context:
space:
mode:
Diffstat (limited to 'include/swaybar')
-rw-r--r--include/swaybar/bar.h7
-rw-r--r--include/swaybar/status_line.h2
2 files changed, 7 insertions, 2 deletions
diff --git a/include/swaybar/bar.h b/include/swaybar/bar.h
index f1ff25b2..1cecea71 100644
--- a/include/swaybar/bar.h
+++ b/include/swaybar/bar.h
@@ -29,10 +29,15 @@ enum x11_button {
FORWARD,
};
+enum hotspot_event_handling {
+ HOTSPOT_IGNORE,
+ HOTSPOT_PROCESS,
+};
+
struct swaybar_hotspot {
struct wl_list link;
int x, y, width, height;
- void (*callback)(struct swaybar_output *output,
+ enum hotspot_event_handling (*callback)(struct swaybar_output *output,
int x, int y, enum x11_button button, void *data);
void (*destroy)(void *data);
void *data;
diff --git a/include/swaybar/status_line.h b/include/swaybar/status_line.h
index 2eaf8140..de9b98d7 100644
--- a/include/swaybar/status_line.h
+++ b/include/swaybar/status_line.h
@@ -71,7 +71,7 @@ void status_error(struct status_line *status, const char *text);
bool status_handle_readable(struct status_line *status);
void status_line_free(struct status_line *status);
bool i3bar_handle_readable(struct status_line *status);
-void i3bar_block_send_click(struct status_line *status,
+enum hotspot_event_handling i3bar_block_send_click(struct status_line *status,
struct i3bar_block *block, int x, int y, enum x11_button button);
void i3bar_block_free(struct i3bar_block *block);
enum x11_button wl_button_to_x11_button(uint32_t button);