Commit Graph

667 Commits

Author SHA1 Message Date
Mike Blumenkrantz ab328c6512 implement support for wl aux hints
this is a direct copy of a feature from tizen git with no modifications other
than what was required for compilation and functionality

https://git.tizen.org/cgit/platform/upstream/enlightenment/commit/?id=8ea090222cee86b57e54f1444c5b63252380fba5
https://git.tizen.org/cgit/platform/upstream/enlightenment/commit/?id=2c5593325c3f32efa92da3c371a780e434a30efd

fix T5780
2017-07-28 15:45:01 -04:00
Mike Blumenkrantz d33351e653 remove wl focus check function
idk what this was for but it was wrong
2017-07-28 15:44:55 -04:00
Mike Blumenkrantz 2b50b69448 Revert "only do configure for wl clients in commit when a buffer is attached"
This reverts commit 9dcc4f632f.

this breaks some corner cases, must investigate further...
2017-07-24 13:24:56 -04:00
Mike Blumenkrantz 9dcc4f632f only do configure for wl clients in commit when a buffer is attached
a null attach does not require a resize, only a hide
2017-07-24 08:26:59 -04:00
Mike Blumenkrantz b472a11f84 ignore wl client ssd mouse events for windows without ssd
ref T5770
2017-07-24 08:12:54 -04:00
Mike Blumenkrantz 66e95311ff only map wl pointer clients if they are the active cursor
ensure cursors which are randomly committed when not being used as
a cursor (e.g., all efl wayland cursors) are not shown

 #TheDisappointer
2017-07-20 17:18:33 -04:00
Mike Blumenkrantz a1d62d01e8 handle multiple input regions for csd clients 2017-07-17 08:14:24 -04:00
Mike Blumenkrantz 0912906ea1 Revert "handle multiple input regions for csd clients"
This reverts commit 950bee7ce4.

accidentally pushed wrong ref, multiple incomplete broken commits were
merged

:(

fix T5739
2017-07-17 08:14:24 -04:00
Mike Blumenkrantz 950bee7ce4 handle multiple input regions for csd clients 2017-07-14 18:40:50 -04:00
Mike Blumenkrantz ac8a9fc2f0 don't set E_Client->want_focus for wl overrides with parents
all input for these goes to the xwl resource anyway, let parent get focus

ref 69c85fc1aa
2017-07-07 16:26:28 -04:00
Mike Blumenkrantz a142a7eb80 focus comp canvas's client when no real client is focused 2017-07-07 16:26:28 -04:00
Mike Blumenkrantz 1b6ccd5aa8 add handler to catch (new) fake elm win wl2 window client
now the compositor canvas has a wl2 window
2017-07-07 16:26:28 -04:00
Mike Blumenkrantz 5df53cec7b process screen events in wl when using fake screens 2017-06-30 10:25:18 -04:00
Mike Blumenkrantz 43dea93969 handle rotations with fake xinerama screens 2017-06-30 10:25:18 -04:00
Mike Blumenkrantz 69c85fc1aa only set E_Client->want_focus for wl override clients if not popup client
do not attempt to focus popups as they are already child windows and thus
do not require keyboard focus
2017-06-30 10:25:17 -04:00
Mike Blumenkrantz 42523d27f0 multiply pointer axis values by 10 for wl clients
wayland clients expect this multiplier, so now scrolling speed should be
back to normal
2017-06-30 10:25:17 -04:00
Derek Foreman 18fbd1da32 Don't delete busy E_Comp_Wl_Buffers
Hardware planes are going to make E_Comp_Wl_Buffer lifetimes harder to
manage, so we need to let the E_Comp_Wl_Buffer object outlive the
resource attached to it.

We already track a busy count, so we just have to use it to prevent
deleting a busy buffer.
2017-06-23 11:52:04 -05:00
Mike Blumenkrantz 773122db66 store output subpixel value to randr2 screen data during drm init 2017-06-16 15:00:12 -04:00
Mike Blumenkrantz d9c03f1059 use fake xinerama screens when initializing wl outputs
always ignore physical screens if fake ones are present
2017-06-16 15:00:12 -04:00
Mike Blumenkrantz 4933569bc1 don't null pointer after deleting internal win during wl delete request
this is invalid during a logout
2017-06-16 15:00:12 -04:00
Mike Blumenkrantz bf157e03dc another fix for e_comp_wl->ptr.x/y coords being wl_fixed instead of ints
ref 2c7e91d38f
2017-06-09 20:18:13 -04:00
Mike Blumenkrantz 9df31011c8 unset wl selection target client if that client is deleted
the frame deletion callback would trigger far too late, allowing
crashes to occur if the selection target client exited between the
time of the drop event and the selection send event
2017-05-12 12:08:37 -04:00
Mike Blumenkrantz b75f0d2be2 unset wl button mask when beginning a move/resize operation
ensure that clients do not receive a release event for any pressed
buttons
2017-05-12 12:08:37 -04:00
Mike Blumenkrantz 6a28856086 remove duplicated client stacking code from wl restack callback
this would always have resulted in double restacking since the client callback
already handles restacks
2017-04-07 16:08:37 -04:00
Mike Blumenkrantz 2ca599b317 apply transient stacking to wl clients when restack would not otherwise occur
ensure that transients are stacked consistently every time
2017-04-07 16:08:37 -04:00
Mike Blumenkrantz c196ef110e re-place transient wl clients when parent is first sized
this should ensure more reliable centering using a nonzero geometry
2017-04-07 16:08:37 -04:00
Mike Blumenkrantz 7fe67cf187 slightly optimize maximize -> fullscreen protocol comms for wl clients
this is a no-op since a configure will be sent later
2017-03-24 13:17:24 -04:00
Mike Blumenkrantz f6e332946c add flag for wl clients to determine ssd mouse-in vs client mouse-in
better handling for moving mouse into ssd region with xwl clients
2017-03-24 13:17:24 -04:00
Mike Blumenkrantz 1be8a5a590 always feed mouse events for wl client move events
better handling for xwayland case of moving pointer into ssd region
2017-03-17 15:08:38 -04:00
Mike Blumenkrantz 7f142f31f5 use even more accurate wl callbacks for detecting ssd mouse in/out events
ensure that any wl client with ssd hits the ssd mouse eventing path
2017-03-17 15:08:38 -04:00
Mike Blumenkrantz a151ac30b8 do not send mouse events to ssd wl clients if mouse is within ssd region 2017-03-17 15:08:38 -04:00
Mike Blumenkrantz f2ab232f3e Revert "Stop sending wayland motion events when the mouse is grabbed"
This reverts commit 0a91a24573.

this should be resolved in a more readable way now
2017-03-17 15:08:38 -04:00
Mike Blumenkrantz 8f197eba71 compare against e_client_action_get() for rejecting wl mouse events
signal actions do not set the cur_mouse_action pointer, but the return
of this function will still match the client for a more accurate heuristic
2017-03-17 15:08:38 -04:00
Mike Blumenkrantz 5a94a95e63 send wl client resize edges during focus-in/out send_configure
avoid prematurely terminating resize operations
2017-03-17 15:08:38 -04:00
Mike Blumenkrantz e23bf0cf68 do not use animations for wl clients with initial maximize state
this looks fugly and breaks all kinds of things
2017-03-17 13:16:59 -04:00
Mike Blumenkrantz 0d8b33c15f use maximized geometry for shell maximize calls on wl clients if !buffer_commit
this is for setting the initial state of a surface as maximized, so do not use
animation geometry here
2017-03-17 13:16:59 -04:00
Mike Blumenkrantz 71c9cedfbf only hide wl clients on surface destroy when surface is mapped
fixes some cases where hide animations would not be visible
2017-03-17 13:16:59 -04:00
Mike Blumenkrantz cc434190ad call wl/x compositor shutdown functions directly during comp shutdown 2017-03-10 15:55:06 -05:00
Mike Blumenkrantz a7f708d568 add wl client flag to indicate status of xdg6 pre-buffer configure
ensure that initial configure is not sent more than once

ref T5044
2017-03-10 15:55:06 -05:00
Mike Blumenkrantz 802136f5f2 do not use saved e_randr screens if fake screens have been added 2017-03-10 15:55:06 -05:00
Mike Blumenkrantz d29fb6b0b5 do not unset E_Client->placed for fullscreen/maximize clients
these are already placed
2017-03-03 10:49:33 -05:00
Mike Blumenkrantz cfb1fa41e6 add all wl client frame callbacks with priority AFTER
ensure that these occur after all other callbacks since they can affect
the lifetime of the client object
2017-03-03 10:49:33 -05:00
Mike Blumenkrantz 504f88d24a hide wl clients before deleting them on surface destroy
==13853== Invalid read of size 8
==13853==    at 0x5C7C56: _e_comp_wl_surface_destroy (e_comp_wl.c:1804)
==13853==    by 0xA999971: destroy_resource (wayland-server.c:611)
==13853==    by 0xA9A06F4: for_each_helper (wayland-util.c:374)
==13853==    by 0xA9A073F: wl_map_for_each (wayland-util.c:387)
==13853==    by 0xA999C87: wl_client_destroy (wayland-server.c:763)
==13853==    by 0xA999216: wl_client_connection_data (wayland-server.c:283)
==13853==    by 0xA99C2B0: wl_event_source_fd_dispatch (event-loop.c:90)
==13853==    by 0xA99CC11: wl_event_loop_dispatch (event-loop.c:423)
==13853==    by 0xA787AC0: _cb_create_data (ecore_wl2_display.c:272)
==13853==    by 0xDBE984D: _ecore_call_fd_cb (ecore_private.h:333)
==13853==    by 0xDBEC01B: _ecore_main_fd_handlers_call (ecore_main.c:1992)
==13853==    by 0xDBEC8A9: _ecore_main_loop_iterate_internal (ecore_main.c:2379)
==13853==    by 0xDBEA672: ecore_main_loop_begin (ecore_main.c:1292)
==13853==    by 0x441DA9: main (e_main.c:1089)
==13853==  Address 0x30ba5d90 is 176 bytes inside a block of size 1,424 free'd
==13853==    at 0x4C2ED4A: free (vg_replace_malloc.c:530)
==13853==    by 0x4603D6: _e_client_free (e_client.c:588)
==13853==    by 0x5475A8: e_object_free (e_object.c:119)
==13853==    by 0x5477C4: e_object_unref (e_object.c:152)
==13853==    by 0x5473D7: e_object_del (e_object.c:60)
==13853==    by 0x5C7C51: _e_comp_wl_surface_destroy (e_comp_wl.c:1803)
==13853==    by 0xA999971: destroy_resource (wayland-server.c:611)
==13853==    by 0xA9A06F4: for_each_helper (wayland-util.c:374)
==13853==    by 0xA9A073F: wl_map_for_each (wayland-util.c:387)
==13853==    by 0xA999C87: wl_client_destroy (wayland-server.c:763)
==13853==    by 0xA999216: wl_client_connection_data (wayland-server.c:283)
==13853==    by 0xA99C2B0: wl_event_source_fd_dispatch (event-loop.c:90)
==13853==    by 0xA99CC11: wl_event_loop_dispatch (event-loop.c:423)
==13853==    by 0xA787AC0: _cb_create_data (ecore_wl2_display.c:272)
==13853==    by 0xDBE984D: _ecore_call_fd_cb (ecore_private.h:333)
==13853==    by 0xDBEC01B: _ecore_main_fd_handlers_call (ecore_main.c:1992)
==13853==    by 0xDBEC8A9: _ecore_main_loop_iterate_internal (ecore_main.c:2379)
==13853==    by 0xDBEA672: ecore_main_loop_begin (ecore_main.c:1292)
==13853==    by 0x441DA9: main (e_main.c:1089)
==13853==  Block was alloc'd at
==13853==    at 0x4C2FA50: calloc (vg_replace_malloc.c:711)
==13853==    by 0x5471A4: e_object_alloc (e_object.c:20)
==13853==    by 0x467AD5: e_client_new (e_client.c:2596)
==13853==    by 0x5C7F11: _e_comp_wl_compositor_cb_surface_create (e_comp_wl.c:1858)
==13853==    by 0xADBDC57: ffi_call_unix64 (in /usr/lib64/libffi.so.6.0.2)
==13853==    by 0xADBD6B9: ffi_call (in /usr/lib64/libffi.so.6.0.2)
==13853==    by 0xA99EEED: wl_closure_invoke (connection.c:935)
==13853==    by 0xA999581: wl_client_connection_data (wayland-server.c:371)
==13853==    by 0xA99C2B0: wl_event_source_fd_dispatch (event-loop.c:90)
==13853==    by 0xA99CC11: wl_event_loop_dispatch (event-loop.c:423)
==13853==    by 0xA787AC0: _cb_create_data (ecore_wl2_display.c:272)
==13853==    by 0xDBE984D: _ecore_call_fd_cb (ecore_private.h:333)
==13853==    by 0xDBEC01B: _ecore_main_fd_handlers_call (ecore_main.c:1992)
==13853==    by 0xDBEC8A9: _ecore_main_loop_iterate_internal (ecore_main.c:2379)
==13853==    by 0xDBEA672: ecore_main_loop_begin (ecore_main.c:1292)
==13853==    by 0x441DA9: main (e_main.c:1089)
2017-03-03 10:49:33 -05:00
Mike Blumenkrantz 58f7d7e54e do not shortcut wl surface commit unignore path for internal wins
this doesn't seem to do anything and therefor is not worthwhile
2017-02-24 14:15:38 -05:00
Mike Blumenkrantz b0cb4b38d6 redo wl client setting of E_Client->take_focus and E_Client->want_focus
this used to be set on show since the assumption was that show was the
first time the client would be seen, but this turns out to be incorrect
and results in focus being set too early (breaking policy)
2017-02-24 14:15:38 -05:00
Mike Blumenkrantz e7539003ba unadjust wl surface coords before applying position during commit
this seems to fix some positioning issues with internal wins
2017-02-24 14:15:38 -05:00
Mike Blumenkrantz a117c977dd e_menu_grab_window_get() -> e_menu_is_active()
0 is a valid canvas window id, and this function was no longer being used
for its original purpose
2017-02-24 14:15:38 -05:00
Mike Blumenkrantz 8f3c9dd796 do not use new_client to determine placement-related paths during wl client commit
this is a remnant from xdg5-only code where new_client meant "first buffer". with
xdg6, this is no longer the case since a surface can receive infinite commits
without ever having a buffer attached

ref 9a82f7bcb0
2017-02-10 17:24:13 -05:00
Mike Blumenkrantz d6052cbbfd unignore wl clients on first commit regardless of buffer attachment
this allows for things to begin catching "new" clients as soon as possible
in the compositor
2017-02-10 17:24:13 -05:00
Mike Blumenkrantz 7c118eb272 use E_Client->changes.size for validating wl client geom during configure
xdg6 allows for clients without buffers to be configured such that the
first buffer will match the configured state

if a client is sized before this point, the changes.size flag will be set
2017-02-10 17:24:13 -05:00