summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2020-01-12 17:36:48 +0100
committerMarcel Hollerbach <mail@marcel-hollerbach.de>2020-03-04 17:26:29 +0100
commit6b337ed19bce8bec149b1dbdb18281f702ba834d (patch)
treee2535446083ec2743433be68f27172cc1e2280a5
parentce070a8fdfc9436e837b18f140f30ddc8a67793e (diff)
ecore_x: add API to request selection changed events for diff. wins
we need that in order to get seleciton per window events, which is required to get a nice mapping onto the ecore_evas object. Differential Revision: https://phab.enlightenment.org/D11193
-rw-r--r--src/lib/ecore_x/Ecore_X.h9
-rw-r--r--src/lib/ecore_x/ecore_x_fixes.c20
2 files changed, 29 insertions, 0 deletions
diff --git a/src/lib/ecore_x/Ecore_X.h b/src/lib/ecore_x/Ecore_X.h
index bb5aedf39e..94b612abc6 100644
--- a/src/lib/ecore_x/Ecore_X.h
+++ b/src/lib/ecore_x/Ecore_X.h
@@ -2444,6 +2444,15 @@ EAPI void ecore_x_root_screen_barriers_set(Ecore_X_Rectangle *scre
2444 */ 2444 */
2445EAPI Eina_Bool ecore_x_fixes_selection_notification_request(Ecore_X_Atom selection); 2445EAPI Eina_Bool ecore_x_fixes_selection_notification_request(Ecore_X_Atom selection);
2446 2446
2447/**
2448 * xfixes selection notification request.
2449 *
2450 * In addition to ecore_x_fixes_selection_notification_request you can also specify for which window you want to get them
2451 * @since 1.24
2452 */
2453EAPI Eina_Bool ecore_x_fixes_window_selection_notification_request(Ecore_X_Window window, Ecore_X_Atom selection);
2454
2455
2447/* XComposite Extension Support */ 2456/* XComposite Extension Support */
2448EAPI Eina_Bool ecore_x_composite_query(void); 2457EAPI Eina_Bool ecore_x_composite_query(void);
2449EAPI void ecore_x_composite_redirect_window(Ecore_X_Window win, Ecore_X_Composite_Update_Type type); 2458EAPI void ecore_x_composite_redirect_window(Ecore_X_Window win, Ecore_X_Composite_Update_Type type);
diff --git a/src/lib/ecore_x/ecore_x_fixes.c b/src/lib/ecore_x/ecore_x_fixes.c
index 5582c3e3ef..4b659c2d8b 100644
--- a/src/lib/ecore_x/ecore_x_fixes.c
+++ b/src/lib/ecore_x/ecore_x_fixes.c
@@ -112,6 +112,26 @@ ecore_x_fixes_selection_notification_request(Ecore_X_Atom selection)
112 return EINA_FALSE; 112 return EINA_FALSE;
113} 113}
114 114
115EAPI Eina_Bool
116ecore_x_fixes_window_selection_notification_request(Ecore_X_Window window, Ecore_X_Atom selection)
117{
118 EINA_SAFETY_ON_NULL_RETURN_VAL(_ecore_x_disp, EINA_FALSE);
119
120#ifdef ECORE_XFIXES
121 if (_fixes_available)
122 {
123 XFixesSelectSelectionInput (_ecore_x_disp,
124 window,
125 selection,
126 XFixesSetSelectionOwnerNotifyMask |
127 XFixesSelectionWindowDestroyNotifyMask |
128 XFixesSelectionClientCloseNotifyMask);
129 return EINA_TRUE;
130 }
131#endif
132 return EINA_FALSE;
133}
134
115EAPI Ecore_X_Region 135EAPI Ecore_X_Region
116ecore_x_region_new(Ecore_X_Rectangle *rects, 136ecore_x_region_new(Ecore_X_Rectangle *rects,
117 int num) 137 int num)