Commit Graph

18910 Commits

Author SHA1 Message Date
Chris Michael 6b56465bac use a new e_pointer for the window canvas
This fixes an issue where internal dialogs were not using the e
cursors but would default back to an x cursor

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 14:36:57 -04:00
Chris Michael 7840d11459 be sure to send the wl_data_device_send_enter when changing surface
focus and add some more debugging for dnd

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 14:11:28 -04:00
Chris Michael 78bcbfff35 trap return value of shm_buffer_get
This function Can fail to return an shm_buffer if the buffer_resource
is an EGL buffer.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 14:06:57 -04:00
Chris Michael 559d53bc5d Add checks for client being a wl pixmap in some functions
If we don't do this, then when we run in X11 with wl client support,
we crash in various places (iconify, etc) when trying to work with
normal X clients.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:39 -04:00
Chris Michael 4bc11ee5d5 fix dereference of incomplete pointer type
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:39 -04:00
Chris Michael b10c0d91ab Fix formatting
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:39 -04:00
Chris Michael 31e38208b4 wl-x11: Declare keyboard strings as NULL (initially) to avoid crash
when updating keymap

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:39 -04:00
Mike Blumenkrantz f56a08fc6c move wl client_resize protocol calls to idler 2014-08-26 10:10:39 -04:00
Mike Blumenkrantz e7a0b193f3 automatically enable pointer and keyboard for wayland-in-X 2014-08-26 10:10:38 -04:00
Mike Blumenkrantz 362a9b6cce reuse existing render post callback for wayland clients 2014-08-26 10:10:38 -04:00
Chris Michael d9cdcdbef4 Fix elm apps crashing from invalid e_remember
Don't set changes.icon during surface creation. There are functions
that get called when icccm.class changes and That is the place to set
changes.icon.

Signed-off-by: Chris Michael <cp.michael@samsung.com>

Additional authors: zmike
2014-08-26 10:10:38 -04:00
Chris Michael 8fa7e4f59d Fix inproper setting of window type during transient_set.
This fixes the issue of some wayland applications always showing up
with the e_border visible.

If we get a transient_set from wl_shell or xdg_shell, don't reset the
client's netwm.type. Some wayland applications are sending us
transient_set with parent to NULL....so don't explicitly set the
netwm.type to dialog.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael 4066cf2ca9 Reduce usage of EC_CHANGED.
Lock subsurface border type to borderless.
Remove commented out code.
Don't mark border.changed during pre_frame callback.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael 6485968ca0 reorder client idler and stacking functions so we can call them after
post_move.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael a15eaa46c4 Reduce potential of unnecessary function calls:
- When we are doing client eval, don't check for Just changes in
property OR fetching. Rather we will check using an AND.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael c93ea90edf Simplify both transient_set functions (wl_shell and xdg_shell).
Remove debugging noise.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael dba9916abe Remove NULL checks for valid client->comp_data ... let the crashing begin !!
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael 201918eca8 Add ERR messages for EINTERN & EAPI functions.
Remove NULL checks ... let the crashing begin !!

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael d1e4cf0be8 Add error messages in EINTERN & EAPI functions.
Remove NULL checks ... let the crashing begin !!

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
MinJeong Kim 6b808e2f3f Remove unwanted NULL check in internal function
Summary: Remove unwanted NULL check in internal function.

Reviewers: gwanglim, devilhorns, zmike

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1250
2014-08-26 10:10:38 -04:00
Seunghun Lee 89b2881476 clear parent's list of transients, when set parent to NULL.
Summary: we also need to clear parent's resource.

Test Plan: N/A

Reviewers: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1238
2014-08-26 10:10:38 -04:00
Chris Michael 814b50f7e6 wl-desktop-shell: Avoid runtime ERR noise for something that is not
really an error.

When we call shell_surface_parent_set with a NULL parent resource,
then there is No reason to try and find the pixmap window of a NULL
parent. Avoid that function call and just set the appropriate
properties and get out.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Mike Blumenkrantz 3b649534c9 Fix building Enlightenment for X11-only, Wayland-Only, and X11 with Wayland clients.
Signed-off-by: Chris Michael <cp.michael@samsung.com>

Additional authors: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael 5448f0a1ac handle setting any pending opaque regions during surface commit and
cleanup the input region code also

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael bb64229ae9 fix return variable type from e_pixmap_window_get function
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael 0ba4fecd76 change client transient_for id to uint64_t
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Chris Michael 07b6052db1 wl_drm: Add short block to mark setup for drm egl rendering
When the new drm hw accel engine is ready, we can replace this little
bit of code and have hardware-accelerated drm.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
MinJeong Kim f0ba92d39e Add simple clipboard based on wayland protocol
Summary:
Whenever any client requests new selection_set,
the data is saved to server-side clipboard directly on this revision.
So data device is able to keep data which is copied from client app have closed already
and is able to provide those data to new focused surface before coming new selection_set request.

Reviewers: devilhorns

Subscribers: cedric, gwanglim

Differential Revision: https://phab.enlightenment.org/D1165
2014-08-26 10:10:38 -04:00
Seunghun Lee 1370d6bd32 Implement wayland subsurface support based on E_Client.
Summary: Support subsurface interface of wayland.

Test Plan:
1. Build enlightenment on devs/devilhorns/e_comp_wl branch.
2. Run enlightenment.
3. Run weston-subsurfaces
   - should be built after removing code of gl surface (not yet implemented)
   - just comment out the line egl_state_create in function of demoapp_create()

Reviewers: gwanglim, devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1182
2014-08-26 10:10:38 -04:00
Gwanglim Lee a96d7290f5 Add missing wl_resource_destroy
Summary:
There are no resource free codes in xdg shell destroy handler
and xdg popup destroy handler. e should delete wayland resource as
client requested.

Test Plan:
1. run e as wayland server
2. run weston-stacking in e
3. click with right mouse button to create xdg popup surface
4. click main surface area to delete xdg popup surface

Reviewers: devilhorns, zmike, raster

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1196
2014-08-26 10:10:38 -04:00
Chris Michael 7418547f76 Don't run xrdb or xmodmap when we are wayland only
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:38 -04:00
Seunghun Lee e5f293214d move the part of code for fetch transient_for in eval time to _e_shell_surface_parent_set().
Summary:
we need to set ec->parent before eval time.
that's because client can request to commit surface calling shell.configure() before eval time.
in this case, ec->parent isn't set yet, configure(move) will be failed.

in order to fix it, we have to set ec->parent in _e_shell_surface_parent_set() before eval time,
but we should check if ec already have parent, and if so, remove its parent's transients before change the value of ec->parent.

Test Plan: N/A

Reviewers: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1177
2014-08-26 10:10:38 -04:00
Gwanglim Lee 6248f11b80 remove EINA_UNUSED in move and resize callbacks
Summary: remove EINA_UNUSED from used function parameters

Test Plan: N/A

Reviewers: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1173
2014-08-26 10:10:38 -04:00
MinJeong Kim 2799388093 Fixed trying to create damage area with 0x0 size
Summary:
This revision fixed failure to create damage area using Eina_Tiler on surface damage callback.
It was caused by trying to create Eina_Tiler with 0x0 size which is from size of E_Client.

Test Plan:
1. Run elementary_test.
2. Select one of the test apps.(no more magic fail message)

Reviewers: zmike, devilhorns

Reviewed By: devilhorns

Subscribers: cedric, gwanglim

Differential Revision: https://phab.enlightenment.org/D1171
2014-08-26 10:10:38 -04:00
Seunghun Lee 4152e1e2dd remove setting ec->parent before evaluation.
Summary:
the value of "ec->parent" should be set in evaluation time,
therefore ec->parent->transients will be reset automatically.

Reviewers: devilhorns

CC: cedric

Differential Revision: https://phab.enlightenment.org/D1155
2014-08-26 10:10:37 -04:00
MinJeong Kim ed16127395 Add focus surface setting of keyboard for copy and paste between clients
Summary:
To enable copy and paste between clients,
wayland data device requires to know what surface is focused.
So this revision have make keyboard get focused surface when client is focused or unfocused,
and create data_offer for new focused surface in order to let new focused surface be able to get data from current selection data_source.

Test Plan:
1. Run wayland server
2. Run elementary_test -to entry5 on wayland server.
3. Run elementary_test -to entry5 on wayland server again. (preparing two clients)
4. Copy text on one of clients, and paste to the other.

Reviewers: devilhorns

CC: gwanglim, cedric

Differential Revision: https://phab.enlightenment.org/D1157
2014-08-26 10:10:37 -04:00
Seunghun Lee 97c39e74cc fix crash when client in wayland request to set parent to null.
Summary: Clear the E_Client's parent if client request to set parent to null.

Test Plan: run weston-stacking.

Reviewers: devilhorns

CC: cedric

Differential Revision: https://phab.enlightenment.org/D1154
2014-08-26 10:10:37 -04:00
Seunghun Lee 2b21742a91 Added conversion for image format to ARGB from XRGB for wayland. evas_object_image_data_set will be used instead of evas_object_image_data_copy_set.
Summary: this patch will provide to launch the application based on XRGB8888 like weston-simple-shm.

Test Plan: launch weston-simple-shm

Reviewers: devilhorns, zmike, raster

CC: cedric

Differential Revision: https://phab.enlightenment.org/D1137
2014-08-26 10:10:37 -04:00
Seunghun Lee 0667d4ce34 Change time unit to milli-second from second when send event of frame done for wayland client.
Summary: that's because weston sample client supposed that the time passed by frame callback is milli-second.

Reviewers: devilhorns, zmike, raster

CC: cedric

Differential Revision: https://phab.enlightenment.org/D1133
2014-08-26 10:10:37 -04:00
Seunghun Lee 6a1ef8b846 map/unmap surface in committing surface should be valid, only when buffer is newly attached. check if buffer is newly attached, when do map/unmap surface.
Summary:
There is a case that client do commit twice after one wl_surface_attach.
In this case, even if no buffer attached, unmapping the surface.
Because server already clear the buffer in first commit.

This patch fixes it.

Reviewers: devilhorns, zmike, raster

CC: cedric

Differential Revision: https://phab.enlightenment.org/D1115
2014-08-26 10:10:37 -04:00
MinJeong Kim b9caebbf7b Add missing function
Summary:
Added missing function _e_comp_wl_data_find_for_client.
@fix

Reviewers: devilhorns

CC: cedric

Differential Revision: https://phab.enlightenment.org/D1102
2014-08-26 10:10:37 -04:00
Chris Michael 5481440c75 Fix formatting.
Rename data_resource_list to data_resources.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:37 -04:00
MinJeong Kim 450206b599 Implement selection copy & paste using data interfaces of wayland
Summary: It supports selection copy & pasete with wl_data_device_manager, wl_data_device, wl_data_offer and wl_data_source.

Test Plan:
1. Build enlightenment on devs/devilhorns/e_comp_wl branch.
2. Run enlightenment.
3. Run elementary_test -to entry5 (or any entry samples).
4. Select any block of text.
5. Do copy the block and Copy anywhere you want.

Reviewers: gwanglim, devilhorns

CC: cedric

Differential Revision: https://phab.enlightenment.org/D1094
2014-08-26 10:10:37 -04:00
Chris Michael 8bd30c9b98 pass the compositor ecore_evas to e_pointer_canvas_new
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:37 -04:00
Chris Michael 488ffacc39 pass the ecore_evas to e_pointer_canvas_new and use Eina_Bool for
true/false values

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:37 -04:00
Chris Michael eafb4ce000 use Eina_Bool for true/false values
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:37 -04:00
Chris Michael 8c90407ce7 use the pointer from the compositor for e_win and don't free the pointer when the window closes
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:37 -04:00
Chris Michael 20e17c97ac create the compositor e_pointer on the ecore_evas
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:37 -04:00
Chris Michael 01fd44e485 add new e_pointer files
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:37 -04:00
Seunghun Lee e402e2363a fix crash and memory leak when press and release any key repeatedly.
Summary:
since the size of wl_array is determined based on one byte,
so in order to compare with uint32_t, the size of wl_array should be divided by uint32_t's size.
and when calculate the size of wl_array by difference between two address,
address should type cast char* as one byte.

Test Plan:
(1) run terminology
(2) input any key several time.

Reviewers: devilhorns, zmike, raster

CC: cedric

Differential Revision: https://phab.enlightenment.org/D1089
2014-08-26 10:10:37 -04:00