Commit Graph

69 Commits

Author SHA1 Message Date
Derek Foreman 1da3aa24dd Fix wl_output tracking in wayland compositor
Summary:
We should keep a list of resources per output to propagate wl_output
changes to each client that bound an output.

The output list now contains all outputs, not just bound ones.

Reviewers: devilhorns, zmike

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2047
2015-02-24 15:10:37 -05:00
Chris Michael be6c62eb34 add E_Comp_Wl_Output structure and function prototype to create outputs
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-02-24 13:24:56 -05:00
Derek Foreman 4276b3ac55 Provide wl_output interface to clients
Reviewers: devilhorns, zmike

Reviewed By: devilhorns, zmike

Subscribers: cedric

Maniphest Tasks: T2131

Differential Revision: https://phab.enlightenment.org/D2007
2015-02-19 14:49:01 -05:00
Mike Blumenkrantz 4d80185e69 send wl keyboard enter during commit
in some cases this was happening before the kbd resource was available; this guarantees that it will be
2015-02-10 19:17:50 -05:00
Mike Blumenkrantz 7e422ed0c2 remove wl opaque tilers, just set border in opaque callback 2015-02-09 21:27:53 -05:00
Mike Blumenkrantz 270bc92f81 add wl util function for calculating pixmap id 2015-02-06 18:32:07 -05:00
Chris Michael 96dd7324f8 add a mod_changed field to compositor data so we can know when
modifiers change

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-02-03 15:37:11 -05:00
Chris Michael c6a5f9448c add function prototype for getting idle time
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-26 14:48:47 -05:00
Chris Michael 3d9e6cd934 remove unused inline function
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-26 09:28:14 -05:00
Chris Michael 41fe2c901a e-comp-wl: Add internal function prototype for subsurface commit
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-11-03 12:27:13 -05:00
Chris Michael c1c3a90f3c e-comp-wl: Cleanup wayland compositor header
Summary: Changes subsurface data structure name, changes cached
damages to be a list (matching surface data structure).

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-11-03 12:27:12 -05:00
Chris Michael 770b3e5f26 change comp_wl_data structure to store the wl_resource of the client
buffer. No longer dealing with reference buffers.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-31 12:27:41 -04:00
Chris Michael d2360f569c e-comp-wl: Remove resize.width & height from structure
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-30 10:39:08 -04:00
Chris Michael 4b1e0e589e e-comp-wl: Comment out EGL include
This fixes a build error from evas engine already including EGL headers

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-30 10:39:08 -04:00
Chris Michael 12d1b5e40f change damages to be a list
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-30 10:39:06 -04:00
Chris Michael bac72a83f3 add internal function prototype for surface commit
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-30 10:39:06 -04:00
Chris Michael 0e525db048 rename surface signal get function
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-30 10:39:06 -04:00
Chris Michael 2b9b18e5fa e-comp-wl: Enable sending of the surface_create signal from the
compositor and provide an API function to retrieve that signal (used
in a pending commit)

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-13 15:51:14 -04:00
Chris Michael 0071b63f06 e-comp-wl: Remove dead structure members
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-01 16:15:00 -04:00
Jérémy Zurcher 25aabe7aa7 add missing 'pragma GCC diagnostic push' 2014-08-27 09:22:27 +02:00
Mike Blumenkrantz 362a9b6cce reuse existing render post callback for wayland clients 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
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
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
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 d52e926a32 add EGL headers for wayland compositor
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:37 -04:00
Chris Michael c6a3d4cfca Add structures for a buffer and reference to a buffer.
Switch client_data structure to use eina_tiler for input, opaque,
damage regions.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:36 -04:00
Chris Michael 0b0c464efd fix e_client sructure for running wayland client applications inside X.
update compositor structure for ability to run X and Wayland Clients.
update wayland compositor data & input file(s) for data structure rename.

NB: Both the X compositor and the Wayland compositor have different
"client data" to store, so e_client structure needs different fields

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:35 -04:00
Chris Michael 434219f758 rewrite wayland compositor:
- reduce memory usage
 - remove duplicated pixmaps
 - remove duplicated pointer images

@feature

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:35 -04:00
Chris Michael 217d5a95bc remove old wayland compositor and old shell files
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-26 10:10:34 -04:00
Gwanglim Lee c70e3eb531 remove duplicate xkb_rule_names and xkb_context
Summary: There are already in inner structure xkb in E_Wayland_Compositor.

Test Plan: Build e

Reviewers: raster, devilhorns, zmike

CC: cedric

Differential Revision: https://phab.enlightenment.org/D742
2014-04-26 13:36:53 -04:00
Chris Michael 915f8f0613 @bugfix: Fix building for WAYLAND_ONLY by using the proper define
sed -i 's/WAYLAND_ONLY/HAVE_WAYLAND_ONLY/g'

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-03-18 07:43:04 +00:00
Mike Blumenkrantz 12d7405a0f huge wl fixup (wayland clients actually working again)
* try to clear up build system for separating out ecore-x

* add #ifdefs for lots of ecore-x stuff

* break out some internal e wl functions for reuse in api

* store wl surface buffers as an inlist

* add protocol-specific client compositor data

** move lots of X client attributes here

* add pixmap type checks to a number of X-specific things, such as grabinput, to block them for non-X clients

* rearrange startup order to work with wayland

* move X screensaver code to e_comp_x

* flag modules still requiring X with -DNEED_X
2014-01-14 20:28:57 -05:00
Mike Blumenkrantz 86656e4df9 compositor rewrite / charlie-foxtrot situation
huge fustercluck commit because there wasn't really a way to separate out the changes. better to just rip it all out at once.

* compositor and window management completely rewritten. this was the goal for E19, but it pretty much required everything existing to be scrapped since it wasn't optimized, streamlined, or sensible. now instead of having the compositor strapped to the window manager like an outboard motor, it's housed more like an automobile engine.

** various comp structs have been merged into other places (eg. E_Comp_Zone is now just part of E_Zone where applicable), leading to a large deduplication of attributes

** awful E_Comp_Win is totally dead, having been replaced with e_comp_object smart objects which work just like normal canvas objects

** protocol-specific window management and compositor functionality is now kept exclusively in backend files

** e_pixmap api provides generic client finding and rendering api

** screen/xinerama screens are now provided directly by compositor on startup and re-set on change

** e_comp_render_update finally replaced with eina_tiler

** wayland compositor no longer creates X windows

** compositor e_layout removed entirely

* e_container is gone. this was made unnecessary in E18, but I kept it to avoid having too much code churn in one release. its sole purpose was to catch some events and handle window stacking, both of which are now just done by the compositor infra

* e_manager is just for screensaver and keybind stuff now, possibly remove later?

* e_border is gone along with a lot of its api. e_client has replaced it, and e_client has been rewritten completely; some parts may be similar, but the design now relies upon having a functional compositor

** window configuration/focus functions are all removed. all windows are now managed solely with evas_object_X functions on the "frame" member of a client, just as any other canvas object can be managed.

*** do NOT set interceptors on a client's comp_object. seriously.

* startup order rewritten: compositor now starts much earlier, other things just use attrs and members of the compositor

* ecore_x_pointer_xy_get usage replaced with ecore_evas_pointer_xy_get

* e_popup is totally gone, existing usage replaced by e_comp_object_util_add where applicable, otherwise just placed normally on the canvas

* deskmirror is (more) broken for now

* illume is totally fucked

* Ecore_X_Window replaced with Ecore_Window in most cases

* edge binding XWindows replaced with regular canvas objects

* some E_Win functionality has changed such that delete callbacks are now correctly called in ALL cases. various dialogs have been updated to not crash as a result

comp files and descriptions:

e_comp.c - overall compositor functions, rendering/update loop, shape cutting

e_comp_x.c - X window management and compositor functionality

e_comp_wl.c - Wayland surface management and compositor functionality

e_comp_canvas.c - general compositor canvas functions and utilities

e_comp_object.c - E_Client->frame member for managing clients as Evas_Objects, utility functions for adding objects to the compositor rendering systems

additional authors: ivan.briano@intel.com

feature: new compositor

removal: e_border, e_container, e_popup
2014-01-14 20:22:02 -05:00
Chris Michael ccf2aa8d15 Update pointer, keyboard, and touch structures for recent upstream
wayland/weston changes.
 - Remove focus_resource and focus_listener
 - Use a list of resources instead of singular resource

NB: Fixes zmike wayland client crash issue ;)

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-09-24 15:20:39 +01:00
Chris Michael 0fd9c57ddc Update E18 wayland client application support with recent wayland git
changes.

 - Remove function & calls to wl_*_release as they are redefined in
the client protocol again.
 - Fix up calls for getting resource_user_data.
 - Add WL_HIDE_DEPRECTAED define

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-09-11 10:12:30 +01:00
Mike Blumenkrantz bdd0bc624d add wl surface -> e_border mapping 2013-09-11 09:02:53 +01:00
Chris Michael 8560bc4726 Remove redundant wl_pointer in grab structure.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-08-28 08:16:02 +01:00
Mike Blumenkrantz 71b387deea use inlist for wl surface list 2013-08-19 03:31:24 +01:00
Chris Michael 0ac1e9b3b9 Add edges to pointer grab for easier access during resize.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-08-15 14:22:12 +01:00
Chris Michael 54d53d82f2 Define wayland compositor variable as externally visible (for people
using -fvisibility=hidden).

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-08-15 07:23:43 +01:00
Chris Michael 8e72f22d5d struct wl_buffer is deprecated now so just use a void pointer.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-07-15 13:42:46 +01:00
Chris Michael e708097c85 Add a reference to the shell for shell_surface
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-07-03 08:57:12 +01:00
Chris Michael bd3281c248 Revert "leak--: Store xkb_rule_names into Input structure so we can free the strings"
This reverts commit 87c1798281.

NB: This actually causes a nasty crash on E shutdown, so I need to
come up with another solution.
2013-06-28 06:49:09 +01:00
Chris Michael 87c1798281 leak--: Store xkb_rule_names into Input structure so we can free the strings
on shutdown or keymap change.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-06-27 11:37:51 +01:00
Chris Michael ee05616f33 Update wayland client support in the E compositor to work with recent
Wayland changes.

NB: Although the code does compile and clients do run, I RECOMMEND
that you do not use this feature right now. There is a current bug in
Wayland that is causing crashes when you close clients.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-06-26 09:23:13 +01:00
Chris Michael 9d2f29f0ae Add functions to allow wayland clients to run inside Enlightenment
again.

Wayland moved the input handling to be inside the "compositor" now, so
we need to add functions/support for that.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-05-13 09:03:43 +01:00
Chris Michael 7c37664ed6 Add egl extension header
Add bind and unbind proc address

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-26 13:48:46 +01:00