Commit Graph

921 Commits

Author SHA1 Message Date
emersion 41e53d1499
Merge pull request #1019 from emersion/virtual-keyboard-destroy
virtual-keyboard: fix wlr_virtual_keyboard_manager_v1_destroy
2018-05-30 13:51:34 +01:00
emersion 28020ff577
Only allow one modifier per DMA-BUF, split attributes struct in render/ 2018-05-30 09:29:12 +01:00
emersion f580112dca
virtual-keyboard: fix wlr_virtual_keyboard_manager_v1_destroy 2018-05-30 09:25:46 +01:00
emersion 87fe9f3466
Merge pull request #1014 from RyanDwyer/fix-wlr-box-contains-point
Fix wlr_box_contains_point comparison
2018-05-29 19:03:29 +01:00
emersion 2681352e04
export-dmabuf: permanently fail if backend doesn't implement export_dmabuf 2018-05-29 18:47:19 +01:00
emersion a16ad4327a
Update protocol 2018-05-29 18:47:19 +01:00
emersion 65198b0aab
export-dmabuf: assert number of planes 2018-05-29 18:47:19 +01:00
emersion 2432c41a49
export-dmabuf: correctly send the number of planes per layer 2018-05-29 18:47:18 +01:00
emersion 3f9796112e
export-dmabuf: fix tv_sec_hi 2018-05-29 18:47:18 +01:00
emersion 00e108f2fc
export-dmabuf: correctly finish wlr_linux_dmabuf_attribs 2018-05-29 18:47:18 +01:00
emersion 1377e551ef
Update wlr-export-dmabuf protocol 2018-05-29 18:47:18 +01:00
emersion e26f4dff98
export-dmabuf: wait for the frame to be ready, send timestamp 2018-05-29 18:47:17 +01:00
emersion 36bd4795d4
export-dmabuf: add basic and incomplete implementation 2018-05-29 18:47:17 +01:00
emersion 9e26808c28
output, backend/drm: add wlr_output_export_dmabuf 2018-05-29 18:45:45 +01:00
emersion e1f56538a8
Merge pull request #999 from dcz-purism/virtual-keyboard
Support virtual keyboard protocol
2018-05-29 18:22:44 +01:00
Ryan Dwyer f8a831859f Fix wlr_box_contains_point comparison 2018-05-29 23:05:01 +10:00
Dorota Czaplejewicz 5334ee8bfd virtual-keyboard: add support for the virtual-keyboard-v1 protocol 2018-05-28 10:05:55 +02:00
emersion 47f097e09b
xdg-shell: add wlr_xdg_toplevel_set_tiled 2018-05-27 13:38:06 +01:00
emersion da504f9253
surface: remove wl_resource_post_event 2018-05-26 19:43:55 +01:00
emersion e849a68e6e
output: correctly clear screen when fullscreened 2018-05-20 13:44:18 +01:00
Drew DeVault 98088e78df
Merge pull request #977 from emersion/split-xdg-shell
Split xdg-shell into multiple files
2018-05-17 08:14:34 -04:00
emersion c74f5b1138
xdg-output: bump output manager version to 2 2018-05-17 09:30:10 +01:00
emersion 63fd2203fe
Add support for version 2 of the xdg-output protocol 2018-05-17 08:42:59 +01:00
emersion dbba1311b7
output: fix lingering hardware cursors 2018-05-15 18:13:26 +01:00
emersion 3036507463
xdg-shell: split into multiple files 2018-05-14 22:28:45 +01:00
emersion c7480d5084
xdg-shell-v6: rename shared private functions to prevent conflicts with xdg-shell stable 2018-05-14 19:16:46 +01:00
emersion facc5aa359
xdg-shell-v6: split into separate files 2018-05-13 22:32:03 +01:00
emersion cc12d03545
xdg-shell: fix positioner
The anchor and gravity bitfields in xdg-shell-unstable-v6 have
been changed to a plain enum whose values cannot be used as a
bitfield in xdg-shell. While it makes input validation easier, it
also makes positioner operations a pain in the ass.
2018-05-13 09:07:25 +01:00
emersion b28f06eca0
Don't use unsafe casts in wlr_xdg_popup_get_toplevel_coords 2018-05-12 22:53:11 +01:00
emersion 7a952dfa2d
xdg-output: fix logical_size
It should be the size of the output in layout coordinates. Prior to
this commit we were not applying the output transform to the size.
2018-05-12 16:25:52 +01:00
emersion db84379242
Send axis source event 2018-05-12 13:53:21 +01:00
emersion 0b58579564
Add support for discrete axis values 2018-05-12 13:34:58 +01:00
emersion cf5013416d
xdg-output: redesign resource destroy 2018-05-11 22:30:26 +01:00
emersion 13098a18ea
Fix hardware cursors scale & transform 2018-05-09 19:58:18 +01:00
Markus Ongyerth 8931452e1d add wlr_layer_surface_surface_at
Adds wlr_layer_surface_surface_at, this is consistent with the other
shell implementations, and simplifies handling in compositors.
2018-05-08 16:03:10 +02:00
emersion 5087199d5d
output-damage: limit the number of damaged rectangles 2018-05-05 14:28:55 +01:00
emersion caf9f9022c
Merge pull request #936 from emersion/full-hardware-cursors
output: always use hardware cursors if available
2018-05-04 19:00:45 +01:00
emersion 2959fcce1a
Merge pull request #951 from chebykinn/fix-maybe-uninitialized
Fix gcc maybe-uninitialized in wlr_cursor apply_output_transform
2018-05-04 16:56:53 +01:00
Drew DeVault 57d03a3eda
Merge pull request #931 from emersion/redesign-resource-destroy
Redesign resource destruction
2018-05-04 11:48:41 -04:00
Ivan Chebykin cec7cd2b39
Fix gcc maybe-uninitialized in wlr_cursor apply_output_transform 2018-05-04 18:41:51 +03:00
emersion d136026a2c
seat: implement inert seat resources 2018-05-03 22:03:44 +01:00
morganamilo 6305e6327f
Fix typos in comments and strings 2018-05-03 21:59:43 +01:00
emersion 5d37b14116
data-device: make sure resources are correctly destroyed 2018-05-03 20:22:51 +01:00
emersion 7843a48432
output: simplify and update code style 2018-05-03 18:46:17 +01:00
emersion ff4708d406
linux-dmabuf: correctly destroy resources 2018-05-03 18:45:30 +01:00
emersion 6d569def6d
compositor, surface: correctly destroy resources 2018-05-03 18:45:30 +01:00
Drew DeVault 2964248f42
Merge pull request #935 from agx/cursor-output-transform
wlr_cursor: transform absolute coordinates
2018-05-03 07:29:32 -04:00
emersion 2cff6dbd63
seat: split into multiple files 2018-05-03 10:30:47 +01:00
emersion 4b5b02057c
Merge pull request #937 from emersion/reorder-data-device
data-device: split into multiple files
2018-05-03 10:23:08 +01:00
Guido Günther 4efae8c177 wlr_cursor: transform absolute coordinates
Honor output rotation when processing absolute coordinates. This fixes
touch events on rotated outputs.

Fixes #928
2018-05-03 11:09:14 +02:00
emersion 1e563e7ecf
data-device: split into multiple files 2018-05-02 18:04:10 +01:00
emersion 6b3eac37f1
output: assert move_cursor if set_cursor is available 2018-05-02 15:04:35 +01:00
Drew DeVault 8f5045c871 Silently ignore touch_{motion,up} for unknown ids 2018-05-02 08:59:27 -04:00
emersion 225d182765
output: always use hardware cursors if available
This changes the `wlr_output_impl.set_cursor` function to take a
`wlr_texture` instead of a byte buffer. This simplifies the
DRM and Wayland backends since they were creating textures from
the byte buffer anyway.

With this commit, performance should be improved when moving the
cursor since outputs don't need to be re-rendered anymore.
2018-05-01 21:38:04 +01:00
emersion 2551ef8871
input-device: add output_name field, populate it from libinput 2018-04-29 14:30:09 +01:00
Drew DeVault a0f4903063
Merge pull request #926 from emersion/fix-x11-backend-memory-leaks
Fix some backend memory leaks
2018-04-29 08:00:59 -04:00
emersion f8e0a03451
backend/x11: correctly destroy input devices 2018-04-28 12:55:36 +01:00
emersion 79da4c175e
backend/headless: remove useless destructor 2018-04-28 12:48:05 +01:00
emersion 6e7c0b57f6
cursor: use NAN for unspecified axes, refactor absolute warping code 2018-04-28 09:24:38 +01:00
emersion 126f12e428
xdg-shell: fix invalid xdg-positioner cast 2018-04-26 18:53:59 +01:00
emersion 43012f3740
compositor: redesign how resources are managed
All public resource creators now take a new ID for the resource
and an optional list where the resource link is added. When the
resource is destroyed it is its own responsibility to remove
itself from the list. This removes the need for the caller to add
a destroy listener.

This commit fixes a few segfaults with resources not removed from
the list when destroyed.
2018-04-26 17:51:06 +01:00
Drew DeVault 979b1b22d5
Merge pull request #914 from emersion/misc-segfault-fixes
Misc segfault fixes
2018-04-26 17:37:27 +02:00
emersion 874909dca6
xdg-shell: fix invalid wlr_xdg_positioner alloc 2018-04-26 15:59:23 +01:00
emersion fcb7ad925d
layer-shell: fix use-after-free when client requests an invalid layer 2018-04-26 15:58:41 +01:00
Drew DeVault 93ebd33aa8
Merge pull request #890 from agx/layer-shell-empty-output-crash
layer-shell: Fix crash when cursor is intially outside any output
2018-04-26 14:31:35 +02:00
Guido Günther d81f0170a3 layer-shell: Don't crash when the compositor didn't find a suitable output
In that case it must have closed the surface.
2018-04-26 14:08:30 +02:00
Drew DeVault fecb971518
Merge pull request #902 from emersion/various-memory-leaks
Various memory leaks
2018-04-26 11:34:49 +02:00
emersion 449f06556a
Destroy wlr_surface with wlr_renderer 2018-04-26 00:11:36 +01:00
emersion d47713ac0f
compositor: destroy subsurface resources with wlr_subcompositor 2018-04-25 23:53:44 +01:00
emersion 89a9c96fab
compositor: make wlr_compositor_destroy destroy resources 2018-04-25 23:53:44 +01:00
emersion 625a7a48dc
Don't use the wlr_ prefix for static functions 2018-04-25 23:51:00 +01:00
emersion b0d99f5c67
Remove wlr_ prefix from local symbols 2018-04-25 23:00:46 +01:00
emersion 8e2f3056f8
layer-shell: fix small memory leak 2018-04-24 22:40:48 +01:00
emersion bc0bfde5ee
cursor: allow to call wlr_cursor_wrap_absolute with zero 2018-04-24 19:46:29 +01:00
emersion 38064f1d18
Fix protocol error when a client destroys and re-creates a subsurface 2018-04-23 21:50:15 +01:00
Drew DeVault 941f88ce23 Fix popup positioning & double popups 2018-04-23 11:24:06 +02:00
Drew DeVault 52baf3dd8a Move get_geometry call back to xdg-shell 2018-04-23 11:24:06 +02:00
Drew DeVault 0a0627f5d0 Finish forward-porting @acrisci's positioner work 2018-04-23 11:24:06 +02:00
Drew DeVault 2e3d901ac5 Forward-port xdg-shell-v6 positioner improvements 2018-04-23 11:24:06 +02:00
Drew DeVault 278aa84619 Basic layer popup rendering 2018-04-23 11:24:06 +02:00
Drew DeVault d3cdb00208 Add (shitty) support for popups to layer example 2018-04-23 11:24:06 +02:00
Drew DeVault 6b7b64ec1e Generalize xdg-shell popups and add to layer-shell 2018-04-23 11:22:23 +02:00
Drew DeVault 625bc7b8b3 assert(surface->output); after new_surface emit 2018-04-23 10:45:48 +02:00
Drew DeVault 177b548b15 Update layer shell with optional wl_output 2018-04-22 18:57:45 +02:00
emersion 3bce5dfc9f
Fix segfaults in wlr_surface_is_* 2018-04-21 19:04:48 +01:00
emersion bfcd3f3707
Add wlr_subcompositor 2018-04-21 19:02:39 +01:00
emersion fa84b267e0
Remove wlr_surface::subsurface 2018-04-21 18:40:25 +01:00
Markus Ongyerth c8ccb1bef3 reorder xkb state handling in wlr_keyboard
wlr_keyboard manages the xkb-common state of the compositor.
It used to update the state, update the modifiers, then notify the
compositor.
When [Shift_L] was pressed and released, this resulted in an event chain:
  Modifiers: Shift
  Key: Shift_L (Pressed)

  Modifiers:
  Key: Shift_L (Release)

The xkb-docs state that the state should be updated *after* the key was
handled [1], to prevent the new state from influencing the actual key
generated.

To achieve this, the event to the compositor is emitted, *before*
wlroots handles the xkb and internal keyboard state.

With this patch applied, the emitted events ill be:
  Modifiers:
  Key: Shift_L (Pressed)

  Modifiers: Shift
  Key: Shift_L (Release)

[1] https://xkbcommon.org/doc/current/group__state.html#gac554aa20743a621692c1a744a05e06ce
2018-04-18 11:54:59 +02:00
emersion 94fa6c88f4
output: don't emit the mode event if it hasn't changed
This also fixes #535.
2018-04-18 00:15:25 +01:00
emersion 1b802d9251
Make wlr_renderer_scissor take normal coords instead of upside-down ones 2018-04-12 19:38:33 -04:00
Drew DeVault 8f4039d799
Merge pull request #861 from emersion/fix-output-transform-compose
Fix wlr_output_transform_compose
2018-04-12 19:27:57 -04:00
emersion 31c8bdc277
Fix wlr_output_transform_compose 2018-04-12 19:05:05 -04:00
emersion fa0be972bb
Fix wlr_xdg_surface_surface_at for popups 2018-04-12 17:17:32 -04:00
Drew DeVault bef5c1fd56
Merge pull request #850 from emersion/remove-backend-egl
backend: remove wlr_backend_get_egl
2018-04-08 11:21:21 -04:00
emersion d2ebbd103c
backend: remove wlr_backend_get_egl 2018-04-08 11:00:56 -04:00
Drew DeVault bf68854a38 Fix destruction of popups without grabs
Fixes #846
2018-04-07 12:21:21 -04:00
Drew DeVault ae4cef9e41
Merge pull request #825 from emersion/surface-iterators
Add surface iterators
2018-04-05 23:06:29 -04:00
Drew DeVault ec0ce8ae1c Fix sending updates to xdg-output resources
Fixes #836
2018-04-05 18:22:48 -04:00
Drew DeVault 6710de9878 Merge branch 'master' into xwayland-dnd 2018-04-05 15:04:49 -04:00
emersion 4a9a9eae9a
Add surface iterators 2018-04-05 14:18:17 -04:00