Add MOUSE_CLEAR_CURRENT action
Title: Add MOUSE_CLEAR_CURRENT Action to Close Notification Under Cursor
Description:
Introduces a new mouse action, MOUSE_CLEAR_CURRENT, allowing users to close the notification under the mouse cursor with a left-click or desired by editing 'dunstrc' file. This removes the notification from history by id. This enhances user control over notifications.
Changes
- src/settings.h: Added
MOUSE_CLEAR_CURRENTtoenum mouse_action. - src/settings_data.h: Added
clear_current|MOUSE_CLEAR_CURRENT. - src/input.c: Implemented in
input_handle_clickto close the notification, remove it from history, and redraw.
Details
- Closes notification with
REASON_USER. - Uses a static
dunst_statusto reset fullscreen/pause/idle states. - Compatible with X11 and Wayland.
- Triggers redraw via
wake_upeven if no notification is found.
Testing
- Verified on X11 and Wayland simulators; works as intended.
- No conflicts with existing functionality across 65 files.
Feedback welcome!
hello. is the difference with close_current that the notification is erased from history? it might be good to add it to the description
hello. is the difference with close_current that the notification is erased from history? it might be good to add it to the description
Yes, it removes the selected notification from history.
please fix the build problems
Sorry, I'll have the updated version up this weekend!
any news?
superseded by #1491