Commit Graph

18875 Commits

Author SHA1 Message Date
Derek Foreman 89e0308fd2 Clear stored root window id when shutting down X
Currently e_comp_util_has_x() will still return true after the X
machinery is shut down - this can lead to crashes on logout under
wayland when xwayland apps are running.  Clearing the root window
id resolves this.

@ref T5593
2017-10-31 12:10:50 -04:00
Mike Blumenkrantz fb5922e97c move x11 compositor cleanup into shutdown function 2017-10-31 12:10:41 -04:00
Derek Foreman 384a71c658 Fix xwayland related crash when mousing out of a window
XWayland likes to set a buffer on the cursor surface then delete it before
we release it.  I'm pretty sure when a client does that we're within spec
to just kill it, but users will likely find this response ungratifying.

So, instead, just gracefully fail to render the undefined surface.

@ref T5593
2017-10-31 12:10:36 -04:00
Mike Blumenkrantz 6c3c7325db cancel wl selections after removing destroy listener
cancel may destroy the selection source, resulting in invalid access

==10735== Invalid write of size 8
==10735==    at 0x87C8095: wl_list_remove (wayland-util.c:56)
==10735==    by 0x2EE745: _e_comp_wl_data_device_selection_set (e_comp_wl_data.c:506)
==10735==    by 0x2EF241: _e_comp_wl_data_device_cb_selection_set (e_comp_wl_data.c:714)
==10735==    by 0x1021F037: ffi_call_unix64 (in /usr/lib/x86_64-linux-gnu/libffi.so.6.0.4)
==10735==    by 0x1021EA99: ffi_call (in /usr/lib/x86_64-linux-gnu/libffi.so.6.0.4)
==10735==    by 0x87C70C0: wl_closure_invoke (connection.c:935)
==10735==    by 0x87C13C8: wl_client_connection_data (wayland-server.c:406)
==10735==    by 0x87C4483: wl_event_source_fd_dispatch (event-loop.c:90)
==10735==    by 0x87C4DE4: wl_event_loop_dispatch (event-loop.c:423)
==10735==    by 0x85AE346: _cb_create_data (ecore_wl2_display.c:399)
==10735==    by 0x946857A: _ecore_call_fd_cb (ecore_private.h:347)
==10735==    by 0x946AE51: _ecore_main_fd_handlers_call (ecore_main.c:2015)
==10735==    by 0x946B823: _ecore_main_loop_iterate_internal (ecore_main.c:2403)
==10735==    by 0x946935E: ecore_main_loop_begin (ecore_main.c:1308)
==10735==    by 0x151139: main (e_main.c:1088)
==10735==  Address 0x222ca980 is 16 bytes inside a block of size 136 free'd
==10735==    at 0x4C2CE1B: free (vg_replace_malloc.c:530)
==10735==    by 0x2F076F: e_comp_wl_clipboard_source_unref (e_comp_wl_data.c:1291)
==10735==    by 0x214C6A09: _xwayland_send_cancelled (dnd.c:149)
==10735==    by 0x2EE71D: _e_comp_wl_data_device_selection_set (e_comp_wl_data.c:504)
==10735==    by 0x2EF241: _e_comp_wl_data_device_cb_selection_set (e_comp_wl_data.c:714)
==10735==    by 0x1021F037: ffi_call_unix64 (in /usr/lib/x86_64-linux-gnu/libffi.so.6.0.4)
==10735==    by 0x1021EA99: ffi_call (in /usr/lib/x86_64-linux-gnu/libffi.so.6.0.4)
==10735==    by 0x87C70C0: wl_closure_invoke (connection.c:935)
==10735==    by 0x87C13C8: wl_client_connection_data (wayland-server.c:406)
==10735==    by 0x87C4483: wl_event_source_fd_dispatch (event-loop.c:90)
==10735==    by 0x87C4DE4: wl_event_loop_dispatch (event-loop.c:423)
==10735==    by 0x85AE346: _cb_create_data (ecore_wl2_display.c:399)
==10735==    by 0x946857A: _ecore_call_fd_cb (ecore_private.h:347)
==10735==    by 0x946AE51: _ecore_main_fd_handlers_call (ecore_main.c:2015)
==10735==    by 0x946B823: _ecore_main_loop_iterate_internal (ecore_main.c:2403)
==10735==    by 0x946935E: ecore_main_loop_begin (ecore_main.c:1308)
==10735==    by 0x151139: main (e_main.c:1088)
==10735==  Block was alloc'd at
==10735==    at 0x4C2DC05: calloc (vg_replace_malloc.c:711)
==10735==    by 0x2F0520: e_comp_wl_clipboard_source_create (e_comp_wl_data.c:1231)
==10735==    by 0x214C71C9: _xwl_selection_notify (dnd.c:286)
==10735==    by 0x946130C: _ecore_call_handler_cb (ecore_private.h:331)
==10735==    by 0x94626BC: _ecore_event_call (ecore_events.c:629)
==10735==    by 0x946B83E: _ecore_main_loop_iterate_internal (ecore_main.c:2408)
==10735==    by 0x946935E: ecore_main_loop_begin (ecore_main.c:1308)
==10735==    by 0x151139: main (e_main.c:1088)
2017-10-31 12:10:21 -04:00
Mike Blumenkrantz 32b2561306 null wl clipboard+selection source pointers when destroying clipboard source
fix T6242
2017-10-31 12:10:16 -04:00
Mike Blumenkrantz 2afb298b75 set null input regions for surfaces upon calling set_cursor or start_drag
these surfaces have no input region according to spec
2017-10-31 12:10:12 -04:00
Mike Blumenkrantz d15c72417c ignore set_input_region requests for wl surfaces which are cursors or drags
according to spec this is correct behavior
2017-10-31 12:10:08 -04:00
Mike Blumenkrantz 854ead5027 do not unqueue render when deleting a client's render update
a render loop may run for reasons other than rendering a specific client
2017-10-31 12:10:02 -04:00
Mike Blumenkrantz 01de5c785f add client refs for the nocomp client
this client may be referenced after deletion during render loop

fix T6151
2017-10-31 12:09:57 -04:00
Carsten Haitzler b6df125850 battery modules - actually set ac power flag based on ac presence
this should fix T3649

@fix
2017-10-31 12:09:15 -04:00
Mike Blumenkrantz e5362e3f4a add render update when showing clients if damages exist
ensure that these clients render as expected

ref T5593
2017-10-31 12:08:41 -04:00
Mike Blumenkrantz 716ab4b43f recreate x11 root pointer when changing application<->enlightenment theme
force new visual to be applied immediately instead of requiring a compositor
restart
2017-10-12 10:47:28 -04:00
Mike Blumenkrantz 6b0b742ace always use e cursor theme for canvas pointers
canvas pointer = wl compositor pointer = always use e theme since there is no
loader for x11 cursors
2017-10-12 10:47:22 -04:00
Mike Blumenkrantz 1e1129e006 check for non-wl compositor when forcing application cursors onto pointers
comp_type is not set during initial pointer creation on startup but will be set at
the point of xwl startup, so use a check which will succeed

fix T6157
ref 2b8c70fe98
2017-10-12 10:47:17 -04:00
Mike Blumenkrantz ce0e22b131 move cursor theme options into separate frame 2017-10-12 10:45:50 -04:00
Mike Blumenkrantz 0710965e1f do not show cursor theme options in wayland compositor mode
this isn't how wayland works, so don't let users footgun themselves
2017-10-12 10:45:45 -04:00
Mike Blumenkrantz 8a97b08145 move 'show cursor' option in mouse settings inside frame 2017-10-12 10:45:42 -04:00
Mike Blumenkrantz 440157e108 Revert "disable option for mouse to use Application theme if we are running in Wayland"
This reverts commit 9e3b8b7528.

this only affects runtime in wayland-only environments while not preventing the option
from taking effect, meaning it affects nobody and prevents nothing
2017-10-12 10:45:38 -04:00
Mike Blumenkrantz c0265690a5 set default cursor on root window for xwl pointer
ref T5593

 #TheDisappointer
2017-10-12 10:45:31 -04:00
Mike Blumenkrantz eb20eb1bd9 handle x11 shaped input under xwayland 2017-10-12 10:45:25 -04:00
Mike Blumenkrantz ccf5a29e47 add max size input rects for wl clients on creation
according to spec, surfaces begin with infinite input area
2017-10-12 10:45:21 -04:00
Mike Blumenkrantz 28b19e8a2e set comp object alpha state when applying native surface
ensure that alpha is set accurately for the native surface
2017-10-12 10:45:12 -04:00
Mike Blumenkrantz cf97d96f22 block gadget configuration unconditionally while desklock is active 2017-10-12 10:45:06 -04:00
Mike Blumenkrantz 613ff4f496 deduplicate global gadget handler variables
ref T6125, T4648
2017-10-12 10:45:00 -04:00
Mike Blumenkrantz 40f7047745 redo bryce eventing
post events are way harder and I don't know why I didn't do this in the
first place?

fix T5974
2017-10-12 10:44:54 -04:00
Mike Blumenkrantz b383539a27 do ecore-x shutdown on xwayland shutdown 2017-10-12 10:44:50 -04:00
Mike Blumenkrantz d84cdbc4e9 defer wl startup apps until after xwayland init completes
startup apps may require x11 connections, so ensure this is available

fix T6122
2017-10-12 10:43:48 -04:00
Mike Blumenkrantz 8e6a91fd9c don't show xwayland clients unconditionally on commit
ensure that the client's desk is visible

fix T6024
2017-10-12 10:43:42 -04:00
Stephen 'Okra' Houston f8743ae323 E Exe: Semi revert 2082bb51d3. The ref count was off to begin with. 2017-10-12 10:43:04 -04:00
Mike Blumenkrantz 689ad82857 emit E_EVENT_EXEC_NEW_CLIENT with phony exes
partially fix T6071
2017-10-12 10:43:04 -04:00
Mike Blumenkrantz 69593aa4be use client geometry for visibility effect geometry, not comp object geometry
clients may defer object geometry setting, resulting in unreliable values here
2017-10-12 10:43:04 -04:00
Mike Blumenkrantz a678414abb remove input-only client fastpath to resize crashes
ref T6023
2017-10-12 10:43:04 -04:00
Mike Blumenkrantz 42e720a7ed don't perform zone updates on client resize
zone updates should probably only happen on client moves, not resizes

ref T6023
2017-10-12 10:39:34 -04:00
Chidambar Zinnoury 3a3b78a58f e menu: Fix missing realize when using key-activation to the right.
See commit 474463ef6c, SVN r39698.
2017-10-12 10:39:26 -04:00
Carsten Haitzler 09ef528897 tiling - ensure notification struct is 0'd before use
this should fix the last 3 crashdumps reported in T6023

@fix
2017-10-12 10:39:16 -04:00
Mike Blumenkrantz e8e93eaa7d remove fdo interfaces from music control dbus xml 2017-10-12 10:38:48 -04:00
Mike Blumenkrantz 2ffa0f23dc fix clickable edge binding activation with other mouse buttons
check for the button specified in the binding, not whether the event
contains a click

fix T4510
2017-10-12 10:38:23 -04:00
Mike Blumenkrantz 8a7ee06aab flag zone/edge mouse binding activation with ON_HOLD
ensure multiple bindings aren't triggered by the same event
2017-10-12 10:37:34 -04:00
Mike Blumenkrantz 0bbd01b6db handle unmovable gadgets in gadget move action
a gadget which refuses to create a duplicate of itself can be considered
immobile

fix T5998
2017-10-12 10:37:29 -04:00
Mike Blumenkrantz 4432299947 block recursive mouse eventing in bryce action handlers
ensure that only the outermost event adds a post callback to avoid
triggering actions multiple times
2017-10-12 10:37:23 -04:00
Mike Blumenkrantz 72144e49c1 hide clients again after show in idler if clients are on hidden desk
clients need initial show to correctly handle mirror visibility but should
then be hidden again

ref 0ee8cc896e
fix T6024
2017-10-12 10:36:59 -04:00
Mike Blumenkrantz 667cb72323 use EC_CHANGED when setting changed flag in client idler 2017-10-12 10:36:53 -04:00
Mike Blumenkrantz 301edff286 resolve desktop spec issues with emixer.desktop
fix T5076
2017-10-12 10:36:31 -04:00
Carsten Haitzler d8753a3c72 e start - fix path prepend/append if already in path assuming clue
"
I have a directory at the head of my PATH that contains alternate
versions of command line utils like grep, ls, etc., but E puts
/usr/bin ahead of it, overriding my tools of choice with the system
defaults.

If my understanding is correct, the only way currently to have
directories that E prepends to your PATH appended instead is to use
-i-really-know-what-i-am-doing-and-accept-full-responsibility-for-it.
I'd like to see a more sane option if there isn't one already.
Alternatively, I wonder if it wouldn't be a better idea to only
prepend directories to PATH if they aren't already contained within
it--thereby preserving the user's desired search order.
"

this should fix T5953

@fix
2017-10-12 10:36:25 -04:00
Mike Blumenkrantz 82e095e8b0 handle shade <-> unshade toggling in same frame
this should result in a no-op instead of a fail-op

fix T6006
2017-10-12 10:35:38 -04:00
Mike Blumenkrantz 378b49f7c5 use animator del function to delete comp object animators 2017-10-12 10:35:30 -04:00
Carsten Haitzler 6ddf1ee961 fix up window+screen positioning fixup so it doesnt catch other clients
so some other clients like mpv also try to explicitly position their
windows (like centering on screen 0 ALWAYS) and this now gets caught
up in trying to detect libreoffice doing the same thing for
presentations. so only support this is the app has explicitly
requested initial positionin explicitly and then use pending configures.
2017-10-12 10:34:26 -04:00
Derek Foreman 8ca6f02914 Fix crash when processing a wayland client cursor set after death
It looks like the only way we can get here with NULL resource data
is when we explicitly cleared it in the del hook, meaning the client
is dead to us.  In this case it's ok to ignore the cursor set request.

ref T4988
2017-10-12 10:33:39 -04:00
Mike Blumenkrantz e2d35d9b77 remove fullscreen clients from vdesk clients list when toggling sticky state
fix T5988
2017-09-07 14:16:01 -04:00
Mike Blumenkrantz 7af9ab44a6 handle first time desk setting for fullscreen clients without crashing
ref T5988
2017-09-07 14:15:57 -04:00