labwc/src/ssd
tokyo4j 25f5cdd3a6 Refactor the logic of placing client-menu with ShowMenu action
Before this commit, we assumed `ShowMenu` action is not bound to any
buttons other than window menu button and always place the client-menu
under the window-menu button when atCursor="no". Also, it was going to be
difficult to distinguish whether the action is executed from the window
menu button or the window icon, which will be added soon.

This commit fixes it to open the menu under the actually-clicked button by
passing `cursor_context` to `actions_run()`, with some refactoring:
- `seat->pressed.resize_edges` is removed and it's calculated from the
  cursor position and `seat->pressed.type` just before running Resize
  action. This slightly changes the existing logic to determine the
  resizing edges with Alt-Right + Drag mousebinding, but
  `seat->pressed.type` is still stored on button press so it doesn't bring
  back the issue #543.
- `seat->pressed.toplevel` is removed and `get_toplevel()` in
  `update_pressed_surface()` may be called more often, but its overhead
  will be negligible.
2024-09-21 18:07:34 +01:00
..
meson.build Replace _ with - in source file names 2024-05-22 07:10:51 +01:00
resize-indicator.c Implement <resize><drawContents> 2024-06-15 21:17:01 +01:00
ssd-border.c theme: add button padding and spacing (#2127) 2024-09-10 22:14:30 +01:00
ssd-extents.c theme: add button padding and spacing (#2127) 2024-09-10 22:14:30 +01:00
ssd-part.c ssd: allow ssd to be smaller than minimal size by hiding buttons 2024-09-03 08:12:25 -04:00
ssd-shadow.c ssd/ssd-shadow.c: fix memory leak 2024-07-02 20:34:25 +01:00
ssd-titlebar.c theme: add button padding and spacing (#2127) 2024-09-10 22:14:30 +01:00
ssd.c Refactor the logic of placing client-menu with ShowMenu action 2024-09-21 18:07:34 +01:00