Commit Graph

1104 Commits

Author SHA1 Message Date
Isaac Freund
684f26acac
river: improve comments on pending/inflight/current 2023-03-06 16:30:42 +01:00
Isaac Freund
05e8fbc8b9
wlr-foreign-toplevel-management: implement protocol
Well, at least as much of it as was implemented before the scene graph
refactor.
2023-03-06 12:58:54 +01:00
Isaac Freund
f21eb4d05b
Xwayland: only raise views if activated 2023-03-06 10:08:10 +01:00
Isaac Freund
b7b371cb4f
pointer-constraints: implement protocol
Now with 50% less pointer warping!

The new implementation requires the user to move the cursor into the
constraint region before the constraint is activated in order to keep
behavior more predictable.
2023-03-05 23:11:54 +01:00
Isaac Freund
1602b34f4f
Seat: use the grab aware API to clear focus
This looks to be a typo made way back in the early days of river.
2023-03-05 13:37:57 +01:00
Isaac Freund
db726718ef
Cursor: use pending position to warp during move 2023-03-05 09:44:14 +01:00
Isaac Freund
cc2b38af92
presentation-time: support protocol 2023-03-04 23:06:41 +01:00
Isaac Freund
b6ac1021ae
Server: remove headless backend
This was previously used to create a noop output, but we no longer rely
on that hack.
2023-03-04 23:02:52 +01:00
Isaac Freund
44004e2d28
SceneNodeData: allow access from wlr_surfaces
This replaces the old View.fromWlrSurface function and is more general.

This commit also moves the xdg activation request_activate listener to
Server as it has no reason to be in View.
2023-03-04 22:41:35 +01:00
Isaac Freund
ea4e589fdc
river: clean up some uneeded TODOs 2023-03-04 20:58:02 +01:00
Isaac Freund
f5f9b526a0
river: fix a few leaks 2023-03-04 20:12:37 +01:00
Isaac Freund
4d2f5bb32d
Cursor: store offset and warp cursor during move
This is more reliable since it uses absolute coordinates instead of a
relative movement which could cause the cursor position to get out of
sync with the view.

This is the same approach used for resize.
2023-03-04 19:17:18 +01:00
Isaac Freund
b4ae62cd40
View: rework configure abstraction
- Move the decision whether a configure should be tracked or not into
the xdg toplevel/xwayland code.

- Only track configures for xdg toplevels with the transaction system
if the dimensions of the view are affected.
2023-03-04 16:03:16 +01:00
Isaac Freund
915fb7ae7b
xdg-shell: honor client move/resize requests 2023-03-03 20:13:06 +01:00
Isaac Freund
c29153255c
Cursor: allow resizing from all edges
Co-authored-by: Leon Henrik Plickat <leonhenrik.plickat@stud.uni-goettingen.de>
2023-03-03 20:13:06 +01:00
Isaac Freund
8d9b6ab99e
deps: update zig-wlroots to fix Xwayland crash 2023-03-03 15:50:24 +01:00
Isaac Freund
4a9d84bdb8
Xwayland: hide override redirect windows if locked 2023-03-03 15:21:54 +01:00
Isaac Freund
0be43ad45f
Root: keep all fullscreen views the correct size
Currently we may resize fullscreen views when they become visible/not
visible when switching tags even if their fullscreen state remains
constant. This is suboptimal, and as it turns out also much more complex
to implement.
2023-03-03 13:40:44 +01:00
Isaac Freund
9ce1847d32
XdgToplevel: fix size_changed check on commit
We need to initialize the geometry on map to ensure the first commit is
handled correctly.

Also we don't care about the x/y of the geometry, only the width/height.
2023-03-02 19:24:54 +01:00
Isaac Freund
56e4efe68d
Xwayland: fix has_fixed_size heuristic for floating 2023-03-02 17:11:32 +01:00
Isaac Freund
9bfa0ece23
View: handle destroy during inflight layout demand 2023-03-02 16:42:16 +01:00
Isaac Freund
686ef11fc8
river: render floating views above the layout 2023-03-02 15:10:10 +01:00
Isaac Freund
ecb959f068
View: fix frame perfection on unmap 2023-03-01 23:04:42 +01:00
Isaac Freund
83fe764fcd
View: only send configures through transactions
This reduces the number of separate configure events sent to clients
through better batching and is also more correct.
2023-03-01 20:44:13 +01:00
Isaac Freund
ed0aa73670
Output: fix background of transformed outputs 2023-03-01 19:40:37 +01:00
Isaac Freund
b1540e2d94
Root: fix use of view.current before update
In commitTransaction() we currently the current view state to determine
whether or not to enable the view's scene tree. However we don't update
the view's current state until after that check.
2023-03-01 19:03:16 +01:00
Isaac Freund
bf759c7c57
View: clamp to output on exiting float/fullscreen 2023-03-01 17:13:14 +01:00
Isaac Freund
50513390ce
View: move borders state to State struct
This state affects rendering, so it should pass through the transaction
system like the rest.
2023-03-01 16:12:27 +01:00
Isaac Freund
c1c72e23a3
Root: fix more fullscreen bugs
Moving fullscreen views between outputs now works properly.
A case in which we did not inform the client that it is no longer
fullscreen has been fixed as well.
2023-03-01 12:16:53 +01:00
Isaac Freund
5f0af38992
session-lock: fix race with multiple outputs
The race is as follows:
1. Output A commits and sets render state to pending_lock_surface
2. Output B commits and sets render state to pending_lock_surface
3. Output A presents and sets render state to lock_surface
4. maybeLock() does not lock because waiting on output B
5. Output A commits and sets render state to pending_lock_surface
6. Output B presents and sets render state to lock_surface
4. maybeLock() does not lock because waiting on output A
2023-03-01 11:33:26 +01:00
Isaac Freund
472f882f42
Output: inline renderOutput function
Having this in a separate file no longer makes sense since the switch to
the scene graph.
2023-03-01 11:32:04 +01:00
Isaac Freund
6411c71151
Root: centralize focus(null) calls in applyPending() 2023-03-01 10:49:44 +01:00
Isaac Freund
07154720fa
csd-filter-add/remove: add missing applyPending()
A transaction is now necessary to update border state.
2023-02-28 23:00:02 +01:00
Isaac Freund
8cb5ca9041
river: fix various fullscreen related bugs 2023-02-28 22:56:12 +01:00
Isaac Freund
e11d4dc0de
LayerSurface: fix use-after-free on destroy
The scene_layer_surface may be destroyed before handleDestroy is called,
which means we can't rely on it to access the wlr_layer_surface in
destroyPopups().
2023-02-28 18:28:17 +01:00
Isaac Freund
005bde367c
OutputStatus: rework implementation
This was motivated by the view tags not being proplerly updated by
Root.commitTransaction() when there were no views on an output.
2023-02-28 18:28:17 +01:00
Isaac Freund
be4330288d
river: rework core data structures & transactions 2023-02-28 18:28:17 +01:00
Isaac Freund
f5dc67cfc1
View: use saved surface trees for transactions 2023-02-28 14:55:59 +01:00
Isaac Freund
ce7fda4ed9
Xwayland: render using the scene graph 2023-02-28 14:55:59 +01:00
Isaac Freund
0b2272ec57
DragIcon: render using the scene graph 2023-02-28 14:55:58 +01:00
Isaac Freund
0e0b585c44
xdg-shell: implement version 5 2023-02-28 14:55:58 +01:00
Isaac Freund
879b880a6a
XdgPopup: reimplement using the scene graph
xdg-shell version 3 is now implemented, supporting popup repositioning.
2023-02-28 14:55:58 +01:00
Isaac Freund
dbcb75dddb
LayerSurface: render using the scene graph
This also brings a lot of code cleanup and proper support for
version 4 of the protocol.
2023-02-28 14:55:58 +01:00
Isaac Freund
85843dd5c7
View: remove dead code
wl_output.enter/leave is handled by wlr_scene now.
2023-02-28 14:55:58 +01:00
Isaac Freund
1b57fe0aa7
Xwayland: create scene tree 2023-02-28 14:55:58 +01:00
Isaac Freund
a545a06c5b
View: implement borders with scene graph 2023-02-28 14:55:58 +01:00
Isaac Freund
f4a8d6dcc9
Output: use separate scene trees for layers 2023-02-28 14:55:58 +01:00
Isaac Freund
b38676f078
session-lock: use the scene graph 2023-02-28 14:55:58 +01:00
Isaac Freund
683ed0f04e
Cursor: remove surfaceAt()
We now use the wlr_scene API to find out what is at the cursor location.
2023-02-28 14:55:58 +01:00
Isaac Freund
4f0ce8fceb
render: use wlr_scene to render views 2023-02-28 14:55:58 +01:00