Commit Graph

173 Commits

Author SHA1 Message Date
Chris Michael 35c3eb7dcf fix compile issue due to output change and fixup subsurface creation to match new "state" paradigm
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-02-26 15:33:40 -05:00
Chris Michael 88f44e1a1d adjust wayland compositor scale when we adjust e_scale
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-02-26 15:33:40 -05:00
Chris Michael 0ac3045827 add a surface_state structure to E_Comp_Wl_Client_Data
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-02-26 15:33:39 -05:00
Bryce Harrington 89dbb9bd27 cosmetic: Whitespace cleanup of wayland client files
Summary:
cosmetic: Cleanup whitespace for wayland compositor

There is excess trailing whitespace in several of the files for the
wayland implementation.  These patches attempt to apply the spacing
rules for Enlightenment as documented at:
https://phab.enlightenment.org/w/coding_convention/

The whitespace rules are applied using the following emacs tabbing
settings:

 (defun start-efl-c-mode ()
  "C mode with adjusted defaults for use with Enlightenment
  development."
  (interactive)
  (c-mode)
  (c-set-style "gnu")
  (setq tab-width 8)
  (setq indent-tabs-mode nil)
  (setq c-basic-offset 3)
  (setq defun-block-intro 3)
  (setq statement-block-intro 3)
  (setq case-label 1)
  (setq statement-case-intro 3)
 )

This patchset also eliminates all tabs in favor of whitespace, as per
the coding style rules.

Reviewers: zmike, cedric, devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2048
2015-02-24 17:34:20 -05:00
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
Chris Michael c2bde038fc Add keyboard_resource to compositor struct.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-26 13:48:46 +01:00
Chris Michael 27fa756808 Add Event handler (for keymap events) to compositor structure.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-26 13:48:46 +01:00
Chris Michael 2344c1efdf Add list of outputs to compositor (needed for drm compositor).
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-23 09:54:56 +01:00
Chris Michael 326a53f9b3 Fix typo in definition of Output_Mode structure.
Add a "Terminal" structure to represent tty's for drm compositing.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-17 11:13:34 +01:00
Chris Michael 6afda6d9bd Add a structure for hardware plane (used in drm compositor).
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-17 09:28:13 +01:00
Chris Michael 761545a885 Fix duplicate structure field.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 14:23:43 +01:00
Chris Michael 83151516e8 Add output and output_mode structures.
These are needed in the drm backend.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 13:47:02 +01:00
Chris Michael 7d6f31fa85 Add a reference to the Evas of the surface.
Use Eina_List for border hooks (as we need more than one anyway).

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:56:12 +01:00
Chris Michael 494bcf7298 Add transient fields to the shell surface structure.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:56:12 +01:00
Chris Michael a719bdc39c Add popup fields to the shell surface structure.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:56:12 +01:00
Chris Michael 58df59aaf4 Add width & height to the grab structure.
Add edges (for resize) to the grab structure.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:56:12 +01:00
Chris Michael a14d7dbe2a Remove dead comments.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:55:00 +01:00
Chris Michael ebb35638f5 Actually export comp_wl_time_get and comp_wl_input_modifiers update
functions as they may be needed in various shell modules.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:54:59 +01:00
Chris Michael 8745eadb3d Add surface smart object to E_Wayland_Surface struture.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:47:55 +01:00
Chris Michael 29be68914f Add headers and defaults for input support and egl support.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:46:24 +01:00
Chris Michael 90dc57e813 Rename input rectangle object (oopsie).
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:46:24 +01:00
Chris Michael 3ce1e0e8e9 Add header for a Wayland Compositor.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:46:24 +01:00
Chris Michael 047920a9f3 Remove all old wayland compositor files.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2013-04-16 12:46:24 +01:00
Lucas De Marchi 8cacf8429d e: merge comp module into core
* Move compositor to core, but letting the configuration there
 * Rename all files and functions from e_mod_comp_* to e_comp_*
 * Move the config dialogs to a new module named conf_comp. It still
   uses a domain config, otherwise it would not pick the current
   user's configuration. Maybe it would be wise to later on move these
   options to e_config
 * Fixup the wizard mess linking the header in the build tree in order
   to be able to create the config. Since now it's in core, we don't
   need to play linking games in the build system

I'm not sure if the wayland part works. It was not even building
previously so I'll let for who cares about this to actually test and
report bugs.



SVN revision: 82454
2013-01-09 11:34:07 +00:00