Johan Malm
48c9e6fda0
osd: show alt-tab switcher center-aligned on all outputs
...
Fixes issue #283
2022-04-20 17:45:10 +01:00
Johan Malm
97846ae45b
cursor: add cursor_update_focus()
...
...and call it from desktop_move_to_front() in order force an enter event
on the surface below the cursor when cycling views.
Fixes #162 and #225
Inspired by PR #164 - just restructured it a bit.
Suggested-by: @bi4k8
Co-authored-by: Consolatis <35009135+Consolatis@users.noreply.github.com>
2022-03-21 17:57:20 +00:00
Consolatis
8444ba4075
Convert menu to node_descriptors
2022-03-03 17:49:54 +00:00
Johan Malm
30298228e3
Rename node-descriptor.c to node.c
...
...in anticipation of adding helpers like node_view_from_node()
2022-03-02 21:07:04 +00:00
Consolatis
51e02e2afa
src/desktop.c: Fix label error
...
Fixes "a label can only be part of a statement
and a declaration is not a statement".
2022-03-02 20:43:59 +00:00
Johan Malm
bd9ac3478a
Remove src/damage.c
2022-03-01 20:54:52 +00:00
Johan Malm
cec0c5cee6
desktop.c: set *view_area right for layer-popup
2022-02-26 23:30:02 +00:00
Johan Malm
2891ff245e
Add node-descriptor for wlr_scene_nodes
...
Support identification of wlr_scene_node role to enable simplification
of codebase including the avoidance of iterating over lists of
layer-surface, menuitems, and so on.
Use node-descriptors for xdg toplevels and popups
2022-02-26 22:35:51 +00:00
Consolatis
a2523081e2
Handle 'lost' unmanaged xsurfaces + improve cursor handling
2022-02-23 21:47:01 +00:00
Consolatis
5862b65f89
Convert SSD to scene nodes
2022-02-23 21:47:01 +00:00
Consolatis
f2d40a8d69
Scene Menu
2022-02-23 21:47:01 +00:00
Consolatis
7ea733761b
Use view->scene_tree as toplevel for view + some legwork:
...
desktop.c move_to_front() calls wlr_scene_node_raise_to_top
desktop.c, ssd/include.h add LAB_SSD_{OSD, MENU, LAYER_SURFACE} enums
desktop.c desktop_surface_and_view_at() -> desktop_node_and_view_at()
cursor.c reenable cursor_rebase()
cursor.c reenable button click on layer surface
2022-02-23 21:47:01 +00:00
Johan Malm
532656ad5b
Use wlroots scene-graph API
...
Move xdg-shell and xwayland-shell surfaces to new API
Also render alt-tab on-screen-display by converting cairo-surface to
wlr_buffer
2022-02-23 21:46:48 +00:00
Consolatis
413811f3a2
Use proper enum argument type for desktop_surface_and_view_at
2022-01-30 21:23:15 +00:00
Johan Malm
2652522a70
cursor: revert 6651d; remove cursor_update_focus()
...
...to ensure new windows receive keyboard focus even if the cursor is
over an existing window.
Fix issue #210
2022-01-24 17:51:54 +00:00
Johan Malm
4964ecd80c
desktop: correctly forward cursor motion-event to layer-popup surfaces
...
...in preference to views and other layer surfaces (except those in the
OVERLAY layer which always go first)
Fixes issue #207 where a BOTTOM layer popup lost mouse focus when a
terminal was behind it.
2022-01-10 18:08:27 +00:00
Johan Malm
a47931bba2
desktop: simplify desktop_focus_and_activate_view()
...
...following view->surface checks in 295d5172
2022-01-02 15:53:05 +00:00
Joshua Ashton
295d5172d4
desktop: Fix activating unmapped views
...
This can happen sometimes in xwayland, need to guard against this.
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-12-31 07:36:25 +00:00
Johan Malm
34a12b3515
Fix coding style
2021-12-26 23:29:01 +00:00
Johan Malm
6651d45ed4
cursor: add cursor_update_focus()
...
...and call it from desktop_move_to_front() in order force an enter event
on the surface below the cursor when cycling views.
Inspired by PR #164 - just restructured it a bit.
Suggested-by: @bi4k8
2021-12-26 22:09:41 +00:00
Johan Malm
238062a859
desktop: rename functions to increase consistency
...
...from
- desktop_raise_view()
- desktop_move_view_to_end_of_cycle()
to
- desktop_move_to_front()
- desktop_move_to_back()
2021-12-06 21:23:49 +00:00
Johan Malm
10884ca2e9
desktop: simplify desktop_move_view_to_end_of_cycle()
2021-12-06 21:07:08 +00:00
bi4k8
7b7178ebfa
move windows to back of cycle when they are minimized
2021-12-06 09:59:06 -05:00
bi4k8
347e6115e3
swallow mouse events only when bindings on Frame mouse contexts are triggered
2021-12-02 17:58:31 +00:00
Johan Malm
d50c2f2eac
Fix minor style violations
2021-11-26 19:27:50 +00:00
John Lindgren
c01d1f124c
Basic support for Move action
...
- Add Move as a default mouse binding for a Titlebar Press action
- Remove the hard-coded handling in cursor_button()
Example config snippet:
<mouse>
<context name="Titlebar">
<mousebind button="Left" action="Press">
<action name="Focus"/>
<action name="Raise"/>
<action name="Move"/>
</mousebind>
</context>
</mouse>
2021-11-26 18:25:04 +00:00
Johan Malm
08a54bd3f5
desktop: use correct coordinates layer_surface_at()
...
Use output coordinates rather than layout coordinates in order to
correctly handle pointer button event on multi-output setup.
2021-10-20 20:57:12 +01:00
Joshua Ashton
846ccb9eb9
action: Implement shift to go backwards in OSD
...
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-18 17:28:34 +01:00
Johan Malm
4d44659c08
desktop: remove deprecated functions
...
- set_activated()
- desktop_set_focus_view_only()
2021-10-16 19:53:00 +01:00
Johan Malm
9a290feeea
desktop: simplify interface for view raise/focus
...
Split desktop_focus_view() into the following two functions:
- desktop_focus_and_activate_view()
- desktop_raise_view()
Always call view_set_activated() rather than using the private
set_activated(). This keeps the code cleaner and ensures
wlr_foreign_toplevel_handle_v1_set_activated() is called.
2021-10-16 19:44:54 +01:00
Johan Malm
1e4598cdce
s/desktop_view_at()/desktop_surface_and_view_at()/
...
Make is clearer what the function does.
2021-09-25 10:04:37 +01:00
Johan Malm
23f28e5082
desktop: desktop_view_at() set *surface correnctly
...
Bug introduced in 23107
2021-09-25 09:40:23 +01:00
Johan Malm
05b89691b0
desktop: fix pointer de-reference typo
...
Bug introduced in 23107
2021-09-25 08:37:24 +01:00
Johan Malm
4c66004fa8
desktop.c: fix typo to compile
2021-09-24 22:13:35 +01:00
Johan Malm
231076a58f
Simplify desktop_view_at()
2021-09-24 22:04:47 +01:00
Johan Malm
ebb632419b
*.c: add SPDX-License-Identifier
2021-09-24 21:45:48 +01:00
Johan Malm
119ef87373
s/focused_view()/desktop_focused_view()
2021-09-20 22:12:34 +01:00
Johan Malm
e4b51fc5e8
desktop.c: make topmost_mapped_view() private
2021-09-20 22:07:19 +01:00
bi4k8
815cd4aa46
define focused_view function and use it for keyboard actions
2021-09-20 21:14:24 +01:00
Johan Malm
a9042e3cde
Fix coding style following 824282dd
2021-08-25 19:59:49 +01:00
Daniel Barlow
39b1d92f9b
implement input_inhibit protocol, needed for swaylock
...
this is in "it appears to work" state, though I blindly copy-pasted a little
more code than I'm happy with, so might benefit from a review
2021-08-22 21:30:42 +01:00
Johan Malm
77ade08158
osd: support 'alt-tab' on screen display
...
The osd window shows title, app_id/class and shell of all views that can
be cycled between.
2021-08-16 07:16:56 +01:00
Johan Malm
9cf0608aba
foreign: handle minimize request
2021-08-05 13:00:34 +01:00
Johan Malm
3bc379cc08
desktop: handle missing output safely
2021-07-19 07:06:36 +01:00
Johan Malm
eaed1a3cab
action: add "Close" to close top-most view
2021-07-12 21:47:27 +01:00
Johan Malm
ee15a5fe56
cursor: handle button press on layer-surface (issue #41 )
2021-07-12 16:44:30 +01:00
Mikhail Kshevetskiy
00db22e44f
focus: add basic follow mouse support
2021-05-28 21:25:19 +01:00
Johan Malm
2a48f2801b
Create a linked list of SSD for each view
2021-03-21 21:46:16 +00:00
Johan Malm
fc76100fd5
Add ssd.h
2021-03-21 20:54:55 +00:00
Johan Malm
a262b729df
Rename deco.c ssd.c
2021-03-20 14:41:39 +00:00