aboutsummaryrefslogtreecommitdiffstats
path: root/legacy/ecore/src/lib/ecore_x
diff options
context:
space:
mode:
Diffstat (limited to 'legacy/ecore/src/lib/ecore_x')
-rw-r--r--legacy/ecore/src/lib/ecore_x/Ecore_X.h3695
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb.c721
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_atoms.c93
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_composite.c105
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_cursor.c378
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_damage.c56
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dnd.c217
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dpms.c91
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_drawable.c28
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_e.c514
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_error.c33
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_events.c933
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_extensions.c9
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_gc.c47
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_icccm.c435
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_image.c454
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_input.c269
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_keymap.c178
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_mwm.c47
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_netwm.c707
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_pixmap.c36
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_private.h370
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_randr.c1324
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_region.c50
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_render.c128
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_screensaver.c82
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_selection.c403
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_shape.c13
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_sync.c84
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_textlist.c186
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_vsync.c215
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_window.c855
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_window_prop.c260
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_window_shadow.c91
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_window_shape.c257
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_xdefaults.c39
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_xfixes.c164
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_xinerama.c45
-rw-r--r--legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_xtest.c92
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x.c497
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_atoms.c16
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_composite.c32
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_cursor.c24
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_damage.c7
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_dnd.c116
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_dpms.c8
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_drawable.c14
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_e.c275
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_error.c20
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_events.c682
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_fixes.c49
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_gc.c140
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_icccm.c421
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_image.c247
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c17
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_netwm.c646
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_pixmap.c29
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_private.h280
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_randr.c53
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_randr.h4
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_randr_11.c84
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_randr_12.c1086
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_randr_12_edid.c408
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_randr_13.c17
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_region.c29
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_screensaver.c12
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_selection.c325
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_sync.c24
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_test.c30
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_vsync.c182
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_window.c517
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_window_prop.c256
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_window_shape.c30
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_xi2.c211
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_xinerama.c26
75 files changed, 11334 insertions, 9184 deletions
diff --git a/legacy/ecore/src/lib/ecore_x/Ecore_X.h b/legacy/ecore/src/lib/ecore_x/Ecore_X.h
index d489b80a84..ba7021ffd2 100644
--- a/legacy/ecore/src/lib/ecore_x/Ecore_X.h
+++ b/legacy/ecore/src/lib/ecore_x/Ecore_X.h
@@ -39,36 +39,36 @@
* @li @ref Ecore_X_Flush_Group
*/
-typedef unsigned int Ecore_X_ID;
+typedef unsigned int Ecore_X_ID;
#ifndef _ECORE_X_WINDOW_PREDEF
-typedef Ecore_X_ID Ecore_X_Window;
+typedef Ecore_X_ID Ecore_X_Window;
#endif // ifndef _ECORE_X_WINDOW_PREDEF
-typedef void * Ecore_X_Visual;
-typedef Ecore_X_ID Ecore_X_Pixmap;
-typedef Ecore_X_ID Ecore_X_Drawable;
+typedef void *Ecore_X_Visual;
+typedef Ecore_X_ID Ecore_X_Pixmap;
+typedef Ecore_X_ID Ecore_X_Drawable;
#ifdef HAVE_ECORE_X_XCB
-typedef Ecore_X_ID Ecore_X_GC;
+typedef Ecore_X_ID Ecore_X_GC;
#else // ifdef HAVE_ECORE_X_XCB
-typedef void * Ecore_X_GC;
+typedef void *Ecore_X_GC;
#endif /* HAVE_ECORE_X_XCB */
-typedef Ecore_X_ID Ecore_X_Atom;
-typedef Ecore_X_ID Ecore_X_Colormap;
-typedef Ecore_X_ID Ecore_X_Time;
-typedef Ecore_X_ID Ecore_X_Cursor;
-typedef void Ecore_X_Display;
-typedef void Ecore_X_Connection;
-typedef void Ecore_X_Screen;
-typedef Ecore_X_ID Ecore_X_Sync_Counter;
-typedef Ecore_X_ID Ecore_X_Sync_Alarm;
-typedef void Ecore_X_XRegion;
-
-typedef Ecore_X_ID Ecore_X_Randr_Output;
-typedef Ecore_X_ID Ecore_X_Randr_Crtc;
-typedef Ecore_X_ID Ecore_X_Randr_Mode;
-typedef unsigned short Ecore_X_Randr_Size_ID;
-typedef int Ecore_X_Randr_Screen;
-
-typedef Ecore_X_ID Ecore_X_Device;
+typedef Ecore_X_ID Ecore_X_Atom;
+typedef Ecore_X_ID Ecore_X_Colormap;
+typedef Ecore_X_ID Ecore_X_Time;
+typedef Ecore_X_ID Ecore_X_Cursor;
+typedef void Ecore_X_Display;
+typedef void Ecore_X_Connection;
+typedef void Ecore_X_Screen;
+typedef Ecore_X_ID Ecore_X_Sync_Counter;
+typedef Ecore_X_ID Ecore_X_Sync_Alarm;
+typedef void Ecore_X_XRegion;
+
+typedef Ecore_X_ID Ecore_X_Randr_Output;
+typedef Ecore_X_ID Ecore_X_Randr_Crtc;
+typedef Ecore_X_ID Ecore_X_Randr_Mode;
+typedef unsigned short Ecore_X_Randr_Size_ID;
+typedef int Ecore_X_Randr_Screen;
+
+typedef Ecore_X_ID Ecore_X_Device;
#ifdef __cplusplus
extern "C" {
@@ -86,7 +86,7 @@ typedef struct _Ecore_X_Icon
unsigned int *data;
} Ecore_X_Icon;
-typedef enum _Ecore_X_GC_Value_Mask
+typedef enum _Ecore_X_GC_Value_Mask
{
ECORE_X_GC_VALUE_MASK_FUNCTION = (1L << 0),
ECORE_X_GC_VALUE_MASK_PLANE_MASK = (1L << 1),
@@ -113,54 +113,54 @@ typedef enum _Ecore_X_GC_Value_Mask
ECORE_X_GC_VALUE_MASK_ARC_MODE = (1L << 22)
} Ecore_X_GC_Value_Mask;
-typedef enum _Ecore_X_Composite_Update_Type
+typedef enum _Ecore_X_Composite_Update_Type
{
ECORE_X_COMPOSITE_UPDATE_AUTOMATIC,
ECORE_X_COMPOSITE_UPDATE_MANUAL
} Ecore_X_Composite_Update_Type;
-typedef enum _Ecore_X_Window_State
+typedef enum _Ecore_X_Window_State
{
/* Unknown state */
- ECORE_X_WINDOW_STATE_UNKNOWN = 0,
- /** The window is iconified. */
- ECORE_X_WINDOW_STATE_ICONIFIED,
- /** The window is a modal dialog box. */
- ECORE_X_WINDOW_STATE_MODAL,
- /** The window manager should keep the window's position fixed
- * even if the virtual desktop scrolls. */
- ECORE_X_WINDOW_STATE_STICKY,
- /** The window has the maximum vertical size. */
- ECORE_X_WINDOW_STATE_MAXIMIZED_VERT,
- /** The window has the maximum horizontal size. */
- ECORE_X_WINDOW_STATE_MAXIMIZED_HORZ,
- /** The window is shaded. */
- ECORE_X_WINDOW_STATE_SHADED,
- /** The window should not be included in the taskbar. */
- ECORE_X_WINDOW_STATE_SKIP_TASKBAR,
- /** The window should not be included in the pager. */
- ECORE_X_WINDOW_STATE_SKIP_PAGER,
- /** The window is invisible (i.e. minimized/iconified) */
- ECORE_X_WINDOW_STATE_HIDDEN,
- /** The window should fill the entire screen and have no
- * window border/decorations */
- ECORE_X_WINDOW_STATE_FULLSCREEN,
- /* The following are not documented because they are not
- * intended for use in applications. */
- ECORE_X_WINDOW_STATE_ABOVE,
- ECORE_X_WINDOW_STATE_BELOW,
- /* FIXME: Documentation */
- ECORE_X_WINDOW_STATE_DEMANDS_ATTENTION
+ ECORE_X_WINDOW_STATE_UNKNOWN = 0,
+ /** The window is iconified. */
+ ECORE_X_WINDOW_STATE_ICONIFIED,
+ /** The window is a modal dialog box. */
+ ECORE_X_WINDOW_STATE_MODAL,
+ /** The window manager should keep the window's position fixed
+ * even if the virtual desktop scrolls. */
+ ECORE_X_WINDOW_STATE_STICKY,
+ /** The window has the maximum vertical size. */
+ ECORE_X_WINDOW_STATE_MAXIMIZED_VERT,
+ /** The window has the maximum horizontal size. */
+ ECORE_X_WINDOW_STATE_MAXIMIZED_HORZ,
+ /** The window is shaded. */
+ ECORE_X_WINDOW_STATE_SHADED,
+ /** The window should not be included in the taskbar. */
+ ECORE_X_WINDOW_STATE_SKIP_TASKBAR,
+ /** The window should not be included in the pager. */
+ ECORE_X_WINDOW_STATE_SKIP_PAGER,
+ /** The window is invisible (i.e. minimized/iconified) */
+ ECORE_X_WINDOW_STATE_HIDDEN,
+ /** The window should fill the entire screen and have no
+ * window border/decorations */
+ ECORE_X_WINDOW_STATE_FULLSCREEN,
+ /* The following are not documented because they are not
+ * intended for use in applications. */
+ ECORE_X_WINDOW_STATE_ABOVE,
+ ECORE_X_WINDOW_STATE_BELOW,
+ /* FIXME: Documentation */
+ ECORE_X_WINDOW_STATE_DEMANDS_ATTENTION
} Ecore_X_Window_State;
-typedef enum _Ecore_X_Window_State_Action
+typedef enum _Ecore_X_Window_State_Action
{
ECORE_X_WINDOW_STATE_ACTION_REMOVE,
ECORE_X_WINDOW_STATE_ACTION_ADD,
ECORE_X_WINDOW_STATE_ACTION_TOGGLE
} Ecore_X_Window_State_Action;
-typedef enum _Ecore_X_Window_Stack_Mode
+typedef enum _Ecore_X_Window_Stack_Mode
{
ECORE_X_WINDOW_STACK_ABOVE = 0,
ECORE_X_WINDOW_STACK_BELOW = 1,
@@ -169,7 +169,7 @@ typedef enum _Ecore_X_Window_Stack_Mode
ECORE_X_WINDOW_STACK_OPPOSITE = 4
} Ecore_X_Window_Stack_Mode;
-typedef enum _Ecore_X_Randr_Orientation
+typedef enum _Ecore_X_Randr_Orientation
{
ECORE_X_RANDR_ORIENTATION_ROT_0 = (1 << 0),
ECORE_X_RANDR_ORIENTATION_ROT_90 = (1 << 1),
@@ -179,14 +179,14 @@ typedef enum _Ecore_X_Randr_Orientation
ECORE_X_RANDR_ORIENTATION_FLIP_Y = (1 << 5)
} Ecore_X_Randr_Orientation;
-typedef enum _Ecore_X_Randr_Connection_Status
+typedef enum _Ecore_X_Randr_Connection_Status
{
ECORE_X_RANDR_CONNECTION_STATUS_CONNECTED = 0,
ECORE_X_RANDR_CONNECTION_STATUS_DISCONNECTED = 1,
ECORE_X_RANDR_CONNECTION_STATUS_UNKNOWN = 2
} Ecore_X_Randr_Connection_Status;
-typedef enum _Ecore_X_Randr_Output_Policy
+typedef enum _Ecore_X_Randr_Output_Policy
{
ECORE_X_RANDR_OUTPUT_POLICY_ABOVE = 1,
ECORE_X_RANDR_OUTPUT_POLICY_RIGHT = 2,
@@ -196,14 +196,14 @@ typedef enum _Ecore_X_Randr_Output_Policy
ECORE_X_RANDR_OUTPUT_POLICY_NONE = 6
} Ecore_X_Randr_Output_Policy;
-typedef enum _Ecore_X_Randr_Relative_Alignment
+typedef enum _Ecore_X_Randr_Relative_Alignment
{
ECORE_X_RANDR_RELATIVE_ALIGNMENT_NONE = 0,
ECORE_X_RANDR_RELATIVE_ALIGNMENT_CENTER_REL = 1,
ECORE_X_RANDR_RELATIVE_ALIGNMENT_CENTER_SCR = 2
} Ecore_X_Randr_Relative_Alignment;
-typedef enum _Ecore_X_Render_Subpixel_Order
+typedef enum _Ecore_X_Render_Subpixel_Order
{
ECORE_X_RENDER_SUBPIXEL_ORDER_UNKNOWN = 0,
ECORE_X_RENDER_SUBPIXEL_ORDER_HORIZONTAL_RGB = 1,
@@ -213,7 +213,7 @@ typedef enum _Ecore_X_Render_Subpixel_Order
ECORE_X_RENDER_SUBPIXEL_ORDER_NONE = 5
} Ecore_X_Render_Subpixel_Order;
-typedef enum _Ecore_X_Randr_Edid_Display_Interface_Type
+typedef enum _Ecore_X_Randr_Edid_Display_Interface_Type
{
ECORE_X_RANDR_EDID_DISPLAY_INTERFACE_UNDEFINED,
ECORE_X_RANDR_EDID_DISPLAY_INTERFACE_DVI,
@@ -222,8 +222,8 @@ typedef enum _Ecore_X_Randr_Edid_Display_Interface_Type
ECORE_X_RANDR_EDID_DISPLAY_INTERFACE_MDDI,
ECORE_X_RANDR_EDID_DISPLAY_INTERFACE_DISPLAY_PORT
} Ecore_X_Randr_Edid_Display_Interface_Type;
-
-typedef enum _Ecore_X_Randr_Edid_Display_Colorscheme
+
+typedef enum _Ecore_X_Randr_Edid_Display_Colorscheme
{
ECORE_X_RANDR_EDID_DISPLAY_COLORSCHEME_MONOCHROME_GRAYSCALE = 0x00,
ECORE_X_RANDR_EDID_DISPLAY_COLORSCHEME_COLOR_RGB = 0x08,
@@ -233,8 +233,8 @@ typedef enum _Ecore_X_Randr_Edid_Display_Colorscheme
ECORE_X_RANDR_EDID_DISPLAY_COLORSCHEME_COLOR_RGB_YCRCB_4_4_4 = 0x444,
ECORE_X_RANDR_EDID_DISPLAY_COLORSCHEME_COLOR_RGB_YCRCB_4_2_2 = 0x422
} Ecore_X_Randr_Edid_Display_Colorscheme;
-
-typedef enum _Ecore_X_Randr_Edid_Aspect_Ratio
+
+typedef enum _Ecore_X_Randr_Edid_Aspect_Ratio
{
ECORE_X_RANDR_EDID_ASPECT_RATIO_4_3 = 0x0,
ECORE_X_RANDR_EDID_ASPECT_RATIO_16_9 = 0x1,
@@ -242,9 +242,9 @@ typedef enum _Ecore_X_Randr_Edid_Aspect_Ratio
ECORE_X_RANDR_EDID_ASPECT_RATIO_5_4 = 0x4,
ECORE_X_RANDR_EDID_ASPECT_RATIO_15_9 = 0x8
} Ecore_X_Randr_Edid_Aspect_Ratio;
-
-#define ECORE_X_RANDR_EDID_UNKNOWN_VALUE -1
-
+
+#define ECORE_X_RANDR_EDID_UNKNOWN_VALUE -1
+
#define ECORE_X_SELECTION_TARGET_TARGETS "TARGETS"
#define ECORE_X_SELECTION_TARGET_TEXT "TEXT"
#define ECORE_X_SELECTION_TARGET_COMPOUND_TEXT "COMPOUND_TEXT"
@@ -254,7 +254,7 @@ typedef enum _Ecore_X_Randr_Edid_Aspect_Ratio
#define ECORE_X_DND_VERSION 5
-typedef enum _Ecore_X_Selection
+typedef enum _Ecore_X_Selection
{
ECORE_X_SELECTION_PRIMARY,
ECORE_X_SELECTION_SECONDARY,
@@ -344,78 +344,78 @@ typedef enum _Ecore_X_Randr_Property_Change
ECORE_X_RANDR_PROPERTY_CHANGE_ADD,
ECORE_X_RANDR_PROPERTY_CHANGE_DEL
} Ecore_X_Randr_Property_Change;
-
-typedef struct _Ecore_X_Event_Mouse_In Ecore_X_Event_Mouse_In;
-typedef struct _Ecore_X_Event_Mouse_Out Ecore_X_Event_Mouse_Out;
-typedef struct _Ecore_X_Event_Window_Focus_In Ecore_X_Event_Window_Focus_In;
-typedef struct _Ecore_X_Event_Window_Focus_Out Ecore_X_Event_Window_Focus_Out;
-typedef struct _Ecore_X_Event_Window_Keymap Ecore_X_Event_Window_Keymap;
-typedef struct _Ecore_X_Event_Window_Damage Ecore_X_Event_Window_Damage;
-typedef struct _Ecore_X_Event_Window_Visibility_Change Ecore_X_Event_Window_Visibility_Change;
-typedef struct _Ecore_X_Event_Window_Create Ecore_X_Event_Window_Create;
-typedef struct _Ecore_X_Event_Window_Destroy Ecore_X_Event_Window_Destroy;
-typedef struct _Ecore_X_Event_Window_Hide Ecore_X_Event_Window_Hide;
-typedef struct _Ecore_X_Event_Window_Show Ecore_X_Event_Window_Show;
-typedef struct _Ecore_X_Event_Window_Show_Request Ecore_X_Event_Window_Show_Request;
-typedef struct _Ecore_X_Event_Window_Reparent Ecore_X_Event_Window_Reparent;
-typedef struct _Ecore_X_Event_Window_Configure Ecore_X_Event_Window_Configure;
-typedef struct _Ecore_X_Event_Window_Configure_Request Ecore_X_Event_Window_Configure_Request;
-typedef struct _Ecore_X_Event_Window_Gravity Ecore_X_Event_Window_Gravity;
-typedef struct _Ecore_X_Event_Window_Resize_Request Ecore_X_Event_Window_Resize_Request;
-typedef struct _Ecore_X_Event_Window_Stack Ecore_X_Event_Window_Stack;
-typedef struct _Ecore_X_Event_Window_Stack_Request Ecore_X_Event_Window_Stack_Request;
-typedef struct _Ecore_X_Event_Window_Property Ecore_X_Event_Window_Property;
-typedef struct _Ecore_X_Event_Window_Colormap Ecore_X_Event_Window_Colormap;
-typedef struct _Ecore_X_Event_Mapping_Change Ecore_X_Event_Mapping_Change;
-typedef struct _Ecore_X_Event_Window_Mapping Ecore_X_Event_Window_Mapping;
-typedef struct _Ecore_X_Event_Selection_Clear Ecore_X_Event_Selection_Clear;
-typedef struct _Ecore_X_Event_Selection_Request Ecore_X_Event_Selection_Request;
-typedef struct _Ecore_X_Event_Selection_Notify Ecore_X_Event_Selection_Notify;
-typedef struct _Ecore_X_Event_Fixes_Selection_Notify Ecore_X_Event_Fixes_Selection_Notify;
-typedef struct _Ecore_X_Selection_Data Ecore_X_Selection_Data;
-typedef struct _Ecore_X_Selection_Data_Files Ecore_X_Selection_Data_Files;
-typedef struct _Ecore_X_Selection_Data_Text Ecore_X_Selection_Data_Text;
-typedef struct _Ecore_X_Selection_Data_Targets Ecore_X_Selection_Data_Targets;
-typedef struct _Ecore_X_Event_Xdnd_Enter Ecore_X_Event_Xdnd_Enter;
-typedef struct _Ecore_X_Event_Xdnd_Position Ecore_X_Event_Xdnd_Position;
-typedef struct _Ecore_X_Event_Xdnd_Status Ecore_X_Event_Xdnd_Status;
-typedef struct _Ecore_X_Event_Xdnd_Leave Ecore_X_Event_Xdnd_Leave;
-typedef struct _Ecore_X_Event_Xdnd_Drop Ecore_X_Event_Xdnd_Drop;
-typedef struct _Ecore_X_Event_Xdnd_Finished Ecore_X_Event_Xdnd_Finished;
-typedef struct _Ecore_X_Event_Client_Message Ecore_X_Event_Client_Message;
-typedef struct _Ecore_X_Event_Window_Shape Ecore_X_Event_Window_Shape;
-typedef struct _Ecore_X_Event_Screensaver_Notify Ecore_X_Event_Screensaver_Notify;
-typedef struct _Ecore_X_Event_Sync_Counter Ecore_X_Event_Sync_Counter;
-typedef struct _Ecore_X_Event_Sync_Alarm Ecore_X_Event_Sync_Alarm;
-typedef struct _Ecore_X_Event_Screen_Change Ecore_X_Event_Screen_Change;
-typedef struct _Ecore_X_Event_Randr_Crtc_Change Ecore_X_Event_Randr_Crtc_Change;
-typedef struct _Ecore_X_Event_Randr_Output_Change Ecore_X_Event_Randr_Output_Change;
+
+typedef struct _Ecore_X_Event_Mouse_In Ecore_X_Event_Mouse_In;
+typedef struct _Ecore_X_Event_Mouse_Out Ecore_X_Event_Mouse_Out;
+typedef struct _Ecore_X_Event_Window_Focus_In Ecore_X_Event_Window_Focus_In;
+typedef struct _Ecore_X_Event_Window_Focus_Out Ecore_X_Event_Window_Focus_Out;
+typedef struct _Ecore_X_Event_Window_Keymap Ecore_X_Event_Window_Keymap;
+typedef struct _Ecore_X_Event_Window_Damage Ecore_X_Event_Window_Damage;
+typedef struct _Ecore_X_Event_Window_Visibility_Change Ecore_X_Event_Window_Visibility_Change;
+typedef struct _Ecore_X_Event_Window_Create Ecore_X_Event_Window_Create;
+typedef struct _Ecore_X_Event_Window_Destroy Ecore_X_Event_Window_Destroy;
+typedef struct _Ecore_X_Event_Window_Hide Ecore_X_Event_Window_Hide;
+typedef struct _Ecore_X_Event_Window_Show Ecore_X_Event_Window_Show;
+typedef struct _Ecore_X_Event_Window_Show_Request Ecore_X_Event_Window_Show_Request;
+typedef struct _Ecore_X_Event_Window_Reparent Ecore_X_Event_Window_Reparent;
+typedef struct _Ecore_X_Event_Window_Configure Ecore_X_Event_Window_Configure;
+typedef struct _Ecore_X_Event_Window_Configure_Request Ecore_X_Event_Window_Configure_Request;
+typedef struct _Ecore_X_Event_Window_Gravity Ecore_X_Event_Window_Gravity;
+typedef struct _Ecore_X_Event_Window_Resize_Request Ecore_X_Event_Window_Resize_Request;
+typedef struct _Ecore_X_Event_Window_Stack Ecore_X_Event_Window_Stack;
+typedef struct _Ecore_X_Event_Window_Stack_Request Ecore_X_Event_Window_Stack_Request;
+typedef struct _Ecore_X_Event_Window_Property Ecore_X_Event_Window_Property;
+typedef struct _Ecore_X_Event_Window_Colormap Ecore_X_Event_Window_Colormap;
+typedef struct _Ecore_X_Event_Mapping_Change Ecore_X_Event_Mapping_Change;
+typedef struct _Ecore_X_Event_Window_Mapping Ecore_X_Event_Window_Mapping;
+typedef struct _Ecore_X_Event_Selection_Clear Ecore_X_Event_Selection_Clear;
+typedef struct _Ecore_X_Event_Selection_Request Ecore_X_Event_Selection_Request;
+typedef struct _Ecore_X_Event_Selection_Notify Ecore_X_Event_Selection_Notify;
+typedef struct _Ecore_X_Event_Fixes_Selection_Notify Ecore_X_Event_Fixes_Selection_Notify;
+typedef struct _Ecore_X_Selection_Data Ecore_X_Selection_Data;
+typedef struct _Ecore_X_Selection_Data_Files Ecore_X_Selection_Data_Files;
+typedef struct _Ecore_X_Selection_Data_Text Ecore_X_Selection_Data_Text;
+typedef struct _Ecore_X_Selection_Data_Targets Ecore_X_Selection_Data_Targets;
+typedef struct _Ecore_X_Event_Xdnd_Enter Ecore_X_Event_Xdnd_Enter;
+typedef struct _Ecore_X_Event_Xdnd_Position Ecore_X_Event_Xdnd_Position;
+typedef struct _Ecore_X_Event_Xdnd_Status Ecore_X_Event_Xdnd_Status;
+typedef struct _Ecore_X_Event_Xdnd_Leave Ecore_X_Event_Xdnd_Leave;
+typedef struct _Ecore_X_Event_Xdnd_Drop Ecore_X_Event_Xdnd_Drop;
+typedef struct _Ecore_X_Event_Xdnd_Finished Ecore_X_Event_Xdnd_Finished;
+typedef struct _Ecore_X_Event_Client_Message Ecore_X_Event_Client_Message;
+typedef struct _Ecore_X_Event_Window_Shape Ecore_X_Event_Window_Shape;
+typedef struct _Ecore_X_Event_Screensaver_Notify Ecore_X_Event_Screensaver_Notify;
+typedef struct _Ecore_X_Event_Sync_Counter Ecore_X_Event_Sync_Counter;
+typedef struct _Ecore_X_Event_Sync_Alarm Ecore_X_Event_Sync_Alarm;
+typedef struct _Ecore_X_Event_Screen_Change Ecore_X_Event_Screen_Change;
+typedef struct _Ecore_X_Event_Randr_Crtc_Change Ecore_X_Event_Randr_Crtc_Change;
+typedef struct _Ecore_X_Event_Randr_Output_Change Ecore_X_Event_Randr_Output_Change;
typedef struct _Ecore_X_Event_Randr_Output_Property_Notify Ecore_X_Event_Randr_Output_Property_Notify;
-typedef struct _Ecore_X_Event_Window_Delete_Request Ecore_X_Event_Window_Delete_Request;
-typedef struct _Ecore_X_Event_Window_Move_Resize_Request Ecore_X_Event_Window_Move_Resize_Request;
-typedef struct _Ecore_X_Event_Window_State_Request Ecore_X_Event_Window_State_Request;
-typedef struct _Ecore_X_Event_Frame_Extents_Request Ecore_X_Event_Frame_Extents_Request;
-typedef struct _Ecore_X_Event_Ping Ecore_X_Event_Ping;
-typedef struct _Ecore_X_Event_Desktop_Change Ecore_X_Event_Desktop_Change;
+typedef struct _Ecore_X_Event_Window_Delete_Request Ecore_X_Event_Window_Delete_Request;
+typedef struct _Ecore_X_Event_Window_Move_Resize_Request Ecore_X_Event_Window_Move_Resize_Request;
+typedef struct _Ecore_X_Event_Window_State_Request Ecore_X_Event_Window_State_Request;
+typedef struct _Ecore_X_Event_Frame_Extents_Request Ecore_X_Event_Frame_Extents_Request;
+typedef struct _Ecore_X_Event_Ping Ecore_X_Event_Ping;
+typedef struct _Ecore_X_Event_Desktop_Change Ecore_X_Event_Desktop_Change;
-typedef struct _Ecore_X_Event_Startup_Sequence Ecore_X_Event_Startup_Sequence;
+typedef struct _Ecore_X_Event_Startup_Sequence Ecore_X_Event_Startup_Sequence;
-typedef struct _Ecore_X_Event_Generic Ecore_X_Event_Generic;
+typedef struct _Ecore_X_Event_Generic Ecore_X_Event_Generic;
-typedef struct _Ecore_X_Randr_Screen_Size Ecore_X_Randr_Screen_Size;
-typedef struct _Ecore_X_Randr_Screen_Size_MM Ecore_X_Randr_Screen_Size_MM;
+typedef struct _Ecore_X_Randr_Screen_Size Ecore_X_Randr_Screen_Size;
+typedef struct _Ecore_X_Randr_Screen_Size_MM Ecore_X_Randr_Screen_Size_MM;
-typedef struct _Ecore_X_Xdnd_Position Ecore_X_Xdnd_Position;
+typedef struct _Ecore_X_Xdnd_Position Ecore_X_Xdnd_Position;
struct _Ecore_X_Event_Mouse_In
{
int modifiers;
int x, y;
Eina_Bool same_screen : 1;
- struct
+ struct
{
- int x, y;
+ int x, y;
} root;
Ecore_X_Window win;
Ecore_X_Window event_win;
@@ -430,9 +430,9 @@ struct _Ecore_X_Event_Mouse_Out
int modifiers;
int x, y;
int same_screen;
- struct
+ struct
{
- int x, y;
+ int x, y;
} root;
Ecore_X_Window win;
Ecore_X_Window event_win;
@@ -627,12 +627,12 @@ typedef enum
struct _Ecore_X_Event_Fixes_Selection_Notify
{
- Ecore_X_Window win;
- Ecore_X_Window owner;
- Ecore_X_Time time;
- Ecore_X_Time selection_time;
- Ecore_X_Selection selection;
- Ecore_X_Atom atom;
+ Ecore_X_Window win;
+ Ecore_X_Window owner;
+ Ecore_X_Time time;
+ Ecore_X_Time selection_time;
+ Ecore_X_Selection selection;
+ Ecore_X_Atom atom;
Ecore_X_Owner_Change_Reason reason;
};
@@ -648,14 +648,14 @@ struct _Ecore_X_Event_Selection_Notify
struct _Ecore_X_Selection_Data
{
- enum
- {
- ECORE_X_SELECTION_CONTENT_NONE,
- ECORE_X_SELECTION_CONTENT_TEXT,
- ECORE_X_SELECTION_CONTENT_FILES,
- ECORE_X_SELECTION_CONTENT_TARGETS,
- ECORE_X_SELECTION_CONTENT_CUSTOM
- } content;
+ enum
+ {
+ ECORE_X_SELECTION_CONTENT_NONE,
+ ECORE_X_SELECTION_CONTENT_TEXT,
+ ECORE_X_SELECTION_CONTENT_FILES,
+ ECORE_X_SELECTION_CONTENT_TARGETS,
+ ECORE_X_SELECTION_CONTENT_CUSTOM
+ } content;
unsigned char *data;
int length;
int format;
@@ -693,9 +693,9 @@ struct _Ecore_X_Event_Xdnd_Enter
struct _Ecore_X_Event_Xdnd_Position
{
Ecore_X_Window win, source;
- struct
+ struct
{
- int x, y;
+ int x, y;
} position;
Ecore_X_Atom action;
};
@@ -703,9 +703,9 @@ struct _Ecore_X_Event_Xdnd_Position
struct _Ecore_X_Xdnd_Position
{
Ecore_X_Window win, prev;
- struct
+ struct
{
- int x, y;
+ int x, y;
} position;
};
@@ -726,16 +726,16 @@ struct _Ecore_X_Event_Xdnd_Drop
{
Ecore_X_Window win, source;
Ecore_X_Atom action;
- struct
+ struct
{
- int x, y;
+ int x, y;
} position;
};
struct _Ecore_X_Event_Xdnd_Finished
{
Ecore_X_Window win, target;
- Eina_Bool completed : 1;
+ Eina_Bool completed : 1;
Ecore_X_Atom action;
};
@@ -744,11 +744,11 @@ struct _Ecore_X_Event_Client_Message
Ecore_X_Window win;
Ecore_X_Atom message_type;
int format;
- union
+ union
{
- char b[20];
- short s[10];
- long l[5];
+ char b[20];
+ short s[10];
+ long l[5];
} data;
Ecore_X_Time time;
};
@@ -836,7 +836,7 @@ struct _Ecore_X_Event_Window_Delete_Request
Ecore_X_Window win;
Ecore_X_Time time;
};
-
+
struct _Ecore_X_Event_Startup_Sequence
{
Ecore_X_Window win;
@@ -959,54 +959,54 @@ typedef enum _Ecore_X_WM_Protocol
{
/* If enabled the window manager will be asked to send a
* delete message instead of just closing (destroying) the window. */
- ECORE_X_WM_PROTOCOL_DELETE_REQUEST,
+ ECORE_X_WM_PROTOCOL_DELETE_REQUEST,
- /* If enabled the window manager will be told that the window
- * explicitly sets input focus. */
- ECORE_X_WM_PROTOCOL_TAKE_FOCUS,
+ /* If enabled the window manager will be told that the window
+ * explicitly sets input focus. */
+ ECORE_X_WM_PROTOCOL_TAKE_FOCUS,
- /* If enabled the window manager can ping the window to check
- * if it is alive. */
- ECORE_X_NET_WM_PROTOCOL_PING,
+ /* If enabled the window manager can ping the window to check
+ * if it is alive. */
+ ECORE_X_NET_WM_PROTOCOL_PING,
- /* If enabled the window manager can sync updating with the
- * window (?) */
- ECORE_X_NET_WM_PROTOCOL_SYNC_REQUEST,
+ /* If enabled the window manager can sync updating with the
+ * window (?) */
+ ECORE_X_NET_WM_PROTOCOL_SYNC_REQUEST,
- /* Number of defined items */
- ECORE_X_WM_PROTOCOL_NUM
+ /* Number of defined items */
+ ECORE_X_WM_PROTOCOL_NUM
} Ecore_X_WM_Protocol;
typedef enum _Ecore_X_Window_Input_Mode
{
/* The window can never be focused */
- ECORE_X_WINDOW_INPUT_MODE_NONE,
+ ECORE_X_WINDOW_INPUT_MODE_NONE,
- /* The window can be focused by the WM but doesn't focus itself */
- ECORE_X_WINDOW_INPUT_MODE_PASSIVE,
+ /* The window can be focused by the WM but doesn't focus itself */
+ ECORE_X_WINDOW_INPUT_MODE_PASSIVE,
- /* The window sets the focus itself if one of its sub-windows
- * already is focused */
- ECORE_X_WINDOW_INPUT_MODE_ACTIVE_LOCAL,
+ /* The window sets the focus itself if one of its sub-windows
+ * already is focused */
+ ECORE_X_WINDOW_INPUT_MODE_ACTIVE_LOCAL,
- /* The window sets the focus itself even if another window
- * is currently focused */
- ECORE_X_WINDOW_INPUT_MODE_ACTIVE_GLOBAL
+ /* The window sets the focus itself even if another window
+ * is currently focused */
+ ECORE_X_WINDOW_INPUT_MODE_ACTIVE_GLOBAL
} Ecore_X_Window_Input_Mode;
typedef enum _Ecore_X_Window_State_Hint
{
/** Do not provide any state hint to the window manager */
- ECORE_X_WINDOW_STATE_HINT_NONE = -1,
+ ECORE_X_WINDOW_STATE_HINT_NONE = -1,
- /** The window wants to remain hidden and NOT iconified */
- ECORE_X_WINDOW_STATE_HINT_WITHDRAWN,
+ /** The window wants to remain hidden and NOT iconified */
+ ECORE_X_WINDOW_STATE_HINT_WITHDRAWN,
- /** The window wants to be mapped normally */
- ECORE_X_WINDOW_STATE_HINT_NORMAL,
+ /** The window wants to be mapped normally */
+ ECORE_X_WINDOW_STATE_HINT_NORMAL,
- /** The window wants to start in an iconified state */
- ECORE_X_WINDOW_STATE_HINT_ICONIC
+ /** The window wants to start in an iconified state */
+ ECORE_X_WINDOW_STATE_HINT_ICONIC
} Ecore_X_Window_State_Hint;
typedef enum _Ecore_X_Window_Type
@@ -1100,699 +1100,862 @@ typedef enum _Ecore_X_Illume_Quickpanel_State
#define ECORE_X_PROP_LIST_ADD 1
#define ECORE_X_PROP_LIST_TOGGLE 2
-EAPI int ecore_x_init(const char *name);
-EAPI int ecore_x_shutdown(void);
-EAPI int ecore_x_disconnect(void);
-EAPI Ecore_X_Display * ecore_x_display_get(void);
-EAPI Ecore_X_Connection * ecore_x_connection_get(void);
-EAPI int ecore_x_fd_get(void);
-EAPI Ecore_X_Screen * ecore_x_default_screen_get(void);
-EAPI void ecore_x_screen_size_get(const Ecore_X_Screen *screen, int *w, int *h);
-EAPI int ecore_x_screen_count_get(void);
-EAPI int ecore_x_screen_index_get(const Ecore_X_Screen *screen);
-EAPI Ecore_X_Screen * ecore_x_screen_get(int index);
-
-EAPI void ecore_x_double_click_time_set(double t);
-EAPI double ecore_x_double_click_time_get(void);
-EAPI void ecore_x_flush(void);
-EAPI void ecore_x_sync(void);
-EAPI void ecore_x_killall(Ecore_X_Window root);
-EAPI void ecore_x_kill(Ecore_X_Window win);
-EAPI int ecore_x_dpi_get(void);
-EAPI Eina_Bool ecore_x_bell(int percent);
-EAPI unsigned int ecore_x_visual_id_get(Ecore_X_Visual visual);
-
-EAPI Ecore_X_Visual ecore_x_default_visual_get(Ecore_X_Display *disp, Ecore_X_Screen *screen);
-EAPI Ecore_X_Colormap ecore_x_default_colormap_get(Ecore_X_Display *disp, Ecore_X_Screen *screen);
-EAPI int ecore_x_default_depth_get(Ecore_X_Display *disp, Ecore_X_Screen *screen);
-
-EAPI Ecore_X_Time ecore_x_current_time_get(void);
-
-EAPI void ecore_x_error_handler_set(void (*func)(void *data), const void *data);
-EAPI void ecore_x_io_error_handler_set(void (*func)(
- void *data), const void *data);
-EAPI int ecore_x_error_request_get(void);
-EAPI int ecore_x_error_code_get(void);
-
-EAPI void ecore_x_event_mask_set(Ecore_X_Window w,
- Ecore_X_Event_Mask mask);
-EAPI void ecore_x_event_mask_unset(Ecore_X_Window w,
- Ecore_X_Event_Mask mask);
-
-EAPI Eina_Bool ecore_x_selection_notify_send(Ecore_X_Window requestor,
- Ecore_X_Atom selection,
- Ecore_X_Atom target,
- Ecore_X_Atom property,
- Ecore_X_Time time);
-EAPI Eina_Bool ecore_x_selection_primary_set(Ecore_X_Window w,
- const void *data,
- int size);
-EAPI Eina_Bool ecore_x_selection_primary_clear(void);
-EAPI Eina_Bool ecore_x_selection_secondary_set(Ecore_X_Window w,
- const void *data,
- int size);
-EAPI Eina_Bool ecore_x_selection_secondary_clear(void);
-EAPI Eina_Bool ecore_x_selection_xdnd_set(Ecore_X_Window w,
- const void *data,
- int size);
-EAPI Eina_Bool ecore_x_selection_xdnd_clear(void);
-EAPI Eina_Bool ecore_x_selection_clipboard_set(Ecore_X_Window w,
- const void *data,
- int size);
-EAPI Eina_Bool ecore_x_selection_clipboard_clear(void);
-EAPI void ecore_x_selection_primary_request(Ecore_X_Window w,
- const char *target);
-EAPI void ecore_x_selection_secondary_request(Ecore_X_Window w,
- const char *target);
-EAPI void ecore_x_selection_xdnd_request(Ecore_X_Window w,
- const char *target);
-EAPI void ecore_x_selection_clipboard_request(Ecore_X_Window w,
- const char *target);
-EAPI Eina_Bool ecore_x_selection_convert(Ecore_X_Atom selection,
- Ecore_X_Atom target,
- void **data_ret,
- int *len,
- Ecore_X_Atom *targprop,
- int *targsize);
-EAPI void ecore_x_selection_converter_add(char *target, Eina_Bool (*func)(
- char *target,
- void *data,
- int size,
- void **data_ret,
- int *size_ret,
- Ecore_X_Atom *,
- int *));
-EAPI void ecore_x_selection_converter_atom_add(Ecore_X_Atom target, Eina_Bool (*func)(
- char *target,
- void *data,
- int size,
- void **data_ret,
- int *size_ret,
+EAPI int
+ ecore_x_init(const char *name);
+EAPI int
+ ecore_x_shutdown(void);
+EAPI int
+ ecore_x_disconnect(void);
+EAPI Ecore_X_Display *
+ ecore_x_display_get(void);
+EAPI Ecore_X_Connection *
+ ecore_x_connection_get(void);
+EAPI int
+ ecore_x_fd_get(void);
+EAPI Ecore_X_Screen *
+ ecore_x_default_screen_get(void);
+EAPI void
+ ecore_x_screen_size_get(const Ecore_X_Screen *screen,
+ int *w,
+ int *h);
+EAPI int
+ ecore_x_screen_count_get(void);
+EAPI int
+ ecore_x_screen_index_get(const Ecore_X_Screen *screen);
+EAPI Ecore_X_Screen *
+ ecore_x_screen_get(int index);
+
+EAPI void
+ ecore_x_double_click_time_set(double t);
+EAPI double
+ ecore_x_double_click_time_get(void);
+EAPI void
+ ecore_x_flush(void);
+EAPI void
+ ecore_x_sync(void);
+EAPI void
+ ecore_x_killall(Ecore_X_Window root);
+EAPI void
+ ecore_x_kill(Ecore_X_Window win);
+EAPI int
+ ecore_x_dpi_get(void);
+EAPI Eina_Bool
+ ecore_x_bell(int percent);
+EAPI unsigned int
+ ecore_x_visual_id_get(Ecore_X_Visual visual);
+
+EAPI Ecore_X_Visual
+ecore_x_default_visual_get(Ecore_X_Display *disp,
+ Ecore_X_Screen *screen);
+EAPI Ecore_X_Colormap
+ecore_x_default_colormap_get(Ecore_X_Display *disp,
+ Ecore_X_Screen *screen);
+EAPI int
+ecore_x_default_depth_get(Ecore_X_Display *disp,
+ Ecore_X_Screen *screen);
+
+EAPI Ecore_X_Time
+ecore_x_current_time_get(void);
+
+EAPI void
+ecore_x_error_handler_set(void (*func)(void *data),
+ const void *data);
+EAPI void
+ecore_x_io_error_handler_set(void (*func)(void *data),
+ const void *data);
+EAPI int
+ ecore_x_error_request_get(void);
+EAPI int
+ ecore_x_error_code_get(void);
+
+EAPI void
+ecore_x_event_mask_set(Ecore_X_Window w,
+ Ecore_X_Event_Mask mask);
+EAPI void
+ecore_x_event_mask_unset(Ecore_X_Window w,
+ Ecore_X_Event_Mask mask);
+
+EAPI Eina_Bool
+ecore_x_selection_notify_send(Ecore_X_Window requestor,
+ Ecore_X_Atom selection,
+ Ecore_X_Atom target,
+ Ecore_X_Atom property,
+ Ecore_X_Time time);
+EAPI Eina_Bool
+ecore_x_selection_primary_set(Ecore_X_Window w,
+ const void *data,
+ int size);
+EAPI Eina_Bool
+ ecore_x_selection_primary_clear(void);
+EAPI Eina_Bool
+ ecore_x_selection_secondary_set(Ecore_X_Window w,
+ const void *data,
+ int size);
+EAPI Eina_Bool
+ ecore_x_selection_secondary_clear(void);
+EAPI Eina_Bool
+ ecore_x_selection_xdnd_set(Ecore_X_Window w,
+ const void *data,
+ int size);
+EAPI Eina_Bool
+ ecore_x_selection_xdnd_clear(void);
+EAPI Eina_Bool
+ ecore_x_selection_clipboard_set(Ecore_X_Window w,
+ const void *data,
+ int size);
+EAPI Eina_Bool
+ ecore_x_selection_clipboard_clear(void);
+EAPI void
+ ecore_x_selection_primary_request(Ecore_X_Window w,
+ const char *target);
+EAPI void
+ecore_x_selection_secondary_request(Ecore_X_Window w,
+ const char *target);
+EAPI void
+ecore_x_selection_xdnd_request(Ecore_X_Window w,
+ const char *target);
+EAPI void
+ecore_x_selection_clipboard_request(Ecore_X_Window w,
+ const char *target);
+EAPI Eina_Bool
+ecore_x_selection_convert(Ecore_X_Atom selection,
+ Ecore_X_Atom target,
+ void **data_ret,
+ int *len,
+ Ecore_X_Atom *targprop,
+ int *targsize);
+EAPI void
+ecore_x_selection_converter_add(char *target,
+ Eina_Bool (*func)(char *target,
+ void *data,
+ int size,
+ void **data_ret,
+ int *size_ret,
+ Ecore_X_Atom *,
+ int *));
+EAPI void
+ecore_x_selection_converter_atom_add(Ecore_X_Atom target,
+ Eina_Bool (*func)(char *target,
+ void *data,
+ int size,
+ void **data_ret,
+ int *size_ret,
Ecore_X_Atom *tprop,
- int *tsize));
-EAPI void ecore_x_selection_converter_del(char *target);
-EAPI void ecore_x_selection_converter_atom_del(Ecore_X_Atom target);
-EAPI void ecore_x_selection_parser_add(const char *target,
- void *(*func)(const char *target,
- void *data, int size,
- int format));
-EAPI void ecore_x_selection_parser_del(const char *target);
-EAPI void ecore_x_selection_owner_set(Ecore_X_Window win, Ecore_X_Atom atom, Ecore_X_Time tm);
-EAPI Ecore_X_Window ecore_x_selection_owner_get(Ecore_X_Atom atom);
-
-EAPI void ecore_x_dnd_aware_set(Ecore_X_Window win, Eina_Bool on);
-EAPI int ecore_x_dnd_version_get(Ecore_X_Window win);
-EAPI Eina_Bool ecore_x_dnd_type_isset(Ecore_X_Window win,
- const char *type);
-EAPI void ecore_x_dnd_type_set(Ecore_X_Window win,
- const char *type,
- Eina_Bool on);
-EAPI void ecore_x_dnd_types_set(Ecore_X_Window win,
- const char **types,
- unsigned int num_types);
-EAPI void ecore_x_dnd_actions_set(Ecore_X_Window win,
- Ecore_X_Atom *actions,
- unsigned int num_actions);
-EAPI Eina_Bool ecore_x_dnd_begin(Ecore_X_Window source,
- unsigned char *data,
- int size);
-EAPI Eina_Bool ecore_x_dnd_drop(void);
-EAPI void ecore_x_dnd_send_status(Eina_Bool will_accept,
- Eina_Bool suppress,
- Ecore_X_Rectangle rectangle,
- Ecore_X_Atom action);
-EAPI void ecore_x_dnd_send_finished(void);
-EAPI void ecore_x_dnd_source_action_set(Ecore_X_Atom action);
-EAPI Ecore_X_Atom ecore_x_dnd_source_action_get(void);
-EAPI void ecore_x_dnd_callback_pos_update_set(void (*cb)(void *, Ecore_X_Xdnd_Position *data),
- const void *data);
-
-EAPI Ecore_X_Window ecore_x_window_new(Ecore_X_Window parent,
- int x,
- int y,
- int w,
- int h);
-EAPI Ecore_X_Window ecore_x_window_override_new(Ecore_X_Window parent,
- int x,
- int y,
- int w,
- int h);
-EAPI int ecore_x_window_argb_get(Ecore_X_Window win);
-EAPI Ecore_X_Window ecore_x_window_manager_argb_new(Ecore_X_Window parent,
- int x,
- int y,
- int w,
- int h);
-EAPI Ecore_X_Window ecore_x_window_argb_new(Ecore_X_Window parent,
- int x,
- int y,
- int w,
- int h);
-EAPI Ecore_X_Window ecore_x_window_override_argb_new(Ecore_X_Window parent,
- int x,
- int y,
- int w,
- int h);
-EAPI Ecore_X_Window ecore_x_window_input_new(Ecore_X_Window parent,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_configure(
- Ecore_X_Window win,
- Ecore_X_Window_Configure_Mask
- mask,
- int x,
- int y,
- int w,
- int h,
- int border_width,
- Ecore_X_Window sibling,
- int stack_mode);
-EAPI void ecore_x_window_cursor_set(Ecore_X_Window win,
- Ecore_X_Cursor c);
-EAPI void ecore_x_window_free(Ecore_X_Window win);
-EAPI void ecore_x_window_ignore_set(Ecore_X_Window win,
- int ignore);
-EAPI Ecore_X_Window * ecore_x_window_ignore_list(int *num);
-
-EAPI void ecore_x_window_delete_request_send(
- Ecore_X_Window win);
-EAPI void ecore_x_window_show(Ecore_X_Window win);
-EAPI void ecore_x_window_hide(Ecore_X_Window win);
-EAPI void ecore_x_window_move(Ecore_X_Window win,
- int x,
- int y);
-EAPI void ecore_x_window_resize(Ecore_X_Window win,
- int w,
- int h);
-EAPI void ecore_x_window_move_resize(Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_focus(Ecore_X_Window win);
-EAPI void ecore_x_window_focus_at_time(Ecore_X_Window win,
- Ecore_X_Time t);
-EAPI Ecore_X_Window ecore_x_window_focus_get(void);
-EAPI void ecore_x_window_raise(Ecore_X_Window win);
-EAPI void ecore_x_window_lower(Ecore_X_Window win);
-EAPI void ecore_x_window_reparent(Ecore_X_Window win,
- Ecore_X_Window new_parent,
- int x,
- int y);
-EAPI void ecore_x_window_size_get(Ecore_X_Window win,
- int *w,
- int *h);
-EAPI void ecore_x_window_geometry_get(Ecore_X_Window win,
- int *x,
- int *y,
- int *w,
- int *h);
-EAPI int ecore_x_window_border_width_get(
- Ecore_X_Window win);
-EAPI void ecore_x_window_border_width_set(
- Ecore_X_Window win,
- int width);
-EAPI int ecore_x_window_depth_get(Ecore_X_Window win);
-EAPI void ecore_x_window_cursor_show(Ecore_X_Window win,
- Eina_Bool show);
-EAPI void ecore_x_window_defaults_set(Ecore_X_Window win);
-EAPI int ecore_x_window_visible_get(Ecore_X_Window win);
-EAPI Ecore_X_Window ecore_x_window_shadow_tree_at_xy_with_skip_get(
- Ecore_X_Window base,
- int x,
- int y,
- Ecore_X_Window *skip,
- int skip_num);
-EAPI Ecore_X_Window ecore_x_window_shadow_parent_get(
- Ecore_X_Window root,
- Ecore_X_Window win);
-EAPI void ecore_x_window_shadow_tree_flush(void);
-EAPI Ecore_X_Window ecore_x_window_root_get(Ecore_X_Window win);
-EAPI Ecore_X_Window ecore_x_window_at_xy_get(int x, int y);
-EAPI Ecore_X_Window ecore_x_window_at_xy_with_skip_get(int x,
- int y,
- Ecore_X_Window *skip,
- int skip_num);
-EAPI Ecore_X_Window ecore_x_window_at_xy_begin_get(
- Ecore_X_Window begin,
- int x,
- int y);
-EAPI Ecore_X_Window ecore_x_window_parent_get(Ecore_X_Window win);
-
-EAPI void ecore_x_window_background_color_set(
- Ecore_X_Window win,
- unsigned
- short r,
- unsigned
- short g,
- unsigned
- short b);
-EAPI void ecore_x_window_gravity_set(Ecore_X_Window win,
- Ecore_X_Gravity grav);
-EAPI void ecore_x_window_pixel_gravity_set(
- Ecore_X_Window win,
- Ecore_X_Gravity
- grav);
-EAPI void ecore_x_window_pixmap_set(Ecore_X_Window win,
- Ecore_X_Pixmap pmap);
-EAPI void ecore_x_window_area_clear(Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_area_expose(Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_override_set(Ecore_X_Window win,
- Eina_Bool override);
-
-EAPI void ecore_x_window_prop_card32_set(
- Ecore_X_Window win,
- Ecore_X_Atom atom,
- unsigned int *val,
- unsigned int num);
-EAPI int ecore_x_window_prop_card32_get(
- Ecore_X_Window win,
- Ecore_X_Atom atom,
- unsigned int *val,
- unsigned int len);
-EAPI int ecore_x_window_prop_card32_list_get(
- Ecore_X_Window win,
- Ecore_X_Atom
- atom,
- unsigned int
- **plst);
-
-EAPI void ecore_x_window_prop_xid_set(Ecore_X_Window win,
- Ecore_X_Atom atom,
- Ecore_X_Atom type,
- Ecore_X_ID *lst,
- unsigned int num);
-EAPI int ecore_x_window_prop_xid_get(Ecore_X_Window win,
- Ecore_X_Atom atom,
- Ecore_X_Atom type,
- Ecore_X_ID *lst,
- unsigned int len);
-EAPI int ecore_x_window_prop_xid_list_get(
- Ecore_X_Window win,
- Ecore_X_Atom
- atom,
- Ecore_X_Atom
- type,
- Ecore_X_ID **
- plst);
-EAPI void ecore_x_window_prop_xid_list_change(
- Ecore_X_Window win,
- Ecore_X_Atom
- atom,
- Ecore_X_Atom
- type,
- Ecore_X_ID
- item,
- int op);
-EAPI void ecore_x_window_prop_atom_set(Ecore_X_Window win,
- Ecore_X_Atom atom,
- Ecore_X_Atom *val,
- unsigned int num);
-EAPI int ecore_x_window_prop_atom_get(Ecore_X_Window win,
- Ecore_X_Atom atom,
- Ecore_X_Atom *val,
- unsigned int len);
-EAPI int ecore_x_window_prop_atom_list_get(
- Ecore_X_Window win,
- Ecore_X_Atom
- atom,
- Ecore_X_Atom *
- *plst);
-EAPI void ecore_x_window_prop_atom_list_change(
- Ecore_X_Window win,
- Ecore_X_Atom
- atom,
- Ecore_X_Atom
- item,
- int op);
-EAPI void ecore_x_window_prop_window_set(
- Ecore_X_Window win,
- Ecore_X_Atom atom,
- Ecore_X_Window *
- val,
- unsigned int num);
-EAPI int ecore_x_window_prop_window_get(
- Ecore_X_Window win,
- Ecore_X_Atom atom,
- Ecore_X_Window *
- val,
- unsigned int len);
-EAPI int ecore_x_window_prop_window_list_get(
- Ecore_X_Window win,
- Ecore_X_Atom
- atom,
- Ecore_X_Window
- **plst);
-
-EAPI Ecore_X_Atom ecore_x_window_prop_any_type(void);
-EAPI void ecore_x_window_prop_property_set(
- Ecore_X_Window win,
- Ecore_X_Atom type,
- Ecore_X_Atom format,
- int size,
- void *data,
- int number);
-EAPI int ecore_x_window_prop_property_get(
- Ecore_X_Window win,
- Ecore_X_Atom property,
- Ecore_X_Atom type,
- int size,
- unsigned char **data,
- int *num);
-EAPI void ecore_x_window_prop_property_del(
- Ecore_X_Window win,
- Ecore_X_Atom property);
-EAPI Ecore_X_Atom * ecore_x_window_prop_list(Ecore_X_Window win,
- int *num_ret);
-EAPI void ecore_x_window_prop_string_set(
- Ecore_X_Window win,
- Ecore_X_Atom type,
- const char *str);
-EAPI char * ecore_x_window_prop_string_get(
- Ecore_X_Window win,
- Ecore_X_Atom type);
-EAPI Eina_Bool ecore_x_window_prop_protocol_isset(
- Ecore_X_Window win,
- Ecore_X_WM_Protocol protocol);
-EAPI Ecore_X_WM_Protocol * ecore_x_window_prop_protocol_list_get(
- Ecore_X_Window win,
- int *num_ret);
-
-EAPI void ecore_x_window_shape_mask_set(Ecore_X_Window win,
- Ecore_X_Pixmap mask);
-EAPI void ecore_x_window_shape_window_set(
- Ecore_X_Window win,
- Ecore_X_Window shape_win);
-EAPI void ecore_x_window_shape_window_set_xy(
- Ecore_X_Window win,
- Ecore_X_Window shape_win,
- int x,
- int y);
-EAPI void ecore_x_window_shape_rectangle_set(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_shape_rectangles_set(
- Ecore_X_Window win,
- Ecore_X_Rectangle *rects,
- int num);
-EAPI void ecore_x_window_shape_input_rectangle_set(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_shape_input_rectangles_set(
- Ecore_X_Window win,
- Ecore_X_Rectangle *rects,
- int num);
-EAPI void ecore_x_window_shape_input_rectangle_add(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_shape_rectangle_subtract(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_shape_input_rectangle_subtract(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_shape_input_window_set_xy(
- Ecore_X_Window win,
- Ecore_X_Window shape_win,
- int x,
- int y);
-EAPI void ecore_x_window_shape_input_window_set(
- Ecore_X_Window win,
- Ecore_X_Window shape_win);
-EAPI void ecore_x_window_shape_window_add(
- Ecore_X_Window win,
- Ecore_X_Window shape_win);
-EAPI void ecore_x_window_shape_window_add_xy(
- Ecore_X_Window win,
- Ecore_X_Window shape_win,
- int x,
- int y);
-EAPI void ecore_x_window_shape_input_window_add_xy(
- Ecore_X_Window win,
- Ecore_X_Window shape_win,
- int x,
- int y);
-EAPI void ecore_x_window_shape_rectangle_add(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_shape_rectangle_clip(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_shape_input_rectangle_clip(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_window_shape_rectangles_add(
- Ecore_X_Window win,
- Ecore_X_Rectangle *rects,
- int num);
-EAPI void ecore_x_window_shape_input_rectangles_add(
- Ecore_X_Window win,
- Ecore_X_Rectangle *rects,
- int num);
-EAPI Ecore_X_Rectangle * ecore_x_window_shape_rectangles_get(
- Ecore_X_Window win,
- int *num_ret);
-EAPI Ecore_X_Rectangle * ecore_x_window_shape_input_rectangles_get(
- Ecore_X_Window win,
- int *num_ret);
-EAPI void ecore_x_window_shape_events_select(
- Ecore_X_Window win,
- Eina_Bool on);
-EAPI void ecore_x_window_shape_input_mask_set(
- Ecore_X_Window win,
- Ecore_X_Pixmap mask);
-
-EAPI Ecore_X_Pixmap ecore_x_pixmap_new(Ecore_X_Window win,
- int w,
- int h,
- int dep);
-EAPI void ecore_x_pixmap_free(Ecore_X_Pixmap pmap);
-EAPI void ecore_x_pixmap_paste(Ecore_X_Pixmap pmap,
- Ecore_X_Drawable dest,
- Ecore_X_GC gc,
- int sx,
- int sy,
- int w,
- int h,
- int dx,
- int dy);
-EAPI void ecore_x_pixmap_geometry_get(Ecore_X_Pixmap pmap,
- int *x,
- int *y,
- int *w,
- int *h);
-EAPI int ecore_x_pixmap_depth_get(Ecore_X_Pixmap pmap);
-
-EAPI Ecore_X_GC ecore_x_gc_new(Ecore_X_Drawable draw,
- Ecore_X_GC_Value_Mask value_mask,
- const unsigned int *value_list);
-EAPI void ecore_x_gc_free(Ecore_X_GC gc);
-EAPI void ecore_x_gc_foreground_set(Ecore_X_GC gc, unsigned long foreground);
-EAPI void ecore_x_gc_background_set(Ecore_X_GC gc, unsigned long background);
-
-EAPI Eina_Bool ecore_x_client_message32_send(Ecore_X_Window win,
- Ecore_X_Atom type,
- Ecore_X_Event_Mask mask,
- long d0,
- long d1,
- long d2,
- long d3,
- long d4);
-EAPI Eina_Bool ecore_x_client_message8_send(Ecore_X_Window win,
- Ecore_X_Atom type,
- const void *data,
- int len);
-EAPI Eina_Bool ecore_x_mouse_move_send(Ecore_X_Window win,
- int x,
- int y);
-EAPI Eina_Bool ecore_x_mouse_down_send(Ecore_X_Window win,
- int x,
- int y,
- int b);
-EAPI Eina_Bool ecore_x_mouse_up_send(Ecore_X_Window win,
- int x,
- int y,
- int b);
-
-EAPI void ecore_x_drawable_geometry_get(Ecore_X_Drawable d,
- int *x,
- int *y,
- int *w,
- int *h);
-EAPI int ecore_x_drawable_border_width_get(
- Ecore_X_Drawable d);
-EAPI int ecore_x_drawable_depth_get(Ecore_X_Drawable d);
-EAPI void ecore_x_drawable_rectangle_fill(
- Ecore_X_Drawable d,
- Ecore_X_GC gc,
- int x,
- int y,
- int width,
- int height);
-
-EAPI Eina_Bool ecore_x_cursor_color_supported_get(void);
-EAPI Ecore_X_Cursor ecore_x_cursor_new(Ecore_X_Window win,
- int *pixels,
- int w,
- int h,
- int hot_x,
- int hot_y);
-EAPI void ecore_x_cursor_free(Ecore_X_Cursor c);
-EAPI Ecore_X_Cursor ecore_x_cursor_shape_get(int shape);
-EAPI void ecore_x_cursor_size_set(int size);
-EAPI int ecore_x_cursor_size_get(void);
+ int *tsize));
+EAPI void
+ ecore_x_selection_converter_del(char *target);
+EAPI void
+ ecore_x_selection_converter_atom_del(Ecore_X_Atom target);
+EAPI void
+ ecore_x_selection_parser_add(const char *target,
+ void *(*func)(const char *target, void *data, int size, int format));
+EAPI void
+ ecore_x_selection_parser_del(const char *target);
+EAPI void
+ ecore_x_selection_owner_set(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Time tm);
+EAPI Ecore_X_Window
+ecore_x_selection_owner_get(Ecore_X_Atom atom);
+
+EAPI void
+ecore_x_dnd_aware_set(Ecore_X_Window win,
+ Eina_Bool on);
+EAPI int
+ ecore_x_dnd_version_get(Ecore_X_Window win);
+EAPI Eina_Bool
+ ecore_x_dnd_type_isset(Ecore_X_Window win,
+ const char *type);
+EAPI void
+ecore_x_dnd_type_set(Ecore_X_Window win,
+ const char *type,
+ Eina_Bool on);
+EAPI void
+ecore_x_dnd_types_set(Ecore_X_Window win,
+ const char **types,
+ unsigned int num_types);
+EAPI void
+ecore_x_dnd_actions_set(Ecore_X_Window win,
+ Ecore_X_Atom *actions,
+ unsigned int num_actions);
+EAPI Eina_Bool
+ecore_x_dnd_begin(Ecore_X_Window source,
+ unsigned char *data,
+ int size);
+EAPI Eina_Bool
+ ecore_x_dnd_drop(void);
+EAPI void
+ ecore_x_dnd_send_status(Eina_Bool will_accept,
+ Eina_Bool suppress,
+ Ecore_X_Rectangle rectangle,
+ Ecore_X_Atom action);
+EAPI void
+ ecore_x_dnd_send_finished(void);
+EAPI void
+ ecore_x_dnd_source_action_set(Ecore_X_Atom action);
+EAPI Ecore_X_Atom
+ ecore_x_dnd_source_action_get(void);
+EAPI void
+ ecore_x_dnd_callback_pos_update_set(void (*cb)(void *,
+ Ecore_X_Xdnd_Position *data),
+ const void *data);
+
+EAPI Ecore_X_Window
+ecore_x_window_new(Ecore_X_Window parent,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI Ecore_X_Window
+ecore_x_window_override_new(Ecore_X_Window parent,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI int
+ ecore_x_window_argb_get(Ecore_X_Window win);
+EAPI Ecore_X_Window
+ ecore_x_window_manager_argb_new(Ecore_X_Window parent,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI Ecore_X_Window
+ecore_x_window_argb_new(Ecore_X_Window parent,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI Ecore_X_Window
+ecore_x_window_override_argb_new(Ecore_X_Window parent,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI Ecore_X_Window
+ecore_x_window_input_new(Ecore_X_Window parent,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_configure(Ecore_X_Window win,
+ Ecore_X_Window_Configure_Mask mask,
+ int x,
+ int y,
+ int w,
+ int h,
+ int border_width,
+ Ecore_X_Window sibling,
+ int stack_mode);
+EAPI void
+ecore_x_window_cursor_set(Ecore_X_Window win,
+ Ecore_X_Cursor c);
+EAPI void
+ ecore_x_window_free(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_ignore_set(Ecore_X_Window win,
+ int ignore);
+EAPI Ecore_X_Window *
+ecore_x_window_ignore_list(int *num);
+
+EAPI void
+ ecore_x_window_delete_request_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_show(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_hide(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_move(Ecore_X_Window win,
+ int x,
+ int y);
+EAPI void
+ecore_x_window_resize(Ecore_X_Window win,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_move_resize(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ ecore_x_window_focus(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_focus_at_time(Ecore_X_Window win,
+ Ecore_X_Time t);
+EAPI Ecore_X_Window
+ ecore_x_window_focus_get(void);
+EAPI void
+ ecore_x_window_raise(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_lower(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_reparent(Ecore_X_Window win,
+ Ecore_X_Window new_parent,
+ int x,
+ int y);
+EAPI void
+ecore_x_window_size_get(Ecore_X_Window win,
+ int *w,
+ int *h);
+EAPI void
+ecore_x_window_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *w,
+ int *h);
+EAPI int
+ ecore_x_window_border_width_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_border_width_set(Ecore_X_Window win,
+ int width);
+EAPI int
+ ecore_x_window_depth_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_cursor_show(Ecore_X_Window win,
+ Eina_Bool show);
+EAPI void
+ ecore_x_window_defaults_set(Ecore_X_Window win);
+EAPI int
+ ecore_x_window_visible_get(Ecore_X_Window win);
+EAPI Ecore_X_Window
+ ecore_x_window_shadow_tree_at_xy_with_skip_get(Ecore_X_Window base,
+ int x,
+ int y,
+ Ecore_X_Window *skip,
+ int skip_num);
+EAPI Ecore_X_Window
+ecore_x_window_shadow_parent_get(Ecore_X_Window root,
+ Ecore_X_Window win);
+EAPI void
+ ecore_x_window_shadow_tree_flush(void);
+EAPI Ecore_X_Window
+ ecore_x_window_root_get(Ecore_X_Window win);
+EAPI Ecore_X_Window
+ ecore_x_window_at_xy_get(int x,
+ int y);
+EAPI Ecore_X_Window
+ecore_x_window_at_xy_with_skip_get(int x,
+ int y,
+ Ecore_X_Window *skip,
+ int skip_num);
+EAPI Ecore_X_Window
+ecore_x_window_at_xy_begin_get(Ecore_X_Window begin,
+ int x,
+ int y);
+EAPI Ecore_X_Window
+ecore_x_window_parent_get(Ecore_X_Window win);
+
+EAPI void
+ecore_x_window_background_color_set(Ecore_X_Window win,
+ unsigned short r,
+ unsigned short g,
+ unsigned short b);
+EAPI void
+ecore_x_window_gravity_set(Ecore_X_Window win,
+ Ecore_X_Gravity grav);
+EAPI void
+ecore_x_window_pixel_gravity_set(Ecore_X_Window win,
+ Ecore_X_Gravity grav);
+EAPI void
+ecore_x_window_pixmap_set(Ecore_X_Window win,
+ Ecore_X_Pixmap pmap);
+EAPI void
+ecore_x_window_area_clear(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_area_expose(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_override_set(Ecore_X_Window win,
+ Eina_Bool override);
+
+EAPI void
+ecore_x_window_prop_card32_set(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ unsigned int *val,
+ unsigned int num);
+EAPI int
+ecore_x_window_prop_card32_get(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ unsigned int *val,
+ unsigned int len);
+EAPI int
+ecore_x_window_prop_card32_list_get(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ unsigned int **plst);
+
+EAPI void
+ecore_x_window_prop_xid_set(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Atom type,
+ Ecore_X_ID *lst,
+ unsigned int num);
+EAPI int
+ecore_x_window_prop_xid_get(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Atom type,
+ Ecore_X_ID *lst,
+ unsigned int len);
+EAPI int
+ecore_x_window_prop_xid_list_get(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Atom type,
+ Ecore_X_ID **plst);
+EAPI void
+ecore_x_window_prop_xid_list_change(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Atom type,
+ Ecore_X_ID item,
+ int op);
+EAPI void
+ecore_x_window_prop_atom_set(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Atom *val,
+ unsigned int num);
+EAPI int
+ecore_x_window_prop_atom_get(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Atom *val,
+ unsigned int len);
+EAPI int
+ecore_x_window_prop_atom_list_get(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Atom **plst);
+EAPI void
+ecore_x_window_prop_atom_list_change(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Atom item,
+ int op);
+EAPI void
+ecore_x_window_prop_window_set(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Window *val,
+ unsigned int num);
+EAPI int
+ecore_x_window_prop_window_get(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Window *val,
+ unsigned int len);
+EAPI int
+ecore_x_window_prop_window_list_get(Ecore_X_Window win,
+ Ecore_X_Atom atom,
+ Ecore_X_Window **plst);
+
+EAPI Ecore_X_Atom
+ ecore_x_window_prop_any_type(void);
+EAPI void
+ ecore_x_window_prop_property_set(Ecore_X_Window win,
+ Ecore_X_Atom type,
+ Ecore_X_Atom format,
+ int size,
+ void *data,
+ int number);
+EAPI int
+ecore_x_window_prop_property_get(Ecore_X_Window win,
+ Ecore_X_Atom property,
+ Ecore_X_Atom type,
+ int size,
+ unsigned char **data,
+ int *num);
+EAPI void
+ecore_x_window_prop_property_del(Ecore_X_Window win,
+ Ecore_X_Atom property);
+EAPI Ecore_X_Atom *
+ecore_x_window_prop_list(Ecore_X_Window win,
+ int *num_ret);
+EAPI void
+ecore_x_window_prop_string_set(Ecore_X_Window win,
+ Ecore_X_Atom type,
+ const char *str);
+EAPI char *
+ecore_x_window_prop_string_get(Ecore_X_Window win,
+ Ecore_X_Atom type);
+EAPI Eina_Bool
+ecore_x_window_prop_protocol_isset(Ecore_X_Window win,
+ Ecore_X_WM_Protocol protocol);
+EAPI Ecore_X_WM_Protocol *
+ecore_x_window_prop_protocol_list_get(Ecore_X_Window win,
+ int *num_ret);
+
+EAPI void
+ecore_x_window_shape_mask_set(Ecore_X_Window win,
+ Ecore_X_Pixmap mask);
+EAPI void
+ecore_x_window_shape_window_set(Ecore_X_Window win,
+ Ecore_X_Window shape_win);
+EAPI void
+ecore_x_window_shape_window_set_xy(Ecore_X_Window win,
+ Ecore_X_Window shape_win,
+ int x,
+ int y);
+EAPI void
+ecore_x_window_shape_rectangle_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_shape_rectangles_set(Ecore_X_Window win,
+ Ecore_X_Rectangle *rects,
+ int num);
+EAPI void
+ecore_x_window_shape_input_rectangle_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_shape_input_rectangles_set(Ecore_X_Window win,
+ Ecore_X_Rectangle *rects,
+ int num);
+EAPI void
+ecore_x_window_shape_input_rectangle_add(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_shape_rectangle_subtract(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_shape_input_rectangle_subtract(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_shape_input_window_set_xy(Ecore_X_Window win,
+ Ecore_X_Window shape_win,
+ int x,
+ int y);
+EAPI void
+ecore_x_window_shape_input_window_set(Ecore_X_Window win,
+ Ecore_X_Window shape_win);
+EAPI void
+ecore_x_window_shape_window_add(Ecore_X_Window win,
+ Ecore_X_Window shape_win);
+EAPI void
+ecore_x_window_shape_window_add_xy(Ecore_X_Window win,
+ Ecore_X_Window shape_win,
+ int x,
+ int y);
+EAPI void
+ecore_x_window_shape_input_window_add_xy(Ecore_X_Window win,
+ Ecore_X_Window shape_win,
+ int x,
+ int y);
+EAPI void
+ecore_x_window_shape_rectangle_add(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_shape_rectangle_clip(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_shape_input_rectangle_clip(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_window_shape_rectangles_add(Ecore_X_Window win,
+ Ecore_X_Rectangle *rects,
+ int num);
+EAPI void
+ecore_x_window_shape_input_rectangles_add(Ecore_X_Window win,
+ Ecore_X_Rectangle *rects,
+ int num);
+EAPI Ecore_X_Rectangle *
+ecore_x_window_shape_rectangles_get(Ecore_X_Window win,
+ int *num_ret);
+EAPI Ecore_X_Rectangle *
+ecore_x_window_shape_input_rectangles_get(Ecore_X_Window win,
+ int *num_ret);
+EAPI void
+ecore_x_window_shape_events_select(Ecore_X_Window win,
+ Eina_Bool on);
+EAPI void
+ecore_x_window_shape_input_mask_set(Ecore_X_Window win,
+ Ecore_X_Pixmap mask);
+
+EAPI Ecore_X_Pixmap
+ecore_x_pixmap_new(Ecore_X_Window win,
+ int w,
+ int h,
+ int dep);
+EAPI void
+ ecore_x_pixmap_free(Ecore_X_Pixmap pmap);
+EAPI void
+ ecore_x_pixmap_paste(Ecore_X_Pixmap pmap,
+ Ecore_X_Drawable dest,
+ Ecore_X_GC gc,
+ int sx,
+ int sy,
+ int w,
+ int h,
+ int dx,
+ int dy);
+EAPI void
+ecore_x_pixmap_geometry_get(Ecore_X_Pixmap pmap,
+ int *x,
+ int *y,
+ int *w,
+ int *h);
+EAPI int
+ecore_x_pixmap_depth_get(Ecore_X_Pixmap pmap);
+
+EAPI Ecore_X_GC
+ecore_x_gc_new(Ecore_X_Drawable draw,
+ Ecore_X_GC_Value_Mask value_mask,
+ const unsigned int *value_list);
+EAPI void
+ ecore_x_gc_free(Ecore_X_GC gc);
+EAPI void
+ ecore_x_gc_foreground_set(Ecore_X_GC gc,
+ unsigned long foreground);
+EAPI void
+ecore_x_gc_background_set(Ecore_X_GC gc,
+ unsigned long background);
+
+EAPI Eina_Bool
+ecore_x_client_message32_send(Ecore_X_Window win,
+ Ecore_X_Atom type,
+ Ecore_X_Event_Mask mask,
+ long d0,
+ long d1,
+ long d2,
+ long d3,
+ long d4);
+EAPI Eina_Bool
+ecore_x_client_message8_send(Ecore_X_Window win,
+ Ecore_X_Atom type,
+ const void *data,
+ int len);
+EAPI Eina_Bool
+ecore_x_mouse_move_send(Ecore_X_Window win,
+ int x,
+ int y);
+EAPI Eina_Bool
+ecore_x_mouse_down_send(Ecore_X_Window win,
+ int x,
+ int y,
+ int b);
+EAPI Eina_Bool
+ecore_x_mouse_up_send(Ecore_X_Window win,
+ int x,
+ int y,
+ int b);
+
+EAPI void
+ecore_x_drawable_geometry_get(Ecore_X_Drawable d,
+ int *x,
+ int *y,
+ int *w,
+ int *h);
+EAPI int
+ ecore_x_drawable_border_width_get(Ecore_X_Drawable d);
+EAPI int
+ ecore_x_drawable_depth_get(Ecore_X_Drawable d);
+EAPI void
+ ecore_x_drawable_rectangle_fill(Ecore_X_Drawable d,
+ Ecore_X_GC gc,
+ int x,
+ int y,
+ int width,
+ int height);
+
+EAPI Eina_Bool
+ ecore_x_cursor_color_supported_get(void);
+EAPI Ecore_X_Cursor
+ ecore_x_cursor_new(Ecore_X_Window win,
+ int *pixels,
+ int w,
+ int h,
+ int hot_x,
+ int hot_y);
+EAPI void
+ ecore_x_cursor_free(Ecore_X_Cursor c);
+EAPI Ecore_X_Cursor
+ ecore_x_cursor_shape_get(int shape);
+EAPI void
+ ecore_x_cursor_size_set(int size);
+EAPI int
+ ecore_x_cursor_size_get(void);
/* FIXME: these funcs need categorising */
-EAPI Ecore_X_Window * ecore_x_window_root_list(int *num_ret);
-EAPI Ecore_X_Window ecore_x_window_root_first_get(void);
-EAPI Eina_Bool ecore_x_window_manage(Ecore_X_Window win);
-EAPI void ecore_x_window_container_manage(
- Ecore_X_Window win);
-EAPI void ecore_x_window_client_manage(Ecore_X_Window win);
-EAPI void ecore_x_window_sniff(Ecore_X_Window win);
-EAPI void ecore_x_window_client_sniff(Ecore_X_Window win);
-
-EAPI Ecore_X_Atom ecore_x_atom_get(const char *name);
-EAPI void ecore_x_atoms_get(const char **names,
- int num,
- Ecore_X_Atom *atoms);
-EAPI char * ecore_x_atom_name_get(Ecore_X_Atom atom);
-
-EAPI void ecore_x_icccm_init(void);
-EAPI void ecore_x_icccm_state_set(
- Ecore_X_Window win,
- Ecore_X_Window_State_Hint
- state);
-EAPI Ecore_X_Window_State_Hint ecore_x_icccm_state_get(Ecore_X_Window win);
-EAPI void ecore_x_icccm_delete_window_send(
- Ecore_X_Window win,
- Ecore_X_Time t);
-EAPI void ecore_x_icccm_take_focus_send(Ecore_X_Window win,
- Ecore_X_Time t);
-EAPI void ecore_x_icccm_save_yourself_send(
- Ecore_X_Window win,
- Ecore_X_Time t);
-EAPI void ecore_x_icccm_move_resize_send(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI void ecore_x_icccm_hints_set(
- Ecore_X_Window win,
- Eina_Bool accepts_focus,
- Ecore_X_Window_State_Hint
- initial_state,
- Ecore_X_Pixmap
- icon_pixmap,
- Ecore_X_Pixmap icon_mask,
- Ecore_X_Window
- icon_window,
- Ecore_X_Window
- window_group,
- Eina_Bool is_urgent);
-EAPI Eina_Bool ecore_x_icccm_hints_get(Ecore_X_Window win,
- Eina_Bool *accepts_focus,
- Ecore_X_Window_State_Hint *initial_state,
- Ecore_X_Pixmap *icon_pixmap,
- Ecore_X_Pixmap *icon_mask,
- Ecore_X_Window *icon_window,
- Ecore_X_Window *window_group,
- Eina_Bool *is_urgent);
-EAPI void ecore_x_icccm_size_pos_hints_set(Ecore_X_Window win,
- Eina_Bool request_pos,
- Ecore_X_Gravity gravity,
- int min_w, int min_h,
- int max_w, int max_h,
- int base_w, int base_h,
- int step_x, int step_y,
- double min_aspect,
- double max_aspect);
-EAPI Eina_Bool ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win,
- Eina_Bool *request_pos,
- Ecore_X_Gravity *gravity,
- int *min_w, int *min_h,
- int *max_w, int *max_h,
- int *base_w, int *base_h,
- int *step_x, int *step_y,
- double *min_aspect,
- double *max_aspect);
-EAPI void ecore_x_icccm_title_set(Ecore_X_Window win, const char *t);
-EAPI char * ecore_x_icccm_title_get(Ecore_X_Window win);
-EAPI void ecore_x_icccm_protocol_atoms_set(Ecore_X_Window win,
- Ecore_X_Atom *protos,
- int num);
-EAPI void ecore_x_icccm_protocol_set(Ecore_X_Window win,
- Ecore_X_WM_Protocol protocol,
- Eina_Bool on);
-EAPI Eina_Bool ecore_x_icccm_protocol_isset(Ecore_X_Window win,
- Ecore_X_WM_Protocol protocol);
-EAPI void ecore_x_icccm_name_class_set(Ecore_X_Window win,
- const char *n,
- const char *c);
-EAPI void ecore_x_icccm_name_class_get(Ecore_X_Window win,
- char **n,
- char **c);
-EAPI char * ecore_x_icccm_client_machine_get(Ecore_X_Window win);
-EAPI void ecore_x_icccm_command_set(Ecore_X_Window win,
- int argc,
- char **argv);
-EAPI void ecore_x_icccm_command_get(Ecore_X_Window win,
- int *argc,
- char ***argv);
-EAPI char * ecore_x_icccm_icon_name_get(Ecore_X_Window win);
-EAPI void ecore_x_icccm_icon_name_set(Ecore_X_Window win,
- const char *t);
-EAPI void ecore_x_icccm_colormap_window_set(Ecore_X_Window win,
- Ecore_X_Window subwin);
-EAPI void ecore_x_icccm_colormap_window_unset(Ecore_X_Window win,
- Ecore_X_Window subwin);
-EAPI void ecore_x_icccm_transient_for_set(Ecore_X_Window win,
- Ecore_X_Window forwin);
-EAPI void ecore_x_icccm_transient_for_unset(Ecore_X_Window win);
-EAPI Ecore_X_Window ecore_x_icccm_transient_for_get(Ecore_X_Window win);
-EAPI void ecore_x_icccm_window_role_set(Ecore_X_Window win,
- const char *role);
-EAPI char * ecore_x_icccm_window_role_get(Ecore_X_Window win);
-EAPI void ecore_x_icccm_client_leader_set(Ecore_X_Window win,
- Ecore_X_Window l);
-EAPI Ecore_X_Window ecore_x_icccm_client_leader_get(Ecore_X_Window win);
-EAPI void ecore_x_icccm_iconic_request_send(Ecore_X_Window win,
- Ecore_X_Window root);
+EAPI Ecore_X_Window *
+ ecore_x_window_root_list(int *num_ret);
+EAPI Ecore_X_Window
+ ecore_x_window_root_first_get(void);
+EAPI Eina_Bool
+ ecore_x_window_manage(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_container_manage(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_client_manage(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_sniff(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_client_sniff(Ecore_X_Window win);
+
+EAPI Ecore_X_Atom
+ ecore_x_atom_get(const char *name);
+EAPI void
+ ecore_x_atoms_get(const char **names,
+ int num,
+ Ecore_X_Atom *atoms);
+EAPI char *
+ecore_x_atom_name_get(Ecore_X_Atom atom);
+
+EAPI void
+ ecore_x_icccm_init(void);
+EAPI void
+ ecore_x_icccm_state_set(Ecore_X_Window win,
+ Ecore_X_Window_State_Hint state);
+EAPI Ecore_X_Window_State_Hint
+ ecore_x_icccm_state_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_icccm_delete_window_send(Ecore_X_Window win,
+ Ecore_X_Time t);
+EAPI void
+ecore_x_icccm_take_focus_send(Ecore_X_Window win,
+ Ecore_X_Time t);
+EAPI void
+ecore_x_icccm_save_yourself_send(Ecore_X_Window win,
+ Ecore_X_Time t);
+EAPI void
+ecore_x_icccm_move_resize_send(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI void
+ecore_x_icccm_hints_set(Ecore_X_Window win,
+ Eina_Bool accepts_focus,
+ Ecore_X_Window_State_Hint initial_state,
+ Ecore_X_Pixmap icon_pixmap,
+ Ecore_X_Pixmap icon_mask,
+ Ecore_X_Window icon_window,
+ Ecore_X_Window window_group,
+ Eina_Bool is_urgent);
+EAPI Eina_Bool
+ecore_x_icccm_hints_get(Ecore_X_Window win,
+ Eina_Bool *accepts_focus,
+ Ecore_X_Window_State_Hint *initial_state,
+ Ecore_X_Pixmap *icon_pixmap,
+ Ecore_X_Pixmap *icon_mask,
+ Ecore_X_Window *icon_window,
+ Ecore_X_Window *window_group,
+ Eina_Bool *is_urgent);
+EAPI void
+ecore_x_icccm_size_pos_hints_set(Ecore_X_Window win,
+ Eina_Bool request_pos,
+ Ecore_X_Gravity gravity,
+ int min_w,
+ int min_h,
+ int max_w,
+ int max_h,
+ int base_w,
+ int base_h,
+ int step_x,
+ int step_y,
+ double min_aspect,
+ double max_aspect);
+EAPI Eina_Bool
+ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win,
+ Eina_Bool *request_pos,
+ Ecore_X_Gravity *gravity,
+ int *min_w,
+ int *min_h,
+ int *max_w,
+ int *max_h,
+ int *base_w,
+ int *base_h,
+ int *step_x,
+ int *step_y,
+ double *min_aspect,
+ double *max_aspect);
+EAPI void
+ecore_x_icccm_title_set(Ecore_X_Window win,
+ const char *t);
+EAPI char *
+ ecore_x_icccm_title_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_icccm_protocol_atoms_set(Ecore_X_Window win,
+ Ecore_X_Atom *protos,
+ int num);
+EAPI void
+ecore_x_icccm_protocol_set(Ecore_X_Window win,
+ Ecore_X_WM_Protocol protocol,
+ Eina_Bool on);
+EAPI Eina_Bool
+ecore_x_icccm_protocol_isset(Ecore_X_Window win,
+ Ecore_X_WM_Protocol protocol);
+EAPI void
+ecore_x_icccm_name_class_set(Ecore_X_Window win,
+ const char *n,
+ const char *c);
+EAPI void
+ecore_x_icccm_name_class_get(Ecore_X_Window win,
+ char **n,
+ char **c);
+EAPI char *
+ ecore_x_icccm_client_machine_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_icccm_command_set(Ecore_X_Window win,
+ int argc,
+ char **argv);
+EAPI void
+ecore_x_icccm_command_get(Ecore_X_Window win,
+ int *argc,
+ char ***argv);
+EAPI char *
+ ecore_x_icccm_icon_name_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_icccm_icon_name_set(Ecore_X_Window win,
+ const char *t);
+EAPI void
+ecore_x_icccm_colormap_window_set(Ecore_X_Window win,
+ Ecore_X_Window subwin);
+EAPI void
+ecore_x_icccm_colormap_window_unset(Ecore_X_Window win,
+ Ecore_X_Window subwin);
+EAPI void
+ecore_x_icccm_transient_for_set(Ecore_X_Window win,
+ Ecore_X_Window forwin);
+EAPI void
+ ecore_x_icccm_transient_for_unset(Ecore_X_Window win);
+EAPI Ecore_X_Window
+ ecore_x_icccm_transient_for_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_icccm_window_role_set(Ecore_X_Window win,
+ const char *role);
+EAPI char *
+ ecore_x_icccm_window_role_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_icccm_client_leader_set(Ecore_X_Window win,
+ Ecore_X_Window l);
+EAPI Ecore_X_Window
+ ecore_x_icccm_client_leader_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_icccm_iconic_request_send(Ecore_X_Window win,
+ Ecore_X_Window root);
typedef enum _Ecore_X_MWM_Hint_Func
{
@@ -1823,496 +1986,520 @@ typedef enum _Ecore_X_MWM_Hint_Input
ECORE_X_MWM_HINT_INPUT_FULL_APPLICATION_MODAL = 3
} Ecore_X_MWM_Hint_Input;
-EAPI Eina_Bool ecore_x_mwm_hints_get(
- Ecore_X_Window win,
- Ecore_X_MWM_Hint_Func
- *fhint,
- Ecore_X_MWM_Hint_Decor
- *dhint,
- Ecore_X_MWM_Hint_Input
- *ihint);
-EAPI void ecore_x_mwm_borderless_set(
- Ecore_X_Window win,
- Eina_Bool borderless);
+EAPI Eina_Bool
+ecore_x_mwm_hints_get(Ecore_X_Window win,
+ Ecore_X_MWM_Hint_Func *fhint,
+ Ecore_X_MWM_Hint_Decor *dhint,
+ Ecore_X_MWM_Hint_Input *ihint);
+EAPI void
+ecore_x_mwm_borderless_set(Ecore_X_Window win,
+ Eina_Bool borderless);
/* netwm */
-EAPI void ecore_x_netwm_init(void);
-EAPI void ecore_x_netwm_shutdown(void);
-EAPI void ecore_x_netwm_wm_identify(
- Ecore_X_Window root,
- Ecore_X_Window check,
- const char *wm_name);
-EAPI void ecore_x_netwm_supported_set(
- Ecore_X_Window root,
- Ecore_X_Atom *supported,
- int num);
-EAPI Eina_Bool ecore_x_netwm_supported_get(
- Ecore_X_Window root,
- Ecore_X_Atom **supported,
- int *num);
-EAPI void ecore_x_netwm_desk_count_set(
- Ecore_X_Window root,
- unsigned int n_desks);
-EAPI void ecore_x_netwm_desk_roots_set(
- Ecore_X_Window root,
- Ecore_X_Window *vroots,
- unsigned int n_desks);
-EAPI void ecore_x_netwm_desk_names_set(
- Ecore_X_Window root,
- const char **names,
- unsigned int n_desks);
-EAPI void ecore_x_netwm_desk_size_set(
- Ecore_X_Window root,
- unsigned int width,
- unsigned int height);
-EAPI void ecore_x_netwm_desk_workareas_set(
- Ecore_X_Window root,
- unsigned int *areas,
- unsigned int n_desks);
-EAPI void ecore_x_netwm_desk_current_set(
- Ecore_X_Window root,
- unsigned int desk);
-EAPI void ecore_x_netwm_desk_viewports_set(
- Ecore_X_Window root,
- unsigned int *origins,
- unsigned int n_desks);
-EAPI void ecore_x_netwm_desk_layout_set(
- Ecore_X_Window root,
- int orientation,
- int columns,
- int rows,
- int starting_corner);
-EAPI void ecore_x_netwm_showing_desktop_set(
- Ecore_X_Window root,
- Eina_Bool on);
-EAPI void ecore_x_netwm_client_list_set(
- Ecore_X_Window root,
- Ecore_X_Window *p_clients,
- unsigned int n_clients);
-EAPI void ecore_x_netwm_client_list_stacking_set(
- Ecore_X_Window root,
- Ecore_X_Window *p_clients,
- unsigned int n_clients);
-EAPI void ecore_x_netwm_client_active_set(
- Ecore_X_Window root,
- Ecore_X_Window win);
-EAPI void ecore_x_netwm_client_active_request(
- Ecore_X_Window root,
- Ecore_X_Window win,
- int type,
- Ecore_X_Window current_win);
-EAPI void ecore_x_netwm_name_set(Ecore_X_Window win,
- const char *name);
-EAPI int ecore_x_netwm_name_get(Ecore_X_Window win,
- char **name);
-EAPI void ecore_x_netwm_startup_id_set(
- Ecore_X_Window win,
- const char *id);
-EAPI int ecore_x_netwm_startup_id_get(
- Ecore_X_Window win,
- char **id);
-EAPI void ecore_x_netwm_visible_name_set(
- Ecore_X_Window win,
- const char *name);
-EAPI int ecore_x_netwm_visible_name_get(
- Ecore_X_Window win,
- char **name);
-EAPI void ecore_x_netwm_icon_name_set(
- Ecore_X_Window win,
- const char *name);
-EAPI int ecore_x_netwm_icon_name_get(
- Ecore_X_Window win,
- char **name);
-EAPI void ecore_x_netwm_visible_icon_name_set(
- Ecore_X_Window win,
- const char *name);
-EAPI int ecore_x_netwm_visible_icon_name_get(
- Ecore_X_Window win,
- char **name);
-EAPI void ecore_x_netwm_desktop_set(
- Ecore_X_Window win,
- unsigned int desk);
-EAPI Eina_Bool ecore_x_netwm_desktop_get(
- Ecore_X_Window win,
- unsigned int *desk);
-EAPI void ecore_x_netwm_strut_set(Ecore_X_Window win,
- int left,
- int right,
- int top,
- int bottom);
-EAPI Eina_Bool ecore_x_netwm_strut_get(Ecore_X_Window win,
- int *left,
- int *right,
- int *top,
- int *bottom);
-EAPI void ecore_x_netwm_strut_partial_set(
- Ecore_X_Window win,
- int left,
- int right,
- int top,
- int bottom,
- int left_start_y,
- int left_end_y,
- int right_start_y,
- int right_end_y,
- int top_start_x,
- int top_end_x,
- int bottom_start_x,
- int bottom_end_x);
-EAPI Eina_Bool ecore_x_netwm_strut_partial_get(
- Ecore_X_Window win,
- int *left,
- int *right,
- int *top,
- int *bottom,
- int *left_start_y,
- int *left_end_y,
- int *right_start_y,
- int *right_end_y,
- int *top_start_x,
- int *top_end_x,
- int *bottom_start_x,
- int *bottom_end_x);
-
-EAPI Eina_Bool ecore_x_netwm_icons_get(Ecore_X_Window win,
- Ecore_X_Icon **icon,
- int *num);
-EAPI void ecore_x_netwm_icon_geometry_set(
- Ecore_X_Window win,
- int x,
- int y,
- int width,
- int height);
-EAPI Eina_Bool ecore_x_netwm_icon_geometry_get(
- Ecore_X_Window win,
- int *x,
- int *y,
- int *width,
- int *height);
-EAPI void ecore_x_netwm_pid_set(Ecore_X_Window win,
- int pid);
-EAPI Eina_Bool ecore_x_netwm_pid_get(Ecore_X_Window win,
- int *pid);
-EAPI void ecore_x_netwm_handled_icons_set(
- Ecore_X_Window win);
-EAPI Eina_Bool ecore_x_netwm_handled_icons_get(
- Ecore_X_Window win);
-EAPI void ecore_x_netwm_user_time_set(
- Ecore_X_Window win,
- unsigned int time);
-EAPI Eina_Bool ecore_x_netwm_user_time_get(
- Ecore_X_Window win,
- unsigned int *time);
-EAPI void ecore_x_netwm_window_state_set(
- Ecore_X_Window win,
- Ecore_X_Window_State *state,
- unsigned int num);
-EAPI Eina_Bool ecore_x_netwm_window_state_get(
- Ecore_X_Window win,
- Ecore_X_Window_State **state,
- unsigned int *num);
-EAPI void ecore_x_netwm_window_type_set(
- Ecore_X_Window win,
- Ecore_X_Window_Type type);
-EAPI Eina_Bool ecore_x_netwm_window_type_get(
- Ecore_X_Window win,
- Ecore_X_Window_Type *type);
-EAPI int ecore_x_netwm_window_types_get(
- Ecore_X_Window win,
- Ecore_X_Window_Type **types);
-EAPI Eina_Bool ecore_x_netwm_allowed_action_isset(
- Ecore_X_Window win,
- Ecore_X_Action action);
-EAPI void ecore_x_netwm_allowed_action_set(
- Ecore_X_Window win,
- Ecore_X_Action *action,
- unsigned int num);
-EAPI Eina_Bool ecore_x_netwm_allowed_action_get(
- Ecore_X_Window win,
- Ecore_X_Action **action,
- unsigned int *num);
-EAPI void ecore_x_netwm_opacity_set(
- Ecore_X_Window win,
- unsigned int opacity);
-EAPI Eina_Bool ecore_x_netwm_opacity_get(
- Ecore_X_Window win,
- unsigned int *opacity);
-EAPI void ecore_x_netwm_frame_size_set(
- Ecore_X_Window win,
- int fl,
- int fr,
- int ft,
- int fb);
-EAPI Eina_Bool ecore_x_netwm_frame_size_get(
- Ecore_X_Window win,
- int *fl,
- int *fr,
- int *ft,
- int *fb);
-EAPI Eina_Bool ecore_x_netwm_sync_counter_get(
- Ecore_X_Window win,
- Ecore_X_Sync_Counter *counter);
-EAPI void ecore_x_netwm_ping_send(Ecore_X_Window win);
-EAPI void ecore_x_netwm_sync_request_send(
- Ecore_X_Window win,
- unsigned int serial);
-EAPI void ecore_x_netwm_state_request_send(
- Ecore_X_Window win,
- Ecore_X_Window root,
- Ecore_X_Window_State s1,
- Ecore_X_Window_State s2,
- Eina_Bool set);
-EAPI void ecore_x_netwm_desktop_request_send(
- Ecore_X_Window win,
- Ecore_X_Window root,
- unsigned int desktop);
-
-EAPI void ecore_x_e_init(void);
-EAPI void ecore_x_e_frame_size_set(
- Ecore_X_Window win,
- int fl,
- int fr,
- int ft,
- int fb);
-EAPI void ecore_x_e_virtual_keyboard_set(
- Ecore_X_Window win,
- unsigned int is_keyboard);
-EAPI Eina_Bool ecore_x_e_virtual_keyboard_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_virtual_keyboard_state_set(
- Ecore_X_Window win,
- Ecore_X_Virtual_Keyboard_State state);
-EAPI Ecore_X_Virtual_Keyboard_State ecore_x_e_virtual_keyboard_state_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_virtual_keyboard_state_send(
- Ecore_X_Window win,
- Ecore_X_Virtual_Keyboard_State state);
+EAPI void
+ ecore_x_netwm_init(void);
+EAPI void
+ ecore_x_netwm_shutdown(void);
+EAPI void
+ ecore_x_netwm_wm_identify(Ecore_X_Window root,
+ Ecore_X_Window check,
+ const char *wm_name);
+EAPI void
+ecore_x_netwm_supported_set(Ecore_X_Window root,
+ Ecore_X_Atom *supported,
+ int num);
+EAPI Eina_Bool
+ecore_x_netwm_supported_get(Ecore_X_Window root,
+ Ecore_X_Atom **supported,
+ int *num);
+EAPI void
+ecore_x_netwm_desk_count_set(Ecore_X_Window root,
+ unsigned int n_desks);
+EAPI void
+ecore_x_netwm_desk_roots_set(Ecore_X_Window root,
+ Ecore_X_Window *vroots,
+ unsigned int n_desks);
+EAPI void
+ecore_x_netwm_desk_names_set(Ecore_X_Window root,
+ const char **names,
+ unsigned int n_desks);
+EAPI void
+ecore_x_netwm_desk_size_set(Ecore_X_Window root,
+ unsigned int width,
+ unsigned int height);
+EAPI void
+ecore_x_netwm_desk_workareas_set(Ecore_X_Window root,
+ unsigned int *areas,
+ unsigned int n_desks);
+EAPI void
+ecore_x_netwm_desk_current_set(Ecore_X_Window root,
+ unsigned int desk);
+EAPI void
+ecore_x_netwm_desk_viewports_set(Ecore_X_Window root,
+ unsigned int *origins,
+ unsigned int n_desks);
+EAPI void
+ecore_x_netwm_desk_layout_set(Ecore_X_Window root,
+ int orientation,
+ int columns,
+ int rows,
+ int starting_corner);
+EAPI void
+ecore_x_netwm_showing_desktop_set(Ecore_X_Window root,
+ Eina_Bool on);
+EAPI void
+ecore_x_netwm_client_list_set(Ecore_X_Window root,
+ Ecore_X_Window *p_clients,
+ unsigned int n_clients);
+EAPI void
+ecore_x_netwm_client_list_stacking_set(Ecore_X_Window root,
+ Ecore_X_Window *p_clients,
+ unsigned int n_clients);
+EAPI void
+ecore_x_netwm_client_active_set(Ecore_X_Window root,
+ Ecore_X_Window win);
+EAPI void
+ecore_x_netwm_client_active_request(Ecore_X_Window root,
+ Ecore_X_Window win,
+ int type,
+ Ecore_X_Window current_win);
+EAPI void
+ecore_x_netwm_name_set(Ecore_X_Window win,
+ const char *name);
+EAPI int
+ecore_x_netwm_name_get(Ecore_X_Window win,
+ char **name);
+EAPI void
+ecore_x_netwm_startup_id_set(Ecore_X_Window win,
+ const char *id);
+EAPI int
+ecore_x_netwm_startup_id_get(Ecore_X_Window win,
+ char **id);
+EAPI void
+ecore_x_netwm_visible_name_set(Ecore_X_Window win,
+ const char *name);
+EAPI int
+ecore_x_netwm_visible_name_get(Ecore_X_Window win,
+ char **name);
+EAPI void
+ecore_x_netwm_icon_name_set(Ecore_X_Window win,
+ const char *name);
+EAPI int
+ecore_x_netwm_icon_name_get(Ecore_X_Window win,
+ char **name);
+EAPI void
+ecore_x_netwm_visible_icon_name_set(Ecore_X_Window win,
+ const char *name);
+EAPI int
+ecore_x_netwm_visible_icon_name_get(Ecore_X_Window win,
+ char **name);
+EAPI void
+ecore_x_netwm_desktop_set(Ecore_X_Window win,
+ unsigned int desk);
+EAPI Eina_Bool
+ecore_x_netwm_desktop_get(Ecore_X_Window win,
+ unsigned int *desk);
+EAPI void
+ecore_x_netwm_strut_set(Ecore_X_Window win,
+ int left,
+ int right,
+ int top,
+ int bottom);
+EAPI Eina_Bool
+ecore_x_netwm_strut_get(Ecore_X_Window win,
+ int *left,
+ int *right,
+ int *top,
+ int *bottom);
+EAPI void
+ecore_x_netwm_strut_partial_set(Ecore_X_Window win,
+ int left,
+ int right,
+ int top,
+ int bottom,
+ int left_start_y,
+ int left_end_y,
+ int right_start_y,
+ int right_end_y,
+ int top_start_x,
+ int top_end_x,
+ int bottom_start_x,
+ int bottom_end_x);
+EAPI Eina_Bool
+ecore_x_netwm_strut_partial_get(Ecore_X_Window win,
+ int *left,
+ int *right,
+ int *top,
+ int *bottom,
+ int *left_start_y,
+ int *left_end_y,
+ int *right_start_y,
+ int *right_end_y,
+ int *top_start_x,
+ int *top_end_x,
+ int *bottom_start_x,
+ int *bottom_end_x);
+
+EAPI Eina_Bool
+ecore_x_netwm_icons_get(Ecore_X_Window win,
+ Ecore_X_Icon **icon,
+ int *num);
+EAPI void
+ecore_x_netwm_icon_geometry_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int width,
+ int height);
+EAPI Eina_Bool
+ecore_x_netwm_icon_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *width,
+ int *height);
+EAPI void
+ecore_x_netwm_pid_set(Ecore_X_Window win,
+ int pid);
+EAPI Eina_Bool
+ecore_x_netwm_pid_get(Ecore_X_Window win,
+ int *pid);
+EAPI void
+ ecore_x_netwm_handled_icons_set(Ecore_X_Window win);
+EAPI Eina_Bool
+ ecore_x_netwm_handled_icons_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_netwm_user_time_set(Ecore_X_Window win,
+ unsigned int time);
+EAPI Eina_Bool
+ecore_x_netwm_user_time_get(Ecore_X_Window win,
+ unsigned int *time);
+EAPI void
+ecore_x_netwm_window_state_set(Ecore_X_Window win,
+ Ecore_X_Window_State *state,
+ unsigned int num);
+EAPI Eina_Bool
+ecore_x_netwm_window_state_get(Ecore_X_Window win,
+ Ecore_X_Window_State **state,
+ unsigned int *num);
+EAPI void
+ecore_x_netwm_window_type_set(Ecore_X_Window win,
+ Ecore_X_Window_Type type);
+EAPI Eina_Bool
+ecore_x_netwm_window_type_get(Ecore_X_Window win,
+ Ecore_X_Window_Type *type);
+EAPI int
+ecore_x_netwm_window_types_get(Ecore_X_Window win,
+ Ecore_X_Window_Type **types);
+EAPI Eina_Bool
+ecore_x_netwm_allowed_action_isset(Ecore_X_Window win,
+ Ecore_X_Action action);
+EAPI void
+ecore_x_netwm_allowed_action_set(Ecore_X_Window win,
+ Ecore_X_Action *action,
+ unsigned int num);
+EAPI Eina_Bool
+ecore_x_netwm_allowed_action_get(Ecore_X_Window win,
+ Ecore_X_Action **action,
+ unsigned int *num);
+EAPI void
+ecore_x_netwm_opacity_set(Ecore_X_Window win,
+ unsigned int opacity);
+EAPI Eina_Bool
+ecore_x_netwm_opacity_get(Ecore_X_Window win,
+ unsigned int *opacity);
+EAPI void
+ecore_x_netwm_frame_size_set(Ecore_X_Window win,
+ int fl,
+ int fr,
+ int ft,
+ int fb);
+EAPI Eina_Bool
+ecore_x_netwm_frame_size_get(Ecore_X_Window win,
+ int *fl,
+ int *fr,
+ int *ft,
+ int *fb);
+EAPI Eina_Bool
+ecore_x_netwm_sync_counter_get(Ecore_X_Window win,
+ Ecore_X_Sync_Counter *counter);
+EAPI void
+ ecore_x_netwm_ping_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_netwm_sync_request_send(Ecore_X_Window win,
+ unsigned int serial);
+EAPI void
+ecore_x_netwm_state_request_send(Ecore_X_Window win,
+ Ecore_X_Window root,
+ Ecore_X_Window_State s1,
+ Ecore_X_Window_State s2,
+ Eina_Bool set);
+EAPI void
+ecore_x_netwm_desktop_request_send(Ecore_X_Window win,
+ Ecore_X_Window root,
+ unsigned int desktop);
+
+EAPI void
+ ecore_x_e_init(void);
+EAPI void
+ ecore_x_e_frame_size_set(Ecore_X_Window win,
+ int fl,
+ int fr,
+ int ft,
+ int fb);
+EAPI void
+ecore_x_e_virtual_keyboard_set(Ecore_X_Window win,
+ unsigned int is_keyboard);
+EAPI Eina_Bool
+ ecore_x_e_virtual_keyboard_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_virtual_keyboard_state_set(Ecore_X_Window win,
+ Ecore_X_Virtual_Keyboard_State state);
+EAPI Ecore_X_Virtual_Keyboard_State
+ ecore_x_e_virtual_keyboard_state_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_virtual_keyboard_state_send(Ecore_X_Window win,
+ Ecore_X_Virtual_Keyboard_State state);
/* Illume functions */
-EAPI void ecore_x_e_illume_zone_set(
- Ecore_X_Window win,
- Ecore_X_Window zone);
-EAPI Ecore_X_Window ecore_x_e_illume_zone_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_zone_list_set(
- Ecore_X_Window win,
- Ecore_X_Window *zones,
- unsigned int n_zones);
-EAPI void ecore_x_e_illume_conformant_set(
- Ecore_X_Window win,
- unsigned int is_conformant);
-EAPI Eina_Bool ecore_x_e_illume_conformant_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_mode_set(
- Ecore_X_Window win,
- Ecore_X_Illume_Mode mode);
-EAPI Ecore_X_Illume_Mode ecore_x_e_illume_mode_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_mode_send(
- Ecore_X_Window win,
- Ecore_X_Illume_Mode mode);
-EAPI void ecore_x_e_illume_focus_back_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_focus_forward_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_focus_home_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_close_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_home_new_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_home_del_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_drag_set(
- Ecore_X_Window win,
- unsigned int drag);
-EAPI Eina_Bool ecore_x_e_illume_drag_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_drag_locked_set(
- Ecore_X_Window win,
- unsigned int is_locked);
-EAPI Eina_Bool ecore_x_e_illume_drag_locked_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_drag_start_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_drag_end_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_indicator_geometry_set(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI Eina_Bool ecore_x_e_illume_indicator_geometry_get(
- Ecore_X_Window win,
- int *x,
- int *y,
- int *w,
- int *h);
-EAPI void ecore_x_e_illume_softkey_geometry_set(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI Eina_Bool ecore_x_e_illume_softkey_geometry_get(
- Ecore_X_Window win,
- int *x,
- int *y,
- int *w,
- int *h);
-EAPI void ecore_x_e_illume_keyboard_geometry_set(
- Ecore_X_Window win,
- int x,
- int y,
- int w,
- int h);
-EAPI Eina_Bool ecore_x_e_illume_keyboard_geometry_get(
- Ecore_X_Window win,
- int *x,
- int *y,
- int *w,
- int *h);
-EAPI void ecore_x_e_illume_quickpanel_set(
- Ecore_X_Window win,
- unsigned int is_quickpanel);
-EAPI Eina_Bool ecore_x_e_illume_quickpanel_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_quickpanel_state_set(
- Ecore_X_Window win,
- Ecore_X_Illume_Quickpanel_State state);
-EAPI Ecore_X_Illume_Quickpanel_State ecore_x_e_illume_quickpanel_state_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_quickpanel_state_send(
- Ecore_X_Window win,
- Ecore_X_Illume_Quickpanel_State state);
-EAPI void ecore_x_e_illume_quickpanel_state_toggle(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_quickpanel_priority_major_set(
- Ecore_X_Window win,
- unsigned int priority);
-EAPI int ecore_x_e_illume_quickpanel_priority_major_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_quickpanel_priority_minor_set(
- Ecore_X_Window win,
- unsigned int priority);
-EAPI int ecore_x_e_illume_quickpanel_priority_minor_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_illume_quickpanel_zone_set(
- Ecore_X_Window win,
- unsigned int zone);
-EAPI int ecore_x_e_illume_quickpanel_zone_get(
- Ecore_X_Window win);
-EAPI void
- ecore_x_e_illume_quickpanel_zone_request_send(
- Ecore_X_Window win);
-EAPI void
- ecore_x_e_illume_quickpanel_position_update_send(
- Ecore_X_Window win);
-
-EAPI void ecore_x_e_comp_sync_counter_set(
- Ecore_X_Window win,
- Ecore_X_Sync_Counter counter);
-EAPI Ecore_X_Sync_Counter ecore_x_e_comp_sync_counter_get(
- Ecore_X_Window win);
-EAPI void ecore_x_e_comp_sync_draw_done_send(
- Ecore_X_Window root,
- Ecore_X_Window win);
-EAPI void ecore_x_e_comp_sync_draw_size_done_send(
- Ecore_X_Window root,
- Ecore_X_Window win,
- int w,
- int h);
-EAPI void ecore_x_e_comp_sync_supported_set(
- Ecore_X_Window root,
- Eina_Bool enabled);
-EAPI Eina_Bool ecore_x_e_comp_sync_supported_get(
- Ecore_X_Window root);
-EAPI void ecore_x_e_comp_sync_begin_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_comp_sync_end_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_comp_sync_cancel_send(
- Ecore_X_Window win);
-
-EAPI void ecore_x_e_comp_flush_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_comp_dump_send(
- Ecore_X_Window win);
-EAPI void ecore_x_e_comp_pixmap_set(
- Ecore_X_Window win,
- Ecore_X_Pixmap pixmap);
-EAPI Ecore_X_Pixmap ecore_x_e_comp_pixmap_get(
- Ecore_X_Window win);
-
-EAPI Ecore_X_Sync_Alarm ecore_x_sync_alarm_new(
- Ecore_X_Sync_Counter counter);
-EAPI Eina_Bool ecore_x_sync_alarm_free(
- Ecore_X_Sync_Alarm alarm);
-EAPI Eina_Bool ecore_x_sync_counter_query(
- Ecore_X_Sync_Counter counter,
- unsigned int *val);
-EAPI Ecore_X_Sync_Counter ecore_x_sync_counter_new(int val);
-EAPI void ecore_x_sync_counter_free(
- Ecore_X_Sync_Counter counter);
-EAPI void ecore_x_sync_counter_inc(
- Ecore_X_Sync_Counter counter,
- int by);
-EAPI void ecore_x_sync_counter_val_wait(
- Ecore_X_Sync_Counter counter,
- int val);
-
-EAPI void ecore_x_sync_counter_set(Ecore_X_Sync_Counter counter, int val);
-EAPI void ecore_x_sync_counter_2_set(Ecore_X_Sync_Counter counter, int val_hi, unsigned int val_lo);
-EAPI Eina_Bool ecore_x_sync_counter_2_query(Ecore_X_Sync_Counter counter, int *val_hi, unsigned int *val_lo);
-
-EAPI int ecore_x_xinerama_screen_count_get(void);
-EAPI Eina_Bool ecore_x_xinerama_screen_geometry_get(
- int screen,
- int *x,
- int *y,
- int *w,
- int *h);
-
-EAPI Eina_Bool ecore_x_screensaver_event_available_get(
- void);
-EAPI int ecore_x_screensaver_idle_time_get(void);
-EAPI void ecore_x_screensaver_set(int timeout,
- int interval,
- int prefer_blanking,
- int allow_exposures);
-EAPI void ecore_x_screensaver_timeout_set(
- int timeout);
-EAPI int ecore_x_screensaver_timeout_get(void);
-EAPI void ecore_x_screensaver_blank_set(int timeout);
-EAPI int ecore_x_screensaver_blank_get(void);
-EAPI void ecore_x_screensaver_expose_set(int timeout);
-EAPI int ecore_x_screensaver_expose_get(void);
-EAPI void ecore_x_screensaver_interval_set(
- int timeout);
-EAPI int ecore_x_screensaver_interval_get(void);
-EAPI void ecore_x_screensaver_event_listen_set(
- Eina_Bool on);
+EAPI void
+ecore_x_e_illume_zone_set(Ecore_X_Window win,
+ Ecore_X_Window zone);
+EAPI Ecore_X_Window
+ ecore_x_e_illume_zone_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_zone_list_set(Ecore_X_Window win,
+ Ecore_X_Window *zones,
+ unsigned int n_zones);
+EAPI void
+ecore_x_e_illume_conformant_set(Ecore_X_Window win,
+ unsigned int is_conformant);
+EAPI Eina_Bool
+ ecore_x_e_illume_conformant_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_mode_set(Ecore_X_Window win,
+ Ecore_X_Illume_Mode mode);
+EAPI Ecore_X_Illume_Mode
+ ecore_x_e_illume_mode_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_mode_send(Ecore_X_Window win,
+ Ecore_X_Illume_Mode mode);
+EAPI void
+ ecore_x_e_illume_focus_back_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_focus_forward_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_focus_home_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_close_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_home_new_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_home_del_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_drag_set(Ecore_X_Window win,
+ unsigned int drag);
+EAPI Eina_Bool
+ ecore_x_e_illume_drag_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_drag_locked_set(Ecore_X_Window win,
+ unsigned int is_locked);
+EAPI Eina_Bool
+ ecore_x_e_illume_drag_locked_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_drag_start_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_drag_end_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_indicator_geometry_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI Eina_Bool
+ecore_x_e_illume_indicator_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *w,
+ int *h);
+EAPI void
+ecore_x_e_illume_softkey_geometry_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI Eina_Bool
+ecore_x_e_illume_softkey_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *w,
+ int *h);
+EAPI void
+ecore_x_e_illume_keyboard_geometry_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h);
+EAPI Eina_Bool
+ecore_x_e_illume_keyboard_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *w,
+ int *h);
+EAPI void
+ecore_x_e_illume_quickpanel_set(Ecore_X_Window win,
+ unsigned int is_quickpanel);
+EAPI Eina_Bool
+ ecore_x_e_illume_quickpanel_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_quickpanel_state_set(Ecore_X_Window win,
+ Ecore_X_Illume_Quickpanel_State state);
+EAPI Ecore_X_Illume_Quickpanel_State
+ ecore_x_e_illume_quickpanel_state_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_quickpanel_state_send(Ecore_X_Window win,
+ Ecore_X_Illume_Quickpanel_State state);
+EAPI void
+ ecore_x_e_illume_quickpanel_state_toggle(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_quickpanel_priority_major_set(Ecore_X_Window win,
+ unsigned int priority);
+EAPI int
+ ecore_x_e_illume_quickpanel_priority_major_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_quickpanel_priority_minor_set(Ecore_X_Window win,
+ unsigned int priority);
+EAPI int
+ ecore_x_e_illume_quickpanel_priority_minor_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_quickpanel_zone_set(Ecore_X_Window win,
+ unsigned int zone);
+EAPI int
+ ecore_x_e_illume_quickpanel_zone_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_quickpanel_zone_request_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_illume_quickpanel_position_update_send(Ecore_X_Window win);
+
+EAPI void
+ecore_x_e_comp_sync_counter_set(Ecore_X_Window win,
+ Ecore_X_Sync_Counter counter);
+EAPI Ecore_X_Sync_Counter
+ ecore_x_e_comp_sync_counter_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_comp_sync_draw_done_send(Ecore_X_Window root,
+ Ecore_X_Window win);
+EAPI void
+ecore_x_e_comp_sync_draw_size_done_send(Ecore_X_Window root,
+ Ecore_X_Window win,
+ int w,
+ int h);
+EAPI void
+ecore_x_e_comp_sync_supported_set(Ecore_X_Window root,
+ Eina_Bool enabled);
+EAPI Eina_Bool
+ ecore_x_e_comp_sync_supported_get(Ecore_X_Window root);
+EAPI void
+ ecore_x_e_comp_sync_begin_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_comp_sync_end_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_comp_sync_cancel_send(Ecore_X_Window win);
+
+EAPI void
+ ecore_x_e_comp_flush_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_comp_dump_send(Ecore_X_Window win);
+EAPI void
+ ecore_x_e_comp_pixmap_set(Ecore_X_Window win,
+ Ecore_X_Pixmap pixmap);
+EAPI Ecore_X_Pixmap
+ecore_x_e_comp_pixmap_get(Ecore_X_Window win);
+
+EAPI Ecore_X_Sync_Alarm
+ ecore_x_sync_alarm_new(Ecore_X_Sync_Counter counter);
+EAPI Eina_Bool
+ ecore_x_sync_alarm_free(Ecore_X_Sync_Alarm alarm);
+EAPI Eina_Bool
+ ecore_x_sync_counter_query(Ecore_X_Sync_Counter counter,
+ unsigned int *val);
+EAPI Ecore_X_Sync_Counter
+ ecore_x_sync_counter_new(int val);
+EAPI void
+ ecore_x_sync_counter_free(Ecore_X_Sync_Counter counter);
+EAPI void
+ ecore_x_sync_counter_inc(Ecore_X_Sync_Counter counter,
+ int by);
+EAPI void
+ecore_x_sync_counter_val_wait(Ecore_X_Sync_Counter counter,
+ int val);
+
+EAPI void
+ecore_x_sync_counter_set(Ecore_X_Sync_Counter counter,
+ int val);
+EAPI void
+ecore_x_sync_counter_2_set(Ecore_X_Sync_Counter counter,
+ int val_hi,
+ unsigned int val_lo);
+EAPI Eina_Bool
+ecore_x_sync_counter_2_query(Ecore_X_Sync_Counter counter,
+ int *val_hi,
+ unsigned int *val_lo);
+
+EAPI int
+ ecore_x_xinerama_screen_count_get(void);
+EAPI Eina_Bool
+ ecore_x_xinerama_screen_geometry_get(int screen,
+ int *x,
+ int *y,
+ int *w,
+ int *h);
+
+EAPI Eina_Bool
+ ecore_x_screensaver_event_available_get(void);
+EAPI int
+ ecore_x_screensaver_idle_time_get(void);
+EAPI void
+ ecore_x_screensaver_set(int timeout,
+ int interval,
+ int prefer_blanking,
+ int allow_exposures);
+EAPI void
+ ecore_x_screensaver_timeout_set(int timeout);
+EAPI int
+ ecore_x_screensaver_timeout_get(void);
+EAPI void
+ ecore_x_screensaver_blank_set(int timeout);
+EAPI int
+ ecore_x_screensaver_blank_get(void);
+EAPI void
+ ecore_x_screensaver_expose_set(int timeout);
+EAPI int
+ ecore_x_screensaver_expose_get(void);
+EAPI void
+ ecore_x_screensaver_interval_set(int timeout);
+EAPI int
+ ecore_x_screensaver_interval_get(void);
+EAPI void
+ ecore_x_screensaver_event_listen_set(Eina_Bool on);
/* FIXME: these funcs need categorising */
typedef struct _Ecore_X_Window_Attributes
{
- Ecore_X_Window root;
- int x, y, w, h;
- int border;
- int depth;
- Eina_Bool visible : 1;
- Eina_Bool viewable : 1;
- Eina_Bool override : 1;
- Eina_Bool input_only : 1;
- Eina_Bool save_under : 1;
+ Ecore_X_Window root;
+ int x, y, w, h;
+ int border;
+ int depth;
+ Eina_Bool visible : 1;
+ Eina_Bool viewable : 1;
+ Eina_Bool override : 1;
+ Eina_Bool input_only : 1;
+ Eina_Bool save_under : 1;
struct
- {
- Ecore_X_Event_Mask mine;
- Ecore_X_Event_Mask all;
- Ecore_X_Event_Mask no_propagate;
- } event_mask;
+ {
+ Ecore_X_Event_Mask mine;
+ Ecore_X_Event_Mask all;
+ Ecore_X_Event_Mask no_propagate;
+ } event_mask;
Ecore_X_Gravity window_gravity;
Ecore_X_Gravity pixel_gravity;
Ecore_X_Colormap colormap;
@@ -2323,83 +2510,128 @@ typedef struct _Ecore_X_Window_Attributes
*/
} Ecore_X_Window_Attributes;
-EAPI Eina_Bool ecore_x_window_attributes_get(
- Ecore_X_Window win,
- Ecore_X_Window_Attributes *
- att_ret);
-EAPI void ecore_x_window_save_set_add(Ecore_X_Window win);
-EAPI void ecore_x_window_save_set_del(Ecore_X_Window win);
-EAPI Ecore_X_Window * ecore_x_window_children_get(Ecore_X_Window win, int *num);
-
-EAPI Eina_Bool ecore_x_pointer_control_set(int accel_num,
- int accel_denom,
- int threshold);
-EAPI Eina_Bool ecore_x_pointer_control_get(int *accel_num,
- int *accel_denom,
- int *threshold);
-EAPI Eina_Bool ecore_x_pointer_mapping_set(unsigned char *map, int nmap);
-EAPI Eina_Bool ecore_x_pointer_mapping_get(unsigned char *map, int nmap);
-EAPI Eina_Bool ecore_x_pointer_grab(Ecore_X_Window win);
-EAPI Eina_Bool ecore_x_pointer_confine_grab(Ecore_X_Window win);
-EAPI void ecore_x_pointer_ungrab(void);
-EAPI Eina_Bool ecore_x_pointer_warp(Ecore_X_Window win, int x, int y);
-EAPI Eina_Bool ecore_x_keyboard_grab(Ecore_X_Window win);
-EAPI void ecore_x_keyboard_ungrab(void);
-EAPI void ecore_x_grab(void);
-EAPI void ecore_x_ungrab(void);
-EAPI void ecore_x_passive_grab_replay_func_set(Eina_Bool (*func)(void *data,
- int event_type,
- void *event),
- void *data);
-EAPI void ecore_x_window_button_grab(Ecore_X_Window win, int button,
- Ecore_X_Event_Mask event_mask,
- int mod, int any_mod);
-EAPI void ecore_x_window_button_ungrab(Ecore_X_Window win,
- int button,
- int mod,
- int any_mod);
-EAPI void ecore_x_window_key_grab(Ecore_X_Window win,
- const char *key,
- int mod,
- int any_mod);
-EAPI void ecore_x_window_key_ungrab(Ecore_X_Window win,
- const char *key,
- int mod,
- int any_mod);
-
-EAPI void ecore_x_focus_reset(void);
-EAPI void ecore_x_events_allow_all(void);
-EAPI void ecore_x_pointer_last_xy_get(int *x, int *y);
-EAPI void ecore_x_pointer_xy_get(Ecore_X_Window win, int *x, int *y);
+EAPI Eina_Bool
+ecore_x_window_attributes_get(Ecore_X_Window win,
+ Ecore_X_Window_Attributes *att_ret);
+EAPI void
+ ecore_x_window_save_set_add(Ecore_X_Window win);
+EAPI void
+ ecore_x_window_save_set_del(Ecore_X_Window win);
+EAPI Ecore_X_Window *
+ ecore_x_window_children_get(Ecore_X_Window win,
+ int *num);
+
+EAPI Eina_Bool
+ecore_x_pointer_control_set(int accel_num,
+ int accel_denom,
+ int threshold);
+EAPI Eina_Bool
+ecore_x_pointer_control_get(int *accel_num,
+ int *accel_denom,
+ int *threshold);
+EAPI Eina_Bool
+ecore_x_pointer_mapping_set(unsigned char *map,
+ int nmap);
+EAPI Eina_Bool
+ecore_x_pointer_mapping_get(unsigned char *map,
+ int nmap);
+EAPI Eina_Bool
+ ecore_x_pointer_grab(Ecore_X_Window win);
+EAPI Eina_Bool
+ ecore_x_pointer_confine_grab(Ecore_X_Window win);
+EAPI void
+ ecore_x_pointer_ungrab(void);
+EAPI Eina_Bool
+ ecore_x_pointer_warp(Ecore_X_Window win,
+ int x,
+ int y);
+EAPI Eina_Bool
+ ecore_x_keyboard_grab(Ecore_X_Window win);
+EAPI void
+ ecore_x_keyboard_ungrab(void);
+EAPI void
+ ecore_x_grab(void);
+EAPI void
+ ecore_x_ungrab(void);
+EAPI void
+ ecore_x_passive_grab_replay_func_set(Eina_Bool (*func)(void *data,
+ int event_type,
+ void *event),
+ void *data);
+EAPI void
+ecore_x_window_button_grab(Ecore_X_Window win,
+ int button,
+ Ecore_X_Event_Mask event_mask,
+ int mod,
+ int any_mod);
+EAPI void
+ecore_x_window_button_ungrab(Ecore_X_Window win,
+ int button,
+ int mod,
+ int any_mod);
+EAPI void
+ecore_x_window_key_grab(Ecore_X_Window win,
+ const char *key,
+ int mod,
+ int any_mod);
+EAPI void
+ecore_x_window_key_ungrab(Ecore_X_Window win,
+ const char *key,
+ int mod,
+ int any_mod);
+
+EAPI void
+ ecore_x_focus_reset(void);
+EAPI void
+ ecore_x_events_allow_all(void);
+EAPI void
+ ecore_x_pointer_last_xy_get(int *x,
+ int *y);
+EAPI void
+ecore_x_pointer_xy_get(Ecore_X_Window win,
+ int *x,
+ int *y);
/* ecore_x_region.c */
-EAPI Ecore_X_XRegion * ecore_x_xregion_new(void);
-EAPI void ecore_x_xregion_free(Ecore_X_XRegion *region);
-EAPI Eina_Bool ecore_x_xregion_set(Ecore_X_XRegion *region,
- Ecore_X_GC gc);
-EAPI void ecore_x_xregion_translate(Ecore_X_XRegion *region,
- int x,
- int y);
-EAPI Eina_Bool ecore_x_xregion_intersect(Ecore_X_XRegion *dst,
- Ecore_X_XRegion *r1,
- Ecore_X_XRegion *r2);
-EAPI Eina_Bool ecore_x_xregion_union(Ecore_X_XRegion *dst,
- Ecore_X_XRegion *r1,
- Ecore_X_XRegion *r2);
-EAPI Eina_Bool ecore_x_xregion_union_rect(Ecore_X_XRegion *dst,
- Ecore_X_XRegion *src,
- Ecore_X_Rectangle *rect);
-EAPI Eina_Bool ecore_x_xregion_subtract(Ecore_X_XRegion *dst,
- Ecore_X_XRegion *r1,
- Ecore_X_XRegion *r2);
-EAPI Eina_Bool ecore_x_xregion_is_empty(Ecore_X_XRegion *region);
-EAPI Eina_Bool ecore_x_xregion_is_equal(Ecore_X_XRegion *r1,
- Ecore_X_XRegion *r2);
-EAPI Eina_Bool ecore_x_xregion_point_contain(Ecore_X_XRegion *region,
- int x,
- int y);
-EAPI Eina_Bool ecore_x_xregion_rect_contain(Ecore_X_XRegion *region,
- Ecore_X_Rectangle *rect);
+EAPI Ecore_X_XRegion *
+ ecore_x_xregion_new(void);
+EAPI void
+ ecore_x_xregion_free(Ecore_X_XRegion *region);
+EAPI Eina_Bool
+ ecore_x_xregion_set(Ecore_X_XRegion *region,
+ Ecore_X_GC gc);
+EAPI void
+ecore_x_xregion_translate(Ecore_X_XRegion *region,
+ int x,
+ int y);
+EAPI Eina_Bool
+ecore_x_xregion_intersect(Ecore_X_XRegion *dst,
+ Ecore_X_XRegion *r1,
+ Ecore_X_XRegion *r2);
+EAPI Eina_Bool
+ecore_x_xregion_union(Ecore_X_XRegion *dst,
+ Ecore_X_XRegion *r1,
+ Ecore_X_XRegion *r2);
+EAPI Eina_Bool
+ecore_x_xregion_union_rect(Ecore_X_XRegion *dst,
+ Ecore_X_XRegion *src,
+ Ecore_X_Rectangle *rect);
+EAPI Eina_Bool
+ecore_x_xregion_subtract(Ecore_X_XRegion *dst,
+ Ecore_X_XRegion *r1,
+ Ecore_X_XRegion *r2);
+EAPI Eina_Bool
+ ecore_x_xregion_is_empty(Ecore_X_XRegion *region);
+EAPI Eina_Bool
+ ecore_x_xregion_is_equal(Ecore_X_XRegion *r1,
+ Ecore_X_XRegion *r2);
+EAPI Eina_Bool
+ecore_x_xregion_point_contain(Ecore_X_XRegion *region,
+ int x,
+ int y);
+EAPI Eina_Bool
+ecore_x_xregion_rect_contain(Ecore_X_XRegion *region,
+ Ecore_X_Rectangle *rect);
/* ecore_x_randr.c */
@@ -2417,66 +2649,58 @@ typedef int Ecore_X_Randr_Connector_Type;
typedef struct _Ecore_X_Randr_Mode_Info
{
- Ecore_X_ID xid;
- unsigned int width;
- unsigned int height;
+ Ecore_X_ID xid;
+ unsigned int width;
+ unsigned int height;
unsigned long dotClock;
- unsigned int hSyncStart;
- unsigned int hSyncEnd;
- unsigned int hTotal;
- unsigned int hSkew;
- unsigned int vSyncStart;
- unsigned int vSyncEnd;
- unsigned int vTotal;
- char *name;
- unsigned int nameLength;
+ unsigned int hSyncStart;
+ unsigned int hSyncEnd;
+ unsigned int hTotal;
+ unsigned int hSkew;
+ unsigned int vSyncStart;
+ unsigned int vSyncEnd;
+ unsigned int vTotal;
+ char *name;
+ unsigned int nameLength;
unsigned long modeFlags;
} Ecore_X_Randr_Mode_Info;
-EAPI int ecore_x_randr_version_get(
- void);
-EAPI Eina_Bool ecore_x_randr_query(void);
+EAPI int
+ ecore_x_randr_version_get(void);
+EAPI Eina_Bool
+ ecore_x_randr_query(void);
/* ecore_x_randr_11.c */
EAPI Ecore_X_Randr_Orientation
- ecore_x_randr_screen_primary_output_orientations_get(
- Ecore_X_Window root);
+ ecore_x_randr_screen_primary_output_orientations_get(Ecore_X_Window root);
EAPI Ecore_X_Randr_Orientation
- ecore_x_randr_screen_primary_output_orientation_get(
- Ecore_X_Window root);
+ ecore_x_randr_screen_primary_output_orientation_get(Ecore_X_Window root);
EAPI Eina_Bool
- ecore_x_randr_screen_primary_output_orientation_set(
- Ecore_X_Window root,
- Ecore_X_Randr_Orientation
- orientation);
+ ecore_x_randr_screen_primary_output_orientation_set(Ecore_X_Window root,
+ Ecore_X_Randr_Orientation orientation);
EAPI Ecore_X_Randr_Screen_Size_MM *
- ecore_x_randr_screen_primary_output_sizes_get(
- Ecore_X_Window root,
- int *num);
-EAPI void
- ecore_x_randr_screen_primary_output_current_size_get(
- Ecore_X_Window root,
- int *w,
- int *h,
- int *w_mm,
- int *h_mm,
- int *size_index);
+ecore_x_randr_screen_primary_output_sizes_get(Ecore_X_Window root,
+ int *num);
+EAPI void
+ecore_x_randr_screen_primary_output_current_size_get(Ecore_X_Window root,
+ int *w,
+ int *h,
+ int *w_mm,
+ int *h_mm,
+ int *size_index);
EAPI Eina_Bool
ecore_x_randr_screen_primary_output_size_set(Ecore_X_Window root,
int size_index);
EAPI Ecore_X_Randr_Refresh_Rate
-ecore_x_randr_screen_primary_output_current_refresh_rate_get(
- Ecore_X_Window root);
+ ecore_x_randr_screen_primary_output_current_refresh_rate_get(Ecore_X_Window root);
EAPI Ecore_X_Randr_Refresh_Rate *
-ecore_x_randr_screen_primary_output_refresh_rates_get(Ecore_X_Window root,
+ ecore_x_randr_screen_primary_output_refresh_rates_get(Ecore_X_Window root,
int size_index,
int *num);
EAPI Eina_Bool
-ecore_x_randr_screen_primary_output_refresh_rate_set(
- Ecore_X_Window root,
- int size_index,
- Ecore_X_Randr_Refresh_Rate
- rate);
+ecore_x_randr_screen_primary_output_refresh_rate_set(Ecore_X_Window root,
+ int size_index,
+ Ecore_X_Randr_Refresh_Rate rate);
/* ecore_x_randr_12.c */
EAPI void
@@ -2490,56 +2714,51 @@ ecore_x_randr_screen_current_size_get(Ecore_X_Window root,
int *w_mm,
int *h_mm);
EAPI void
- ecore_x_randr_screen_size_range_get(Ecore_X_Window root,
+ecore_x_randr_screen_size_range_get(Ecore_X_Window root,
int *wmin,
int *hmin,
int *wmax,
int *hmax);
-EAPI void ecore_x_randr_screen_reset(
- Ecore_X_Window root);
+EAPI void
+ ecore_x_randr_screen_reset(Ecore_X_Window root);
EAPI Eina_Bool
- ecore_x_randr_screen_current_size_set(Ecore_X_Window root,
+ ecore_x_randr_screen_current_size_set(Ecore_X_Window root,
int w,
int h,
int w_mm,
int h_mm);
EAPI Ecore_X_Randr_Mode_Info **
- ecore_x_randr_modes_info_get(Ecore_X_Window root,
+ecore_x_randr_modes_info_get(Ecore_X_Window root,
int *num);
EAPI Ecore_X_Randr_Mode_Info *
- ecore_x_randr_mode_info_get(Ecore_X_Window root,
+ecore_x_randr_mode_info_get(Ecore_X_Window root,
Ecore_X_Randr_Mode mode);
EAPI void
- ecore_x_randr_mode_info_free(
- Ecore_X_Randr_Mode_Info *mode_info);
-EAPI Ecore_X_Randr_Crtc * ecore_x_randr_crtcs_get(
- Ecore_X_Window root,
- int *num);
-EAPI Ecore_X_Randr_Output *ecore_x_randr_outputs_get(
- Ecore_X_Window root,
- int *num);
+ ecore_x_randr_mode_info_free(Ecore_X_Randr_Mode_Info *mode_info);
+EAPI Ecore_X_Randr_Crtc *
+ ecore_x_randr_crtcs_get(Ecore_X_Window root,
+ int *num);
+EAPI Ecore_X_Randr_Output *ecore_x_randr_outputs_get(Ecore_X_Window root,
+ int *num);
EAPI Ecore_X_Randr_Output *
- ecore_x_randr_window_outputs_get(
- Ecore_X_Window window,
- int *num);
+ecore_x_randr_window_outputs_get(Ecore_X_Window window,
+ int *num);
EINA_DEPRECATED EAPI Ecore_X_Randr_Output *
- ecore_x_randr_current_output_get(
- Ecore_X_Window window,
- int *num);
+ecore_x_randr_current_output_get(Ecore_X_Window window,
+ int *num);
EAPI Ecore_X_Randr_Crtc *
- ecore_x_randr_current_crtc_get(Ecore_X_Window window,
+ecore_x_randr_current_crtc_get(Ecore_X_Window window,
int *num);
EAPI Ecore_X_Randr_Output *
- ecore_x_randr_crtc_outputs_get(Ecore_X_Window root,
+ecore_x_randr_crtc_outputs_get(Ecore_X_Window root,
Ecore_X_Randr_Crtc crtc,
int *num);
EAPI Ecore_X_Randr_Output *
- ecore_x_randr_crtc_possible_outputs_get(
- Ecore_X_Window root,
- Ecore_X_Randr_Crtc crtc,
- int *num);
+ecore_x_randr_crtc_possible_outputs_get(Ecore_X_Window root,
+ Ecore_X_Randr_Crtc crtc,
+ int *num);
EAPI void
- ecore_x_randr_crtc_geometry_get(Ecore_X_Window root,
+ecore_x_randr_crtc_geometry_get(Ecore_X_Window root,
Ecore_X_Randr_Crtc crtc,
int *x,
int *y,
@@ -2556,7 +2775,8 @@ ecore_x_randr_crtc_pos_set(Ecore_X_Window root,
int x,
int y);
EAPI Ecore_X_Randr_Mode
-ecore_x_randr_crtc_mode_get(Ecore_X_Window root, Ecore_X_Randr_Crtc crtc);
+ecore_x_randr_crtc_mode_get(Ecore_X_Window root,
+ Ecore_X_Randr_Crtc crtc);
EAPI Eina_Bool
ecore_x_randr_crtc_mode_set(Ecore_X_Window root,
Ecore_X_Randr_Crtc crtc,
@@ -2576,7 +2796,8 @@ EAPI Ecore_X_Randr_Orientation
ecore_x_randr_crtc_orientations_get(Ecore_X_Window root,
Ecore_X_Randr_Crtc crtc);
EAPI Ecore_X_Randr_Orientation
-ecore_x_randr_crtc_orientation_get(Ecore_X_Window root, Ecore_X_Randr_Crtc crtc);
+ecore_x_randr_crtc_orientation_get(Ecore_X_Window root,
+ Ecore_X_Randr_Crtc crtc);
EAPI Eina_Bool
ecore_x_randr_crtc_orientation_set(Ecore_X_Window root,
Ecore_X_Randr_Crtc crtc,
@@ -2601,41 +2822,44 @@ ecore_x_randr_crtc_pos_relative_set(Ecore_X_Window root,
Ecore_X_Randr_Output_Policy policy,
Ecore_X_Randr_Relative_Alignment alignment);
EAPI Ecore_X_Randr_Mode *
- ecore_x_randr_output_modes_get(Ecore_X_Window root,
+ecore_x_randr_output_modes_get(Ecore_X_Window root,
Ecore_X_Randr_Output output,
int *num,
int *npreferred);
-EAPI Ecore_X_Randr_Output *ecore_x_randr_output_clones_get(Ecore_X_Window root, Ecore_X_Randr_Output output, int *num);
-EAPI Ecore_X_Randr_Crtc *ecore_x_randr_output_possible_crtcs_get(Ecore_X_Window root, Ecore_X_Randr_Output output, int *num);
+EAPI Ecore_X_Randr_Output *ecore_x_randr_output_clones_get(Ecore_X_Window root,
+ Ecore_X_Randr_Output output,
+ int *num);
+EAPI Ecore_X_Randr_Crtc *ecore_x_randr_output_possible_crtcs_get(Ecore_X_Window root,
+ Ecore_X_Randr_Output output,
+ int *num);
EAPI Ecore_X_Randr_Crtc
- ecore_x_randr_output_crtc_get(Ecore_X_Window root,
+ecore_x_randr_output_crtc_get(Ecore_X_Window root,
Ecore_X_Randr_Output output);
EAPI char *
- ecore_x_randr_output_name_get(Ecore_X_Window root,
+ecore_x_randr_output_name_get(Ecore_X_Window root,
Ecore_X_Randr_Output output,
int *len);
EAPI int
- ecore_x_randr_crtc_gamma_ramp_size_get(
- Ecore_X_Randr_Crtc crtc);
+ ecore_x_randr_crtc_gamma_ramp_size_get(Ecore_X_Randr_Crtc crtc);
EAPI Ecore_X_Randr_Crtc_Gamma **
- ecore_x_randr_crtc_gamma_ramps_get(Ecore_X_Randr_Crtc crtc);
+ ecore_x_randr_crtc_gamma_ramps_get(Ecore_X_Randr_Crtc crtc);
EAPI Eina_Bool
- ecore_x_randr_crtc_gamma_ramps_set(Ecore_X_Randr_Crtc crtc,
+ ecore_x_randr_crtc_gamma_ramps_set(Ecore_X_Randr_Crtc crtc,
const Ecore_X_Randr_Crtc_Gamma *red,
const Ecore_X_Randr_Crtc_Gamma *green,
const Ecore_X_Randr_Crtc_Gamma *blue);
EAPI Eina_Bool
- ecore_x_randr_move_all_crtcs_but(Ecore_X_Window root,
+ecore_x_randr_move_all_crtcs_but(Ecore_X_Window root,
const Ecore_X_Randr_Crtc *not_moved,
int nnot_moved,
int dx,
int dy);
-EAPI Eina_Bool ecore_x_randr_move_crtcs(
- Ecore_X_Window root,
- const Ecore_X_Randr_Crtc *crtcs,
- int ncrtc,
- int dx,
- int dy);
+EAPI Eina_Bool
+ecore_x_randr_move_crtcs(Ecore_X_Window root,
+ const Ecore_X_Randr_Crtc *crtcs,
+ int ncrtc,
+ int dx,
+ int dy);
EAPI void
ecore_x_randr_mode_size_get(Ecore_X_Window root,
Ecore_X_Randr_Mode mode,
@@ -2655,7 +2879,7 @@ ecore_x_randr_output_crtc_set(Ecore_X_Window root,
const Ecore_X_Randr_Crtc crtc);
/* ecore_x_randr_12_edid.c */
-
+
/*
* @brief Validates the header from raw EDID data.
*
@@ -2665,8 +2889,8 @@ ecore_x_randr_output_crtc_set(Ecore_X_Window root,
*/
EAPI Eina_Bool
ecore_x_randr_edid_has_valid_header(unsigned char *edid,
- unsigned long edid_length);
-
+ unsigned long edid_length);
+
/*
* @brief Checks whether a display's EDID has a valid checksum.
*
@@ -2677,24 +2901,24 @@ ecore_x_randr_edid_has_valid_header(unsigned char *edid,
EAPI Eina_Bool
ecore_x_randr_edid_info_has_valid_checksum(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the encoded version from raw EDID data.
*
* The return value has the minor version in the lowest 8 bits, and the major
* version in all the rest of the bits. i.e.
- *
+ *
* minor = (version & 0x000000ff);
* major = (version & 0xffffff00) >> 8;
- *
+ *
* @param edid the edid structure
* @param edid_length length of the edid structure
* @return The encoded major and minor version encasuplated an int.
*/
EAPI int
-ecore_x_randr_edid_version_get(unsigned char *edid,
+ecore_x_randr_edid_version_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the encoded manufacturer from raw EDID data.
*
@@ -2705,7 +2929,7 @@ ecore_x_randr_edid_version_get(unsigned char *edid,
EAPI char *
ecore_x_randr_edid_manufacturer_name_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the encoded name from raw EDID data.
*
@@ -2716,7 +2940,7 @@ ecore_x_randr_edid_manufacturer_name_get(unsigned char *edid,
EAPI char *
ecore_x_randr_edid_display_name_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the encoded ASCII from raw EDID data.
*
@@ -2725,9 +2949,9 @@ ecore_x_randr_edid_display_name_get(unsigned char *edid,
* @return The encoded ASCII display identifier.
*/
EAPI char *
-ecore_x_randr_edid_display_ascii_get(unsigned char *edid,
+ecore_x_randr_edid_display_ascii_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the encoded serial identifier from raw EDID data.
*
@@ -2736,9 +2960,9 @@ ecore_x_randr_edid_display_ascii_get(unsigned char *edid,
* @return The encoded serial identifier.
*/
EAPI char *
-ecore_x_randr_edid_display_serial_get(unsigned char *edid,
+ecore_x_randr_edid_display_serial_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the encoded model number from raw EDID data.
*
@@ -2751,7 +2975,7 @@ ecore_x_randr_edid_display_serial_get(unsigned char *edid,
EAPI int
ecore_x_randr_edid_model_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the manufacturer serial number from raw EDID data.
*
@@ -2762,7 +2986,7 @@ ecore_x_randr_edid_model_get(unsigned char *edid,
EAPI int
ecore_x_randr_edid_manufacturer_serial_number_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the manufacturer model number from raw EDID data.
*
@@ -2773,7 +2997,7 @@ ecore_x_randr_edid_manufacturer_serial_number_get(unsigned char *edid,
EAPI int
ecore_x_randr_edid_manufacturer_model_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Looks up the DPMS support from raw EDID data.
*
@@ -2784,7 +3008,7 @@ ecore_x_randr_edid_manufacturer_model_get(unsigned char *edid,
EAPI Eina_Bool
ecore_x_randr_edid_dpms_available_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Looks up the DPMS Standby support from raw EDID data.
*
@@ -2795,7 +3019,7 @@ ecore_x_randr_edid_dpms_available_get(unsigned char *edid,
EAPI Eina_Bool
ecore_x_randr_edid_dpms_standby_available_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Looks up the DPMS Suspend support from raw EDID data.
*
@@ -2806,7 +3030,7 @@ ecore_x_randr_edid_dpms_standby_available_get(unsigned char *edid,
EAPI Eina_Bool
ecore_x_randr_edid_dpms_suspend_available_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Looks up the DPMS Off support from raw EDID data.
*
@@ -2817,7 +3041,7 @@ ecore_x_randr_edid_dpms_suspend_available_get(unsigned char *edid,
EAPI Eina_Bool
ecore_x_randr_edid_dpms_off_available_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the preferred aspect ratio from raw EDID data.
*
@@ -2828,7 +3052,7 @@ ecore_x_randr_edid_dpms_off_available_get(unsigned char *edid,
EAPI Ecore_X_Randr_Edid_Aspect_Ratio
ecore_x_randr_edid_display_aspect_ratio_preferred_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the supported aspect ratios from raw EDID data.
*
@@ -2839,7 +3063,7 @@ ecore_x_randr_edid_display_aspect_ratio_preferred_get(unsigned char *edid,
EAPI Ecore_X_Randr_Edid_Aspect_Ratio
ecore_x_randr_edid_display_aspect_ratios_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the supported colorschemes from raw EDID data.
*
@@ -2850,7 +3074,7 @@ ecore_x_randr_edid_display_aspect_ratios_get(unsigned char *edid,
EAPI Ecore_X_Randr_Edid_Display_Colorscheme
ecore_x_randr_edid_display_colorscheme_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the display type from raw EDID data.
*
@@ -2861,7 +3085,7 @@ ecore_x_randr_edid_display_colorscheme_get(unsigned char *edid,
EAPI Eina_Bool
ecore_x_randr_edid_display_type_digital_get(unsigned char *edid,
unsigned long edid_length);
-
+
/*
* @brief Get the display interface type from raw EDID data.
*
@@ -2872,10 +3096,11 @@ ecore_x_randr_edid_display_type_digital_get(unsigned char *edid,
EAPI Ecore_X_Randr_Edid_Display_Interface_Type
ecore_x_randr_edid_display_interface_type_get(unsigned char *edid,
unsigned long edid_length);
-
+
/* ecore_x_randr_13.c */
EAPI void
-ecore_x_randr_screen_backlight_level_set(Ecore_X_Window root, double level);
+ecore_x_randr_screen_backlight_level_set(Ecore_X_Window root,
+ double level);
EAPI double
ecore_x_randr_output_backlight_level_get(Ecore_X_Window root,
Ecore_X_Randr_Output output);
@@ -2884,9 +3109,9 @@ ecore_x_randr_output_backlight_level_set(Ecore_X_Window root,
Ecore_X_Randr_Output output,
double level);
EAPI Ecore_X_Randr_Output
-ecore_x_randr_primary_output_get(Ecore_X_Window root);
+ ecore_x_randr_primary_output_get(Ecore_X_Window root);
EAPI void
-ecore_x_randr_primary_output_set(Ecore_X_Window root,
+ ecore_x_randr_primary_output_set(Ecore_X_Window root,
Ecore_X_Randr_Output output);
EAPI Ecore_X_Render_Subpixel_Order
ecore_x_randr_output_subpixel_order_get(Ecore_X_Window root,
@@ -2950,7 +3175,8 @@ ecore_x_randr_crtc_tracking_area_set(Ecore_X_Window root,
const int w,
const int h);
EAPI Eina_Rectangle *
-ecore_x_randr_crtc_border_area_get(Ecore_X_Window root, Ecore_X_Randr_Crtc crtc);
+ecore_x_randr_crtc_border_area_get(Ecore_X_Window root,
+ Ecore_X_Randr_Crtc crtc);
EAPI Eina_Bool
ecore_x_randr_crtc_border_area_set(Ecore_X_Window root,
Ecore_X_Randr_Crtc crtc,
@@ -2960,67 +3186,88 @@ ecore_x_randr_crtc_border_area_set(Ecore_X_Window root,
const int bottom);
/* XRender Support (horrendously incomplete) */
-typedef Ecore_X_ID Ecore_X_Picture;
+typedef Ecore_X_ID Ecore_X_Picture;
/* XFixes Extension Support */
-typedef Ecore_X_ID Ecore_X_Region;
+typedef Ecore_X_ID Ecore_X_Region;
-typedef enum _Ecore_X_Region_Type {
+typedef enum _Ecore_X_Region_Type
+{
ECORE_X_REGION_BOUNDING,
ECORE_X_REGION_CLIP
} Ecore_X_Region_Type;
-EAPI Ecore_X_Region ecore_x_region_new(Ecore_X_Rectangle *rects, int num);
-EAPI Ecore_X_Region ecore_x_region_new_from_bitmap(Ecore_X_Pixmap bitmap);
-EAPI Ecore_X_Region ecore_x_region_new_from_window(Ecore_X_Window win,
- Ecore_X_Region_Type type);
-EAPI Ecore_X_Region ecore_x_region_new_from_gc(Ecore_X_GC gc);
-EAPI Ecore_X_Region ecore_x_region_new_from_picture(Ecore_X_Picture picture);
-EAPI void ecore_x_region_free(Ecore_X_Region region);
-EAPI void ecore_x_region_set(Ecore_X_Region region,
- Ecore_X_Rectangle *rects,
- int num);
-EAPI void ecore_x_region_copy(Ecore_X_Region dest,
- Ecore_X_Region source);
-EAPI void ecore_x_region_combine(Ecore_X_Region dest,
- Ecore_X_Region source1,
- Ecore_X_Region source2);
-EAPI void ecore_x_region_intersect(Ecore_X_Region dest,
- Ecore_X_Region source1,
- Ecore_X_Region source2);
-EAPI void ecore_x_region_subtract(Ecore_X_Region dest,
- Ecore_X_Region source1,
- Ecore_X_Region source2);
-EAPI void ecore_x_region_invert(Ecore_X_Region dest,
- Ecore_X_Rectangle *bounds,
- Ecore_X_Region source);
-EAPI void ecore_x_region_translate(Ecore_X_Region region,
- int dx,
- int dy);
-EAPI void ecore_x_region_extents(Ecore_X_Region dest,
- Ecore_X_Region source);
-EAPI Ecore_X_Rectangle * ecore_x_region_fetch(Ecore_X_Region region,
- int *num,
- Ecore_X_Rectangle *bounds);
-EAPI void ecore_x_region_expand(Ecore_X_Region dest,
- Ecore_X_Region source,
- unsigned int left,
- unsigned int right,
- unsigned int top,
- unsigned int bottom);
-EAPI void ecore_x_region_gc_clip_set(Ecore_X_Region region,
- Ecore_X_GC gc,
- int x_origin,
- int y_origin);
-EAPI void ecore_x_region_window_shape_set(Ecore_X_Region region,
- Ecore_X_Window win,
- Ecore_X_Shape_Type type,
- int x_offset,
- int y_offset);
-EAPI void ecore_x_region_picture_clip_set(Ecore_X_Region region,
- Ecore_X_Picture picture,
- int x_origin,
- int y_origin);
+EAPI Ecore_X_Region
+ecore_x_region_new(Ecore_X_Rectangle *rects,
+ int num);
+EAPI Ecore_X_Region
+ ecore_x_region_new_from_bitmap(Ecore_X_Pixmap bitmap);
+EAPI Ecore_X_Region
+ ecore_x_region_new_from_window(Ecore_X_Window win,
+ Ecore_X_Region_Type type);
+EAPI Ecore_X_Region
+ ecore_x_region_new_from_gc(Ecore_X_GC gc);
+EAPI Ecore_X_Region
+ ecore_x_region_new_from_picture(Ecore_X_Picture picture);
+EAPI void
+ ecore_x_region_free(Ecore_X_Region region);
+EAPI void
+ ecore_x_region_set(Ecore_X_Region region,
+ Ecore_X_Rectangle *rects,
+ int num);
+EAPI void
+ecore_x_region_copy(Ecore_X_Region dest,
+ Ecore_X_Region source);
+EAPI void
+ecore_x_region_combine(Ecore_X_Region dest,
+ Ecore_X_Region source1,
+ Ecore_X_Region source2);
+EAPI void
+ecore_x_region_intersect(Ecore_X_Region dest,
+ Ecore_X_Region source1,
+ Ecore_X_Region source2);
+EAPI void
+ecore_x_region_subtract(Ecore_X_Region dest,
+ Ecore_X_Region source1,
+ Ecore_X_Region source2);
+EAPI void
+ecore_x_region_invert(Ecore_X_Region dest,
+ Ecore_X_Rectangle *bounds,
+ Ecore_X_Region source);
+EAPI void
+ecore_x_region_translate(Ecore_X_Region region,
+ int dx,
+ int dy);
+EAPI void
+ecore_x_region_extents(Ecore_X_Region dest,
+ Ecore_X_Region source);
+EAPI Ecore_X_Rectangle *
+ecore_x_region_fetch(Ecore_X_Region region,
+ int *num,
+ Ecore_X_Rectangle *bounds);
+EAPI void
+ecore_x_region_expand(Ecore_X_Region dest,
+ Ecore_X_Region source,
+ unsigned int left,
+ unsigned int right,
+ unsigned int top,
+ unsigned int bottom);
+EAPI void
+ecore_x_region_gc_clip_set(Ecore_X_Region region,
+ Ecore_X_GC gc,
+ int x_origin,
+ int y_origin);
+EAPI void
+ecore_x_region_window_shape_set(Ecore_X_Region region,
+ Ecore_X_Window win,
+ Ecore_X_Shape_Type type,
+ int x_offset,
+ int y_offset);
+EAPI void
+ecore_x_region_picture_clip_set(Ecore_X_Region region,
+ Ecore_X_Picture picture,
+ int x_origin,
+ int y_origin);
/**
* xfixes selection notification request.
@@ -3030,28 +3277,40 @@ EAPI void ecore_x_region_picture_clip_set(Ecore_X_Region regi
* @return EINA_TRUE on success, EINA_FALSE otherwise.
* @since 1.1.0
*/
-EAPI Eina_Bool ecore_x_fixes_selection_notification_request(Ecore_X_Atom selection);
+EAPI Eina_Bool
+ecore_x_fixes_selection_notification_request(Ecore_X_Atom selection);
/* XComposite Extension Support */
-EAPI Eina_Bool ecore_x_composite_query(void);
-EAPI void ecore_x_composite_redirect_window(Ecore_X_Window win,
- Ecore_X_Composite_Update_Type type);
-EAPI void ecore_x_composite_redirect_subwindows(Ecore_X_Window win,
- Ecore_X_Composite_Update_Type type);
-EAPI void ecore_x_composite_unredirect_window(Ecore_X_Window win,
- Ecore_X_Composite_Update_Type type);
-EAPI void ecore_x_composite_unredirect_subwindows(Ecore_X_Window win,
- Ecore_X_Composite_Update_Type type);
-EAPI Ecore_X_Pixmap ecore_x_composite_name_window_pixmap_get(Ecore_X_Window win);
-EAPI void ecore_x_composite_window_events_disable(Ecore_X_Window win);
-EAPI void ecore_x_composite_window_events_enable(Ecore_X_Window win);
-EAPI Ecore_X_Window ecore_x_composite_render_window_enable(Ecore_X_Window root);
-EAPI void ecore_x_composite_render_window_disable(Ecore_X_Window root);
+EAPI Eina_Bool
+ ecore_x_composite_query(void);
+EAPI void
+ ecore_x_composite_redirect_window(Ecore_X_Window win,
+ Ecore_X_Composite_Update_Type type);
+EAPI void
+ecore_x_composite_redirect_subwindows(Ecore_X_Window win,
+ Ecore_X_Composite_Update_Type type);
+EAPI void
+ecore_x_composite_unredirect_window(Ecore_X_Window win,
+ Ecore_X_Composite_Update_Type type);
+EAPI void
+ecore_x_composite_unredirect_subwindows(Ecore_X_Window win,
+ Ecore_X_Composite_Update_Type type);
+EAPI Ecore_X_Pixmap
+ ecore_x_composite_name_window_pixmap_get(Ecore_X_Window win);
+EAPI void
+ ecore_x_composite_window_events_disable(Ecore_X_Window win);
+EAPI void
+ ecore_x_composite_window_events_enable(Ecore_X_Window win);
+EAPI Ecore_X_Window
+ ecore_x_composite_render_window_enable(Ecore_X_Window root);
+EAPI void
+ ecore_x_composite_render_window_disable(Ecore_X_Window root);
/* XDamage Extension Support */
-typedef Ecore_X_ID Ecore_X_Damage;
+typedef Ecore_X_ID Ecore_X_Damage;
-typedef enum _Ecore_X_Damage_Report_Level {
+typedef enum _Ecore_X_Damage_Report_Level
+{
ECORE_X_DAMAGE_REPORT_RAW_RECTANGLES,
ECORE_X_DAMAGE_REPORT_DELTA_RECTANGLES,
ECORE_X_DAMAGE_REPORT_BOUNDING_BOX,
@@ -3069,85 +3328,121 @@ struct _Ecore_X_Event_Damage
Ecore_X_Rectangle geometry;
};
-typedef struct _Ecore_X_Event_Damage Ecore_X_Event_Damage;
-
-EAPI Eina_Bool ecore_x_damage_query(void);
-EAPI Ecore_X_Damage ecore_x_damage_new(Ecore_X_Drawable d,
- Ecore_X_Damage_Report_Level level);
-EAPI void ecore_x_damage_free(Ecore_X_Damage damage);
-EAPI void ecore_x_damage_subtract(Ecore_X_Damage damage,
- Ecore_X_Region repair,
- Ecore_X_Region parts);
-
-EAPI Eina_Bool ecore_x_screen_is_composited(int screen);
-EAPI void ecore_x_screen_is_composited_set(int screen,
- Ecore_X_Window win);
-
-EAPI Eina_Bool ecore_x_dpms_query(void);
-EAPI Eina_Bool ecore_x_dpms_capable_get(void);
-EAPI Eina_Bool ecore_x_dpms_enabled_get(void);
-EAPI void ecore_x_dpms_enabled_set(int enabled);
-EAPI void ecore_x_dpms_timeouts_get(unsigned int *standby,
- unsigned int *suspend,
- unsigned int *off);
-EAPI Eina_Bool ecore_x_dpms_timeouts_set(unsigned int standby,
- unsigned int suspend,
- unsigned int off);
-EAPI unsigned int ecore_x_dpms_timeout_standby_get(void);
-EAPI unsigned int ecore_x_dpms_timeout_suspend_get(void);
-EAPI unsigned int ecore_x_dpms_timeout_off_get(void);
-EAPI void ecore_x_dpms_timeout_standby_set(unsigned int new_timeout);
-EAPI void ecore_x_dpms_timeout_suspend_set(unsigned int new_timeout);
-EAPI void ecore_x_dpms_timeout_off_set(unsigned int new_timeout);
-
-EAPI Eina_Bool ecore_x_test_fake_key_down(const char *key);
-EAPI Eina_Bool ecore_x_test_fake_key_up(const char *key);
-EAPI Eina_Bool ecore_x_test_fake_key_press(const char *key);
-EAPI const char * ecore_x_keysym_string_get(int keysym);
-
-typedef struct _Ecore_X_Image Ecore_X_Image;
-
-EAPI Ecore_X_Image * ecore_x_image_new(int w,
- int h,
- Ecore_X_Visual vis,
- int depth);
-EAPI void ecore_x_image_free(Ecore_X_Image *im);
-EAPI Eina_Bool ecore_x_image_get(Ecore_X_Image *im,
- Ecore_X_Drawable draw,
- int x,
- int y,
- int sx,
- int sy,
- int w,
- int h);
-EAPI void ecore_x_image_put(Ecore_X_Image *im,
- Ecore_X_Drawable draw,
- Ecore_X_GC gc,
- int x,
- int y,
- int sx,
- int sy,
- int w,
- int h);
-EAPI void * ecore_x_image_data_get(Ecore_X_Image *im,
- int *bpl,
- int *rows,
- int *bpp);
-EAPI Eina_Bool ecore_x_image_is_argb32_get(Ecore_X_Image *im);
-
-EAPI Eina_Bool ecore_x_image_to_argb_convert(void *src, int sbpp,
- int sbpl,
- Ecore_X_Colormap c,
- Ecore_X_Visual v,
- int x, int y, int w, int h,
- unsigned int *dst,
- int dbpl,
- int dx, int dy);
-
-EAPI Eina_Bool ecore_x_input_multi_select(Ecore_X_Window win);
-
-EAPI Eina_Bool ecore_x_vsync_animator_tick_source_set(Ecore_X_Window win);
-
+typedef struct _Ecore_X_Event_Damage Ecore_X_Event_Damage;
+
+EAPI Eina_Bool
+ ecore_x_damage_query(void);
+EAPI Ecore_X_Damage
+ ecore_x_damage_new(Ecore_X_Drawable d,
+ Ecore_X_Damage_Report_Level level);
+EAPI void
+ ecore_x_damage_free(Ecore_X_Damage damage);
+EAPI void
+ ecore_x_damage_subtract(Ecore_X_Damage damage,
+ Ecore_X_Region repair,
+ Ecore_X_Region parts);
+
+EAPI Eina_Bool
+ ecore_x_screen_is_composited(int screen);
+EAPI void
+ ecore_x_screen_is_composited_set(int screen,
+ Ecore_X_Window win);
+
+EAPI Eina_Bool
+ ecore_x_dpms_query(void);
+EAPI Eina_Bool
+ ecore_x_dpms_capable_get(void);
+EAPI Eina_Bool
+ ecore_x_dpms_enabled_get(void);
+EAPI void
+ ecore_x_dpms_enabled_set(int enabled);
+EAPI void
+ ecore_x_dpms_timeouts_get(unsigned int *standby,
+ unsigned int *suspend,
+ unsigned int *off);
+EAPI Eina_Bool
+ecore_x_dpms_timeouts_set(unsigned int standby,
+ unsigned int suspend,
+ unsigned int off);
+EAPI unsigned int
+ ecore_x_dpms_timeout_standby_get(void);
+EAPI unsigned int
+ ecore_x_dpms_timeout_suspend_get(void);
+EAPI unsigned int
+ ecore_x_dpms_timeout_off_get(void);
+EAPI void
+ ecore_x_dpms_timeout_standby_set(unsigned int new_timeout);
+EAPI void
+ ecore_x_dpms_timeout_suspend_set(unsigned int new_timeout);
+EAPI void
+ ecore_x_dpms_timeout_off_set(unsigned int new_timeout);
+
+EAPI Eina_Bool
+ ecore_x_test_fake_key_down(const char *key);
+EAPI Eina_Bool
+ ecore_x_test_fake_key_up(const char *key);
+EAPI Eina_Bool
+ ecore_x_test_fake_key_press(const char *key);
+EAPI const char *
+ ecore_x_keysym_string_get(int keysym);
+
+typedef struct _Ecore_X_Image Ecore_X_Image;
+
+EAPI Ecore_X_Image *
+ecore_x_image_new(int w,
+ int h,
+ Ecore_X_Visual vis,
+ int depth);
+EAPI void
+ ecore_x_image_free(Ecore_X_Image *im);
+EAPI Eina_Bool
+ ecore_x_image_get(Ecore_X_Image *im,
+ Ecore_X_Drawable draw,
+ int x,
+ int y,
+ int sx,
+ int sy,
+ int w,
+ int h);
+EAPI void
+ecore_x_image_put(Ecore_X_Image *im,
+ Ecore_X_Drawable draw,
+ Ecore_X_GC gc,
+ int x,
+ int y,
+ int sx,
+ int sy,
+ int w,
+ int h);
+EAPI void *
+ecore_x_image_data_get(Ecore_X_Image *im,
+ int *bpl,
+ int *rows,
+ int *bpp);
+EAPI Eina_Bool
+ecore_x_image_is_argb32_get(Ecore_X_Image *im);
+
+EAPI Eina_Bool
+ecore_x_image_to_argb_convert(void *src,
+ int sbpp,
+ int sbpl,
+ Ecore_X_Colormap c,
+ Ecore_X_Visual v,
+ int x,
+ int y,
+ int w,
+ int h,
+ unsigned int *dst,
+ int dbpl,
+ int dx,
+ int dy);
+
+EAPI Eina_Bool
+ecore_x_input_multi_select(Ecore_X_Window win);
+
+EAPI Eina_Bool
+ecore_x_vsync_animator_tick_source_set(Ecore_X_Window win);
+
#ifdef __cplusplus
}
#endif // ifdef __cplusplus
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb.c
index 156f8d21d9..f01490b902 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb.c
@@ -3,9 +3,11 @@
#include <dlfcn.h>
/* local function prototypes */
-static int _ecore_xcb_shutdown(Eina_Bool close_display);
-static Eina_Bool _ecore_xcb_fd_handle(void *data, Ecore_Fd_Handler *hdlr __UNUSED__);
-static Eina_Bool _ecore_xcb_fd_handle_buff(void *data, Ecore_Fd_Handler *hdlr __UNUSED__);
+static int _ecore_xcb_shutdown(Eina_Bool close_display);
+static Eina_Bool _ecore_xcb_fd_handle(void *data,
+ Ecore_Fd_Handler *hdlr __UNUSED__);
+static Eina_Bool _ecore_xcb_fd_handle_buff(void *data,
+ Ecore_Fd_Handler *hdlr __UNUSED__);
static Eina_Bool _ecore_xcb_idle_enter(void *data __UNUSED__);
/* local variables */
@@ -38,25 +40,25 @@ double _ecore_xcb_double_click_time = 0.25;
* being shut down. 0 is returned if an error occurs.
* @ingroup Ecore_X_Init_Group
*/
-EAPI int
-ecore_x_init(const char *name)
+EAPI int
+ecore_x_init(const char *name)
{
char *gl = NULL;
uint32_t mask, list[1];
/* check if we have initialized already */
- if (++_ecore_xcb_init_count != 1)
+ if (++_ecore_xcb_init_count != 1)
return _ecore_xcb_init_count;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
/* try to initialize eina */
- if (!eina_init()) return --_ecore_xcb_init_count;
+ if (!eina_init()) return --_ecore_xcb_init_count;
/* setup ecore_xcb log domain */
- _ecore_xcb_log_dom =
+ _ecore_xcb_log_dom =
eina_log_domain_register("ecore_x", ECORE_XCB_DEFAULT_LOG_COLOR);
- if (_ecore_xcb_log_dom < 0)
+ if (_ecore_xcb_log_dom < 0)
{
EINA_LOG_ERR("Cannot create Ecore Xcb log domain");
eina_shutdown();
@@ -64,137 +66,138 @@ ecore_x_init(const char *name)
}
/* try to initialize ecore */
- if (!ecore_init())
+ if (!ecore_init())
{
/* unregister log domain */
- eina_log_domain_unregister(_ecore_xcb_log_dom);
- _ecore_xcb_log_dom = -1;
- eina_shutdown();
- return --_ecore_xcb_init_count;
+ eina_log_domain_unregister(_ecore_xcb_log_dom);
+ _ecore_xcb_log_dom = -1;
+ eina_shutdown();
+ return --_ecore_xcb_init_count;
}
/* try to initialize ecore_event */
- if (!ecore_event_init())
+ if (!ecore_event_init())
{
/* unregister log domain */
- eina_log_domain_unregister(_ecore_xcb_log_dom);
- _ecore_xcb_log_dom = -1;
- ecore_shutdown();
- eina_shutdown();
- return --_ecore_xcb_init_count;
+ eina_log_domain_unregister(_ecore_xcb_log_dom);
+ _ecore_xcb_log_dom = -1;
+ ecore_shutdown();
+ eina_shutdown();
+ return --_ecore_xcb_init_count;
}
/* NB: XLib has XInitThreads */
/* check for env var which says we are not going to use GL @ all
- *
- * NB: This is done because if someone wants a 'pure' xcb implementation
- * of ecore_x, all they need do is export this variable in the environment
- * and ecore_x will not use xlib stuff at all.
- *
- * The upside is you can get pure xcb-based ecore_x (w/ all the speed), but
- * there is a down-side here in that you cannot get OpenGL without XLib :(
+ *
+ * NB: This is done because if someone wants a 'pure' xcb implementation
+ * of ecore_x, all they need do is export this variable in the environment
+ * and ecore_x will not use xlib stuff at all.
+ *
+ * The upside is you can get pure xcb-based ecore_x (w/ all the speed), but
+ * there is a down-side here in that you cannot get OpenGL without XLib :(
*/
if ((gl = getenv("ECORE_X_NO_XLIB")))
{
- /* we found the env var that says 'Yes, we are not ever gonna try
+ /* we found the env var that says 'Yes, we are not ever gonna try
* OpenGL so it is safe to not use XLib at all' */
- /* try to connect to the display server */
- _ecore_xcb_conn = xcb_connect(name, NULL);
+ /* try to connect to the display server */
+ _ecore_xcb_conn = xcb_connect(name, NULL);
}
- else
+ else
{
- /* env var was not specified, so we will assume that the user
+ /* env var was not specified, so we will assume that the user
* may want opengl @ some point. connect this way for opengl to work */
- void *libxcb, *libxlib;
- Display *(*_real_display)(const char *display);
- xcb_connection_t *(*_real_connection)(Display *dpy);
- void (*_real_queue)(Display *dpy, enum XEventQueueOwner owner);
- int (*_real_close)(Display *dpy);
+ void *libxcb, *libxlib;
+ Display *(*_real_display)(const char *display);
+ xcb_connection_t *(*_real_connection)(Display * dpy);
+ void (*_real_queue)(Display *dpy,
+ enum XEventQueueOwner owner);
+ int (*_real_close)(Display *dpy);
#ifdef EVAS_FRAME_QUEUING
- Status (*_real_threads)(void);
+ Status (*_real_threads)(void);
#endif
- /* want to dlopen here to avoid actual library linkage */
- libxlib = dlopen("libX11.so", (RTLD_LAZY | RTLD_GLOBAL));
- if (!libxlib)
- libxlib = dlopen("libX11.so.6", (RTLD_LAZY | RTLD_GLOBAL));
- if (!libxlib)
- libxlib = dlopen("libX11.so.6.3.0", (RTLD_LAZY | RTLD_GLOBAL));
- if (!libxlib)
- {
- ERR("Could not dlsym to libX11");
- /* unregister log domain */
- eina_log_domain_unregister(_ecore_xcb_log_dom);
- _ecore_xcb_log_dom = -1;
- ecore_event_shutdown();
- ecore_shutdown();
- eina_shutdown();
- return --_ecore_xcb_init_count;
- }
-
- libxcb = dlopen("libX11-xcb.so", (RTLD_LAZY | RTLD_GLOBAL));
- if (!libxcb)
- libxcb = dlopen("libX11-xcb.so.1", (RTLD_LAZY | RTLD_GLOBAL));
- if (!libxcb)
- libxcb = dlopen("libX11-xcb.so.1.0.0", (RTLD_LAZY | RTLD_GLOBAL));
- if (!libxcb)
- {
- ERR("Could not dlsym to libX11-xcb");
- /* unregister log domain */
- eina_log_domain_unregister(_ecore_xcb_log_dom);
- _ecore_xcb_log_dom = -1;
- ecore_event_shutdown();
- ecore_shutdown();
- eina_shutdown();
- return --_ecore_xcb_init_count;
- }
-
- _real_display = dlsym(libxlib, "XOpenDisplay");
- _real_close = dlsym(libxlib, "XCloseDisplay");
- _real_connection = dlsym(libxcb, "XGetXCBConnection");
- _real_queue = dlsym(libxcb, "XSetEventQueueOwner");
+ /* want to dlopen here to avoid actual library linkage */
+ libxlib = dlopen("libX11.so", (RTLD_LAZY | RTLD_GLOBAL));
+ if (!libxlib)
+ libxlib = dlopen("libX11.so.6", (RTLD_LAZY | RTLD_GLOBAL));
+ if (!libxlib)
+ libxlib = dlopen("libX11.so.6.3.0", (RTLD_LAZY | RTLD_GLOBAL));
+ if (!libxlib)
+ {
+ ERR("Could not dlsym to libX11");
+ /* unregister log domain */
+ eina_log_domain_unregister(_ecore_xcb_log_dom);
+ _ecore_xcb_log_dom = -1;
+ ecore_event_shutdown();
+ ecore_shutdown();
+ eina_shutdown();
+ return --_ecore_xcb_init_count;
+ }
+
+ libxcb = dlopen("libX11-xcb.so", (RTLD_LAZY | RTLD_GLOBAL));
+ if (!libxcb)
+ libxcb = dlopen("libX11-xcb.so.1", (RTLD_LAZY | RTLD_GLOBAL));
+ if (!libxcb)
+ libxcb = dlopen("libX11-xcb.so.1.0.0", (RTLD_LAZY | RTLD_GLOBAL));
+ if (!libxcb)
+ {
+ ERR("Could not dlsym to libX11-xcb");
+ /* unregister log domain */
+ eina_log_domain_unregister(_ecore_xcb_log_dom);
+ _ecore_xcb_log_dom = -1;
+ ecore_event_shutdown();
+ ecore_shutdown();
+ eina_shutdown();
+ return --_ecore_xcb_init_count;
+ }
+
+ _real_display = dlsym(libxlib, "XOpenDisplay");
+ _real_close = dlsym(libxlib, "XCloseDisplay");
+ _real_connection = dlsym(libxcb, "XGetXCBConnection");
+ _real_queue = dlsym(libxcb, "XSetEventQueueOwner");
#ifdef EVAS_FRAME_QUEUING
- _real_threads = dlsym(libxlib, "XInitThreads");
+ _real_threads = dlsym(libxlib, "XInitThreads");
#endif
- if (_real_display)
- {
+ if (_real_display)
+ {
#ifdef EVAS_FRAME_QUEUING
- if (_real_threads) _real_threads();
+ if (_real_threads) _real_threads();
#endif
- _ecore_xcb_display = _real_display(name);
- if (!_ecore_xcb_display)
- {
- ERR("Could not open Display via XLib");
- /* unregister log domain */
- eina_log_domain_unregister(_ecore_xcb_log_dom);
- _ecore_xcb_log_dom = -1;
- ecore_event_shutdown();
- ecore_shutdown();
- eina_shutdown();
- return --_ecore_xcb_init_count;
- }
- if (_real_connection)
- _ecore_xcb_conn = _real_connection(_ecore_xcb_display);
- if (!_ecore_xcb_conn)
- {
- ERR("Could not get XCB Connection from XLib");
-
- if (_real_close) _real_close(_ecore_xcb_display);
-
- /* unregister log domain */
- eina_log_domain_unregister(_ecore_xcb_log_dom);
- _ecore_xcb_log_dom = -1;
- ecore_event_shutdown();
- ecore_shutdown();
- eina_shutdown();
- return --_ecore_xcb_init_count;
- }
- if (_real_queue)
- _real_queue(_ecore_xcb_display, XCBOwnsEventQueue);
- }
+ _ecore_xcb_display = _real_display(name);
+ if (!_ecore_xcb_display)
+ {
+ ERR("Could not open Display via XLib");
+ /* unregister log domain */
+ eina_log_domain_unregister(_ecore_xcb_log_dom);
+ _ecore_xcb_log_dom = -1;
+ ecore_event_shutdown();
+ ecore_shutdown();
+ eina_shutdown();
+ return --_ecore_xcb_init_count;
+ }
+ if (_real_connection)
+ _ecore_xcb_conn = _real_connection(_ecore_xcb_display);
+ if (!_ecore_xcb_conn)
+ {
+ ERR("Could not get XCB Connection from XLib");
+
+ if (_real_close) _real_close(_ecore_xcb_display);
+
+ /* unregister log domain */
+ eina_log_domain_unregister(_ecore_xcb_log_dom);
+ _ecore_xcb_log_dom = -1;
+ ecore_event_shutdown();
+ ecore_shutdown();
+ eina_shutdown();
+ return --_ecore_xcb_init_count;
+ }
+ if (_real_queue)
+ _real_queue(_ecore_xcb_display, XCBOwnsEventQueue);
+ }
}
if (xcb_connection_has_error(_ecore_xcb_conn))
@@ -209,13 +212,13 @@ ecore_x_init(const char *name)
}
/* grab the default screen */
- _ecore_xcb_screen =
+ _ecore_xcb_screen =
xcb_setup_roots_iterator(xcb_get_setup(_ecore_xcb_conn)).data;
/* NB: This method of init/finalize extensions first, then atoms
- * Does end up being 2 round trips to X, BUT if we do extensions init then
- * atoms init first, and call the 'finalize' functions later, we end up
- * being slower, so it's a trade-off. This current method clocks in
+ * Does end up being 2 round trips to X, BUT if we do extensions init then
+ * atoms init first, and call the 'finalize' functions later, we end up
+ * being slower, so it's a trade-off. This current method clocks in
* around 0.003 for fetching atoms VS 0.010 for init both then finalize */
/* prefetch extension data */
@@ -239,13 +242,13 @@ ecore_x_init(const char *name)
_ecore_xcb_keymap_finalize();
/* setup ecore fd handler */
- _ecore_xcb_fd_handler =
- ecore_main_fd_handler_add(xcb_get_file_descriptor(_ecore_xcb_conn),
- ECORE_FD_READ, _ecore_xcb_fd_handle,
- _ecore_xcb_conn, _ecore_xcb_fd_handle_buff,
+ _ecore_xcb_fd_handler =
+ ecore_main_fd_handler_add(xcb_get_file_descriptor(_ecore_xcb_conn),
+ ECORE_FD_READ, _ecore_xcb_fd_handle,
+ _ecore_xcb_conn, _ecore_xcb_fd_handle_buff,
_ecore_xcb_conn);
- if (!_ecore_xcb_fd_handler)
+ if (!_ecore_xcb_fd_handler)
return _ecore_xcb_shutdown(EINA_TRUE);
/* prefetch atoms */
@@ -263,13 +266,13 @@ ecore_x_init(const char *name)
/* old e hints init: dummy function */
ecore_x_e_init();
- _ecore_xcb_atoms_wm_protocol[ECORE_X_WM_PROTOCOL_DELETE_REQUEST] =
+ _ecore_xcb_atoms_wm_protocol[ECORE_X_WM_PROTOCOL_DELETE_REQUEST] =
ECORE_X_ATOM_WM_DELETE_WINDOW;
- _ecore_xcb_atoms_wm_protocol[ECORE_X_WM_PROTOCOL_TAKE_FOCUS] =
+ _ecore_xcb_atoms_wm_protocol[ECORE_X_WM_PROTOCOL_TAKE_FOCUS] =
ECORE_X_ATOM_WM_TAKE_FOCUS;
- _ecore_xcb_atoms_wm_protocol[ECORE_X_NET_WM_PROTOCOL_PING] =
+ _ecore_xcb_atoms_wm_protocol[ECORE_X_NET_WM_PROTOCOL_PING] =
ECORE_X_ATOM_NET_WM_PING;
- _ecore_xcb_atoms_wm_protocol[ECORE_X_NET_WM_PROTOCOL_SYNC_REQUEST] =
+ _ecore_xcb_atoms_wm_protocol[ECORE_X_NET_WM_PROTOCOL_SYNC_REQUEST] =
ECORE_X_ATOM_NET_WM_SYNC_REQUEST;
/* setup selection */
@@ -278,7 +281,7 @@ ecore_x_init(const char *name)
/* setup dnd */
_ecore_xcb_dnd_init();
- _ecore_xcb_idle_enterer =
+ _ecore_xcb_idle_enterer =
ecore_idle_enterer_add(_ecore_xcb_idle_enter, NULL);
return _ecore_xcb_init_count;
@@ -294,8 +297,8 @@ ecore_x_init(const char *name)
* being shut down.
* @ingroup Ecore_X_Init_Group
*/
-EAPI int
-ecore_x_shutdown(void)
+EAPI int
+ecore_x_shutdown(void)
{
return _ecore_xcb_shutdown(EINA_TRUE);
}
@@ -307,8 +310,8 @@ ecore_x_shutdown(void)
*
* @ingroup Ecore_X_Init_Group
*/
-EAPI int
-ecore_x_disconnect(void)
+EAPI int
+ecore_x_disconnect(void)
{
return _ecore_xcb_shutdown(EINA_FALSE);
}
@@ -324,13 +327,13 @@ ecore_x_disconnect(void)
* Sends all X commands in the X Display buffer.
* @ingroup Ecore_X_Flush_Group
*/
-EAPI void
-ecore_x_flush(void)
+EAPI void
+ecore_x_flush(void)
{
// LOGFN(__FILE__, __LINE__, __FUNCTION__);
- CHECK_XCB_CONN;
- xcb_flush(_ecore_xcb_conn);
+ CHECK_XCB_CONN;
+ xcb_flush(_ecore_xcb_conn);
}
/**
@@ -339,7 +342,7 @@ ecore_x_flush(void)
* @ingroup Ecore_X_Display_Attr_Group
*/
EAPI Ecore_X_Screen *
-ecore_x_default_screen_get(void)
+ecore_x_default_screen_get(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -347,7 +350,7 @@ ecore_x_default_screen_get(void)
}
EAPI Ecore_X_Connection *
-ecore_x_connection_get(void)
+ecore_x_connection_get(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -358,8 +361,8 @@ ecore_x_connection_get(void)
/**
* Return the last event time
*/
-EAPI Ecore_X_Time
-ecore_x_current_time_get(void)
+EAPI Ecore_X_Time
+ecore_x_current_time_get(void)
{
return _ecore_xcb_events_last_time_get();
}
@@ -369,37 +372,37 @@ ecore_x_current_time_get(void)
* processed by the server.
* @ingroup Ecore_X_Flush_Group
*/
-EAPI void
-ecore_x_sync(void)
+EAPI void
+ecore_x_sync(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- free(xcb_get_input_focus_reply(_ecore_xcb_conn,
- xcb_get_input_focus_unchecked(_ecore_xcb_conn),
+ free(xcb_get_input_focus_reply(_ecore_xcb_conn,
+ xcb_get_input_focus_unchecked(_ecore_xcb_conn),
NULL));
}
-EAPI void
-ecore_x_grab(void)
+EAPI void
+ecore_x_grab(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
_ecore_xcb_grab_count++;
- if (_ecore_xcb_grab_count == 1)
+ if (_ecore_xcb_grab_count == 1)
xcb_grab_server(_ecore_xcb_conn);
}
-EAPI void
-ecore_x_ungrab(void)
+EAPI void
+ecore_x_ungrab(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
_ecore_xcb_grab_count--;
if (_ecore_xcb_grab_count < 0) _ecore_xcb_grab_count = 0;
- if (_ecore_xcb_grab_count == 0)
+ if (_ecore_xcb_grab_count == 0)
xcb_ungrab_server(_ecore_xcb_conn);
}
@@ -416,8 +419,15 @@ ecore_x_ungrab(void)
*
* @return EINA_TRUE on success EINA_FALSE otherwise.
*/
-EAPI Eina_Bool
-ecore_x_client_message32_send(Ecore_X_Window win, Ecore_X_Atom type, Ecore_X_Event_Mask mask, long d0, long d1, long d2, long d3, long d4)
+EAPI Eina_Bool
+ecore_x_client_message32_send(Ecore_X_Window win,
+ Ecore_X_Atom type,
+ Ecore_X_Event_Mask mask,
+ long d0,
+ long d1,
+ long d2,
+ long d3,
+ long d4)
{
xcb_client_message_event_t ev;
xcb_void_cookie_t cookie;
@@ -441,7 +451,7 @@ ecore_x_client_message32_send(Ecore_X_Window win, Ecore_X_Atom type, Ecore_X_Eve
cookie = xcb_send_event(_ecore_xcb_conn, 0, win, mask, (const char *)&ev);
err = xcb_request_check(_ecore_xcb_conn, cookie);
- if (err)
+ if (err)
{
DBG("Problem Sending Event");
DBG("\tType: %d", type);
@@ -464,8 +474,11 @@ ecore_x_client_message32_send(Ecore_X_Window win, Ecore_X_Atom type, Ecore_X_Eve
*
* @return EINA_TRUE on success EINA_FALSE otherwise.
*/
-EAPI Eina_Bool
-ecore_x_client_message8_send(Ecore_X_Window win, Ecore_X_Atom type, const void *data, int len)
+EAPI Eina_Bool
+ecore_x_client_message8_send(Ecore_X_Window win,
+ Ecore_X_Atom type,
+ const void *data,
+ int len)
{
xcb_client_message_event_t ev;
xcb_void_cookie_t cookie;
@@ -484,11 +497,11 @@ ecore_x_client_message8_send(Ecore_X_Window win, Ecore_X_Atom type, const void *
memcpy(ev.data.data8, data, len);
memset(ev.data.data8 + len, 0, 20 - len);
- cookie = xcb_send_event(_ecore_xcb_conn, 0, win,
+ cookie = xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
err = xcb_request_check(_ecore_xcb_conn, cookie);
- if (err)
+ if (err)
{
DBG("Problem Sending Event");
DBG("\tType: %d", type);
@@ -501,8 +514,11 @@ ecore_x_client_message8_send(Ecore_X_Window win, Ecore_X_Atom type, const void *
return EINA_TRUE;
}
-EAPI Eina_Bool
-ecore_x_mouse_down_send(Ecore_X_Window win, int x, int y, int b)
+EAPI Eina_Bool
+ecore_x_mouse_down_send(Ecore_X_Window win,
+ int x,
+ int y,
+ int b)
{
xcb_translate_coordinates_cookie_t cookie;
xcb_translate_coordinates_reply_t *reply;
@@ -521,7 +537,7 @@ ecore_x_mouse_down_send(Ecore_X_Window win, int x, int y, int b)
memset(&ev, 0, sizeof(xcb_button_press_event_t));
- ev.response_type = XCB_BUTTON_PRESS;
+ ev.response_type = XCB_BUTTON_PRESS;
ev.event = win;
ev.child = win;
ev.root = root;
@@ -535,11 +551,11 @@ ecore_x_mouse_down_send(Ecore_X_Window win, int x, int y, int b)
ev.time = ecore_x_current_time_get();
free(reply);
- vcookie = xcb_send_event(_ecore_xcb_conn, 1, win,
+ vcookie = xcb_send_event(_ecore_xcb_conn, 1, win,
XCB_EVENT_MASK_BUTTON_PRESS, (const char *)&ev);
err = xcb_request_check(_ecore_xcb_conn, vcookie);
- if (err)
+ if (err)
{
_ecore_xcb_error_handle(err);
free(err);
@@ -549,8 +565,11 @@ ecore_x_mouse_down_send(Ecore_X_Window win, int x, int y, int b)
return EINA_TRUE;
}
-EAPI Eina_Bool
-ecore_x_mouse_up_send(Ecore_X_Window win, int x, int y, int b)
+EAPI Eina_Bool
+ecore_x_mouse_up_send(Ecore_X_Window win,
+ int x,
+ int y,
+ int b)
{
xcb_translate_coordinates_cookie_t cookie;
xcb_translate_coordinates_reply_t *reply;
@@ -583,11 +602,11 @@ ecore_x_mouse_up_send(Ecore_X_Window win, int x, int y, int b)
ev.time = ecore_x_current_time_get();
free(reply);
- vcookie = xcb_send_event(_ecore_xcb_conn, 1, win,
+ vcookie = xcb_send_event(_ecore_xcb_conn, 1, win,
XCB_EVENT_MASK_BUTTON_RELEASE, (const char *)&ev);
err = xcb_request_check(_ecore_xcb_conn, vcookie);
- if (err)
+ if (err)
{
_ecore_xcb_error_handle(err);
free(err);
@@ -597,8 +616,10 @@ ecore_x_mouse_up_send(Ecore_X_Window win, int x, int y, int b)
return EINA_TRUE;
}
-EAPI Eina_Bool
-ecore_x_mouse_move_send(Ecore_X_Window win, int x, int y)
+EAPI Eina_Bool
+ecore_x_mouse_move_send(Ecore_X_Window win,
+ int x,
+ int y)
{
xcb_translate_coordinates_cookie_t cookie;
xcb_translate_coordinates_reply_t *reply;
@@ -631,11 +652,11 @@ ecore_x_mouse_move_send(Ecore_X_Window win, int x, int y)
ev.time = ecore_x_current_time_get();
free(reply);
- vcookie = xcb_send_event(_ecore_xcb_conn, 1, win,
+ vcookie = xcb_send_event(_ecore_xcb_conn, 1, win,
XCB_EVENT_MASK_POINTER_MOTION, (const char *)&ev);
err = xcb_request_check(_ecore_xcb_conn, vcookie);
- if (err)
+ if (err)
{
_ecore_xcb_error_handle(err);
free(err);
@@ -645,8 +666,8 @@ ecore_x_mouse_move_send(Ecore_X_Window win, int x, int y)
return EINA_TRUE;
}
-EAPI Eina_Bool
-ecore_x_keyboard_grab(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_keyboard_grab(Ecore_X_Window win)
{
xcb_grab_keyboard_cookie_t cookie;
xcb_grab_keyboard_reply_t *reply;
@@ -654,8 +675,8 @@ ecore_x_keyboard_grab(Ecore_X_Window win)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- cookie =
- xcb_grab_keyboard_unchecked(_ecore_xcb_conn, 0, win, XCB_CURRENT_TIME,
+ cookie =
+ xcb_grab_keyboard_unchecked(_ecore_xcb_conn, 0, win, XCB_CURRENT_TIME,
XCB_GRAB_MODE_ASYNC, XCB_GRAB_MODE_ASYNC);
reply = xcb_grab_keyboard_reply(_ecore_xcb_conn, cookie, NULL);
if (!reply) return EINA_FALSE;
@@ -663,8 +684,8 @@ ecore_x_keyboard_grab(Ecore_X_Window win)
return EINA_TRUE;
}
-EAPI void
-ecore_x_keyboard_ungrab(void)
+EAPI void
+ecore_x_keyboard_ungrab(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -672,8 +693,10 @@ ecore_x_keyboard_ungrab(void)
xcb_ungrab_keyboard(_ecore_xcb_conn, XCB_CURRENT_TIME);
}
-EAPI void
-ecore_x_pointer_xy_get(Ecore_X_Window win, int *x, int *y)
+EAPI void
+ecore_x_pointer_xy_get(Ecore_X_Window win,
+ int *x,
+ int *y)
{
xcb_query_pointer_cookie_t cookie;
xcb_query_pointer_reply_t *reply;
@@ -694,8 +717,10 @@ ecore_x_pointer_xy_get(Ecore_X_Window win, int *x, int *y)
free(reply);
}
-EAPI Eina_Bool
-ecore_x_pointer_control_set(int accel_num, int accel_denom, int threshold)
+EAPI Eina_Bool
+ecore_x_pointer_control_set(int accel_num,
+ int accel_denom,
+ int threshold)
{
xcb_void_cookie_t vcookie;
xcb_generic_error_t *err;
@@ -703,11 +728,11 @@ ecore_x_pointer_control_set(int accel_num, int accel_denom, int threshold)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- vcookie =
- xcb_change_pointer_control(_ecore_xcb_conn,
+ vcookie =
+ xcb_change_pointer_control(_ecore_xcb_conn,
accel_num, accel_denom, threshold, 1, 1);
err = xcb_request_check(_ecore_xcb_conn, vcookie);
- if (err)
+ if (err)
{
_ecore_xcb_error_handle(err);
free(err);
@@ -717,8 +742,10 @@ ecore_x_pointer_control_set(int accel_num, int accel_denom, int threshold)
return EINA_TRUE;
}
-EAPI Eina_Bool
-ecore_x_pointer_control_get(int *accel_num, int *accel_denom, int *threshold)
+EAPI Eina_Bool
+ecore_x_pointer_control_get(int *accel_num,
+ int *accel_denom,
+ int *threshold)
{
xcb_get_pointer_control_cookie_t cookie;
xcb_get_pointer_control_reply_t *reply;
@@ -742,8 +769,9 @@ ecore_x_pointer_control_get(int *accel_num, int *accel_denom, int *threshold)
return EINA_TRUE;
}
-EAPI Eina_Bool
-ecore_x_pointer_mapping_set(unsigned char *map, int nmap)
+EAPI Eina_Bool
+ecore_x_pointer_mapping_set(unsigned char *map,
+ int nmap)
{
xcb_set_pointer_mapping_cookie_t cookie;
xcb_set_pointer_mapping_reply_t *reply;
@@ -755,15 +783,16 @@ ecore_x_pointer_mapping_set(unsigned char *map, int nmap)
cookie = xcb_set_pointer_mapping_unchecked(_ecore_xcb_conn, nmap, map);
reply = xcb_set_pointer_mapping_reply(_ecore_xcb_conn, cookie, NULL);
if (!reply) return EINA_FALSE;
- ret =
+ ret =
(reply->status == XCB_MAPPING_STATUS_SUCCESS) ? EINA_TRUE : EINA_FALSE;
free(reply);
return ret;
}
-EAPI Eina_Bool
-ecore_x_pointer_mapping_get(unsigned char *map, int nmap)
+EAPI Eina_Bool
+ecore_x_pointer_mapping_get(unsigned char *map,
+ int nmap)
{
xcb_get_pointer_mapping_cookie_t cookie;
xcb_get_pointer_mapping_reply_t *reply;
@@ -785,7 +814,7 @@ ecore_x_pointer_mapping_get(unsigned char *map, int nmap)
return EINA_FALSE;
}
- if (map)
+ if (map)
{
uint8_t *tmp;
int i = 0;
@@ -799,8 +828,8 @@ ecore_x_pointer_mapping_get(unsigned char *map, int nmap)
return EINA_TRUE;
}
-EAPI Eina_Bool
-ecore_x_pointer_grab(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_pointer_grab(Ecore_X_Window win)
{
xcb_grab_pointer_cookie_t cookie;
xcb_grab_pointer_reply_t *reply;
@@ -810,13 +839,13 @@ ecore_x_pointer_grab(Ecore_X_Window win)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- mask = (XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE |
- XCB_EVENT_MASK_ENTER_WINDOW | XCB_EVENT_MASK_LEAVE_WINDOW |
+ mask = (XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE |
+ XCB_EVENT_MASK_ENTER_WINDOW | XCB_EVENT_MASK_LEAVE_WINDOW |
XCB_EVENT_MASK_POINTER_MOTION);
- cookie = xcb_grab_pointer_unchecked(_ecore_xcb_conn, 0, win, mask,
- XCB_GRAB_MODE_ASYNC,
- XCB_GRAB_MODE_ASYNC,
+ cookie = xcb_grab_pointer_unchecked(_ecore_xcb_conn, 0, win, mask,
+ XCB_GRAB_MODE_ASYNC,
+ XCB_GRAB_MODE_ASYNC,
XCB_NONE, XCB_NONE, XCB_CURRENT_TIME);
reply = xcb_grab_pointer_reply(_ecore_xcb_conn, cookie, NULL);
if (!reply) return EINA_FALSE;
@@ -827,8 +856,8 @@ ecore_x_pointer_grab(Ecore_X_Window win)
return ret;
}
-EAPI Eina_Bool
-ecore_x_pointer_confine_grab(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_pointer_confine_grab(Ecore_X_Window win)
{
xcb_grab_pointer_cookie_t cookie;
xcb_grab_pointer_reply_t *reply;
@@ -838,13 +867,13 @@ ecore_x_pointer_confine_grab(Ecore_X_Window win)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- mask = (XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE |
- XCB_EVENT_MASK_ENTER_WINDOW | XCB_EVENT_MASK_LEAVE_WINDOW |
+ mask = (XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE |
+ XCB_EVENT_MASK_ENTER_WINDOW | XCB_EVENT_MASK_LEAVE_WINDOW |
XCB_EVENT_MASK_POINTER_MOTION);
- cookie = xcb_grab_pointer_unchecked(_ecore_xcb_conn, 0, win, mask,
- XCB_GRAB_MODE_ASYNC,
- XCB_GRAB_MODE_ASYNC,
+ cookie = xcb_grab_pointer_unchecked(_ecore_xcb_conn, 0, win, mask,
+ XCB_GRAB_MODE_ASYNC,
+ XCB_GRAB_MODE_ASYNC,
win, XCB_NONE, XCB_CURRENT_TIME);
reply = xcb_grab_pointer_reply(_ecore_xcb_conn, cookie, NULL);
if (!reply) return EINA_FALSE;
@@ -855,8 +884,8 @@ ecore_x_pointer_confine_grab(Ecore_X_Window win)
return ret;
}
-EAPI void
-ecore_x_pointer_ungrab(void)
+EAPI void
+ecore_x_pointer_ungrab(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -864,8 +893,10 @@ ecore_x_pointer_ungrab(void)
xcb_ungrab_pointer(_ecore_xcb_conn, XCB_CURRENT_TIME);
}
-EAPI Eina_Bool
-ecore_x_pointer_warp(Ecore_X_Window win, int x, int y)
+EAPI Eina_Bool
+ecore_x_pointer_warp(Ecore_X_Window win,
+ int x,
+ int y)
{
xcb_void_cookie_t vcookie;
xcb_generic_error_t *err;
@@ -873,10 +904,10 @@ ecore_x_pointer_warp(Ecore_X_Window win, int x, int y)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- vcookie =
+ vcookie =
xcb_warp_pointer_checked(_ecore_xcb_conn, XCB_NONE, win, 0, 0, 0, 0, x, y);
err = xcb_request_check(_ecore_xcb_conn, vcookie);
- if (err)
+ if (err)
{
_ecore_xcb_error_handle(err);
free(err);
@@ -898,8 +929,8 @@ ecore_x_pointer_warp(Ecore_X_Window win, int x, int y)
*
* @returns EINA_TRUE on success, EINA_FALSE otherwise.
*/
-EAPI Eina_Bool
-ecore_x_bell(int percent)
+EAPI Eina_Bool
+ecore_x_bell(int percent)
{
xcb_void_cookie_t cookie;
xcb_generic_error_t *err;
@@ -909,7 +940,7 @@ ecore_x_bell(int percent)
// FIXME: Use unchecked version after development is ironed out
cookie = xcb_bell_checked(_ecore_xcb_conn, percent);
err = xcb_request_check(_ecore_xcb_conn, cookie);
- if (err)
+ if (err)
{
_ecore_xcb_error_handle(err);
free(err);
@@ -919,8 +950,10 @@ ecore_x_bell(int percent)
return EINA_TRUE;
}
-EAPI void
-ecore_x_display_size_get(Ecore_X_Display *dsp __UNUSED__, int *w, int *h)
+EAPI void
+ecore_x_display_size_get(Ecore_X_Display *dsp __UNUSED__,
+ int *w,
+ int *h)
{
xcb_screen_t *screen;
@@ -933,8 +966,8 @@ ecore_x_display_size_get(Ecore_X_Display *dsp __UNUSED__, int *w, int *h)
if (h) *h = screen->height_in_pixels;
}
-EAPI unsigned long
-ecore_x_display_black_pixel_get(Ecore_X_Display *dsp __UNUSED__)
+EAPI unsigned long
+ecore_x_display_black_pixel_get(Ecore_X_Display *dsp __UNUSED__)
{
xcb_screen_t *screen;
@@ -946,8 +979,8 @@ ecore_x_display_black_pixel_get(Ecore_X_Display *dsp __UNUSED__)
return screen->black_pixel;
}
-EAPI unsigned long
-ecore_x_display_white_pixel_get(Ecore_X_Display *dsp __UNUSED__)
+EAPI unsigned long
+ecore_x_display_white_pixel_get(Ecore_X_Display *dsp __UNUSED__)
{
xcb_screen_t *screen;
@@ -959,8 +992,9 @@ ecore_x_display_white_pixel_get(Ecore_X_Display *dsp __UNUSED__)
return screen->white_pixel;
}
-EAPI void
-ecore_x_pointer_last_xy_get(int *x, int *y)
+EAPI void
+ecore_x_pointer_last_xy_get(int *x,
+ int *y)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -968,20 +1002,20 @@ ecore_x_pointer_last_xy_get(int *x, int *y)
if (y) *y = _ecore_xcb_event_last_root_y;
}
-EAPI void
-ecore_x_focus_reset(void)
+EAPI void
+ecore_x_focus_reset(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- xcb_set_input_focus(_ecore_xcb_conn, XCB_INPUT_FOCUS_POINTER_ROOT,
- ((xcb_screen_t *)_ecore_xcb_screen)->root,
+ xcb_set_input_focus(_ecore_xcb_conn, XCB_INPUT_FOCUS_POINTER_ROOT,
+ ((xcb_screen_t *)_ecore_xcb_screen)->root,
XCB_CURRENT_TIME);
// ecore_x_flush();
}
-EAPI void
-ecore_x_events_allow_all(void)
+EAPI void
+ecore_x_events_allow_all(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -997,8 +1031,8 @@ ecore_x_events_allow_all(void)
*
* @param win Window of the client to be killed
*/
-EAPI void
-ecore_x_kill(Ecore_X_Window win)
+EAPI void
+ecore_x_kill(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -1016,8 +1050,8 @@ ecore_x_kill(Ecore_X_Window win)
*
* @param root The window whose children will be killed.
*/
-EAPI void
-ecore_x_killall(Ecore_X_Window root)
+EAPI void
+ecore_x_killall(Ecore_X_Window root)
{
int screens = 0, i = 0;
@@ -1063,8 +1097,8 @@ ecore_x_killall(Ecore_X_Window root)
*
* @return the general screen DPI (dots/pixels per inch).
*/
-EAPI int
-ecore_x_dpi_get(void)
+EAPI int
+ecore_x_dpi_get(void)
{
uint16_t mw = 0, w = 0;
@@ -1073,7 +1107,7 @@ ecore_x_dpi_get(void)
mw = ((xcb_screen_t *)_ecore_xcb_screen)->width_in_millimeters;
if (mw <= 0) return 75;
w = ((xcb_screen_t *)_ecore_xcb_screen)->width_in_pixels;
- return ((((w * 254) / mw) + 5) / 10);
+ return (((w * 254) / mw) + 5) / 10;
}
/**
@@ -1088,19 +1122,19 @@ ecore_x_dpi_get(void)
* @ingroup Ecore_X_Display_Attr_Group
*/
EAPI Ecore_X_Display *
-ecore_x_display_get(void)
+ecore_x_display_get(void)
{
char *gl = NULL;
CHECK_XCB_CONN;
- /* if we have the 'dont use xlib' env var, then we are not using
+ /* if we have the 'dont use xlib' env var, then we are not using
* XLib and thus cannot return a real XDisplay.
- *
+ *
* NB: This may break EFL in some places and needs lots of testing !!! */
- if ((gl = getenv("ECORE_X_NO_XLIB")))
+ if ((gl = getenv("ECORE_X_NO_XLIB")))
return (Ecore_X_Display *)_ecore_xcb_conn;
- else /* we can safely return an XDisplay var */
+ else /* we can safely return an XDisplay var */
return (Ecore_X_Display *)_ecore_xcb_display;
}
@@ -1109,16 +1143,19 @@ ecore_x_display_get(void)
* @return The current X display file descriptor.
* @ingroup Ecore_X_Display_Attr_Group
*/
-EAPI int
-ecore_x_fd_get(void)
+EAPI int
+ecore_x_fd_get(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
return xcb_get_file_descriptor(_ecore_xcb_conn);
}
-EAPI void
-ecore_x_passive_grab_replay_func_set(Eina_Bool (*func) (void *data, int type, void *event), void *data)
+EAPI void
+ecore_x_passive_grab_replay_func_set(Eina_Bool (*func)(void *data,
+ int type,
+ void *event),
+ void *data)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -1136,8 +1173,10 @@ ecore_x_passive_grab_replay_func_set(Eina_Bool (*func) (void *data, int type, vo
*
* @since 1.1
*/
-EAPI void
-ecore_x_screen_size_get(const Ecore_X_Screen *screen, int *w, int *h)
+EAPI void
+ecore_x_screen_size_get(const Ecore_X_Screen *screen,
+ int *w,
+ int *h)
{
xcb_screen_t *s;
@@ -1152,14 +1191,14 @@ ecore_x_screen_size_get(const Ecore_X_Screen *screen, int *w, int *h)
/**
* Retrieves the count of screens.
- *
+ *
* @return The count of screens.
* @ingroup Ecore_X_Display_Attr_Group
*
* @since 1.1
*/
-EAPI int
-ecore_x_screen_count_get(void)
+EAPI int
+ecore_x_screen_count_get(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -1169,25 +1208,25 @@ ecore_x_screen_count_get(void)
/**
* Retrieves the index number of the given screen.
- *
+ *
* @return The index number of the screen.
* @ingroup Ecore_X_Display_Attr_Group
*
* @since 1.1
*/
-EAPI int
-ecore_x_screen_index_get(const Ecore_X_Screen *screen)
+EAPI int
+ecore_x_screen_index_get(const Ecore_X_Screen *screen)
{
xcb_screen_iterator_t iter;
int i = 0;
CHECK_XCB_CONN;
- iter =
+ iter =
xcb_setup_roots_iterator(xcb_get_setup(_ecore_xcb_conn));
- for (; iter.rem; xcb_screen_next(&iter))
+ for (; iter.rem; xcb_screen_next(&iter))
{
- if (iter.data == (xcb_screen_t *)screen)
+ if (iter.data == (xcb_screen_t *)screen)
return i;
i++;
}
@@ -1197,29 +1236,29 @@ ecore_x_screen_index_get(const Ecore_X_Screen *screen)
/**
* Retrieves the screen based on index number.
- *
+ *
* @return The Ecore_X_Screen at this index.
* @ingroup Ecore_X_Display_Attr_Group
*
* @since 1.1
*/
EAPI Ecore_X_Screen *
-ecore_x_screen_get(int index)
+ecore_x_screen_get(int index)
{
xcb_screen_iterator_t iter;
int i = 0;
CHECK_XCB_CONN;
- iter =
+ iter =
xcb_setup_roots_iterator(xcb_get_setup(_ecore_xcb_conn));
- for (i = 0; iter.rem; xcb_screen_next(&iter), i++)
+ for (i = 0; iter.rem; xcb_screen_next(&iter), i++)
if (i == index) return iter.data;
return NULL;
}
-EAPI unsigned int
+EAPI unsigned int
ecore_x_visual_id_get(Ecore_X_Visual visual)
{
return ((xcb_visualtype_t *)visual)->visual_id;
@@ -1234,8 +1273,9 @@ ecore_x_visual_id_get(Ecore_X_Visual visual)
* @return The default visual.
* @since 1.1.0
*/
-EAPI Ecore_X_Visual
-ecore_x_default_visual_get(Ecore_X_Display *disp __UNUSED__, Ecore_X_Screen *screen)
+EAPI Ecore_X_Visual
+ecore_x_default_visual_get(Ecore_X_Display *disp __UNUSED__,
+ Ecore_X_Screen *screen)
{
xcb_screen_t *s;
xcb_depth_iterator_t diter;
@@ -1245,10 +1285,10 @@ ecore_x_default_visual_get(Ecore_X_Display *disp __UNUSED__, Ecore_X_Screen *scr
s = (xcb_screen_t *)screen;
diter = xcb_screen_allowed_depths_iterator(s);
- for (; diter.rem; xcb_depth_next(&diter))
+ for (; diter.rem; xcb_depth_next(&diter))
{
viter = xcb_depth_visuals_iterator(diter.data);
- for (; viter.rem; xcb_visualtype_next(&viter))
+ for (; viter.rem; xcb_visualtype_next(&viter))
{
if (viter.data->visual_id == s->root_visual)
return viter.data;
@@ -1266,8 +1306,9 @@ ecore_x_default_visual_get(Ecore_X_Display *disp __UNUSED__, Ecore_X_Screen *scr
* @return The default colormap.
* @since 1.1.0
*/
-EAPI Ecore_X_Colormap
-ecore_x_default_colormap_get(Ecore_X_Display *disp __UNUSED__, Ecore_X_Screen *screen)
+EAPI Ecore_X_Colormap
+ecore_x_default_colormap_get(Ecore_X_Display *disp __UNUSED__,
+ Ecore_X_Screen *screen)
{
xcb_screen_t *s;
@@ -1284,8 +1325,9 @@ ecore_x_default_colormap_get(Ecore_X_Display *disp __UNUSED__, Ecore_X_Screen *s
* @return The default depth.
* @since 1.1.0
*/
-EAPI int
-ecore_x_default_depth_get(Ecore_X_Display *disp __UNUSED__, Ecore_X_Screen *screen)
+EAPI int
+ecore_x_default_depth_get(Ecore_X_Display *disp __UNUSED__,
+ Ecore_X_Screen *screen)
{
xcb_screen_t *s;
@@ -1303,8 +1345,8 @@ ecore_x_default_depth_get(Ecore_X_Display *disp __UNUSED__, Ecore_X_Screen *scre
* @param t The time in seconds
* @ingroup Ecore_X_Display_Attr_Group
*/
-EAPI void
-ecore_x_double_click_time_set(double t)
+EAPI void
+ecore_x_double_click_time_set(double t)
{
if (t < 0.0) t = 0.0;
_ecore_xcb_double_click_time = t;
@@ -1318,20 +1360,20 @@ ecore_x_double_click_time_set(double t)
* @return The timeout for double clicks in seconds.
* @ingroup Ecore_X_Display_Attr_Group
*/
-EAPI double
-ecore_x_double_click_time_get(void)
+EAPI double
+ecore_x_double_click_time_get(void)
{
return _ecore_xcb_double_click_time;
}
/* local function prototypes */
-static int
-_ecore_xcb_shutdown(Eina_Bool close_display)
+static int
+_ecore_xcb_shutdown(Eina_Bool close_display)
{
- if (--_ecore_xcb_init_count != 0)
+ if (--_ecore_xcb_init_count != 0)
return _ecore_xcb_init_count;
- if (!_ecore_xcb_conn)
+ if (!_ecore_xcb_conn)
return _ecore_xcb_init_count;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -1344,9 +1386,9 @@ _ecore_xcb_shutdown(Eina_Bool close_display)
ecore_main_fd_handler_del(_ecore_xcb_fd_handler);
/* disconnect from display server */
- if (close_display)
+ if (close_display)
xcb_disconnect(_ecore_xcb_conn);
- else
+ else
{
close(xcb_get_file_descriptor(_ecore_xcb_conn));
_ecore_xcb_conn = NULL;
@@ -1386,8 +1428,9 @@ _ecore_xcb_shutdown(Eina_Bool close_display)
return _ecore_xcb_init_count;
}
-static Eina_Bool
-_ecore_xcb_fd_handle(void *data, Ecore_Fd_Handler *hdlr __UNUSED__)
+static Eina_Bool
+_ecore_xcb_fd_handle(void *data,
+ Ecore_Fd_Handler *hdlr __UNUSED__)
{
xcb_connection_t *conn;
xcb_generic_event_t *ev = NULL;
@@ -1395,7 +1438,7 @@ _ecore_xcb_fd_handle(void *data, Ecore_Fd_Handler *hdlr __UNUSED__)
conn = (xcb_connection_t *)data;
- if (_ecore_xcb_event_buffered)
+ if (_ecore_xcb_event_buffered)
{
_ecore_xcb_events_handle(_ecore_xcb_event_buffered);
free(_ecore_xcb_event_buffered);
@@ -1404,39 +1447,39 @@ _ecore_xcb_fd_handle(void *data, Ecore_Fd_Handler *hdlr __UNUSED__)
// xcb_flush(conn);
- while ((ev = xcb_poll_for_event(conn)))
+ while ((ev = xcb_poll_for_event(conn)))
{
- /* NB: Ecore Xlib uses filterevent for xim, but xcb does not support
+ /* NB: Ecore Xlib uses filterevent for xim, but xcb does not support
* xim, so no need for it here */
- /* check for errors first */
- if (xcb_connection_has_error(conn))
- {
- xcb_generic_error_t *err;
-
- err = (xcb_generic_error_t *)ev;
- _ecore_xcb_io_error_handle(err);
- }
- else
- {
- /* trap mouse motion events and filter out all but the last one.
- * we do this because handling every one is fairly cpu intensive
- * (especially on under-powered devices).
- *
- * NB: I've tested this extensively and have found no ill effects,
- * but if someone notices something, please report it */
- /* if ((ev->response_type & ~0x80) == XCB_MOTION_NOTIFY) */
- /* { */
- /* if (ev_mouse) free(ev_mouse); */
- /* ev_mouse = ev; */
- /* } */
- /* else */
- /* { */
- /* FIXME: Filter event for XIM */
- _ecore_xcb_events_handle(ev);
- free(ev);
- /* } */
- }
+ /* check for errors first */
+ if (xcb_connection_has_error(conn))
+ {
+ xcb_generic_error_t *err;
+
+ err = (xcb_generic_error_t *)ev;
+ _ecore_xcb_io_error_handle(err);
+ }
+ else
+ {
+ /* trap mouse motion events and filter out all but the last one.
+ * we do this because handling every one is fairly cpu intensive
+ * (especially on under-powered devices).
+ *
+ * NB: I've tested this extensively and have found no ill effects,
+ * but if someone notices something, please report it */
+ /* if ((ev->response_type & ~0x80) == XCB_MOTION_NOTIFY) */
+ /* { */
+ /* if (ev_mouse) free(ev_mouse); */
+ /* ev_mouse = ev; */
+ /* } */
+ /* else */
+ /* { */
+ /* FIXME: Filter event for XIM */
+ _ecore_xcb_events_handle(ev);
+ free(ev);
+ /* } */
+ }
}
/* if (ev_mouse) */
@@ -1448,47 +1491,48 @@ _ecore_xcb_fd_handle(void *data, Ecore_Fd_Handler *hdlr __UNUSED__)
return ECORE_CALLBACK_RENEW;
}
-static Eina_Bool
-_ecore_xcb_fd_handle_buff(void *data, Ecore_Fd_Handler *hdlr __UNUSED__)
+static Eina_Bool
+_ecore_xcb_fd_handle_buff(void *data,
+ Ecore_Fd_Handler *hdlr __UNUSED__)
{
xcb_connection_t *conn;
xcb_generic_event_t *ev = NULL;
conn = (xcb_connection_t *)data;
ev = xcb_poll_for_event(conn);
- if (ev)
+ if (ev)
{
/* check for errors first */
- if (xcb_connection_has_error(conn))
- {
- xcb_generic_error_t *err;
-
- err = (xcb_generic_error_t *)ev;
- _ecore_xcb_io_error_handle(err);
- return ECORE_CALLBACK_CANCEL;
- }
- /* trap mouse motion events and filter out all but the last one.
- * we do this because handling every one is fairly cpu intensive
- * (especially on under-powered devices).
- *
- * NB: I've tested this extensively and have found no ill effects,
- * but if someone notices something, please report it */
- /* else if ((ev->response_type & ~0x80) == XCB_MOTION_NOTIFY) */
- /* { */
- /* free(ev); */
- /* return ECORE_CALLBACK_CANCEL; */
- /* } */
- /* else */
- {
- _ecore_xcb_event_buffered = ev;
- return ECORE_CALLBACK_RENEW;
- }
+ if (xcb_connection_has_error(conn))
+ {
+ xcb_generic_error_t *err;
+
+ err = (xcb_generic_error_t *)ev;
+ _ecore_xcb_io_error_handle(err);
+ return ECORE_CALLBACK_CANCEL;
+ }
+ /* trap mouse motion events and filter out all but the last one.
+ * we do this because handling every one is fairly cpu intensive
+ * (especially on under-powered devices).
+ *
+ * NB: I've tested this extensively and have found no ill effects,
+ * but if someone notices something, please report it */
+ /* else if ((ev->response_type & ~0x80) == XCB_MOTION_NOTIFY) */
+ /* { */
+ /* free(ev); */
+ /* return ECORE_CALLBACK_CANCEL; */
+ /* } */
+ /* else */
+ {
+ _ecore_xcb_event_buffered = ev;
+ return ECORE_CALLBACK_RENEW;
+ }
}
return ECORE_CALLBACK_CANCEL;
}
-static Eina_Bool
-_ecore_xcb_idle_enter(void *data __UNUSED__)
+static Eina_Bool
+_ecore_xcb_idle_enter(void *data __UNUSED__)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -1496,3 +1540,4 @@ _ecore_xcb_idle_enter(void *data __UNUSED__)
xcb_flush(_ecore_xcb_conn);
return ECORE_CALLBACK_RENEW;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_atoms.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_atoms.c
index 59d1c3acc6..769ffacdd1 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_atoms.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_atoms.c
@@ -5,9 +5,9 @@
#define ECORE_X_ATOMS_COUNT 199
typedef struct _Xcb_Atom Xcb_Atom;
-struct _Xcb_Atom
+struct _Xcb_Atom
{
- const char *name;
+ const char *name;
Ecore_X_Atom *atom;
};
@@ -15,7 +15,7 @@ struct _Xcb_Atom
/* local variables */
static xcb_intern_atom_cookie_t cookies[ECORE_X_ATOMS_COUNT];
-static Xcb_Atom atoms[] =
+static Xcb_Atom atoms[] =
{
{ "ATOM", &ECORE_X_ATOM_ATOM },
{ "CARDINAL", &ECORE_X_ATOM_CARDINAL },
@@ -124,12 +124,12 @@ static Xcb_Atom atoms[] =
{ "_NET_WM_WINDOW_TYPE_DIALOG", &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DIALOG },
{ "_NET_WM_WINDOW_TYPE_NORMAL", &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NORMAL },
{ "_NET_WM_WINDOW_TYPE_DROPDOWN_MENU",
- &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DROPDOWN_MENU },
+ &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DROPDOWN_MENU },
{ "_NET_WM_WINDOW_TYPE_POPUP_MENU",
- &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_POPUP_MENU },
+ &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_POPUP_MENU },
{ "_NET_WM_WINDOW_TYPE_TOOLTIP", &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_TOOLTIP },
{ "_NET_WM_WINDOW_TYPE_NOTIFICATION",
- &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NOTIFICATION },
+ &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NOTIFICATION },
{ "_NET_WM_WINDOW_TYPE_COMBO", &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_COMBO },
{ "_NET_WM_WINDOW_TYPE_DND", &ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DND },
@@ -137,9 +137,9 @@ static Xcb_Atom atoms[] =
{ "_NET_WM_STATE_MODAL", &ECORE_X_ATOM_NET_WM_STATE_MODAL },
{ "_NET_WM_STATE_STICKY", &ECORE_X_ATOM_NET_WM_STATE_STICKY },
{ "_NET_WM_STATE_MAXIMIZED_VERT",
- &ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_VERT },
+ &ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_VERT },
{ "_NET_WM_STATE_MAXIMIZED_HORZ",
- &ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_HORZ },
+ &ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_HORZ },
{ "_NET_WM_STATE_SHADED", &ECORE_X_ATOM_NET_WM_STATE_SHADED },
{ "_NET_WM_STATE_SKIP_TASKBAR", &ECORE_X_ATOM_NET_WM_STATE_SKIP_TASKBAR },
{ "_NET_WM_STATE_SKIP_PAGER", &ECORE_X_ATOM_NET_WM_STATE_SKIP_PAGER },
@@ -148,7 +148,7 @@ static Xcb_Atom atoms[] =
{ "_NET_WM_STATE_ABOVE", &ECORE_X_ATOM_NET_WM_STATE_ABOVE },
{ "_NET_WM_STATE_BELOW", &ECORE_X_ATOM_NET_WM_STATE_BELOW },
{ "_NET_WM_STATE_DEMANDS_ATTENTION",
- &ECORE_X_ATOM_NET_WM_STATE_DEMANDS_ATTENTION },
+ &ECORE_X_ATOM_NET_WM_STATE_DEMANDS_ATTENTION },
{ "_NET_WM_ALLOWED_ACTIONS", &ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS },
{ "_NET_WM_ACTION_MOVE", &ECORE_X_ATOM_NET_WM_ACTION_MOVE },
@@ -157,12 +157,12 @@ static Xcb_Atom atoms[] =
{ "_NET_WM_ACTION_SHADE", &ECORE_X_ATOM_NET_WM_ACTION_SHADE },
{ "_NET_WM_ACTION_STICK", &ECORE_X_ATOM_NET_WM_ACTION_STICK },
{ "_NET_WM_ACTION_MAXIMIZE_HORZ",
- &ECORE_X_ATOM_NET_WM_ACTION_MAXIMIZE_HORZ },
+ &ECORE_X_ATOM_NET_WM_ACTION_MAXIMIZE_HORZ },
{ "_NET_WM_ACTION_MAXIMIZE_VERT",
- &ECORE_X_ATOM_NET_WM_ACTION_MAXIMIZE_VERT },
+ &ECORE_X_ATOM_NET_WM_ACTION_MAXIMIZE_VERT },
{ "_NET_WM_ACTION_FULLSCREEN", &ECORE_X_ATOM_NET_WM_ACTION_FULLSCREEN },
{ "_NET_WM_ACTION_CHANGE_DESKTOP",
- &ECORE_X_ATOM_NET_WM_ACTION_CHANGE_DESKTOP },
+ &ECORE_X_ATOM_NET_WM_ACTION_CHANGE_DESKTOP },
{ "_NET_WM_ACTION_CLOSE", &ECORE_X_ATOM_NET_WM_ACTION_CLOSE },
{ "_NET_WM_ACTION_ABOVE", &ECORE_X_ATOM_NET_WM_ACTION_ABOVE },
{ "_NET_WM_ACTION_BELOW", &ECORE_X_ATOM_NET_WM_ACTION_BELOW },
@@ -180,7 +180,7 @@ static Xcb_Atom atoms[] =
{ "_NET_WM_PING", &ECORE_X_ATOM_NET_WM_PING },
{ "_NET_WM_SYNC_REQUEST", &ECORE_X_ATOM_NET_WM_SYNC_REQUEST },
{ "_NET_WM_SYNC_REQUEST_COUNTER",
- &ECORE_X_ATOM_NET_WM_SYNC_REQUEST_COUNTER },
+ &ECORE_X_ATOM_NET_WM_SYNC_REQUEST_COUNTER },
{ "_NET_WM_WINDOW_OPACITY", &ECORE_X_ATOM_NET_WM_WINDOW_OPACITY },
{ "_NET_WM_WINDOW_SHADOW", &ECORE_X_ATOM_NET_WM_WINDOW_SHADOW },
@@ -202,12 +202,12 @@ static Xcb_Atom atoms[] =
{ "_E_VIRTUAL_KEYBOARD_NUMERIC", &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_NUMERIC },
{ "_E_VIRTUAL_KEYBOARD_PIN", &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_PIN },
{ "_E_VIRTUAL_KEYBOARD_PHONE_NUMBER",
- &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_PHONE_NUMBER },
+ &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_PHONE_NUMBER },
{ "_E_VIRTUAL_KEYBOARD_HEX", &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_HEX },
{ "_E_VIRTUAL_KEYBOARD_TERMINAL",
- &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_TERMINAL },
- { "_E_VIRTUAL_KEYBOARD_PASSWORD",
- &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_PASSWORD },
+ &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_TERMINAL },
+ { "_E_VIRTUAL_KEYBOARD_PASSWORD",
+ &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_PASSWORD },
{ "_E_VIRTUAL_KEYBOARD_IP", &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_IP },
{ "_E_VIRTUAL_KEYBOARD_HOST", &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_HOST },
{ "_E_VIRTUAL_KEYBOARD_FILE", &ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_FILE },
@@ -233,22 +233,22 @@ static Xcb_Atom atoms[] =
{ "_E_ILLUME_DRAG_START", &ECORE_X_ATOM_E_ILLUME_DRAG_START },
{ "_E_ILLUME_DRAG_END", &ECORE_X_ATOM_E_ILLUME_DRAG_END },
{ "_E_ILLUME_INDICATOR_GEOMETRY",
- &ECORE_X_ATOM_E_ILLUME_INDICATOR_GEOMETRY },
+ &ECORE_X_ATOM_E_ILLUME_INDICATOR_GEOMETRY },
{ "_E_ILLUME_SOFTKEY_GEOMETRY", &ECORE_X_ATOM_E_ILLUME_SOFTKEY_GEOMETRY },
{ "_E_ILLUME_KEYBOARD_GEOMETRY", &ECORE_X_ATOM_E_ILLUME_KEYBOARD_GEOMETRY },
{ "_E_ILLUME_QUICKPANEL", &ECORE_X_ATOM_E_ILLUME_QUICKPANEL },
{ "_E_ILLUME_QUICKPANEL_STATE", &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE },
{ "_E_ILLUME_QUICKPANEL_STATE_TOGGLE",
- &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE_TOGGLE },
+ &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE_TOGGLE },
{ "_E_ILLUME_QUICKPANEL_ON", &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_ON },
{ "_E_ILLUME_QUICKPANEL_OFF", &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_OFF },
{ "_E_ILLUME_QUICKPANEL_PRIORITY_MAJOR",
- &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MAJOR },
+ &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MAJOR },
{ "_E_ILLUME_QUICKPANEL_PRIORITY_MINOR",
- &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MINOR },
+ &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MINOR },
{ "_E_ILLUME_QUICKPANEL_ZONE", &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_ZONE },
{ "_E_ILLUME_QUICKPANEL_POSITION_UPDATE",
- &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_POSITION_UPDATE },
+ &ECORE_X_ATOM_E_ILLUME_QUICKPANEL_POSITION_UPDATE },
{ "_E_COMP_SYNC_COUNTER", &ECORE_X_ATOM_E_COMP_SYNC_COUNTER },
{ "_E_COMP_SYNC_DRAW_DONE", &ECORE_X_ATOM_E_COMP_SYNC_DRAW_DONE },
@@ -264,8 +264,8 @@ static Xcb_Atom atoms[] =
{ "_E_VIDEO_POSITION", &ECORE_X_ATOM_E_VIDEO_POSITION }
};
-void
-_ecore_xcb_atoms_init(void)
+void
+_ecore_xcb_atoms_init(void)
{
int i = 0, num = 0;
@@ -273,16 +273,16 @@ _ecore_xcb_atoms_init(void)
CHECK_XCB_CONN;
num = (sizeof(atoms) / sizeof(Xcb_Atom));
- for (i = 0; i < num; i++)
+ for (i = 0; i < num; i++)
{
- cookies[i] =
- xcb_intern_atom_unchecked(_ecore_xcb_conn, 0,
+ cookies[i] =
+ xcb_intern_atom_unchecked(_ecore_xcb_conn, 0,
strlen(atoms[i].name), atoms[i].name);
}
}
-void
-_ecore_xcb_atoms_finalize(void)
+void
+_ecore_xcb_atoms_finalize(void)
{
int i = 0, num = 0;
@@ -290,7 +290,7 @@ _ecore_xcb_atoms_finalize(void)
CHECK_XCB_CONN;
num = (sizeof(atoms) / sizeof(Xcb_Atom));
- for (i = 0; i < num; i++)
+ for (i = 0; i < num; i++)
{
xcb_intern_atom_reply_t *reply = NULL;
@@ -303,13 +303,13 @@ _ecore_xcb_atoms_finalize(void)
/**
* @defgroup Ecore_X_Atom_Group XCB Atom Functions
- *
+ *
* Functions that operate on atoms
*/
/**
* Retrieves the atom value associated to a name.
- *
+ *
* @param name Unused.
* @return Associated atom value.
*
@@ -321,11 +321,11 @@ _ecore_xcb_atoms_finalize(void)
* To use this function, you must call before, and in order,
* ecore_x_atom_get_prefetch(), which sends the InternAtom request,
* then ecore_x_atom_get_fetch(), which gets the reply.
- *
+ *
* @ingroup Ecore_X_Atom_Group
*/
-EAPI Ecore_X_Atom
-ecore_x_atom_get(const char *name)
+EAPI Ecore_X_Atom
+ecore_x_atom_get(const char *name)
{
xcb_intern_atom_cookie_t cookie;
xcb_intern_atom_reply_t *reply;
@@ -344,14 +344,14 @@ ecore_x_atom_get(const char *name)
/**
* Retrieves the name of the given atom.
- *
- * @param atom
+ *
+ * @param atom
* @return The name of the atom.
*
* @ingroup Ecore_X_Atom_Group
*/
EAPI char *
-ecore_x_atom_name_get(Ecore_X_Atom atom)
+ecore_x_atom_name_get(Ecore_X_Atom atom)
{
xcb_get_atom_name_cookie_t cookie;
xcb_get_atom_name_reply_t *reply;
@@ -366,7 +366,7 @@ ecore_x_atom_name_get(Ecore_X_Atom atom)
if (!reply) return NULL;
len = xcb_get_atom_name_name_length(reply);
name = (char *)malloc(sizeof(char) * (len + 1));
- if (!name)
+ if (!name)
{
free(reply);
return NULL;
@@ -378,8 +378,10 @@ ecore_x_atom_name_get(Ecore_X_Atom atom)
return name;
}
-EAPI void
-ecore_x_atoms_get(const char **names, int num, Ecore_X_Atom *atoms)
+EAPI void
+ecore_x_atoms_get(const char **names,
+ int num,
+ Ecore_X_Atom *atoms)
{
xcb_intern_atom_cookie_t cookies[num];
int i = 0;
@@ -387,13 +389,13 @@ ecore_x_atoms_get(const char **names, int num, Ecore_X_Atom *atoms)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- for (i = 0; i < num; i++)
+ for (i = 0; i < num; i++)
{
- cookies[i] =
- xcb_intern_atom_unchecked(_ecore_xcb_conn, 0,
+ cookies[i] =
+ xcb_intern_atom_unchecked(_ecore_xcb_conn, 0,
strlen(names[i]), names[i]);
}
- for (i = 0; i < num; i++)
+ for (i = 0; i < num; i++)
{
xcb_intern_atom_reply_t *reply = NULL;
@@ -403,3 +405,4 @@ ecore_x_atoms_get(const char **names, int num, Ecore_X_Atom *atoms)
free(reply);
}
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_composite.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_composite.c
index 0f66b24483..f247b34777 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_composite.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_composite.c
@@ -6,8 +6,8 @@
/* local variables */
static Eina_Bool _composite_avail = EINA_FALSE;
-void
-_ecore_xcb_composite_init(void)
+void
+_ecore_xcb_composite_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -16,8 +16,8 @@ _ecore_xcb_composite_init(void)
#endif
}
-void
-_ecore_xcb_composite_finalize(void)
+void
+_ecore_xcb_composite_finalize(void)
{
#ifdef ECORE_XCB_COMPOSITE
const xcb_query_extension_reply_t *ext_reply;
@@ -27,34 +27,34 @@ _ecore_xcb_composite_finalize(void)
#ifdef ECORE_XCB_COMPOSITE
ext_reply = xcb_get_extension_data(_ecore_xcb_conn, &xcb_composite_id);
- if ((ext_reply) && (ext_reply->present))
+ if ((ext_reply) && (ext_reply->present))
{
xcb_composite_query_version_cookie_t cookie;
xcb_composite_query_version_reply_t *reply;
- cookie =
- xcb_composite_query_version_unchecked(_ecore_xcb_conn,
- XCB_COMPOSITE_MAJOR_VERSION,
+ cookie =
+ xcb_composite_query_version_unchecked(_ecore_xcb_conn,
+ XCB_COMPOSITE_MAJOR_VERSION,
XCB_COMPOSITE_MINOR_VERSION);
- reply =
+ reply =
xcb_composite_query_version_reply(_ecore_xcb_conn, cookie, NULL);
- if (reply)
+ if (reply)
{
-// if ((reply->major_version >= XCB_COMPOSITE_MAJOR_VERSION) &&
- if (reply->minor_version >= XCB_COMPOSITE_MINOR_VERSION)
- {
+// if ((reply->major_version >= XCB_COMPOSITE_MAJOR_VERSION) &&
+ if (reply->minor_version >= XCB_COMPOSITE_MINOR_VERSION)
+ {
# ifdef ECORE_XCB_RENDER
- if (_ecore_xcb_render_avail_get())
- {
+ if (_ecore_xcb_render_avail_get())
+ {
# ifdef ECORE_XCB_XFIXES
- if (_ecore_xcb_xfixes_avail_get())
- _composite_avail = EINA_TRUE;
+ if (_ecore_xcb_xfixes_avail_get())
+ _composite_avail = EINA_TRUE;
# endif
- }
+ }
# endif
- }
+ }
- free(reply);
+ free(reply);
}
}
#endif
@@ -62,26 +62,27 @@ _ecore_xcb_composite_finalize(void)
/**
* @defgroup Ecore_X_Composite_Group X Composite Extension Functions
- *
+ *
* Functions related to the X Composite Extension
*/
/**
* Return whether the Composite Extension is available
- *
+ *
* @return EINA_TRUE is the Composite Extension is available, EINA_FALSE if not
- *
+ *
* @ingroup Ecore_X_Composite_Group
*/
-EAPI Eina_Bool
-ecore_x_composite_query(void)
+EAPI Eina_Bool
+ecore_x_composite_query(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
return _composite_avail;
}
-EAPI void
-ecore_x_composite_redirect_window(Ecore_X_Window win, Ecore_X_Composite_Update_Type type)
+EAPI void
+ecore_x_composite_redirect_window(Ecore_X_Window win,
+ Ecore_X_Composite_Update_Type type)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -91,11 +92,12 @@ ecore_x_composite_redirect_window(Ecore_X_Window win, Ecore_X_Composite_Update_T
#ifdef ECORE_XCB_COMPOSITE
uint8_t update = XCB_COMPOSITE_REDIRECT_AUTOMATIC;
- switch (type)
+ switch (type)
{
case ECORE_X_COMPOSITE_UPDATE_AUTOMATIC:
update = XCB_COMPOSITE_REDIRECT_AUTOMATIC;
break;
+
case ECORE_X_COMPOSITE_UPDATE_MANUAL:
update = XCB_COMPOSITE_REDIRECT_MANUAL;
break;
@@ -105,8 +107,9 @@ ecore_x_composite_redirect_window(Ecore_X_Window win, Ecore_X_Composite_Update_T
#endif
}
-EAPI void
-ecore_x_composite_redirect_subwindows(Ecore_X_Window win, Ecore_X_Composite_Update_Type type)
+EAPI void
+ecore_x_composite_redirect_subwindows(Ecore_X_Window win,
+ Ecore_X_Composite_Update_Type type)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -116,11 +119,12 @@ ecore_x_composite_redirect_subwindows(Ecore_X_Window win, Ecore_X_Composite_Upda
#ifdef ECORE_XCB_COMPOSITE
uint8_t update = XCB_COMPOSITE_REDIRECT_AUTOMATIC;
- switch (type)
+ switch (type)
{
case ECORE_X_COMPOSITE_UPDATE_AUTOMATIC:
update = XCB_COMPOSITE_REDIRECT_AUTOMATIC;
break;
+
case ECORE_X_COMPOSITE_UPDATE_MANUAL:
update = XCB_COMPOSITE_REDIRECT_MANUAL;
break;
@@ -130,8 +134,9 @@ ecore_x_composite_redirect_subwindows(Ecore_X_Window win, Ecore_X_Composite_Upda
#endif
}
-EAPI void
-ecore_x_composite_unredirect_window(Ecore_X_Window win, Ecore_X_Composite_Update_Type type)
+EAPI void
+ecore_x_composite_unredirect_window(Ecore_X_Window win,
+ Ecore_X_Composite_Update_Type type)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -141,11 +146,12 @@ ecore_x_composite_unredirect_window(Ecore_X_Window win, Ecore_X_Composite_Update
#ifdef ECORE_XCB_COMPOSITE
uint8_t update = XCB_COMPOSITE_REDIRECT_AUTOMATIC;
- switch (type)
+ switch (type)
{
case ECORE_X_COMPOSITE_UPDATE_AUTOMATIC:
update = XCB_COMPOSITE_REDIRECT_AUTOMATIC;
break;
+
case ECORE_X_COMPOSITE_UPDATE_MANUAL:
update = XCB_COMPOSITE_REDIRECT_MANUAL;
break;
@@ -155,8 +161,9 @@ ecore_x_composite_unredirect_window(Ecore_X_Window win, Ecore_X_Composite_Update
#endif
}
-EAPI void
-ecore_x_composite_unredirect_subwindows(Ecore_X_Window win, Ecore_X_Composite_Update_Type type)
+EAPI void
+ecore_x_composite_unredirect_subwindows(Ecore_X_Window win,
+ Ecore_X_Composite_Update_Type type)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -166,11 +173,12 @@ ecore_x_composite_unredirect_subwindows(Ecore_X_Window win, Ecore_X_Composite_Up
#ifdef ECORE_XCB_COMPOSITE
uint8_t update = XCB_COMPOSITE_REDIRECT_AUTOMATIC;
- switch (type)
+ switch (type)
{
case ECORE_X_COMPOSITE_UPDATE_AUTOMATIC:
update = XCB_COMPOSITE_REDIRECT_AUTOMATIC;
break;
+
case ECORE_X_COMPOSITE_UPDATE_MANUAL:
update = XCB_COMPOSITE_REDIRECT_MANUAL;
break;
@@ -180,8 +188,8 @@ ecore_x_composite_unredirect_subwindows(Ecore_X_Window win, Ecore_X_Composite_Up
#endif
}
-EAPI Ecore_X_Pixmap
-ecore_x_composite_name_window_pixmap_get(Ecore_X_Window win)
+EAPI Ecore_X_Pixmap
+ecore_x_composite_name_window_pixmap_get(Ecore_X_Window win)
{
#ifdef ECORE_XCB_COMPOSITE
Ecore_X_Pixmap pmap = XCB_NONE;
@@ -201,8 +209,8 @@ ecore_x_composite_name_window_pixmap_get(Ecore_X_Window win)
return pmap;
}
-EAPI void
-ecore_x_composite_window_events_disable(Ecore_X_Window win)
+EAPI void
+ecore_x_composite_window_events_disable(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -218,8 +226,8 @@ ecore_x_composite_window_events_disable(Ecore_X_Window win)
#endif
}
-EAPI void
-ecore_x_composite_window_events_enable(Ecore_X_Window win)
+EAPI void
+ecore_x_composite_window_events_enable(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -235,8 +243,8 @@ ecore_x_composite_window_events_enable(Ecore_X_Window win)
#endif
}
-EAPI Ecore_X_Window
-ecore_x_composite_render_window_enable(Ecore_X_Window root)
+EAPI Ecore_X_Window
+ecore_x_composite_render_window_enable(Ecore_X_Window root)
{
Ecore_X_Window win = 0;
#ifdef ECORE_XCB_COMPOSITE
@@ -251,7 +259,7 @@ ecore_x_composite_render_window_enable(Ecore_X_Window root)
#ifdef ECORE_XCB_COMPOSITE
cookie = xcb_composite_get_overlay_window_unchecked(_ecore_xcb_conn, root);
- reply =
+ reply =
xcb_composite_get_overlay_window_reply(_ecore_xcb_conn, cookie, NULL);
if (!reply) return win;
@@ -265,8 +273,8 @@ ecore_x_composite_render_window_enable(Ecore_X_Window root)
return win;
}
-EAPI void
-ecore_x_composite_render_window_disable(Ecore_X_Window win)
+EAPI void
+ecore_x_composite_render_window_disable(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -278,3 +286,4 @@ ecore_x_composite_render_window_disable(Ecore_X_Window win)
// ecore_x_flush();
#endif
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_cursor.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_cursor.c
index 06654d724c..755df04e4f 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_cursor.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_cursor.c
@@ -8,11 +8,13 @@
#ifdef ECORE_XCB_CURSOR
static xcb_render_pictforminfo_t *_ecore_xcb_cursor_format_get(void);
#endif
-static void _ecore_xcb_cursor_default_size_get(void);
-static void _ecore_xcb_cursor_dpi_size_get(void);
-static void _ecore_xcb_cursor_guess_size(void);
+static void _ecore_xcb_cursor_default_size_get(void);
+static void _ecore_xcb_cursor_dpi_size_get(void);
+static void _ecore_xcb_cursor_guess_size(void);
#ifdef ECORE_XCB_CURSOR
-static Ecore_X_Cursor _ecore_xcb_cursor_image_load_cursor(xcb_image_t *img, int hot_x, int hot_y);
+static Ecore_X_Cursor _ecore_xcb_cursor_image_load_cursor(xcb_image_t *img,
+ int hot_x,
+ int hot_y);
#endif
static void _ecore_xcb_cursor_image_destroy(xcb_image_t *img);
@@ -24,15 +26,15 @@ static uint32_t _ecore_xcb_cursor_format_id = 0;
// static xcb_render_pictforminfo_t *_ecore_xcb_cursor_format = NULL;
#endif
-void
-_ecore_xcb_cursor_init(void)
+void
+_ecore_xcb_cursor_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
/* NB: No-op */
}
-void
-_ecore_xcb_cursor_finalize(void)
+void
+_ecore_xcb_cursor_finalize(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -40,7 +42,7 @@ _ecore_xcb_cursor_finalize(void)
_ecore_xcb_cursor = _ecore_xcb_render_argb_get();
/* find render pict format */
- if (_ecore_xcb_cursor_format_id <= 0)
+ if (_ecore_xcb_cursor_format_id <= 0)
_ecore_xcb_cursor_format_id = _ecore_xcb_cursor_format_get()->id;
#endif
@@ -55,21 +57,26 @@ _ecore_xcb_cursor_finalize(void)
if (_ecore_xcb_cursor_size == 0)
_ecore_xcb_cursor_guess_size();
- /* NB: Would normally add theme stuff here, but E cursor does not support
- * xcursor themes. Delay parsing that stuff out until such time if/when the
+ /* NB: Would normally add theme stuff here, but E cursor does not support
+ * xcursor themes. Delay parsing that stuff out until such time if/when the
* user selects to use X Cursor, rather than E cursor */
}
-EAPI Eina_Bool
-ecore_x_cursor_color_supported_get(void)
+EAPI Eina_Bool
+ecore_x_cursor_color_supported_get(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
return _ecore_xcb_cursor;
}
-EAPI Ecore_X_Cursor
-ecore_x_cursor_new(Ecore_X_Window win, int *pixels, int w, int h, int hot_x, int hot_y)
+EAPI Ecore_X_Cursor
+ecore_x_cursor_new(Ecore_X_Window win,
+ int *pixels,
+ int w,
+ int h,
+ int hot_x,
+ int hot_y)
{
Ecore_X_Cursor cursor = 0;
xcb_image_t *img;
@@ -78,10 +85,10 @@ ecore_x_cursor_new(Ecore_X_Window win, int *pixels, int w, int h, int hot_x, int
CHECK_XCB_CONN;
#ifdef ECORE_XCB_CURSOR
- if (_ecore_xcb_cursor)
+ if (_ecore_xcb_cursor)
{
- img = _ecore_xcb_image_create_native(w, h, XCB_IMAGE_FORMAT_Z_PIXMAP,
- 32, NULL, (w * h * sizeof(int)),
+ img = _ecore_xcb_image_create_native(w, h, XCB_IMAGE_FORMAT_Z_PIXMAP,
+ 32, NULL, (w * h * sizeof(int)),
(uint8_t *)pixels);
cursor = _ecore_xcb_cursor_image_load_cursor(img, hot_x, hot_y);
_ecore_xcb_cursor_image_destroy(img);
@@ -89,152 +96,152 @@ ecore_x_cursor_new(Ecore_X_Window win, int *pixels, int w, int h, int hot_x, int
}
else
#endif
- {
- Ecore_X_GC gc;
- xcb_pixmap_t pmap, mask;
- uint32_t *pix;
- uint8_t fr = 0x00, fg = 0x00, fb = 0x00;
- uint8_t br = 0xff, bg = 0xff, bb = 0xff;
- uint32_t brightest = 0, darkest = 255 * 3;
- uint16_t x, y;
- const uint32_t dither[2][2] =
- {
- {0, 2},
- {3, 1}
- };
-
- img = _ecore_xcb_image_create_native(w, h, XCB_IMAGE_FORMAT_Z_PIXMAP,
- 1, NULL, ~0, NULL);
- if (img->data) free(img->data);
- img->data = malloc(img->size);
-
- pmap = xcb_generate_id(_ecore_xcb_conn);
- xcb_create_pixmap(_ecore_xcb_conn, 1, pmap, win, w, h);
- mask = xcb_generate_id(_ecore_xcb_conn);
- xcb_create_pixmap(_ecore_xcb_conn, 1, mask, win, w, h);
-
- pix = (uint32_t *)pixels;
- for (y = 0; y < h; y++)
- {
- for (x = 0; x < w; x++)
- {
- uint8_t r, g, b, a;
-
- a = (pix[0] >> 24) & 0xff;
- r = (pix[0] >> 16) & 0xff;
- g = (pix[0] >> 8) & 0xff;
- b = (pix[0]) & 0xff;
- if (a > 0)
- {
- if ((uint32_t)(r + g + b) > brightest)
- {
- brightest = r + g + b;
- br = r;
- bg = g;
- bb = b;
- }
-
- if ((uint32_t)(r + g + b) < darkest)
- {
- darkest = r + g + b;
- fr = r;
- fg = g;
- fb = b;
- }
- }
- pix++;
- }
- }
-
- pix = (uint32_t *)pixels;
- for (y = 0; y < h; y++)
- {
- for (x = 0; x < w; x++)
- {
- uint32_t v;
- uint8_t r, g, b;
- int32_t d1, d2;
-
- r = (pix[0] >> 16) & 0xff;
- g = (pix[0] >> 8) & 0xff;
- b = (pix[0]) & 0xff;
- d1 =
- ((r - fr) * (r - fr)) +
- ((g - fg) * (g - fg)) +
- ((b - fb) * (b - fb));
- d2 =
- ((r - br) * (r - br)) +
- ((g - bg) * (g - bg)) +
- ((b - bb) * (b - bb));
- if (d1 + d2)
- {
- v = (((d2 * 255) / (d1 + d2)) * 5) / 256;
- if (v > dither[x & 0x1][y & 0x1])
- v = 1;
- else
- v = 0;
- }
- else
- v = 0;
-
- xcb_image_put_pixel(img, x, y, v);
- pix++;
- }
- }
-
- gc = ecore_x_gc_new(pmap, 0, NULL);
- xcb_put_image(_ecore_xcb_conn, img->format, pmap, gc, w, h,
- 0, 0, 0, img->depth, img->size, img->data);
- ecore_x_gc_free(gc);
-
- pix = (uint32_t *)pixels;
- for (y = 0; y < h; y++)
- {
- for (x = 0; x < w; x++)
- {
- uint32_t v;
-
- v = (((pix[0] >> 24) & 0xff) * 5) / 256;
- if (v > dither[x & 0x1][y & 0x1])
- v = 1;
- else
- v = 0;
-
- xcb_image_put_pixel(img, x, y, v);
- pix++;
- }
- }
-
- gc = ecore_x_gc_new(mask, 0, NULL);
- xcb_put_image(_ecore_xcb_conn, img->format, mask, gc, w, h,
- 0, 0, 0, img->depth, img->size, img->data);
- ecore_x_gc_free(gc);
-
- if (img->data) free(img->data);
- _ecore_xcb_cursor_image_destroy(img);
-
- cursor = xcb_generate_id(_ecore_xcb_conn);
- xcb_create_cursor(_ecore_xcb_conn, cursor, pmap, mask,
- fr << 8 | fr, fg << 8 | fg, fb << 8 | fb,
- br << 8 | br, bg << 8 | bg, bb << 8 | bb,
- hot_x, hot_y);
-
- xcb_free_pixmap(_ecore_xcb_conn, pmap);
- xcb_free_pixmap(_ecore_xcb_conn, mask);
-
- return cursor;
- }
+ {
+ Ecore_X_GC gc;
+ xcb_pixmap_t pmap, mask;
+ uint32_t *pix;
+ uint8_t fr = 0x00, fg = 0x00, fb = 0x00;
+ uint8_t br = 0xff, bg = 0xff, bb = 0xff;
+ uint32_t brightest = 0, darkest = 255 * 3;
+ uint16_t x, y;
+ const uint32_t dither[2][2] =
+ {
+ {0, 2},
+ {3, 1}
+ };
+
+ img = _ecore_xcb_image_create_native(w, h, XCB_IMAGE_FORMAT_Z_PIXMAP,
+ 1, NULL, ~0, NULL);
+ if (img->data) free(img->data);
+ img->data = malloc(img->size);
+
+ pmap = xcb_generate_id(_ecore_xcb_conn);
+ xcb_create_pixmap(_ecore_xcb_conn, 1, pmap, win, w, h);
+ mask = xcb_generate_id(_ecore_xcb_conn);
+ xcb_create_pixmap(_ecore_xcb_conn, 1, mask, win, w, h);
+
+ pix = (uint32_t *)pixels;
+ for (y = 0; y < h; y++)
+ {
+ for (x = 0; x < w; x++)
+ {
+ uint8_t r, g, b, a;
+
+ a = (pix[0] >> 24) & 0xff;
+ r = (pix[0] >> 16) & 0xff;
+ g = (pix[0] >> 8) & 0xff;
+ b = (pix[0]) & 0xff;
+ if (a > 0)
+ {
+ if ((uint32_t)(r + g + b) > brightest)
+ {
+ brightest = r + g + b;
+ br = r;
+ bg = g;
+ bb = b;
+ }
+
+ if ((uint32_t)(r + g + b) < darkest)
+ {
+ darkest = r + g + b;
+ fr = r;
+ fg = g;
+ fb = b;
+ }
+ }
+ pix++;
+ }
+ }
+
+ pix = (uint32_t *)pixels;
+ for (y = 0; y < h; y++)
+ {
+ for (x = 0; x < w; x++)
+ {
+ uint32_t v;
+ uint8_t r, g, b;
+ int32_t d1, d2;
+
+ r = (pix[0] >> 16) & 0xff;
+ g = (pix[0] >> 8) & 0xff;
+ b = (pix[0]) & 0xff;
+ d1 =
+ ((r - fr) * (r - fr)) +
+ ((g - fg) * (g - fg)) +
+ ((b - fb) * (b - fb));
+ d2 =
+ ((r - br) * (r - br)) +
+ ((g - bg) * (g - bg)) +
+ ((b - bb) * (b - bb));
+ if (d1 + d2)
+ {
+ v = (((d2 * 255) / (d1 + d2)) * 5) / 256;
+ if (v > dither[x & 0x1][y & 0x1])
+ v = 1;
+ else
+ v = 0;
+ }
+ else
+ v = 0;
+
+ xcb_image_put_pixel(img, x, y, v);
+ pix++;
+ }
+ }
+
+ gc = ecore_x_gc_new(pmap, 0, NULL);
+ xcb_put_image(_ecore_xcb_conn, img->format, pmap, gc, w, h,
+ 0, 0, 0, img->depth, img->size, img->data);
+ ecore_x_gc_free(gc);
+
+ pix = (uint32_t *)pixels;
+ for (y = 0; y < h; y++)
+ {
+ for (x = 0; x < w; x++)
+ {
+ uint32_t v;
+
+ v = (((pix[0] >> 24) & 0xff) * 5) / 256;
+ if (v > dither[x & 0x1][y & 0x1])
+ v = 1;
+ else
+ v = 0;
+
+ xcb_image_put_pixel(img, x, y, v);
+ pix++;
+ }
+ }
+
+ gc = ecore_x_gc_new(mask, 0, NULL);
+ xcb_put_image(_ecore_xcb_conn, img->format, mask, gc, w, h,
+ 0, 0, 0, img->depth, img->size, img->data);
+ ecore_x_gc_free(gc);
+
+ if (img->data) free(img->data);
+ _ecore_xcb_cursor_image_destroy(img);
+
+ cursor = xcb_generate_id(_ecore_xcb_conn);
+ xcb_create_cursor(_ecore_xcb_conn, cursor, pmap, mask,
+ fr << 8 | fr, fg << 8 | fg, fb << 8 | fb,
+ br << 8 | br, bg << 8 | bg, bb << 8 | bb,
+ hot_x, hot_y);
+
+ xcb_free_pixmap(_ecore_xcb_conn, pmap);
+ xcb_free_pixmap(_ecore_xcb_conn, mask);
+
+ return cursor;
+ }
return 0;
}
-EAPI void
-ecore_x_cursor_free(Ecore_X_Cursor c)
+EAPI void
+ecore_x_cursor_free(Ecore_X_Cursor c)
{
// LOGFN(__FILE__, __LINE__, __FUNCTION__);
- CHECK_XCB_CONN;
+ CHECK_XCB_CONN;
- xcb_free_cursor(_ecore_xcb_conn, c);
+ xcb_free_cursor(_ecore_xcb_conn, c);
}
/*
@@ -242,8 +249,8 @@ ecore_x_cursor_free(Ecore_X_Cursor c)
* Note that the return value must not be freed with
* ecore_x_cursor_free()!
*/
-EAPI Ecore_X_Cursor
-ecore_x_cursor_shape_get(int shape)
+EAPI Ecore_X_Cursor
+ecore_x_cursor_shape_get(int shape)
{
Ecore_X_Cursor cursor = 0;
xcb_font_t font;
@@ -256,15 +263,15 @@ ecore_x_cursor_shape_get(int shape)
cursor = xcb_generate_id(_ecore_xcb_conn);
/* FIXME: Add request check ?? */
- xcb_create_glyph_cursor(_ecore_xcb_conn, cursor, font, font,
+ xcb_create_glyph_cursor(_ecore_xcb_conn, cursor, font, font,
shape, shape + 1, 0, 0, 0, 65535, 65535, 65535);
xcb_close_font(_ecore_xcb_conn, font);
return cursor;
}
-EAPI void
-ecore_x_cursor_size_set(int size)
+EAPI void
+ecore_x_cursor_size_set(int size)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -272,8 +279,8 @@ ecore_x_cursor_size_set(int size)
/* NB: May need to adjust size of current cursors here */
}
-EAPI int
-ecore_x_cursor_size_get(void)
+EAPI int
+ecore_x_cursor_size_get(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -283,7 +290,7 @@ ecore_x_cursor_size_get(void)
/* local functions */
#ifdef ECORE_XCB_CURSOR
static xcb_render_pictforminfo_t *
-_ecore_xcb_cursor_format_get(void)
+_ecore_xcb_cursor_format_get(void)
{
const xcb_render_query_pict_formats_reply_t *reply;
xcb_render_pictforminfo_t *ret = NULL;
@@ -291,16 +298,17 @@ _ecore_xcb_cursor_format_get(void)
CHECK_XCB_CONN;
reply = xcb_render_util_query_formats(_ecore_xcb_conn);
- if (reply)
- ret = xcb_render_util_find_standard_format(reply,
+ if (reply)
+ ret = xcb_render_util_find_standard_format(reply,
XCB_PICT_STANDARD_ARGB_32);
return ret;
}
+
#endif
-static void
-_ecore_xcb_cursor_default_size_get(void)
+static void
+_ecore_xcb_cursor_default_size_get(void)
{
char *s = NULL;
int v = 0;
@@ -308,7 +316,7 @@ _ecore_xcb_cursor_default_size_get(void)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
s = getenv("XCURSOR_SIZE");
- if (!s)
+ if (!s)
{
_ecore_xcb_xdefaults_init();
v = _ecore_xcb_xdefaults_int_get("Xcursor", "size");
@@ -319,8 +327,8 @@ _ecore_xcb_cursor_default_size_get(void)
if (v) _ecore_xcb_cursor_size = ((v * 16) / 72);
}
-static void
-_ecore_xcb_cursor_dpi_size_get(void)
+static void
+_ecore_xcb_cursor_dpi_size_get(void)
{
int v = 0;
@@ -332,8 +340,8 @@ _ecore_xcb_cursor_dpi_size_get(void)
_ecore_xcb_xdefaults_shutdown();
}
-static void
-_ecore_xcb_cursor_guess_size(void)
+static void
+_ecore_xcb_cursor_guess_size(void)
{
int w = 0, h = 0, s = 0;
@@ -346,8 +354,10 @@ _ecore_xcb_cursor_guess_size(void)
}
#ifdef ECORE_XCB_CURSOR
-static Ecore_X_Cursor
-_ecore_xcb_cursor_image_load_cursor(xcb_image_t *img, int hot_x, int hot_y)
+static Ecore_X_Cursor
+_ecore_xcb_cursor_image_load_cursor(xcb_image_t *img,
+ int hot_x,
+ int hot_y)
{
Ecore_X_Cursor cursor = 0;
Ecore_X_GC gc;
@@ -357,18 +367,18 @@ _ecore_xcb_cursor_image_load_cursor(xcb_image_t *img, int hot_x, int hot_y)
CHECK_XCB_CONN;
pmap = xcb_generate_id(_ecore_xcb_conn);
- xcb_create_pixmap(_ecore_xcb_conn, img->depth, pmap,
- ((xcb_screen_t *)_ecore_xcb_screen)->root,
+ xcb_create_pixmap(_ecore_xcb_conn, img->depth, pmap,
+ ((xcb_screen_t *)_ecore_xcb_screen)->root,
img->width, img->height);
gc = ecore_x_gc_new(pmap, 0, NULL);
- xcb_put_image(_ecore_xcb_conn, img->format, pmap, gc,
- img->width, img->height, 0, 0, 0, img->depth,
+ xcb_put_image(_ecore_xcb_conn, img->format, pmap, gc,
+ img->width, img->height, 0, 0, 0, img->depth,
img->size, img->data);
ecore_x_gc_free(gc);
pict = xcb_generate_id(_ecore_xcb_conn);
- xcb_render_create_picture(_ecore_xcb_conn, pict, pmap,
+ xcb_render_create_picture(_ecore_xcb_conn, pict, pmap,
_ecore_xcb_cursor_format_id, 0, NULL);
xcb_free_pixmap(_ecore_xcb_conn, pmap);
@@ -378,11 +388,13 @@ _ecore_xcb_cursor_image_load_cursor(xcb_image_t *img, int hot_x, int hot_y)
return cursor;
}
+
#endif
-static void
-_ecore_xcb_cursor_image_destroy(xcb_image_t *img)
+static void
+_ecore_xcb_cursor_image_destroy(xcb_image_t *img)
{
CHECK_XCB_CONN;
if (img) xcb_image_destroy(img);
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_damage.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_damage.c
index 84870a8689..d0ffde12a1 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_damage.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_damage.c
@@ -9,8 +9,8 @@ static Eina_Bool _damage_avail = EINA_FALSE;
/* external variables */
int _ecore_xcb_event_damage = -1;
-void
-_ecore_xcb_damage_init(void)
+void
+_ecore_xcb_damage_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -19,8 +19,8 @@ _ecore_xcb_damage_init(void)
#endif
}
-void
-_ecore_xcb_damage_finalize(void)
+void
+_ecore_xcb_damage_finalize(void)
{
#ifdef ECORE_XCB_DAMAGE
const xcb_query_extension_reply_t *ext_reply;
@@ -30,14 +30,14 @@ _ecore_xcb_damage_finalize(void)
#ifdef ECORE_XCB_DAMAGE
ext_reply = xcb_get_extension_data(_ecore_xcb_conn, &xcb_damage_id);
- if ((ext_reply) && (ext_reply->present))
+ if ((ext_reply) && (ext_reply->present))
{
xcb_damage_query_version_cookie_t cookie;
xcb_damage_query_version_reply_t *reply;
- cookie =
- xcb_damage_query_version_unchecked(_ecore_xcb_conn,
- XCB_DAMAGE_MAJOR_VERSION,
+ cookie =
+ xcb_damage_query_version_unchecked(_ecore_xcb_conn,
+ XCB_DAMAGE_MAJOR_VERSION,
XCB_DAMAGE_MINOR_VERSION);
reply = xcb_damage_query_version_reply(_ecore_xcb_conn, cookie, NULL);
if (reply)
@@ -54,30 +54,31 @@ _ecore_xcb_damage_finalize(void)
/**
* @defgroup Ecore_X_Damage_Group X Damage Extension Functions
- *
+ *
* Functions related to the X Damage Extension.
*/
-EAPI Eina_Bool
-ecore_x_damage_query(void)
+EAPI Eina_Bool
+ecore_x_damage_query(void)
{
return _damage_avail;
}
/**
* Create a damage object
- *
+ *
* @param drawable The drawable to monitor
* @param level The level of the damage report
* @return The damage object
- *
- * Creates a damage object to monitor changes to @p drawable,
+ *
+ * Creates a damage object to monitor changes to @p drawable,
* with the level @p level.
- *
+ *
* @ingroup Ecore_X_Damage_Group
*/
-EAPI Ecore_X_Damage
-ecore_x_damage_new(Ecore_X_Drawable drawable, Ecore_X_Damage_Report_Level level)
+EAPI Ecore_X_Damage
+ecore_x_damage_new(Ecore_X_Drawable drawable,
+ Ecore_X_Damage_Report_Level level)
{
Ecore_X_Damage damage = 0;
@@ -97,15 +98,15 @@ ecore_x_damage_new(Ecore_X_Drawable drawable, Ecore_X_Damage_Report_Level level)
/**
* Destroy a damage object
- *
+ *
* @param The damage object to destroy
- *
+ *
* Destroys the damage object @p damage
- *
+ *
* @ingroup Ecore_X_Damage_Group
*/
-EAPI void
-ecore_x_damage_free(Ecore_X_Damage damage)
+EAPI void
+ecore_x_damage_free(Ecore_X_Damage damage)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -120,7 +121,7 @@ ecore_x_damage_free(Ecore_X_Damage damage)
/**
* Synchronously modifies the region
- *
+ *
* @param damage The damage object to destroy
* @param repair The repair region
* @param parts The parts region
@@ -133,11 +134,13 @@ ecore_x_damage_free(Ecore_X_Damage damage)
* 1) parts = damage INTERSECT repair
* 2) damage = damage - parts
* 3) Generate DamageNotify for remaining damage areas
- *
+ *
* @ingroup Ecore_X_Damage_Group
*/
-EAPI void
-ecore_x_damage_subtract(Ecore_X_Damage damage, Ecore_X_Region repair, Ecore_X_Region parts)
+EAPI void
+ecore_x_damage_subtract(Ecore_X_Damage damage,
+ Ecore_X_Region repair,
+ Ecore_X_Region parts)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -149,3 +152,4 @@ ecore_x_damage_subtract(Ecore_X_Damage damage, Ecore_X_Region repair, Ecore_X_Re
// ecore_x_flush();
#endif
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dnd.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dnd.c
index 7b313b831c..677de38bc7 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dnd.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dnd.c
@@ -5,14 +5,20 @@
#endif
/* local structures */
-typedef struct _Version_Cache_Item
+typedef struct _Version_Cache_Item
{
Ecore_X_Window win;
- int ver;
+ int ver;
} Version_Cache_Item;
/* local function prototypes */
-static Eina_Bool _ecore_xcb_dnd_converter_copy(char *target __UNUSED__, void *data, int size, void **data_ret, int *size_ret, Ecore_X_Atom *tprop __UNUSED__, int *count __UNUSED__);
+static Eina_Bool _ecore_xcb_dnd_converter_copy(char *target __UNUSED__,
+ void *data,
+ int size,
+ void **data_ret,
+ int *size_ret,
+ Ecore_X_Atom *tprop __UNUSED__,
+ int *count __UNUSED__);
/* local variables */
static int _ecore_xcb_dnd_init_count = 0;
@@ -20,7 +26,8 @@ static Ecore_X_DND_Source *_source = NULL;
static Ecore_X_DND_Target *_target = NULL;
static Version_Cache_Item *_version_cache = NULL;
static int _version_cache_num = 0, _version_cache_alloc = 0;
-static void (*_posupdatecb)(void *, Ecore_X_Xdnd_Position *);
+static void (*_posupdatecb)(void *,
+ Ecore_X_Xdnd_Position *);
static void *_posupdatedata;
/* external variables */
@@ -31,12 +38,12 @@ EAPI int ECORE_X_EVENT_XDND_LEAVE = 0;
EAPI int ECORE_X_EVENT_XDND_DROP = 0;
EAPI int ECORE_X_EVENT_XDND_FINISHED = 0;
-void
-_ecore_xcb_dnd_init(void)
+void
+_ecore_xcb_dnd_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!_ecore_xcb_dnd_init_count)
+ if (!_ecore_xcb_dnd_init_count)
{
_source = calloc(1, sizeof(Ecore_X_DND_Source));
if (!_source) return;
@@ -47,7 +54,7 @@ _ecore_xcb_dnd_init(void)
_source->prev.window = 0;
_target = calloc(1, sizeof(Ecore_X_DND_Target));
- if (!_target)
+ if (!_target)
{
free(_source);
_source = NULL;
@@ -67,8 +74,8 @@ _ecore_xcb_dnd_init(void)
_ecore_xcb_dnd_init_count++;
}
-void
-_ecore_xcb_dnd_shutdown(void)
+void
+_ecore_xcb_dnd_shutdown(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -81,8 +88,11 @@ _ecore_xcb_dnd_shutdown(void)
_ecore_xcb_dnd_init_count = 0;
}
-EAPI void
-ecore_x_dnd_send_status(Eina_Bool will_accept, Eina_Bool suppress, Ecore_X_Rectangle rect, Ecore_X_Atom action)
+EAPI void
+ecore_x_dnd_send_status(Eina_Bool will_accept,
+ Eina_Bool suppress,
+ Ecore_X_Rectangle rect,
+ Ecore_X_Atom action)
{
xcb_client_message_event_t ev;
@@ -111,19 +121,19 @@ ecore_x_dnd_send_status(Eina_Bool will_accept, Eina_Bool suppress, Ecore_X_Recta
ev.data.data32[3] <<= 16;
ev.data.data32[3] |= rect.height;
- if (will_accept)
+ if (will_accept)
ev.data.data32[4] = action;
- else
+ else
ev.data.data32[4] = XCB_NONE;
_target->accepted_action = action;
- xcb_send_event(_ecore_xcb_conn, 0, _target->source,
+ xcb_send_event(_ecore_xcb_conn, 0, _target->source,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
}
-EAPI Eina_Bool
-ecore_x_dnd_drop(void)
+EAPI Eina_Bool
+ecore_x_dnd_drop(void)
{
xcb_client_message_event_t ev;
Eina_Bool status = EINA_FALSE;
@@ -133,38 +143,38 @@ ecore_x_dnd_drop(void)
memset(&ev, 0, sizeof(xcb_client_message_event_t));
- if (_source->dest)
+ if (_source->dest)
{
ev.response_type = XCB_CLIENT_MESSAGE;
ev.format = 32;
ev.window = _source->dest;
- if (_source->will_accept)
+ if (_source->will_accept)
{
ev.type = ECORE_X_ATOM_XDND_DROP;
ev.data.data32[0] = _source->win;
ev.data.data32[1] = 0;
ev.data.data32[2] = _source->time;
- xcb_send_event(_ecore_xcb_conn, 0, _source->dest,
+ xcb_send_event(_ecore_xcb_conn, 0, _source->dest,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
_source->state = ECORE_X_DND_SOURCE_DROPPED;
status = EINA_TRUE;
}
- else
+ else
{
ev.type = ECORE_X_ATOM_XDND_LEAVE;
ev.data.data32[0] = _source->win;
ev.data.data32[1] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, _source->dest,
+ xcb_send_event(_ecore_xcb_conn, 0, _source->dest,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
_source->state = ECORE_X_DND_SOURCE_IDLE;
}
}
- else
+ else
{
ecore_x_selection_xdnd_clear();
_source->state = ECORE_X_DND_SOURCE_IDLE;
@@ -176,22 +186,23 @@ ecore_x_dnd_drop(void)
return status;
}
-EAPI void
-ecore_x_dnd_aware_set(Ecore_X_Window win, Eina_Bool on)
+EAPI void
+ecore_x_dnd_aware_set(Ecore_X_Window win,
+ Eina_Bool on)
{
Ecore_X_Atom prop_data = ECORE_X_DND_VERSION;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
if (on)
- ecore_x_window_prop_property_set(win, ECORE_X_ATOM_XDND_AWARE,
+ ecore_x_window_prop_property_set(win, ECORE_X_ATOM_XDND_AWARE,
ECORE_X_ATOM_ATOM, 32, &prop_data, 1);
else
ecore_x_window_prop_property_del(win, ECORE_X_ATOM_XDND_AWARE);
}
-EAPI int
-ecore_x_dnd_version_get(Ecore_X_Window win)
+EAPI int
+ecore_x_dnd_version_get(Ecore_X_Window win)
{
unsigned char *data;
int num = 0;
@@ -199,13 +210,13 @@ ecore_x_dnd_version_get(Ecore_X_Window win)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (_source->state == ECORE_X_DND_SOURCE_DRAGGING)
+ if (_source->state == ECORE_X_DND_SOURCE_DRAGGING)
{
- if (_version_cache)
+ if (_version_cache)
{
int i = 0;
- for (i = 0; i < _version_cache_num; i++)
+ for (i = 0; i < _version_cache_num; i++)
{
if (_version_cache[i].win == win)
return _version_cache[i].ver;
@@ -213,19 +224,19 @@ ecore_x_dnd_version_get(Ecore_X_Window win)
}
}
- if (ecore_x_window_prop_property_get(win, ECORE_X_ATOM_XDND_AWARE,
- ECORE_X_ATOM_ATOM, 32, &data, &num))
+ if (ecore_x_window_prop_property_get(win, ECORE_X_ATOM_XDND_AWARE,
+ ECORE_X_ATOM_ATOM, 32, &data, &num))
{
int version = 0;
version = (int)*data;
free(data);
- if (_source->state == ECORE_X_DND_SOURCE_DRAGGING)
+ if (_source->state == ECORE_X_DND_SOURCE_DRAGGING)
{
_version_cache_num++;
if (_version_cache_num > _version_cache_alloc)
_version_cache_alloc += 16;
- t = realloc(_version_cache,
+ t = realloc(_version_cache,
_version_cache_alloc * sizeof(Version_Cache_Item));
if (!t) return 0;
_version_cache = t;
@@ -235,12 +246,12 @@ ecore_x_dnd_version_get(Ecore_X_Window win)
return version;
}
- if (_source->state == ECORE_X_DND_SOURCE_DRAGGING)
+ if (_source->state == ECORE_X_DND_SOURCE_DRAGGING)
{
_version_cache_num++;
if (_version_cache_num > _version_cache_alloc)
_version_cache_alloc += 16;
- t = realloc(_version_cache,
+ t = realloc(_version_cache,
_version_cache_alloc * sizeof(Version_Cache_Item));
if (!t) return 0;
_version_cache = t;
@@ -251,8 +262,9 @@ ecore_x_dnd_version_get(Ecore_X_Window win)
return 0;
}
-EAPI Eina_Bool
-ecore_x_dnd_type_isset(Ecore_X_Window win, const char *type)
+EAPI Eina_Bool
+ecore_x_dnd_type_isset(Ecore_X_Window win,
+ const char *type)
{
int num = 0, i = 0;
Eina_Bool ret = EINA_FALSE;
@@ -262,15 +274,15 @@ ecore_x_dnd_type_isset(Ecore_X_Window win, const char *type)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- if (!ecore_x_window_prop_property_get(win, ECORE_X_ATOM_XDND_TYPE_LIST,
+ if (!ecore_x_window_prop_property_get(win, ECORE_X_ATOM_XDND_TYPE_LIST,
ECORE_X_ATOM_ATOM, 32, &data, &num))
return ret;
atom = ecore_x_atom_get(type);
atoms = (Ecore_X_Atom *)data;
- for (i = 0; i < num; ++i)
+ for (i = 0; i < num; ++i)
{
- if (atom == atoms[i])
+ if (atom == atoms[i])
{
ret = EINA_TRUE;
break;
@@ -281,8 +293,10 @@ ecore_x_dnd_type_isset(Ecore_X_Window win, const char *type)
return ret;
}
-EAPI void
-ecore_x_dnd_type_set(Ecore_X_Window win, const char *type, Eina_Bool on)
+EAPI void
+ecore_x_dnd_type_set(Ecore_X_Window win,
+ const char *type,
+ Eina_Bool on)
{
Ecore_X_Atom atom, *oldset = NULL, *newset = NULL;
int i = 0, j = 0, num = 0;
@@ -292,12 +306,12 @@ ecore_x_dnd_type_set(Ecore_X_Window win, const char *type, Eina_Bool on)
CHECK_XCB_CONN;
atom = ecore_x_atom_get(type);
- ecore_x_window_prop_property_get(win, ECORE_X_ATOM_XDND_TYPE_LIST,
+ ecore_x_window_prop_property_get(win, ECORE_X_ATOM_XDND_TYPE_LIST,
ECORE_X_ATOM_ATOM, 32, &old_data, &num);
oldset = (Ecore_X_Atom *)old_data;
- if (on)
+ if (on)
{
- if (ecore_x_dnd_type_isset(win, type))
+ if (ecore_x_dnd_type_isset(win, type))
{
free(old_data);
return;
@@ -308,27 +322,27 @@ ecore_x_dnd_type_set(Ecore_X_Window win, const char *type, Eina_Bool on)
for (i = 0; i < num; i++)
newset[i + 1] = oldset[i];
newset[0] = atom;
- ecore_x_window_prop_property_set(win, ECORE_X_ATOM_XDND_TYPE_LIST,
+ ecore_x_window_prop_property_set(win, ECORE_X_ATOM_XDND_TYPE_LIST,
ECORE_X_ATOM_ATOM, 32, data, num + 1);
}
- else
+ else
{
- if (!ecore_x_dnd_type_isset(win, type))
+ if (!ecore_x_dnd_type_isset(win, type))
{
free(old_data);
return;
}
newset = calloc(num - 1, sizeof(Ecore_X_Atom));
- if (!newset)
+ if (!newset)
{
free(old_data);
return;
}
data = (unsigned char *)newset;
for (i = 0; i < num; i++)
- if (oldset[i] != atom)
+ if (oldset[i] != atom)
newset[j++] = oldset[i];
- ecore_x_window_prop_property_set(win, ECORE_X_ATOM_XDND_TYPE_LIST,
+ ecore_x_window_prop_property_set(win, ECORE_X_ATOM_XDND_TYPE_LIST,
ECORE_X_ATOM_ATOM, 32, data, num - 1);
}
free(oldset);
@@ -336,7 +350,9 @@ ecore_x_dnd_type_set(Ecore_X_Window win, const char *type, Eina_Bool on)
}
EAPI void
-ecore_x_dnd_types_set(Ecore_X_Window win, const char **types, unsigned int num_types)
+ecore_x_dnd_types_set(Ecore_X_Window win,
+ const char **types,
+ unsigned int num_types)
{
Ecore_X_Atom *newset = NULL;
unsigned int i;
@@ -346,7 +362,7 @@ ecore_x_dnd_types_set(Ecore_X_Window win, const char **types, unsigned int num_t
CHECK_XCB_CONN;
if (!num_types)
- ecore_x_window_prop_property_del(win, ECORE_X_ATOM_XDND_TYPE_LIST);
+ ecore_x_window_prop_property_del(win, ECORE_X_ATOM_XDND_TYPE_LIST);
else
{
newset = calloc(num_types, sizeof(Ecore_X_Atom));
@@ -360,14 +376,16 @@ ecore_x_dnd_types_set(Ecore_X_Window win, const char **types, unsigned int num_t
_ecore_xcb_dnd_converter_copy);
}
ecore_x_window_prop_property_set(win, ECORE_X_ATOM_XDND_TYPE_LIST,
- ECORE_X_ATOM_ATOM, 32, data,
+ ECORE_X_ATOM_ATOM, 32, data,
num_types);
free(newset);
}
}
EAPI void
-ecore_x_dnd_actions_set(Ecore_X_Window win, Ecore_X_Atom *actions, unsigned int num_actions)
+ecore_x_dnd_actions_set(Ecore_X_Window win,
+ Ecore_X_Atom *actions,
+ unsigned int num_actions)
{
unsigned int i;
unsigned char *data = NULL;
@@ -376,7 +394,7 @@ ecore_x_dnd_actions_set(Ecore_X_Window win, Ecore_X_Atom *actions, unsigned int
CHECK_XCB_CONN;
if (!num_actions)
- ecore_x_window_prop_property_del(win, ECORE_X_ATOM_XDND_ACTION_LIST);
+ ecore_x_window_prop_property_del(win, ECORE_X_ATOM_XDND_ACTION_LIST);
else
{
data = (unsigned char *)actions;
@@ -384,7 +402,7 @@ ecore_x_dnd_actions_set(Ecore_X_Window win, Ecore_X_Atom *actions, unsigned int
ecore_x_selection_converter_atom_add(actions[i],
_ecore_xcb_dnd_converter_copy);
ecore_x_window_prop_property_set(win, ECORE_X_ATOM_XDND_ACTION_LIST,
- ECORE_X_ATOM_ATOM, 32, data,
+ ECORE_X_ATOM_ATOM, 32, data,
num_actions);
}
}
@@ -404,14 +422,18 @@ ecore_x_dnd_actions_set(Ecore_X_Window win, Ecore_X_Atom *actions, unsigned int
* @param data User data.
*/
EAPI void
-ecore_x_dnd_callback_pos_update_set(void (*cb)(void *, Ecore_X_Xdnd_Position *data), const void *data)
+ecore_x_dnd_callback_pos_update_set(void (*cb)(void *,
+ Ecore_X_Xdnd_Position *data),
+ const void *data)
{
_posupdatecb = cb;
_posupdatedata = (void *)data;
}
-EAPI Eina_Bool
-ecore_x_dnd_begin(Ecore_X_Window source, unsigned char *data, int size)
+EAPI Eina_Bool
+ecore_x_dnd_begin(Ecore_X_Window source,
+ unsigned char *data,
+ int size)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -444,8 +466,8 @@ ecore_x_dnd_begin(Ecore_X_Window source, unsigned char *data, int size)
return EINA_TRUE;
}
-EAPI void
-ecore_x_dnd_send_finished(void)
+EAPI void
+ecore_x_dnd_send_finished(void)
{
xcb_client_message_event_t ev;
@@ -463,43 +485,45 @@ ecore_x_dnd_send_finished(void)
ev.data.data32[0] = _target->win;
ev.data.data32[1] = 0;
ev.data.data32[2] = 0;
- if (_target->will_accept)
+ if (_target->will_accept)
{
ev.data.data32[1] |= 0x1UL;
ev.data.data32[2] = _target->accepted_action;
}
- xcb_send_event(_ecore_xcb_conn, 0, _target->source,
+ xcb_send_event(_ecore_xcb_conn, 0, _target->source,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
_target->state = ECORE_X_DND_TARGET_IDLE;
}
-EAPI void
-ecore_x_dnd_source_action_set(Ecore_X_Atom action)
+EAPI void
+ecore_x_dnd_source_action_set(Ecore_X_Atom action)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
_source->action = action;
if (_source->prev.window)
- _ecore_xcb_dnd_drag(_source->prev.window,
+ _ecore_xcb_dnd_drag(_source->prev.window,
_source->prev.x, _source->prev.y);
}
Ecore_X_DND_Source *
-_ecore_xcb_dnd_source_get(void)
+_ecore_xcb_dnd_source_get(void)
{
return _source;
}
Ecore_X_DND_Target *
-_ecore_xcb_dnd_target_get(void)
+_ecore_xcb_dnd_target_get(void)
{
return _target;
}
-void
-_ecore_xcb_dnd_drag(Ecore_X_Window root, int x, int y)
+void
+_ecore_xcb_dnd_drag(Ecore_X_Window root,
+ int x,
+ int y)
{
xcb_client_message_event_t ev;
Ecore_X_Window win, *skip;
@@ -521,34 +545,34 @@ _ecore_xcb_dnd_drag(Ecore_X_Window root, int x, int y)
while ((win) && !(ecore_x_dnd_version_get(win)))
win = ecore_x_window_shadow_parent_get(root, win);
- if ((_source->dest) && (win != _source->dest))
+ if ((_source->dest) && (win != _source->dest))
{
ev.window = _source->dest;
ev.type = ECORE_X_ATOM_XDND_LEAVE;
ev.data.data32[0] = _source->win;
ev.data.data32[1] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, _source->dest,
+ xcb_send_event(_ecore_xcb_conn, 0, _source->dest,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
_source->suppress = 0;
}
- if (win)
+ if (win)
{
int x1, x2, y1, y2;
- _source->version = MIN(ECORE_X_DND_VERSION,
+ _source->version = MIN(ECORE_X_DND_VERSION,
ecore_x_dnd_version_get(win));
- if (win != _source->dest)
+ if (win != _source->dest)
{
int i = 0;
unsigned char *data;
Ecore_X_Atom *types;
- ecore_x_window_prop_property_get(_source->win,
- ECORE_X_ATOM_XDND_TYPE_LIST,
- ECORE_X_ATOM_ATOM, 32,
+ ecore_x_window_prop_property_get(_source->win,
+ ECORE_X_ATOM_XDND_TYPE_LIST,
+ ECORE_X_ATOM_ATOM, 32,
&data, &num);
types = (Ecore_X_Atom *)data;
ev.window = win;
@@ -567,7 +591,7 @@ _ecore_xcb_dnd_drag(Ecore_X_Window root, int x, int y)
ev.data.data32[i + 2] = types[i];
free(data);
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
_source->await_status = 0;
@@ -579,8 +603,8 @@ _ecore_xcb_dnd_drag(Ecore_X_Window root, int x, int y)
y1 = _source->rectangle.y;
y2 = _source->rectangle.y + _source->rectangle.height;
- if ((!_source->await_status) || (!_source->suppress) ||
- ((x < x1) || (x > x2) || (y < y1) || (y > y2)))
+ if ((!_source->await_status) || (!_source->suppress) ||
+ ((x < x1) || (x > x2) || (y < y1) || (y > y2)))
{
ev.window = win;
ev.type = ECORE_X_ATOM_XDND_POSITION;
@@ -590,14 +614,14 @@ _ecore_xcb_dnd_drag(Ecore_X_Window root, int x, int y)
ev.data.data32[3] = _source->time;
ev.data.data32[4] = _source->action;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
_source->await_status = 1;
}
}
- if (_posupdatecb)
+ if (_posupdatecb)
{
pos.position.x = x;
pos.position.y = y;
@@ -612,15 +636,21 @@ _ecore_xcb_dnd_drag(Ecore_X_Window root, int x, int y)
_source->dest = win;
}
-EAPI Ecore_X_Atom
-ecore_x_dnd_source_action_get(void)
+EAPI Ecore_X_Atom
+ecore_x_dnd_source_action_get(void)
{
return _source->action;
}
/* local functions */
-static Eina_Bool
-_ecore_xcb_dnd_converter_copy(char *target __UNUSED__, void *data, int size, void **data_ret, int *size_ret, Ecore_X_Atom *tprop __UNUSED__, int *count __UNUSED__)
+static Eina_Bool
+_ecore_xcb_dnd_converter_copy(char *target __UNUSED__,
+ void *data,
+ int size,
+ void **data_ret,
+ int *size_ret,
+ Ecore_X_Atom *tprop __UNUSED__,
+ int *count __UNUSED__)
{
Ecore_Xcb_Textproperty text_prop;
Ecore_Xcb_Encoding_Style style = XcbTextStyle;
@@ -634,12 +664,12 @@ _ecore_xcb_dnd_converter_copy(char *target __UNUSED__, void *data, int size, voi
if (!mystr) return EINA_FALSE;
memcpy(mystr, data, size);
- if (_ecore_xcb_mb_textlist_to_textproperty(&mystr, 1, style, &text_prop))
+ if (_ecore_xcb_mb_textlist_to_textproperty(&mystr, 1, style, &text_prop))
{
int len;
len = strlen((char *)text_prop.value) + 1;
- if (!(*data_ret = malloc(len)))
+ if (!(*data_ret = malloc(len)))
{
free(mystr);
return EINA_FALSE;
@@ -650,9 +680,10 @@ _ecore_xcb_dnd_converter_copy(char *target __UNUSED__, void *data, int size, voi
free(mystr);
return EINA_TRUE;
}
- else
+ else
{
free(mystr);
return EINA_FALSE;
}
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dpms.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dpms.c
index fb5a33083b..63b7f1ea95 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dpms.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_dpms.c
@@ -6,8 +6,8 @@
/* local variables */
static Eina_Bool _dpms_avail = EINA_FALSE;
-void
-_ecore_xcb_dpms_init(void)
+void
+_ecore_xcb_dpms_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -16,8 +16,8 @@ _ecore_xcb_dpms_init(void)
#endif
}
-void
-_ecore_xcb_dpms_finalize(void)
+void
+_ecore_xcb_dpms_finalize(void)
{
#ifdef ECORE_XCB_DPMS
const xcb_query_extension_reply_t *ext_reply;
@@ -25,21 +25,21 @@ _ecore_xcb_dpms_finalize(void)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
-#ifdef ECORE_XCB_DPMS
+#ifdef ECORE_XCB_DPMS
ext_reply = xcb_get_extension_data(_ecore_xcb_conn, &xcb_dpms_id);
- if ((ext_reply) && (ext_reply->present))
+ if ((ext_reply) && (ext_reply->present))
{
xcb_dpms_get_version_cookie_t cookie;
xcb_dpms_get_version_reply_t *reply;
- cookie =
- xcb_dpms_get_version_unchecked(_ecore_xcb_conn,
- XCB_DPMS_MAJOR_VERSION,
+ cookie =
+ xcb_dpms_get_version_unchecked(_ecore_xcb_conn,
+ XCB_DPMS_MAJOR_VERSION,
XCB_DPMS_MINOR_VERSION);
reply = xcb_dpms_get_version_reply(_ecore_xcb_conn, cookie, NULL);
- if (reply)
+ if (reply)
{
- if (reply->server_major_version >= 1)
+ if (reply->server_major_version >= 1)
_dpms_avail = EINA_TRUE;
free(reply);
}
@@ -49,27 +49,27 @@ _ecore_xcb_dpms_finalize(void)
/**
* @defgroup Ecore_X_DPMS_Group X DPMS Extension Functions
- *
+ *
* Functions related to the X DPMS Extension
*/
/**
* Checks if the DPMS extension is available or not.
- *
- * @return @c EINA_TRUE if the DPMS extension is available,
+ *
+ * @return @c EINA_TRUE if the DPMS extension is available,
* @c EINA_FALSE otherwise.
*
* Return EINA_TRUE if the X server supports the DPMS Extension version 1.0,
* EINA_FALSE otherwise.
- *
+ *
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI Eina_Bool
-ecore_x_dpms_query(void)
+EAPI Eina_Bool
+ecore_x_dpms_query(void)
{
// LOGFN(__FILE__, __LINE__, __FUNCTION__);
- return _dpms_avail;
+ return _dpms_avail;
}
/**
@@ -77,8 +77,8 @@ ecore_x_dpms_query(void)
* @return @c 1 if the X server is capable of DPMS, @c 0 otherwise.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI Eina_Bool
-ecore_x_dpms_capable_get(void)
+EAPI Eina_Bool
+ecore_x_dpms_capable_get(void)
{
Eina_Bool ret = EINA_FALSE;
#ifdef ECORE_XCB_DPMS
@@ -94,7 +94,7 @@ ecore_x_dpms_capable_get(void)
#ifdef ECORE_XCB_DPMS
cookie = xcb_dpms_capable_unchecked(_ecore_xcb_conn);
reply = xcb_dpms_capable_reply(_ecore_xcb_conn, cookie, NULL);
- if (reply)
+ if (reply)
{
ret = reply->capable;
free(reply);
@@ -109,8 +109,8 @@ ecore_x_dpms_capable_get(void)
* @return @c EINA_TRUE if DPMS is enabled, @c EINA_FALSE otherwise.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI Eina_Bool
-ecore_x_dpms_enabled_get(void)
+EAPI Eina_Bool
+ecore_x_dpms_enabled_get(void)
{
Eina_Bool ret = EINA_FALSE;
#ifdef ECORE_XCB_DPMS
@@ -139,8 +139,8 @@ ecore_x_dpms_enabled_get(void)
* @param enabled @c 0 to disable DPMS characteristics of the server, enable it otherwise.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI void
-ecore_x_dpms_enabled_set(int enabled)
+EAPI void
+ecore_x_dpms_enabled_set(int enabled)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -148,9 +148,9 @@ ecore_x_dpms_enabled_set(int enabled)
if (!_dpms_avail) return;
#ifdef ECORE_XCB_DPMS
- if (enabled)
+ if (enabled)
xcb_dpms_enable(_ecore_xcb_conn);
- else
+ else
xcb_dpms_disable(_ecore_xcb_conn);
#endif
}
@@ -162,8 +162,10 @@ ecore_x_dpms_enabled_set(int enabled)
* @param off Amount of time of inactivity before the monitor is shut off.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI void
-ecore_x_dpms_timeouts_get(unsigned int *standby, unsigned int *suspend, unsigned int *off)
+EAPI void
+ecore_x_dpms_timeouts_get(unsigned int *standby,
+ unsigned int *suspend,
+ unsigned int *off)
{
#ifdef ECORE_XCB_DPMS
xcb_dpms_get_timeouts_cookie_t cookie;
@@ -197,8 +199,10 @@ ecore_x_dpms_timeouts_get(unsigned int *standby, unsigned int *suspend, unsigned
* @param off Amount of time of inactivity before the monitor is shut off.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI Eina_Bool
-ecore_x_dpms_timeouts_set(unsigned int standby, unsigned int suspend, unsigned int off)
+EAPI Eina_Bool
+ecore_x_dpms_timeouts_set(unsigned int standby,
+ unsigned int suspend,
+ unsigned int off)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -219,8 +223,8 @@ ecore_x_dpms_timeouts_set(unsigned int standby, unsigned int suspend, unsigned i
* @return The standby timeout value.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI unsigned int
-ecore_x_dpms_timeout_standby_get(void)
+EAPI unsigned int
+ecore_x_dpms_timeout_standby_get(void)
{
unsigned int standby = 0;
@@ -236,8 +240,8 @@ ecore_x_dpms_timeout_standby_get(void)
* @return The suspend timeout value.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI unsigned int
-ecore_x_dpms_timeout_suspend_get(void)
+EAPI unsigned int
+ecore_x_dpms_timeout_suspend_get(void)
{
unsigned int suspend = 0;
@@ -253,8 +257,8 @@ ecore_x_dpms_timeout_suspend_get(void)
* @return The off timeout value.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI unsigned int
-ecore_x_dpms_timeout_off_get(void)
+EAPI unsigned int
+ecore_x_dpms_timeout_off_get(void)
{
unsigned int off = 0;
@@ -269,8 +273,8 @@ ecore_x_dpms_timeout_off_get(void)
* @param new_standby Amount of time of inactivity before standby mode will be invoked.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI void
-ecore_x_dpms_timeout_standby_set(unsigned int new_timeout)
+EAPI void
+ecore_x_dpms_timeout_standby_set(unsigned int new_timeout)
{
unsigned int standby = 0, suspend = 0, off = 0;
@@ -285,8 +289,8 @@ ecore_x_dpms_timeout_standby_set(unsigned int new_timeout)
* @param suspend Amount of time of inactivity before the screen is placed into suspend mode.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI void
-ecore_x_dpms_timeout_suspend_set(unsigned int new_timeout)
+EAPI void
+ecore_x_dpms_timeout_suspend_set(unsigned int new_timeout)
{
unsigned int standby = 0, suspend = 0, off = 0;
@@ -301,8 +305,8 @@ ecore_x_dpms_timeout_suspend_set(unsigned int new_timeout)
* @param off Amount of time of inactivity before the monitor is shut off.
* @ingroup Ecore_X_DPMS_Group
*/
-EAPI void
-ecore_x_dpms_timeout_off_set(unsigned int new_timeout)
+EAPI void
+ecore_x_dpms_timeout_off_set(unsigned int new_timeout)
{
unsigned int standby = 0, suspend = 0, off = 0;
@@ -311,3 +315,4 @@ ecore_x_dpms_timeout_off_set(unsigned int new_timeout)
ecore_x_dpms_timeouts_get(&standby, &suspend, &off);
ecore_x_dpms_timeouts_set(standby, suspend, new_timeout);
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_drawable.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_drawable.c
index 6ea235b789..4e9a3564ce 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_drawable.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_drawable.c
@@ -15,8 +15,13 @@
* @param width The width of the rectangle.
* @param height The height of the rectangle.
*/
-EAPI void
-ecore_x_drawable_rectangle_fill(Ecore_X_Drawable draw, Ecore_X_GC gc, int x, int y, int w, int h)
+EAPI void
+ecore_x_drawable_rectangle_fill(Ecore_X_Drawable draw,
+ Ecore_X_GC gc,
+ int x,
+ int y,
+ int w,
+ int h)
{
xcb_rectangle_t rect;
@@ -27,7 +32,7 @@ ecore_x_drawable_rectangle_fill(Ecore_X_Drawable draw, Ecore_X_GC gc, int x, int
rect.y = y;
rect.width = w;
rect.height = h;
- xcb_poly_fill_rectangle(_ecore_xcb_conn, draw, gc, 1,
+ xcb_poly_fill_rectangle(_ecore_xcb_conn, draw, gc, 1,
(const xcb_rectangle_t *)&rect);
// ecore_x_flush();
}
@@ -41,8 +46,12 @@ ecore_x_drawable_rectangle_fill(Ecore_X_Drawable draw, Ecore_X_GC gc, int x, int
* @param h Pointer to an integer into which the height is to be stored.
* @ingroup Ecore_X_Drawable_Group
*/
-EAPI void
-ecore_x_drawable_geometry_get(Ecore_X_Drawable draw, int *x, int *y, int *w, int *h)
+EAPI void
+ecore_x_drawable_geometry_get(Ecore_X_Drawable draw,
+ int *x,
+ int *y,
+ int *w,
+ int *h)
{
xcb_get_geometry_cookie_t cookie;
xcb_get_geometry_reply_t *reply;
@@ -70,8 +79,8 @@ ecore_x_drawable_geometry_get(Ecore_X_Drawable draw, int *x, int *y, int *w, int
* @return The border width of the given drawable.
* @ingroup Ecore_X_Drawable_Group
*/
-EAPI int
-ecore_x_drawable_border_width_get(Ecore_X_Drawable d)
+EAPI int
+ecore_x_drawable_border_width_get(Ecore_X_Drawable d)
{
xcb_get_geometry_cookie_t cookie;
xcb_get_geometry_reply_t *reply;
@@ -94,8 +103,8 @@ ecore_x_drawable_border_width_get(Ecore_X_Drawable d)
* @return The depth of the given drawable.
* @ingroup Ecore_X_Drawable_Group
*/
-EAPI int
-ecore_x_drawable_depth_get(Ecore_X_Drawable d)
+EAPI int
+ecore_x_drawable_depth_get(Ecore_X_Drawable d)
{
xcb_get_geometry_cookie_t cookie;
xcb_get_geometry_reply_t *reply;
@@ -111,3 +120,4 @@ ecore_x_drawable_depth_get(Ecore_X_Drawable d)
free(reply);
return ret;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_e.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_e.c
index 5b9162d1f8..c868f5eede 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_e.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_e.c
@@ -1,21 +1,21 @@
#include "ecore_xcb_private.h"
/* local function prototypes */
-static Ecore_X_Atom _ecore_xcb_e_vkbd_atom_get(Ecore_X_Virtual_Keyboard_State state);
-static Ecore_X_Virtual_Keyboard_State _ecore_xcb_e_vkbd_state_get(Ecore_X_Atom atom);
-static Ecore_X_Atom _ecore_xcb_e_quickpanel_atom_get(Ecore_X_Illume_Quickpanel_State state);
+static Ecore_X_Atom _ecore_xcb_e_vkbd_atom_get(Ecore_X_Virtual_Keyboard_State state);
+static Ecore_X_Virtual_Keyboard_State _ecore_xcb_e_vkbd_state_get(Ecore_X_Atom atom);
+static Ecore_X_Atom _ecore_xcb_e_quickpanel_atom_get(Ecore_X_Illume_Quickpanel_State state);
static Ecore_X_Illume_Quickpanel_State _ecore_xcb_e_quickpanel_state_get(Ecore_X_Atom atom);
-static Ecore_X_Atom _ecore_xcb_e_illume_atom_get(Ecore_X_Illume_Mode mode);
-static Ecore_X_Illume_Mode _ecore_xcb_e_illume_mode_get(Ecore_X_Atom atom);
+static Ecore_X_Atom _ecore_xcb_e_illume_atom_get(Ecore_X_Illume_Mode mode);
+static Ecore_X_Illume_Mode _ecore_xcb_e_illume_mode_get(Ecore_X_Atom atom);
-EAPI void
-ecore_x_e_init(void)
+EAPI void
+ecore_x_e_init(void)
{
-
}
-EAPI void
-ecore_x_e_comp_sync_draw_done_send(Ecore_X_Window root, Ecore_X_Window win)
+EAPI void
+ecore_x_e_comp_sync_draw_done_send(Ecore_X_Window root,
+ Ecore_X_Window win)
{
xcb_client_message_event_t ev;
@@ -36,14 +36,17 @@ ecore_x_e_comp_sync_draw_done_send(Ecore_X_Window root, Ecore_X_Window win)
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, root,
- (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
- XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
+ xcb_send_event(_ecore_xcb_conn, 0, root,
+ (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
+ XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_e_comp_sync_draw_size_done_send(Ecore_X_Window root, Ecore_X_Window win, int w, int h)
+EAPI void
+ecore_x_e_comp_sync_draw_size_done_send(Ecore_X_Window root,
+ Ecore_X_Window win,
+ int w,
+ int h)
{
xcb_client_message_event_t ev;
@@ -64,40 +67,41 @@ ecore_x_e_comp_sync_draw_size_done_send(Ecore_X_Window root, Ecore_X_Window win,
ev.data.data32[3] = h;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, root,
- (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
- XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
+ xcb_send_event(_ecore_xcb_conn, 0, root,
+ (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
+ XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_e_comp_sync_counter_set(Ecore_X_Window win, Ecore_X_Sync_Counter counter)
+EAPI void
+ecore_x_e_comp_sync_counter_set(Ecore_X_Window win,
+ Ecore_X_Sync_Counter counter)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
if (counter)
- ecore_x_window_prop_xid_set(win, ECORE_X_ATOM_E_COMP_SYNC_COUNTER,
+ ecore_x_window_prop_xid_set(win, ECORE_X_ATOM_E_COMP_SYNC_COUNTER,
ECORE_X_ATOM_CARDINAL, &counter, 1);
else
ecore_x_window_prop_property_del(win, ECORE_X_ATOM_E_COMP_SYNC_COUNTER);
}
-EAPI Ecore_X_Sync_Counter
-ecore_x_e_comp_sync_counter_get(Ecore_X_Window win)
+EAPI Ecore_X_Sync_Counter
+ecore_x_e_comp_sync_counter_get(Ecore_X_Window win)
{
Ecore_X_Sync_Counter counter = 0;
int ret = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ret = ecore_x_window_prop_xid_get(win, ECORE_X_ATOM_E_COMP_SYNC_COUNTER,
+ ret = ecore_x_window_prop_xid_get(win, ECORE_X_ATOM_E_COMP_SYNC_COUNTER,
ECORE_X_ATOM_CARDINAL, &counter, 1);
if (ret != 1) return 0;
return counter;
}
-EAPI Eina_Bool
-ecore_x_e_comp_sync_supported_get(Ecore_X_Window root)
+EAPI Eina_Bool
+ecore_x_e_comp_sync_supported_get(Ecore_X_Window root)
{
Ecore_X_Window win, win2;
int ret = 0;
@@ -105,54 +109,55 @@ ecore_x_e_comp_sync_supported_get(Ecore_X_Window root)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
if (!root) root = ((xcb_screen_t *)_ecore_xcb_screen)->root;
- ret =
- ecore_x_window_prop_xid_get(root, ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
+ ret =
+ ecore_x_window_prop_xid_get(root, ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
ECORE_X_ATOM_WINDOW, &win, 1);
- if ((ret == 1) && (win))
+ if ((ret == 1) && (win))
{
- ret =
- ecore_x_window_prop_xid_get(win, ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
+ ret =
+ ecore_x_window_prop_xid_get(win, ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
ECORE_X_ATOM_WINDOW, &win2, 1);
- if ((ret == 1) && (win2 == win))
+ if ((ret == 1) && (win2 == win))
return EINA_TRUE;
}
return EINA_FALSE;
}
-EAPI void
-ecore_x_e_comp_sync_supported_set(Ecore_X_Window root, Eina_Bool enabled)
+EAPI void
+ecore_x_e_comp_sync_supported_set(Ecore_X_Window root,
+ Eina_Bool enabled)
{
Ecore_X_Window win;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
if (!root) root = ((xcb_screen_t *)_ecore_xcb_screen)->root;
- if (enabled)
+ if (enabled)
{
win = ecore_x_window_new(root, 1, 2, 3, 4);
- ecore_x_window_prop_xid_set(win, ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
+ ecore_x_window_prop_xid_set(win, ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
ECORE_X_ATOM_WINDOW, &win, 1);
- ecore_x_window_prop_xid_set(root, ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
+ ecore_x_window_prop_xid_set(root, ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
ECORE_X_ATOM_WINDOW, &win, 1);
}
- else
+ else
{
int ret = 0;
- ret = ecore_x_window_prop_xid_get(root,
- ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
+ ret = ecore_x_window_prop_xid_get(root,
+ ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED,
ECORE_X_ATOM_WINDOW, &win, 1);
- if ((ret == 1) && (win))
+ if ((ret == 1) && (win))
{
- ecore_x_window_prop_property_del(root,
+ ecore_x_window_prop_property_del(root,
ECORE_X_ATOM_E_COMP_SYNC_SUPPORTED);
ecore_x_window_free(win);
}
}
}
-EAPI void
-ecore_x_e_comp_sync_begin_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_comp_sync_begin_send(Ecore_X_Window win)
{
xcb_client_message_event_t ev;
@@ -171,13 +176,13 @@ ecore_x_e_comp_sync_begin_send(Ecore_X_Window win)
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_e_comp_sync_end_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_comp_sync_end_send(Ecore_X_Window win)
{
xcb_client_message_event_t ev;
@@ -196,13 +201,13 @@ ecore_x_e_comp_sync_end_send(Ecore_X_Window win)
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_e_comp_sync_cancel_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_comp_sync_cancel_send(Ecore_X_Window win)
{
xcb_client_message_event_t ev;
@@ -221,13 +226,13 @@ ecore_x_e_comp_sync_cancel_send(Ecore_X_Window win)
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_e_comp_flush_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_comp_flush_send(Ecore_X_Window win)
{
xcb_client_message_event_t ev;
@@ -246,13 +251,13 @@ ecore_x_e_comp_flush_send(Ecore_X_Window win)
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_e_comp_dump_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_comp_dump_send(Ecore_X_Window win)
{
xcb_client_message_event_t ev;
@@ -271,39 +276,44 @@ ecore_x_e_comp_dump_send(Ecore_X_Window win)
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_e_comp_pixmap_set(Ecore_X_Window win, Ecore_X_Pixmap pixmap)
+EAPI void
+ecore_x_e_comp_pixmap_set(Ecore_X_Window win,
+ Ecore_X_Pixmap pixmap)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
if (pixmap)
- ecore_x_window_prop_xid_set(win, ECORE_X_ATOM_E_COMP_PIXMAP,
+ ecore_x_window_prop_xid_set(win, ECORE_X_ATOM_E_COMP_PIXMAP,
ECORE_X_ATOM_PIXMAP, &pixmap, 1);
else
ecore_x_window_prop_property_del(win, pixmap);
}
-EAPI Ecore_X_Pixmap
-ecore_x_e_comp_pixmap_get(Ecore_X_Window win)
+EAPI Ecore_X_Pixmap
+ecore_x_e_comp_pixmap_get(Ecore_X_Window win)
{
Ecore_X_Pixmap pixmap = 0;
int ret = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ret = ecore_x_window_prop_xid_get(win, ECORE_X_ATOM_E_COMP_PIXMAP,
+ ret = ecore_x_window_prop_xid_get(win, ECORE_X_ATOM_E_COMP_PIXMAP,
ECORE_X_ATOM_PIXMAP, &pixmap, 1);
if (ret != 1) return 0;
return pixmap;
}
-EAPI void
-ecore_x_e_frame_size_set(Ecore_X_Window win, int fl, int fr, int ft, int fb)
+EAPI void
+ecore_x_e_frame_size_set(Ecore_X_Window win,
+ int fl,
+ int fr,
+ int ft,
+ int fb)
{
uint32_t frames[4];
@@ -316,176 +326,187 @@ ecore_x_e_frame_size_set(Ecore_X_Window win, int fl, int fr, int ft, int fb)
ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_FRAME_SIZE, frames, 4);
}
-EAPI Ecore_X_Virtual_Keyboard_State
-ecore_x_e_virtual_keyboard_state_get(Ecore_X_Window win)
+EAPI Ecore_X_Virtual_Keyboard_State
+ecore_x_e_virtual_keyboard_state_get(Ecore_X_Window win)
{
Ecore_X_Atom atom = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_atom_get(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_STATE,
+ if (!ecore_x_window_prop_atom_get(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_STATE,
&atom, 1))
return ECORE_X_VIRTUAL_KEYBOARD_STATE_UNKNOWN;
return _ecore_xcb_e_vkbd_state_get(atom);
}
-EAPI void
-ecore_x_e_virtual_keyboard_state_set(Ecore_X_Window win, Ecore_X_Virtual_Keyboard_State state)
+EAPI void
+ecore_x_e_virtual_keyboard_state_set(Ecore_X_Window win,
+ Ecore_X_Virtual_Keyboard_State state)
{
Ecore_X_Atom atom = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
atom = _ecore_xcb_e_vkbd_atom_get(state);
- ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_STATE,
+ ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_STATE,
&atom, 1);
}
-EAPI void
-ecore_x_e_virtual_keyboard_state_send(Ecore_X_Window win, Ecore_X_Virtual_Keyboard_State state)
+EAPI void
+ecore_x_e_virtual_keyboard_state_send(Ecore_X_Window win,
+ Ecore_X_Virtual_Keyboard_State state)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_STATE,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
- _ecore_xcb_e_vkbd_atom_get(state),
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_STATE,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ _ecore_xcb_e_vkbd_atom_get(state),
0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_virtual_keyboard_set(Ecore_X_Window win, unsigned int is_keyboard)
+EAPI void
+ecore_x_e_virtual_keyboard_set(Ecore_X_Window win,
+ unsigned int is_keyboard)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD,
&is_keyboard, 1);
}
-EAPI Eina_Bool
-ecore_x_e_virtual_keyboard_get(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_e_virtual_keyboard_get(Ecore_X_Window win)
{
unsigned int val = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD,
+ if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_E_VIRTUAL_KEYBOARD,
&val, 1))
return EINA_FALSE;
return val ? EINA_TRUE : EINA_FALSE;
}
-EAPI int
-ecore_x_e_illume_quickpanel_priority_major_get(Ecore_X_Window win)
+EAPI int
+ecore_x_e_illume_quickpanel_priority_major_get(Ecore_X_Window win)
{
unsigned int val = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win,
- ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MAJOR,
+ if (!ecore_x_window_prop_card32_get(win,
+ ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MAJOR,
&val, 1))
return 0;
return val;
}
-EAPI void
-ecore_x_e_illume_quickpanel_priority_major_set(Ecore_X_Window win, unsigned int priority)
+EAPI void
+ecore_x_e_illume_quickpanel_priority_major_set(Ecore_X_Window win,
+ unsigned int priority)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win,
- ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MAJOR,
+ ecore_x_window_prop_card32_set(win,
+ ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MAJOR,
&priority, 1);
}
-EAPI int
-ecore_x_e_illume_quickpanel_priority_minor_get(Ecore_X_Window win)
+EAPI int
+ecore_x_e_illume_quickpanel_priority_minor_get(Ecore_X_Window win)
{
unsigned int val = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win,
- ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MINOR,
+ if (!ecore_x_window_prop_card32_get(win,
+ ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MINOR,
&val, 1))
return 0;
return val;
}
-EAPI void
-ecore_x_e_illume_quickpanel_priority_minor_set(Ecore_X_Window win, unsigned int priority)
+EAPI void
+ecore_x_e_illume_quickpanel_priority_minor_set(Ecore_X_Window win,
+ unsigned int priority)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win,
- ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MINOR,
+ ecore_x_window_prop_card32_set(win,
+ ECORE_X_ATOM_E_ILLUME_QUICKPANEL_PRIORITY_MINOR,
&priority, 1);
}
-EAPI void
-ecore_x_e_illume_quickpanel_zone_set(Ecore_X_Window win, unsigned int zone)
+EAPI void
+ecore_x_e_illume_quickpanel_zone_set(Ecore_X_Window win,
+ unsigned int zone)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL_ZONE,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL_ZONE,
&zone, 1);
}
-EAPI int
-ecore_x_e_illume_quickpanel_zone_get(Ecore_X_Window win)
+EAPI int
+ecore_x_e_illume_quickpanel_zone_get(Ecore_X_Window win)
{
unsigned int val = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win,
- ECORE_X_ATOM_E_ILLUME_QUICKPANEL_ZONE,
+ if (!ecore_x_window_prop_card32_get(win,
+ ECORE_X_ATOM_E_ILLUME_QUICKPANEL_ZONE,
&val, 1))
return 0;
return val;
}
-EAPI void
-ecore_x_e_illume_quickpanel_position_update_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_quickpanel_position_update_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win,
- ECORE_X_ATOM_E_ILLUME_QUICKPANEL_POSITION_UPDATE,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win,
+ ECORE_X_ATOM_E_ILLUME_QUICKPANEL_POSITION_UPDATE,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI Eina_Bool
-ecore_x_e_illume_conformant_get(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_e_illume_conformant_get(Ecore_X_Window win)
{
unsigned int val = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_E_ILLUME_CONFORMANT,
+ if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_E_ILLUME_CONFORMANT,
&val, 1))
return EINA_FALSE;
return val ? EINA_TRUE : EINA_FALSE;
}
-EAPI void
-ecore_x_e_illume_conformant_set(Ecore_X_Window win, unsigned int is_conformant)
+EAPI void
+ecore_x_e_illume_conformant_set(Ecore_X_Window win,
+ unsigned int is_conformant)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_CONFORMANT,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_CONFORMANT,
&is_conformant, 1);
}
-EAPI void
-ecore_x_e_illume_softkey_geometry_set(Ecore_X_Window win, int x, int y, int w, int h)
+EAPI void
+ecore_x_e_illume_softkey_geometry_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h)
{
unsigned int geom[4];
@@ -495,12 +516,16 @@ ecore_x_e_illume_softkey_geometry_set(Ecore_X_Window win, int x, int y, int w, i
geom[1] = y;
geom[2] = w;
geom[3] = h;
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_SOFTKEY_GEOMETRY,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_SOFTKEY_GEOMETRY,
geom, 4);
}
-EAPI Eina_Bool
-ecore_x_e_illume_softkey_geometry_get(Ecore_X_Window win, int *x, int *y, int *w, int *h)
+EAPI Eina_Bool
+ecore_x_e_illume_softkey_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *w,
+ int *h)
{
unsigned int geom[4];
@@ -511,8 +536,8 @@ ecore_x_e_illume_softkey_geometry_get(Ecore_X_Window win, int *x, int *y, int *w
if (w) *w = 0;
if (h) *h = 0;
- if (ecore_x_window_prop_card32_get(win,
- ECORE_X_ATOM_E_ILLUME_SOFTKEY_GEOMETRY,
+ if (ecore_x_window_prop_card32_get(win,
+ ECORE_X_ATOM_E_ILLUME_SOFTKEY_GEOMETRY,
geom, 4) != 4)
return EINA_FALSE;
@@ -524,8 +549,12 @@ ecore_x_e_illume_softkey_geometry_get(Ecore_X_Window win, int *x, int *y, int *w
return EINA_TRUE;
}
-EAPI void
-ecore_x_e_illume_indicator_geometry_set(Ecore_X_Window win, int x, int y, int w, int h)
+EAPI void
+ecore_x_e_illume_indicator_geometry_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h)
{
unsigned int geom[4];
@@ -535,13 +564,17 @@ ecore_x_e_illume_indicator_geometry_set(Ecore_X_Window win, int x, int y, int w,
geom[1] = y;
geom[2] = w;
geom[3] = h;
- ecore_x_window_prop_card32_set(win,
- ECORE_X_ATOM_E_ILLUME_INDICATOR_GEOMETRY,
+ ecore_x_window_prop_card32_set(win,
+ ECORE_X_ATOM_E_ILLUME_INDICATOR_GEOMETRY,
geom, 4);
}
-EAPI Eina_Bool
-ecore_x_e_illume_indicator_geometry_get(Ecore_X_Window win, int *x, int *y, int *w, int *h)
+EAPI Eina_Bool
+ecore_x_e_illume_indicator_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *w,
+ int *h)
{
unsigned int geom[4];
@@ -552,8 +585,8 @@ ecore_x_e_illume_indicator_geometry_get(Ecore_X_Window win, int *x, int *y, int
if (w) *w = 0;
if (h) *h = 0;
- if (ecore_x_window_prop_card32_get(win,
- ECORE_X_ATOM_E_ILLUME_INDICATOR_GEOMETRY,
+ if (ecore_x_window_prop_card32_get(win,
+ ECORE_X_ATOM_E_ILLUME_INDICATOR_GEOMETRY,
geom, 4) != 4)
return EINA_FALSE;
@@ -565,8 +598,12 @@ ecore_x_e_illume_indicator_geometry_get(Ecore_X_Window win, int *x, int *y, int
return EINA_TRUE;
}
-EAPI void
-ecore_x_e_illume_keyboard_geometry_set(Ecore_X_Window win, int x, int y, int w, int h)
+EAPI void
+ecore_x_e_illume_keyboard_geometry_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h)
{
unsigned int geom[4];
@@ -576,12 +613,16 @@ ecore_x_e_illume_keyboard_geometry_set(Ecore_X_Window win, int x, int y, int w,
geom[1] = y;
geom[2] = w;
geom[3] = h;
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_KEYBOARD_GEOMETRY,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_KEYBOARD_GEOMETRY,
geom, 4);
}
-EAPI Eina_Bool
-ecore_x_e_illume_keyboard_geometry_get(Ecore_X_Window win, int *x, int *y, int *w, int *h)
+EAPI Eina_Bool
+ecore_x_e_illume_keyboard_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *w,
+ int *h)
{
unsigned int geom[4];
@@ -592,8 +633,8 @@ ecore_x_e_illume_keyboard_geometry_get(Ecore_X_Window win, int *x, int *y, int *
if (w) *w = 0;
if (h) *h = 0;
- if (ecore_x_window_prop_card32_get(win,
- ECORE_X_ATOM_E_ILLUME_KEYBOARD_GEOMETRY,
+ if (ecore_x_window_prop_card32_get(win,
+ ECORE_X_ATOM_E_ILLUME_KEYBOARD_GEOMETRY,
geom, 4) != 4)
return EINA_FALSE;
@@ -605,78 +646,82 @@ ecore_x_e_illume_keyboard_geometry_get(Ecore_X_Window win, int *x, int *y, int *
return EINA_TRUE;
}
-EAPI void
-ecore_x_e_illume_quickpanel_set(Ecore_X_Window win, unsigned int is_quickpanel)
+EAPI void
+ecore_x_e_illume_quickpanel_set(Ecore_X_Window win,
+ unsigned int is_quickpanel)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL,
&is_quickpanel, 1);
}
-EAPI Eina_Bool
-ecore_x_e_illume_quickpanel_get(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_e_illume_quickpanel_get(Ecore_X_Window win)
{
unsigned int val = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL,
+ if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL,
&val, 1))
return EINA_FALSE;
return val ? EINA_TRUE : EINA_FALSE;
}
-EAPI void
-ecore_x_e_illume_quickpanel_state_set(Ecore_X_Window win, Ecore_X_Illume_Quickpanel_State state)
+EAPI void
+ecore_x_e_illume_quickpanel_state_set(Ecore_X_Window win,
+ Ecore_X_Illume_Quickpanel_State state)
{
Ecore_X_Atom atom = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
atom = _ecore_xcb_e_quickpanel_atom_get(state);
- ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE,
+ ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE,
&atom, 1);
}
-EAPI Ecore_X_Illume_Quickpanel_State
-ecore_x_e_illume_quickpanel_state_get(Ecore_X_Window win)
+EAPI Ecore_X_Illume_Quickpanel_State
+ecore_x_e_illume_quickpanel_state_get(Ecore_X_Window win)
{
Ecore_X_Atom atom = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_atom_get(win,
- ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE,
+ if (!ecore_x_window_prop_atom_get(win,
+ ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE,
&atom, 1))
return ECORE_X_ILLUME_QUICKPANEL_STATE_UNKNOWN;
return _ecore_xcb_e_quickpanel_state_get(atom);
}
-EAPI void
-ecore_x_e_illume_quickpanel_state_send(Ecore_X_Window win, Ecore_X_Illume_Quickpanel_State state)
+EAPI void
+ecore_x_e_illume_quickpanel_state_send(Ecore_X_Window win,
+ Ecore_X_Illume_Quickpanel_State state)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
- _ecore_xcb_e_quickpanel_atom_get(state),
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ _ecore_xcb_e_quickpanel_atom_get(state),
0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_quickpanel_state_toggle(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_quickpanel_state_toggle(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win,
- ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE_TOGGLE,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win,
+ ECORE_X_ATOM_E_ILLUME_QUICKPANEL_STATE_TOGGLE,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
0, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_mode_set(Ecore_X_Window win, Ecore_X_Illume_Mode mode)
+EAPI void
+ecore_x_e_illume_mode_set(Ecore_X_Window win,
+ Ecore_X_Illume_Mode mode)
{
Ecore_X_Atom atom = 0;
@@ -686,8 +731,8 @@ ecore_x_e_illume_mode_set(Ecore_X_Window win, Ecore_X_Illume_Mode mode)
ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_E_ILLUME_MODE, &atom, 1);
}
-EAPI Ecore_X_Illume_Mode
-ecore_x_e_illume_mode_get(Ecore_X_Window win)
+EAPI Ecore_X_Illume_Mode
+ecore_x_e_illume_mode_get(Ecore_X_Window win)
{
Ecore_X_Atom atom = 0;
@@ -699,110 +744,113 @@ ecore_x_e_illume_mode_get(Ecore_X_Window win)
return _ecore_xcb_e_illume_mode_get(atom);
}
-EAPI void
-ecore_x_e_illume_mode_send(Ecore_X_Window win, Ecore_X_Illume_Mode mode)
+EAPI void
+ecore_x_e_illume_mode_send(Ecore_X_Window win,
+ Ecore_X_Illume_Mode mode)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_MODE,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
- _ecore_xcb_e_illume_atom_get(mode),
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_MODE,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ _ecore_xcb_e_illume_atom_get(mode),
0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_focus_back_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_focus_back_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_FOCUS_BACK,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_FOCUS_BACK,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_focus_forward_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_focus_forward_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_FOCUS_FORWARD,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_FOCUS_FORWARD,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_focus_home_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_focus_home_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_FOCUS_HOME,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_FOCUS_HOME,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_close_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_close_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_CLOSE,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_CLOSE,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_home_new_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_home_new_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_HOME_NEW,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_HOME_NEW,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_home_del_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_home_del_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_HOME_DEL,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_HOME_DEL,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_drag_set(Ecore_X_Window win, unsigned int drag)
+EAPI void
+ecore_x_e_illume_drag_set(Ecore_X_Window win,
+ unsigned int drag)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_DRAG, &drag, 1);
}
-EAPI void
-ecore_x_e_illume_drag_locked_set(Ecore_X_Window win, unsigned int is_locked)
+EAPI void
+ecore_x_e_illume_drag_locked_set(Ecore_X_Window win,
+ unsigned int is_locked)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_DRAG_LOCKED,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_E_ILLUME_DRAG_LOCKED,
&is_locked, 1);
}
-EAPI Eina_Bool
-ecore_x_e_illume_drag_locked_get(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_e_illume_drag_locked_get(Ecore_X_Window win)
{
unsigned int val = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_E_ILLUME_DRAG_LOCKED,
+ if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_E_ILLUME_DRAG_LOCKED,
&val, 1))
return EINA_FALSE;
return val ? EINA_TRUE : EINA_FALSE;
}
-EAPI Eina_Bool
-ecore_x_e_illume_drag_get(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_e_illume_drag_get(Ecore_X_Window win)
{
unsigned int val = 0;
@@ -814,52 +862,55 @@ ecore_x_e_illume_drag_get(Ecore_X_Window win)
return val ? EINA_TRUE : EINA_FALSE;
}
-EAPI void
-ecore_x_e_illume_drag_start_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_drag_start_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_DRAG_START,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_DRAG_START,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_drag_end_send(Ecore_X_Window win)
+EAPI void
+ecore_x_e_illume_drag_end_send(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_DRAG_END,
- ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_E_ILLUME_DRAG_END,
+ ECORE_X_EVENT_MASK_WINDOW_CONFIGURE,
1, 0, 0, 0, 0);
}
-EAPI void
-ecore_x_e_illume_zone_set(Ecore_X_Window win, Ecore_X_Window zone)
+EAPI void
+ecore_x_e_illume_zone_set(Ecore_X_Window win,
+ Ecore_X_Window zone)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
ecore_x_window_prop_window_set(win, ECORE_X_ATOM_E_ILLUME_ZONE, &zone, 1);
}
-EAPI Ecore_X_Window
-ecore_x_e_illume_zone_get(Ecore_X_Window win)
+EAPI Ecore_X_Window
+ecore_x_e_illume_zone_get(Ecore_X_Window win)
{
Ecore_X_Window zone;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_window_get(win, ECORE_X_ATOM_E_ILLUME_ZONE,
+ if (!ecore_x_window_prop_window_get(win, ECORE_X_ATOM_E_ILLUME_ZONE,
&zone, 1))
return 0;
return zone;
}
-EAPI void
-ecore_x_e_illume_zone_list_set(Ecore_X_Window win, Ecore_X_Window *zones, unsigned int num)
+EAPI void
+ecore_x_e_illume_zone_list_set(Ecore_X_Window win,
+ Ecore_X_Window *zones,
+ unsigned int num)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_window_set(win, ECORE_X_ATOM_E_ILLUME_ZONE_LIST,
+ ecore_x_window_prop_window_set(win, ECORE_X_ATOM_E_ILLUME_ZONE_LIST,
zones, num);
}
@@ -871,35 +922,50 @@ _ecore_xcb_e_vkbd_atom_get(Ecore_X_Virtual_Keyboard_State state)
{
case ECORE_X_VIRTUAL_KEYBOARD_STATE_OFF:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_OFF;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_ON:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_ON;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_ALPHA:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_ALPHA;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_NUMERIC:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_NUMERIC;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_PIN:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_PIN;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_PHONE_NUMBER:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_PHONE_NUMBER;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_HEX:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_HEX;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_TERMINAL:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_TERMINAL;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_PASSWORD:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_PASSWORD;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_IP:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_IP;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_HOST:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_HOST;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_FILE:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_FILE;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_URL:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_URL;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_KEYPAD:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_KEYPAD;
+
case ECORE_X_VIRTUAL_KEYBOARD_STATE_J2ME:
return ECORE_X_ATOM_E_VIRTUAL_KEYBOARD_J2ME;
- default:
+
+ default:
break;
}
return 0;
@@ -949,8 +1015,10 @@ _ecore_xcb_e_quickpanel_atom_get(Ecore_X_Illume_Quickpanel_State state)
{
case ECORE_X_ILLUME_QUICKPANEL_STATE_ON:
return ECORE_X_ATOM_E_ILLUME_QUICKPANEL_ON;
+
case ECORE_X_ILLUME_QUICKPANEL_STATE_OFF:
return ECORE_X_ATOM_E_ILLUME_QUICKPANEL_OFF;
+
default:
break;
}
@@ -975,10 +1043,13 @@ _ecore_xcb_e_illume_atom_get(Ecore_X_Illume_Mode mode)
{
case ECORE_X_ILLUME_MODE_SINGLE:
return ECORE_X_ATOM_E_ILLUME_MODE_SINGLE;
+
case ECORE_X_ILLUME_MODE_DUAL_TOP:
return ECORE_X_ATOM_E_ILLUME_MODE_DUAL_TOP;
+
case ECORE_X_ILLUME_MODE_DUAL_LEFT:
return ECORE_X_ATOM_E_ILLUME_MODE_DUAL_LEFT;
+
default:
break;
}
@@ -997,3 +1068,4 @@ _ecore_xcb_e_illume_mode_get(Ecore_X_Atom atom)
return ECORE_X_ILLUME_MODE_UNKNOWN;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_error.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_error.c
index 0afd8b2a90..bbd9c2ab5a 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_error.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_error.c
@@ -16,8 +16,9 @@ static int _error_code = 0;
*
* Set the X error handler function
*/
-EAPI void
-ecore_x_error_handler_set(void (*func)(void *data), const void *data)
+EAPI void
+ecore_x_error_handler_set(void (*func)(void *data),
+ const void *data)
{
_error_func = func;
_error_data = (void *)data;
@@ -30,8 +31,9 @@ ecore_x_error_handler_set(void (*func)(void *data), const void *data)
*
* Set the X I/O error handler function
*/
-EAPI void
-ecore_x_io_error_handler_set(void (*func)(void *data), const void *data)
+EAPI void
+ecore_x_io_error_handler_set(void (*func)(void *data),
+ const void *data)
{
_io_error_func = func;
_io_error_data = (void *)data;
@@ -43,8 +45,8 @@ ecore_x_io_error_handler_set(void (*func)(void *data), const void *data)
*
* Return the X request code that caused the last X error
*/
-EAPI int
-ecore_x_error_request_get(void)
+EAPI int
+ecore_x_error_request_get(void)
{
return _error_request_code;
}
@@ -55,14 +57,14 @@ ecore_x_error_request_get(void)
*
* Return the error code from the last X error
*/
-EAPI int
-ecore_x_error_code_get(void)
+EAPI int
+ecore_x_error_code_get(void)
{
return _error_code;
}
-int
-_ecore_xcb_error_handle(xcb_generic_error_t *err)
+int
+_ecore_xcb_error_handle(xcb_generic_error_t *err)
{
WRN("Got Error:");
WRN("\tEvent: %s", xcb_event_get_request_label(err->major_code));
@@ -71,12 +73,12 @@ _ecore_xcb_error_handle(xcb_generic_error_t *err)
#ifdef OLD_XCB_VERSION
if (err->error_code == XCB_EVENT_ERROR_BAD_VALUE)
WRN("\tBad Value: %d", ((xcb_value_error_t *)err)->bad_value);
- else if (err->error_code == XCB_EVENT_ERROR_BAD_WINDOW)
+ else if (err->error_code == XCB_EVENT_ERROR_BAD_WINDOW)
WRN("\tBad Window: %d", ((xcb_window_error_t *)err)->bad_value);
#else
if (err->error_code == XCB_VALUE)
WRN("\tBad Value: %d", ((xcb_value_error_t *)err)->bad_value);
- else if (err->error_code == XCB_WINDOW)
+ else if (err->error_code == XCB_WINDOW)
WRN("\tBad Window: %d", ((xcb_window_error_t *)err)->bad_value);
#endif
@@ -88,11 +90,11 @@ _ecore_xcb_error_handle(xcb_generic_error_t *err)
return 0;
}
-int
-_ecore_xcb_io_error_handle(xcb_generic_error_t *err)
+int
+_ecore_xcb_io_error_handle(xcb_generic_error_t *err)
{
CRIT("IO Error:");
- if (err)
+ if (err)
{
CRIT("\tRequest: %d", err->sequence);
CRIT("\tCode: %d", err->error_code);
@@ -104,3 +106,4 @@ _ecore_xcb_io_error_handle(xcb_generic_error_t *err)
return 0;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_events.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_events.c
index 819be1b68d..b1edca1043 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_events.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_events.c
@@ -23,80 +23,84 @@
# define CODESET "INVALID"
#endif
-typedef struct _Ecore_X_Mouse_Down_Info
+typedef struct _Ecore_X_Mouse_Down_Info
{
EINA_INLIST;
- int dev;
- Ecore_X_Time last_time;
- Ecore_X_Time last_last_time;
+ int dev;
+ Ecore_X_Time last_time;
+ Ecore_X_Time last_last_time;
Ecore_X_Window last_win;
Ecore_X_Window last_last_win;
Ecore_X_Window last_event_win;
Ecore_X_Window last_last_event_win;
- Eina_Bool did_double : 1;
- Eina_Bool did_triple : 1;
+ Eina_Bool did_double : 1;
+ Eina_Bool did_triple : 1;
} Ecore_X_Mouse_Down_Info;
/* local function prototypes */
-static void _ecore_xcb_event_handle_any_event(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_key_press(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_key_release(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_button_press(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_button_release(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_motion_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_enter_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_leave_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_keymap_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_focus_in(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_focus_out(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_expose(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_graphics_exposure(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_visibility_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_create_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_destroy_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_map_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_unmap_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_map_request(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_reparent_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_configure_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_configure_request(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_gravity_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_resize_request(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_circulate_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_circulate_request(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_property_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_selection_clear(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_selection_request(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_selection_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_colormap_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_mapping_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_damage_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_randr_change(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_randr_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_randr_crtc_change(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_randr_output_change(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_randr_output_property_change(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_screensaver_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_any_event(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_key_press(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_key_release(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_button_press(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_button_release(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_motion_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_enter_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_leave_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_keymap_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_focus_in(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_focus_out(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_expose(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_graphics_exposure(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_visibility_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_create_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_destroy_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_map_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_unmap_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_map_request(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_reparent_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_configure_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_configure_request(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_gravity_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_resize_request(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_circulate_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_circulate_request(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_property_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_selection_clear(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_selection_request(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_selection_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_colormap_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_mapping_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_damage_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_randr_change(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_randr_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_randr_crtc_change(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_randr_output_change(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_randr_output_property_change(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_screensaver_notify(xcb_generic_event_t *event);
#ifdef ECORE_XCB_SHAPE
-static void _ecore_xcb_event_handle_shape_change(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_shape_change(xcb_generic_event_t *event);
#endif
-static void _ecore_xcb_event_handle_sync_counter(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_sync_alarm(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_xfixes_selection_notify(xcb_generic_event_t *event __UNUSED__);
-static void _ecore_xcb_event_handle_xfixes_cursor_notify(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_generic_event(xcb_generic_event_t *event);
-static void _ecore_xcb_event_handle_input_event(xcb_generic_event_t *event);
-
-static void _ecore_xcb_event_key_press(xcb_generic_event_t *event);
-static void _ecore_xcb_event_key_release(xcb_generic_event_t *event);
-static void _ecore_xcb_event_mouse_move_free(void *data __UNUSED__, void *event);
-static Ecore_X_Event_Mode _ecore_xcb_event_mode_get(uint8_t mode);
-static Ecore_X_Event_Detail _ecore_xcb_event_detail_get(uint8_t detail);
-static void _ecore_xcb_event_xdnd_enter_free(void *data __UNUSED__, void *event);
-static void _ecore_xcb_event_selection_notify_free(void *data __UNUSED__, void *event);
-static void _ecore_xcb_event_generic_event_free(void *data, void *event);
-static void _ecore_xcb_event_mouse_down_info_clear(void);
+static void _ecore_xcb_event_handle_sync_counter(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_sync_alarm(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_xfixes_selection_notify(xcb_generic_event_t *event __UNUSED__);
+static void _ecore_xcb_event_handle_xfixes_cursor_notify(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_generic_event(xcb_generic_event_t *event);
+static void _ecore_xcb_event_handle_input_event(xcb_generic_event_t *event);
+
+static void _ecore_xcb_event_key_press(xcb_generic_event_t *event);
+static void _ecore_xcb_event_key_release(xcb_generic_event_t *event);
+static void _ecore_xcb_event_mouse_move_free(void *data __UNUSED__,
+ void *event);
+static Ecore_X_Event_Mode _ecore_xcb_event_mode_get(uint8_t mode);
+static Ecore_X_Event_Detail _ecore_xcb_event_detail_get(uint8_t detail);
+static void _ecore_xcb_event_xdnd_enter_free(void *data __UNUSED__,
+ void *event);
+static void _ecore_xcb_event_selection_notify_free(void *data __UNUSED__,
+ void *event);
+static void _ecore_xcb_event_generic_event_free(void *data,
+ void *event);
+static void _ecore_xcb_event_mouse_down_info_clear(void);
static Ecore_X_Mouse_Down_Info *_ecore_xcb_event_mouse_down_info_get(int dev);
/* local variables */
@@ -159,8 +163,8 @@ EAPI int ECORE_X_EVENT_STARTUP_SEQUENCE_CHANGE = 0;
EAPI int ECORE_X_EVENT_STARTUP_SEQUENCE_REMOVE = 0;
EAPI int ECORE_X_EVENT_GENERIC = 0;
-void
-_ecore_xcb_events_init(void)
+void
+_ecore_xcb_events_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -217,23 +221,23 @@ _ecore_xcb_events_init(void)
}
}
-void
-_ecore_xcb_events_shutdown(void)
+void
+_ecore_xcb_events_shutdown(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
_ecore_xcb_event_mouse_down_info_clear();
_ecore_xcb_event_last_mouse_move = EINA_FALSE;
-// if (_ecore_xcb_event_last_mouse_move_event)
+// if (_ecore_xcb_event_last_mouse_move_event)
// {
// ecore_event_del(_ecore_xcb_event_last_mouse_move_event);
// _ecore_xcb_event_last_mouse_move_event = NULL;
// }
}
-void
-_ecore_xcb_events_handle(xcb_generic_event_t *ev)
+void
+_ecore_xcb_events_handle(xcb_generic_event_t *ev)
{
uint8_t response = 0;
@@ -242,43 +246,43 @@ _ecore_xcb_events_handle(xcb_generic_event_t *ev)
/* strip highest bit (set if event is generated) */
response = (ev->response_type & ~0x80);
- if (response == 0)
+ if (response == 0)
{
xcb_generic_error_t *err;
err = (xcb_generic_error_t *)ev;
- /* NB: There is no way to check access of destroyed windows,
- * so trap those cases and ignore. We also ignore BadValue from
- * xcb_grab/ungrab_button (happens when we are using any_mod)
+ /* NB: There is no way to check access of destroyed windows,
+ * so trap those cases and ignore. We also ignore BadValue from
+ * xcb_grab/ungrab_button (happens when we are using any_mod)
* and a few others */
#ifdef OLD_XCB_VERSION
if (err->error_code == XCB_EVENT_ERROR_BAD_WINDOW) return;
- else if (err->error_code == XCB_EVENT_ERROR_BAD_MATCH)
+ else if (err->error_code == XCB_EVENT_ERROR_BAD_MATCH)
{
- if ((err->major_code == XCB_SET_INPUT_FOCUS) ||
+ if ((err->major_code == XCB_SET_INPUT_FOCUS) ||
(err->major_code == XCB_CONFIGURE_WINDOW))
return;
}
- else if (err->error_code == XCB_EVENT_ERROR_BAD_VALUE)
+ else if (err->error_code == XCB_EVENT_ERROR_BAD_VALUE)
{
- if ((err->major_code == XCB_KILL_CLIENT) ||
- (err->major_code == XCB_GRAB_BUTTON) ||
+ if ((err->major_code == XCB_KILL_CLIENT) ||
+ (err->major_code == XCB_GRAB_BUTTON) ||
(err->major_code == XCB_UNGRAB_BUTTON))
return;
}
#else
if (err->error_code == XCB_WINDOW) return;
- else if (err->error_code == XCB_MATCH)
+ else if (err->error_code == XCB_MATCH)
{
- if ((err->major_code == XCB_SET_INPUT_FOCUS) ||
+ if ((err->major_code == XCB_SET_INPUT_FOCUS) ||
(err->major_code == XCB_CONFIGURE_WINDOW))
return;
}
- else if (err->error_code == XCB_VALUE)
+ else if (err->error_code == XCB_VALUE)
{
- if ((err->major_code == XCB_KILL_CLIENT) ||
- (err->major_code == XCB_GRAB_BUTTON) ||
+ if ((err->major_code == XCB_KILL_CLIENT) ||
+ (err->major_code == XCB_GRAB_BUTTON) ||
(err->major_code == XCB_UNGRAB_BUTTON))
return;
}
@@ -293,7 +297,7 @@ _ecore_xcb_events_handle(xcb_generic_event_t *ev)
else if (err->error_code == 8) // bad match
WRN("\tMatch: %d", ((xcb_match_error_t *)err)->bad_value);
- if (err->major_code == XCB_SEND_EVENT)
+ if (err->major_code == XCB_SEND_EVENT)
{
WRN("\tSend Event Error");
WRN("\t\tSeq: %d", ev->sequence);
@@ -315,21 +319,21 @@ _ecore_xcb_events_handle(xcb_generic_event_t *ev)
_ecore_xcb_event_handle_key_press(ev);
else if (response == XCB_KEY_RELEASE)
_ecore_xcb_event_handle_key_release(ev);
- else if (response == XCB_BUTTON_PRESS)
+ else if (response == XCB_BUTTON_PRESS)
_ecore_xcb_event_handle_button_press(ev);
else if (response == XCB_BUTTON_RELEASE)
_ecore_xcb_event_handle_button_release(ev);
else if (response == XCB_MOTION_NOTIFY)
_ecore_xcb_event_handle_motion_notify(ev);
- else if (response == XCB_ENTER_NOTIFY)
+ else if (response == XCB_ENTER_NOTIFY)
_ecore_xcb_event_handle_enter_notify(ev);
- else if (response == XCB_LEAVE_NOTIFY)
+ else if (response == XCB_LEAVE_NOTIFY)
_ecore_xcb_event_handle_leave_notify(ev);
else if (response == XCB_KEYMAP_NOTIFY)
_ecore_xcb_event_handle_keymap_notify(ev);
- else if (response == XCB_FOCUS_IN)
+ else if (response == XCB_FOCUS_IN)
_ecore_xcb_event_handle_focus_in(ev);
- else if (response == XCB_FOCUS_OUT)
+ else if (response == XCB_FOCUS_OUT)
_ecore_xcb_event_handle_focus_out(ev);
else if (response == XCB_EXPOSE)
_ecore_xcb_event_handle_expose(ev);
@@ -341,17 +345,17 @@ _ecore_xcb_events_handle(xcb_generic_event_t *ev)
_ecore_xcb_event_handle_create_notify(ev);
else if (response == XCB_DESTROY_NOTIFY)
_ecore_xcb_event_handle_destroy_notify(ev);
- else if (response == XCB_MAP_NOTIFY)
+ else if (response == XCB_MAP_NOTIFY)
_ecore_xcb_event_handle_map_notify(ev);
- else if (response == XCB_UNMAP_NOTIFY)
+ else if (response == XCB_UNMAP_NOTIFY)
_ecore_xcb_event_handle_unmap_notify(ev);
else if (response == XCB_MAP_REQUEST)
_ecore_xcb_event_handle_map_request(ev);
else if (response == XCB_REPARENT_NOTIFY)
_ecore_xcb_event_handle_reparent_notify(ev);
- else if (response == XCB_CONFIGURE_NOTIFY)
+ else if (response == XCB_CONFIGURE_NOTIFY)
_ecore_xcb_event_handle_configure_notify(ev);
- else if (response == XCB_CONFIGURE_REQUEST)
+ else if (response == XCB_CONFIGURE_REQUEST)
_ecore_xcb_event_handle_configure_request(ev);
else if (response == XCB_GRAVITY_NOTIFY)
_ecore_xcb_event_handle_gravity_notify(ev);
@@ -371,66 +375,67 @@ _ecore_xcb_events_handle(xcb_generic_event_t *ev)
_ecore_xcb_event_handle_selection_notify(ev);
else if (response == XCB_COLORMAP_NOTIFY)
_ecore_xcb_event_handle_colormap_notify(ev);
- else if (response == XCB_CLIENT_MESSAGE)
+ else if (response == XCB_CLIENT_MESSAGE)
_ecore_xcb_event_handle_client_message(ev);
- else if (response == XCB_MAPPING_NOTIFY)
+ else if (response == XCB_MAPPING_NOTIFY)
_ecore_xcb_event_handle_mapping_notify(ev);
else if (response == 35) /* GenericEvent == 35 */
_ecore_xcb_event_handle_generic_event(ev);
#ifdef ECORE_XCB_DAMAGE
- else if ((_ecore_xcb_event_damage >= 0) &&
+ else if ((_ecore_xcb_event_damage >= 0) &&
(response == (_ecore_xcb_event_damage + XCB_DAMAGE_NOTIFY)))
_ecore_xcb_event_handle_damage_notify(ev);
#endif
#ifdef ECORE_XCB_RANDR
- else if ((_ecore_xcb_event_randr >= 0) &&
- (response ==
- _ecore_xcb_event_randr + XCB_RANDR_SCREEN_CHANGE_NOTIFY))
+ else if ((_ecore_xcb_event_randr >= 0) &&
+ (response ==
+ _ecore_xcb_event_randr + XCB_RANDR_SCREEN_CHANGE_NOTIFY))
_ecore_xcb_event_handle_randr_change(ev);
- else if ((_ecore_xcb_event_randr >= 0) &&
+ else if ((_ecore_xcb_event_randr >= 0) &&
(response == (_ecore_xcb_event_randr + XCB_RANDR_NOTIFY)))
_ecore_xcb_event_handle_randr_notify(ev);
#endif
#ifdef ECORE_XCB_SCREENSAVER
- else if ((_ecore_xcb_event_screensaver >= 0) &&
- (response ==
- _ecore_xcb_event_screensaver + XCB_SCREENSAVER_NOTIFY))
+ else if ((_ecore_xcb_event_screensaver >= 0) &&
+ (response ==
+ _ecore_xcb_event_screensaver + XCB_SCREENSAVER_NOTIFY))
_ecore_xcb_event_handle_screensaver_notify(ev);
#endif
#ifdef ECORE_XCB_SHAPE
- else if ((_ecore_xcb_event_shape >= 0) &&
+ else if ((_ecore_xcb_event_shape >= 0) &&
(response == (_ecore_xcb_event_shape + XCB_SHAPE_NOTIFY)))
_ecore_xcb_event_handle_shape_change(ev);
#endif
#ifdef ECORE_XCB_SYNC
- else if ((_ecore_xcb_event_sync >= 0) &&
+ else if ((_ecore_xcb_event_sync >= 0) &&
(response == (_ecore_xcb_event_sync + XCB_SYNC_COUNTER_NOTIFY)))
_ecore_xcb_event_handle_sync_counter(ev);
- else if ((_ecore_xcb_event_sync >= 0) &&
+ else if ((_ecore_xcb_event_sync >= 0) &&
(response == (_ecore_xcb_event_sync + XCB_SYNC_ALARM_NOTIFY)))
_ecore_xcb_event_handle_sync_alarm(ev);
#endif
#ifdef ECORE_XCB_XFIXES
- else if ((_ecore_xcb_event_xfixes >= 0) &&
- (response ==
- _ecore_xcb_event_xfixes + XCB_XFIXES_SELECTION_NOTIFY))
+ else if ((_ecore_xcb_event_xfixes >= 0) &&
+ (response ==
+ _ecore_xcb_event_xfixes + XCB_XFIXES_SELECTION_NOTIFY))
_ecore_xcb_event_handle_xfixes_selection_notify(ev);
- else if ((_ecore_xcb_event_xfixes >= 0) &&
+ else if ((_ecore_xcb_event_xfixes >= 0) &&
(response == (_ecore_xcb_event_xfixes + XCB_XFIXES_CURSOR_NOTIFY)))
_ecore_xcb_event_handle_xfixes_cursor_notify(ev);
#endif
}
-Ecore_X_Time
-_ecore_xcb_events_last_time_get(void)
+Ecore_X_Time
+_ecore_xcb_events_last_time_get(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
return _ecore_xcb_event_last_time;
}
-EAPI void
-ecore_x_event_mask_set(Ecore_X_Window win, Ecore_X_Event_Mask mask)
+EAPI void
+ecore_x_event_mask_set(Ecore_X_Window win,
+ Ecore_X_Event_Mask mask)
{
xcb_get_window_attributes_cookie_t cookie;
xcb_get_window_attributes_reply_t *reply;
@@ -446,13 +451,14 @@ ecore_x_event_mask_set(Ecore_X_Window win, Ecore_X_Event_Mask mask)
list = (mask | reply->your_event_mask);
free(reply);
- xcb_change_window_attributes(_ecore_xcb_conn, win,
+ xcb_change_window_attributes(_ecore_xcb_conn, win,
XCB_CW_EVENT_MASK, &list);
// ecore_x_flush();
}
-EAPI void
-ecore_x_event_mask_unset(Ecore_X_Window win, Ecore_X_Event_Mask mask)
+EAPI void
+ecore_x_event_mask_unset(Ecore_X_Window win,
+ Ecore_X_Event_Mask mask)
{
xcb_get_window_attributes_cookie_t cookie;
xcb_get_window_attributes_reply_t *reply;
@@ -468,13 +474,13 @@ ecore_x_event_mask_unset(Ecore_X_Window win, Ecore_X_Event_Mask mask)
list = (reply->your_event_mask & ~mask);
free(reply);
- xcb_change_window_attributes(_ecore_xcb_conn, win,
+ xcb_change_window_attributes(_ecore_xcb_conn, win,
XCB_CW_EVENT_MASK, &list);
// ecore_x_flush();
}
-unsigned int
-_ecore_xcb_events_modifiers_get(unsigned int state)
+unsigned int
+_ecore_xcb_events_modifiers_get(unsigned int state)
{
unsigned int modifiers = 0;
@@ -501,8 +507,8 @@ _ecore_xcb_events_modifiers_get(unsigned int state)
}
/* local functions */
-static void
-_ecore_xcb_event_handle_any_event(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_any_event(xcb_generic_event_t *event)
{
xcb_generic_event_t *ev;
@@ -515,27 +521,27 @@ _ecore_xcb_event_handle_any_event(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_ANY, ev, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_key_press(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_key_press(xcb_generic_event_t *event)
{
_ecore_xcb_event_key_press(event);
}
-static void
-_ecore_xcb_event_handle_key_release(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_key_release(xcb_generic_event_t *event)
{
_ecore_xcb_event_key_release(event);
}
-static void
-_ecore_xcb_event_handle_button_press(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_button_press(xcb_generic_event_t *event)
{
xcb_button_press_event_t *ev;
_ecore_xcb_event_last_mouse_move = EINA_FALSE;
ev = (xcb_button_press_event_t *)event;
- if ((ev->detail > 3) && (ev->detail < 8))
+ if ((ev->detail > 3) && (ev->detail < 8))
{
Ecore_Event_Mouse_Wheel *e;
@@ -543,24 +549,28 @@ _ecore_xcb_event_handle_button_press(xcb_generic_event_t *event)
e->timestamp = ev->time;
e->modifiers = _ecore_xcb_events_modifiers_get(ev->state);
- switch (ev->detail)
+ switch (ev->detail)
{
case 4:
e->direction = 0;
e->z = -1;
break;
+
case 5:
e->direction = 0;
e->z = 1;
break;
+
case 6:
e->direction = 1;
e->z = -1;
break;
+
case 7:
e->direction = 1;
e->z = 1;
break;
+
default:
e->direction = 0;
e->z = 0;
@@ -586,76 +596,76 @@ _ecore_xcb_event_handle_button_press(xcb_generic_event_t *event)
ecore_event_add(ECORE_EVENT_MOUSE_WHEEL, e, NULL, NULL);
- _ecore_xcb_window_grab_allow_events(ev->event, ev->child,
- ECORE_EVENT_MOUSE_WHEEL,
+ _ecore_xcb_window_grab_allow_events(ev->event, ev->child,
+ ECORE_EVENT_MOUSE_WHEEL,
e, ev->time);
}
- else
+ else
{
Ecore_Event_Mouse_Button *e;
unsigned int child_win = 0;
child_win = (ev->child ? ev->child : ev->event);
- _ecore_xcb_event_mouse_move(ev->time, ev->state,
- ev->event_x, ev->event_y,
- ev->root_x, ev->root_y,
- ev->event, child_win,
- ev->root, ev->same_screen,
- 0, 1, 1, 1.0, 0.0,
- ev->event_x, ev->event_y,
+ _ecore_xcb_event_mouse_move(ev->time, ev->state,
+ ev->event_x, ev->event_y,
+ ev->root_x, ev->root_y,
+ ev->event, child_win,
+ ev->root, ev->same_screen,
+ 0, 1, 1, 1.0, 0.0,
+ ev->event_x, ev->event_y,
ev->root_x, ev->root_y);
- e = _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_DOWN,
- ev->time,
- ev->state, ev->detail,
- ev->event_x, ev->event_y,
- ev->root_x, ev->root_y, ev->event,
- child_win,
- ev->root, ev->same_screen,
- 0, 1, 1, 1.0, 0.0,
- ev->event_x, ev->event_y,
+ e = _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_DOWN,
+ ev->time,
+ ev->state, ev->detail,
+ ev->event_x, ev->event_y,
+ ev->root_x, ev->root_y, ev->event,
+ child_win,
+ ev->root, ev->same_screen,
+ 0, 1, 1, 1.0, 0.0,
+ ev->event_x, ev->event_y,
ev->root_x, ev->root_y);
if (e)
- _ecore_xcb_window_grab_allow_events(ev->event, ev->child,
- ECORE_EVENT_MOUSE_BUTTON_DOWN,
+ _ecore_xcb_window_grab_allow_events(ev->event, ev->child,
+ ECORE_EVENT_MOUSE_BUTTON_DOWN,
e, ev->time);
}
}
-static void
-_ecore_xcb_event_handle_button_release(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_button_release(xcb_generic_event_t *event)
{
xcb_button_release_event_t *ev;
_ecore_xcb_event_last_mouse_move = EINA_FALSE;
ev = (xcb_button_release_event_t *)event;
- if ((ev->detail <= 3) || (ev->detail > 7))
+ if ((ev->detail <= 3) || (ev->detail > 7))
{
- _ecore_xcb_event_mouse_move(ev->time, ev->state,
- ev->event_x, ev->event_y,
- ev->root_x, ev->root_y,
- ev->event,
- (ev->child ? ev->child : ev->event),
- ev->root, ev->same_screen,
- 0, 1, 1, 1.0, 0.0,
- ev->event_x, ev->event_y,
+ _ecore_xcb_event_mouse_move(ev->time, ev->state,
+ ev->event_x, ev->event_y,
+ ev->root_x, ev->root_y,
+ ev->event,
+ (ev->child ? ev->child : ev->event),
+ ev->root, ev->same_screen,
+ 0, 1, 1, 1.0, 0.0,
+ ev->event_x, ev->event_y,
ev->root_x, ev->root_y);
- _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_UP, ev->time,
- ev->state, ev->detail,
- ev->event_x, ev->event_y, ev->root_x,
- ev->root_y, ev->event,
- (ev->child ? ev->child : ev->event),
- ev->root, ev->same_screen,
- 0, 1, 1, 1.0, 0.0,
- ev->event_x, ev->event_y,
+ _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_UP, ev->time,
+ ev->state, ev->detail,
+ ev->event_x, ev->event_y, ev->root_x,
+ ev->root_y, ev->event,
+ (ev->child ? ev->child : ev->event),
+ ev->root, ev->same_screen,
+ 0, 1, 1, 1.0, 0.0,
+ ev->event_x, ev->event_y,
ev->root_x, ev->root_y);
}
}
-static void
-_ecore_xcb_event_handle_motion_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_motion_notify(xcb_generic_event_t *event)
{
xcb_motion_notify_event_t *ev;
@@ -668,22 +678,22 @@ _ecore_xcb_event_handle_motion_notify(xcb_generic_event_t *event)
/* _ecore_xcb_event_last_mouse_move_event = NULL; */
/* } */
- _ecore_xcb_event_mouse_move(ev->time, ev->state,
- ev->event_x, ev->event_y,
- ev->root_x, ev->root_y,
- ev->event,
- (ev->child ? ev->child : ev->event),
- ev->root, ev->same_screen,
- 0, 1, 1, 1.0, 0.0,
- ev->event_x, ev->event_y,
+ _ecore_xcb_event_mouse_move(ev->time, ev->state,
+ ev->event_x, ev->event_y,
+ ev->root_x, ev->root_y,
+ ev->event,
+ (ev->child ? ev->child : ev->event),
+ ev->root, ev->same_screen,
+ 0, 1, 1, 1.0, 0.0,
+ ev->event_x, ev->event_y,
ev->root_x, ev->root_y);
_ecore_xcb_event_last_mouse_move = EINA_TRUE;
_ecore_xcb_dnd_drag(ev->root, ev->root_x, ev->root_y);
}
-static void
-_ecore_xcb_event_handle_enter_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_enter_notify(xcb_generic_event_t *event)
{
xcb_enter_notify_event_t *ev;
Ecore_X_Event_Mouse_In *e;
@@ -691,14 +701,14 @@ _ecore_xcb_event_handle_enter_notify(xcb_generic_event_t *event)
_ecore_xcb_event_last_mouse_move = EINA_FALSE;
ev = (xcb_enter_notify_event_t *)event;
- _ecore_xcb_event_mouse_move(ev->time, ev->state,
- ev->event_x, ev->event_y,
- ev->root_x, ev->root_y,
- ev->event,
- (ev->child ? ev->child : ev->event),
- ev->root, ev->same_screen_focus,
- 0, 1, 1, 1.0, 0.0,
- ev->event_x, ev->event_y,
+ _ecore_xcb_event_mouse_move(ev->time, ev->state,
+ ev->event_x, ev->event_y,
+ ev->root_x, ev->root_y,
+ ev->event,
+ (ev->child ? ev->child : ev->event),
+ ev->root, ev->same_screen_focus,
+ 0, 1, 1, 1.0, 0.0,
+ ev->event_x, ev->event_y,
ev->root_x, ev->root_y);
if (!(e = calloc(1, sizeof(Ecore_X_Event_Mouse_In)))) return;
@@ -723,8 +733,8 @@ _ecore_xcb_event_handle_enter_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_MOUSE_IN, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_leave_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_leave_notify(xcb_generic_event_t *event)
{
xcb_leave_notify_event_t *ev;
Ecore_X_Event_Mouse_Out *e;
@@ -732,14 +742,14 @@ _ecore_xcb_event_handle_leave_notify(xcb_generic_event_t *event)
_ecore_xcb_event_last_mouse_move = EINA_FALSE;
ev = (xcb_enter_notify_event_t *)event;
- _ecore_xcb_event_mouse_move(ev->time, ev->state,
- ev->event_x, ev->event_y,
- ev->root_x, ev->root_y,
- ev->event,
- (ev->child ? ev->child : ev->event),
- ev->root, ev->same_screen_focus,
- 0, 1, 1, 1.0, 0.0,
- ev->event_x, ev->event_y,
+ _ecore_xcb_event_mouse_move(ev->time, ev->state,
+ ev->event_x, ev->event_y,
+ ev->root_x, ev->root_y,
+ ev->event,
+ (ev->child ? ev->child : ev->event),
+ ev->root, ev->same_screen_focus,
+ 0, 1, 1, 1.0, 0.0,
+ ev->event_x, ev->event_y,
ev->root_x, ev->root_y);
if (!(e = calloc(1, sizeof(Ecore_X_Event_Mouse_Out)))) return;
@@ -768,17 +778,17 @@ _ecore_xcb_event_handle_leave_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_MOUSE_OUT, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_keymap_notify(xcb_generic_event_t *event __UNUSED__)
+static void
+_ecore_xcb_event_handle_keymap_notify(xcb_generic_event_t *event __UNUSED__)
{
// LOGFN(__FILE__, __LINE__, __FUNCTION__);
- // FIXME: handle this event type
- _ecore_xcb_event_last_mouse_move = EINA_FALSE;
+ // FIXME: handle this event type
+ _ecore_xcb_event_last_mouse_move = EINA_FALSE;
}
-static void
-_ecore_xcb_event_handle_focus_in(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_focus_in(xcb_generic_event_t *event)
{
xcb_focus_in_event_t *ev;
Ecore_X_Event_Window_Focus_In *e;
@@ -797,8 +807,8 @@ _ecore_xcb_event_handle_focus_in(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_FOCUS_IN, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_focus_out(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_focus_out(xcb_generic_event_t *event)
{
xcb_focus_out_event_t *ev;
Ecore_X_Event_Window_Focus_Out *e;
@@ -817,8 +827,8 @@ _ecore_xcb_event_handle_focus_out(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_FOCUS_OUT, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_expose(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_expose(xcb_generic_event_t *event)
{
xcb_expose_event_t *ev;
Ecore_X_Event_Window_Damage *e;
@@ -838,8 +848,8 @@ _ecore_xcb_event_handle_expose(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_DAMAGE, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_graphics_exposure(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_graphics_exposure(xcb_generic_event_t *event)
{
xcb_graphics_exposure_event_t *ev;
Ecore_X_Event_Window_Damage *e;
@@ -859,8 +869,8 @@ _ecore_xcb_event_handle_graphics_exposure(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_DAMAGE, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_visibility_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_visibility_notify(xcb_generic_event_t *event)
{
xcb_visibility_notify_event_t *ev;
Ecore_X_Event_Window_Visibility_Change *e;
@@ -880,8 +890,8 @@ _ecore_xcb_event_handle_visibility_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_VISIBILITY_CHANGE, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_create_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_create_notify(xcb_generic_event_t *event)
{
xcb_create_notify_event_t *ev;
Ecore_X_Event_Window_Create *e;
@@ -906,8 +916,8 @@ _ecore_xcb_event_handle_create_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_CREATE, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_destroy_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_destroy_notify(xcb_generic_event_t *event)
{
xcb_destroy_notify_event_t *ev;
Ecore_X_Event_Window_Destroy *e;
@@ -925,8 +935,8 @@ _ecore_xcb_event_handle_destroy_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_DESTROY, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_map_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_map_notify(xcb_generic_event_t *event)
{
xcb_map_notify_event_t *ev;
Ecore_X_Event_Window_Show *e;
@@ -942,8 +952,8 @@ _ecore_xcb_event_handle_map_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_SHOW, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_unmap_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_unmap_notify(xcb_generic_event_t *event)
{
xcb_unmap_notify_event_t *ev;
Ecore_X_Event_Window_Hide *e;
@@ -959,8 +969,8 @@ _ecore_xcb_event_handle_unmap_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_HIDE, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_map_request(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_map_request(xcb_generic_event_t *event)
{
xcb_map_request_event_t *ev;
Ecore_X_Event_Window_Show_Request *e;
@@ -976,8 +986,8 @@ _ecore_xcb_event_handle_map_request(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_SHOW_REQUEST, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_reparent_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_reparent_notify(xcb_generic_event_t *event)
{
xcb_reparent_notify_event_t *ev;
Ecore_X_Event_Window_Reparent *e;
@@ -994,8 +1004,8 @@ _ecore_xcb_event_handle_reparent_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_REPARENT, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_configure_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_configure_notify(xcb_generic_event_t *event)
{
xcb_configure_notify_event_t *ev;
Ecore_X_Event_Window_Configure *e;
@@ -1020,15 +1030,15 @@ _ecore_xcb_event_handle_configure_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_CONFIGURE, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_configure_request(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_configure_request(xcb_generic_event_t *event)
{
xcb_configure_request_event_t *ev;
Ecore_X_Event_Window_Configure_Request *e;
_ecore_xcb_event_last_mouse_move = EINA_FALSE;
ev = (xcb_configure_request_event_t *)event;
- if (!(e = calloc(1, sizeof(Ecore_X_Event_Window_Configure_Request))))
+ if (!(e = calloc(1, sizeof(Ecore_X_Event_Window_Configure_Request))))
return;
e->win = ev->window;
@@ -1040,20 +1050,24 @@ _ecore_xcb_event_handle_configure_request(xcb_generic_event_t *event)
e->h = ev->height;
e->border = ev->border_width;
e->value_mask = ev->value_mask;
- switch (ev->stack_mode)
+ switch (ev->stack_mode)
{
case XCB_STACK_MODE_ABOVE:
e->detail = ECORE_X_WINDOW_STACK_ABOVE;
break;
+
case XCB_STACK_MODE_BELOW:
e->detail = ECORE_X_WINDOW_STACK_BELOW;
break;
+
case XCB_STACK_MODE_TOP_IF:
e->detail = ECORE_X_WINDOW_STACK_TOP_IF;
break;
+
case XCB_STACK_MODE_BOTTOM_IF:
e->detail = ECORE_X_WINDOW_STACK_BOTTOM_IF;
break;
+
case XCB_STACK_MODE_OPPOSITE:
e->detail = ECORE_X_WINDOW_STACK_OPPOSITE;
break;
@@ -1063,8 +1077,8 @@ _ecore_xcb_event_handle_configure_request(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_CONFIGURE_REQUEST, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_gravity_notify(xcb_generic_event_t *event __UNUSED__)
+static void
+_ecore_xcb_event_handle_gravity_notify(xcb_generic_event_t *event __UNUSED__)
{
/*
xcb_gravity_notify_event_t *ev;
@@ -1079,11 +1093,11 @@ _ecore_xcb_event_handle_gravity_notify(xcb_generic_event_t *event __UNUSED__)
e->time = _ecore_xcb_event_last_time;
ecore_event_add(ECORE_X_EVENT_WINDOW_GRAVITY, e, NULL, NULL);
-*/
+ */
}
-static void
-_ecore_xcb_event_handle_resize_request(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_resize_request(xcb_generic_event_t *event)
{
xcb_resize_request_event_t *ev;
Ecore_X_Event_Window_Resize_Request *e;
@@ -1100,8 +1114,8 @@ _ecore_xcb_event_handle_resize_request(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_RESIZE_REQUEST, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_circulate_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_circulate_notify(xcb_generic_event_t *event)
{
xcb_circulate_notify_event_t *ev;
Ecore_X_Event_Window_Stack *e;
@@ -1121,8 +1135,8 @@ _ecore_xcb_event_handle_circulate_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_STACK, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_circulate_request(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_circulate_request(xcb_generic_event_t *event)
{
xcb_circulate_request_event_t *ev;
Ecore_X_Event_Window_Stack_Request *e;
@@ -1142,8 +1156,8 @@ _ecore_xcb_event_handle_circulate_request(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_STACK_REQUEST, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_property_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_property_notify(xcb_generic_event_t *event)
{
xcb_property_notify_event_t *ev;
Ecore_X_Event_Window_Property *e;
@@ -1160,8 +1174,8 @@ _ecore_xcb_event_handle_property_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_PROPERTY, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_selection_clear(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_selection_clear(xcb_generic_event_t *event)
{
xcb_selection_clear_event_t *ev;
Ecore_X_Event_Selection_Clear *e;
@@ -1188,8 +1202,8 @@ _ecore_xcb_event_handle_selection_clear(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_SELECTION_CLEAR, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_selection_request(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_selection_request(xcb_generic_event_t *event)
{
xcb_selection_request_event_t *ev;
Ecore_X_Event_Selection_Request *e;
@@ -1210,13 +1224,13 @@ _ecore_xcb_event_handle_selection_request(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_SELECTION_REQUEST, e, NULL, NULL);
- if ((sd = _ecore_xcb_selection_get(ev->selection)) &&
- (sd->win == ev->owner))
+ if ((sd = _ecore_xcb_selection_get(ev->selection)) &&
+ (sd->win == ev->owner))
{
Ecore_X_Selection_Intern *si;
si = _ecore_xcb_selection_get(ev->selection);
- if (si->data)
+ if (si->data)
{
Ecore_X_Atom property = XCB_NONE, type;
void *data = NULL;
@@ -1226,24 +1240,24 @@ _ecore_xcb_event_handle_selection_request(xcb_generic_event_t *event)
typesize = 8;
len = sd->length;
- if (!ecore_x_selection_convert(ev->selection, ev->target,
+ if (!ecore_x_selection_convert(ev->selection, ev->target,
&data, &len, &type, &typesize))
property = XCB_NONE;
else if (data)
{
- ecore_x_window_prop_property_set(ev->requestor, ev->property,
+ ecore_x_window_prop_property_set(ev->requestor, ev->property,
type, typesize, data, len);
property = ev->property;
free(data);
}
- ecore_x_selection_notify_send(ev->requestor, ev->selection,
+ ecore_x_selection_notify_send(ev->requestor, ev->selection,
ev->target, property, ev->time);
}
}
}
-static void
-_ecore_xcb_event_handle_selection_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_selection_notify(xcb_generic_event_t *event)
{
xcb_selection_notify_event_t *ev;
Ecore_X_Event_Selection_Notify *e;
@@ -1256,18 +1270,18 @@ _ecore_xcb_event_handle_selection_notify(xcb_generic_event_t *event)
_ecore_xcb_event_last_mouse_move = EINA_FALSE;
ev = (xcb_selection_notify_event_t *)event;
selection = ev->selection;
- if (ev->target == ECORE_X_ATOM_SELECTION_TARGETS)
+ if (ev->target == ECORE_X_ATOM_SELECTION_TARGETS)
{
- format =
- ecore_x_window_prop_property_get(ev->requestor, ev->property,
+ format =
+ ecore_x_window_prop_property_get(ev->requestor, ev->property,
XCB_ATOM_ATOM, 32, &data, &num);
if (!format) return;
}
- else
+ else
{
- format =
- ecore_x_window_prop_property_get(ev->requestor, ev->property,
- XCB_GET_PROPERTY_TYPE_ANY, 8,
+ format =
+ ecore_x_window_prop_property_get(ev->requestor, ev->property,
+ XCB_GET_PROPERTY_TYPE_ANY, 8,
&data, &num);
if (!format) return;
}
@@ -1292,12 +1306,12 @@ _ecore_xcb_event_handle_selection_notify(xcb_generic_event_t *event)
e->data = _ecore_xcb_selection_parse(e->target, data, num, format);
- ecore_event_add(ECORE_X_EVENT_SELECTION_NOTIFY, e,
+ ecore_event_add(ECORE_X_EVENT_SELECTION_NOTIFY, e,
_ecore_xcb_event_selection_notify_free, NULL);
}
-static void
-_ecore_xcb_event_handle_colormap_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_colormap_notify(xcb_generic_event_t *event)
{
xcb_colormap_notify_event_t *ev;
Ecore_X_Event_Window_Colormap *e;
@@ -1317,8 +1331,8 @@ _ecore_xcb_event_handle_colormap_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_COLORMAP, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
{
xcb_client_message_event_t *ev;
@@ -1330,8 +1344,8 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
/* otherwise generate generic client message event. this would handle*/
/* netwm, ICCCM, gnomewm, old kde and mwm hint client message protocols */
- if ((ev->type == ECORE_X_ATOM_WM_PROTOCOLS) && (ev->format == 32) &&
- (ev->data.data32[0] == ECORE_X_ATOM_WM_DELETE_WINDOW))
+ if ((ev->type == ECORE_X_ATOM_WM_PROTOCOLS) && (ev->format == 32) &&
+ (ev->data.data32[0] == ECORE_X_ATOM_WM_DELETE_WINDOW))
{
Ecore_X_Event_Window_Delete_Request *e;
@@ -1341,8 +1355,8 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->time = _ecore_xcb_event_last_time;
ecore_event_add(ECORE_X_EVENT_WINDOW_DELETE_REQUEST, e, NULL, NULL);
}
- else if ((ev->type == ECORE_X_ATOM_NET_WM_MOVERESIZE) &&
- (ev->format == 32) && (ev->data.data32[2] < 9))
+ else if ((ev->type == ECORE_X_ATOM_NET_WM_MOVERESIZE) &&
+ (ev->format == 32) && (ev->data.data32[2] < 9))
{
Ecore_X_Event_Window_Move_Resize_Request *e;
@@ -1356,7 +1370,7 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->source = ev->data.data32[4];
ecore_event_add(ECORE_X_EVENT_WINDOW_MOVE_RESIZE_REQUEST, e, NULL, NULL);
}
- else if (ev->type == ECORE_X_ATOM_XDND_ENTER)
+ else if (ev->type == ECORE_X_ATOM_XDND_ENTER)
{
Ecore_X_Event_Xdnd_Enter *e;
Ecore_X_DND_Target *target;
@@ -1368,23 +1382,23 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
target->source = ev->data.data32[0];
target->win = ev->window;
target->version = (int)(ev->data.data32[1] >> 24);
- if (target->version > ECORE_X_DND_VERSION)
+ if (target->version > ECORE_X_DND_VERSION)
{
- WRN("DND: Requested version %d but we only support up to %d",
+ WRN("DND: Requested version %d but we only support up to %d",
target->version, ECORE_X_DND_VERSION);
free(e);
return;
}
- if (ev->data.data32[1] & 0x1UL)
+ if (ev->data.data32[1] & 0x1UL)
{
unsigned char *data;
Ecore_X_Atom *types;
int num_ret = 0;
- if (!ecore_x_window_prop_property_get(target->source,
- ECORE_X_ATOM_XDND_TYPE_LIST,
- ECORE_X_ATOM_ATOM, 32,
- &data, &num_ret))
+ if (!ecore_x_window_prop_property_get(target->source,
+ ECORE_X_ATOM_XDND_TYPE_LIST,
+ ECORE_X_ATOM_ATOM, 32,
+ &data, &num_ret))
{
WRN("DND: Could not fetch data type list from source window");
free(e);
@@ -1392,7 +1406,7 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
}
types = (Ecore_X_Atom *)data;
e->types = calloc(num_ret, sizeof(char *));
- if (e->types)
+ if (e->types)
{
int i = 0;
@@ -1401,16 +1415,16 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
}
e->num_types = num_ret;
}
- else
+ else
{
int i = 0;
e->types = calloc(3, sizeof(char *));
- if (e->types)
+ if (e->types)
{
- while ((i < 3) && (ev->data.data32[i + 2]))
+ while ((i < 3) && (ev->data.data32[i + 2]))
{
- e->types[i] =
+ e->types[i] =
ecore_x_atom_name_get(ev->data.data32[i + 2]);
i++;
}
@@ -1420,22 +1434,22 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->win = target->win;
e->source = target->source;
- ecore_event_add(ECORE_X_EVENT_XDND_ENTER, e,
+ ecore_event_add(ECORE_X_EVENT_XDND_ENTER, e,
_ecore_xcb_event_xdnd_enter_free, NULL);
}
- else if (ev->type == ECORE_X_ATOM_XDND_POSITION)
+ else if (ev->type == ECORE_X_ATOM_XDND_POSITION)
{
Ecore_X_Event_Xdnd_Position *e;
Ecore_X_DND_Target *target;
DBG("Got Xdnd Position Event");
target = _ecore_xcb_dnd_target_get();
- if ((target->source != (Ecore_X_Window)ev->data.data32[0]) ||
+ if ((target->source != (Ecore_X_Window)ev->data.data32[0]) ||
(target->win != ev->window)) return;
target->pos.x = ev->data.data32[2] >> 16;
target->pos.y = ev->data.data32[2] & 0xFFFFUL;
target->action = ev->data.data32[4];
- target->time = (target->version >= 1) ?
+ target->time = (target->version >= 1) ?
(Ecore_X_Time)ev->data.data32[3] : XCB_CURRENT_TIME;
e = calloc(1, sizeof(Ecore_X_Event_Xdnd_Position));
@@ -1447,14 +1461,14 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->action = target->action;
ecore_event_add(ECORE_X_EVENT_XDND_POSITION, e, NULL, NULL);
}
- else if (ev->type == ECORE_X_ATOM_XDND_STATUS)
+ else if (ev->type == ECORE_X_ATOM_XDND_STATUS)
{
Ecore_X_Event_Xdnd_Status *e;
Ecore_X_DND_Source *source;
DBG("Got Xdnd Status Event");
source = _ecore_xcb_dnd_source_get();
- if ((source->win != ev->window) ||
+ if ((source->win != ev->window) ||
(source->dest != (Ecore_X_Window)ev->data.data32[0]))
return;
@@ -1480,15 +1494,15 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_XDND_STATUS, e, NULL, NULL);
}
- else if (ev->type == ECORE_X_ATOM_XDND_LEAVE)
+ else if (ev->type == ECORE_X_ATOM_XDND_LEAVE)
{
Ecore_X_Event_Xdnd_Leave *e;
Ecore_X_DND_Target *target;
DBG("Got Xdnd Leave Event");
target = _ecore_xcb_dnd_target_get();
- if ((target->source != (Ecore_X_Window)ev->data.data32[0]) ||
- (target->win != ev->window))
+ if ((target->source != (Ecore_X_Window)ev->data.data32[0]) ||
+ (target->win != ev->window))
return;
target->state = ECORE_X_DND_TARGET_IDLE;
e = calloc(1, sizeof(Ecore_X_Event_Xdnd_Leave));
@@ -1497,17 +1511,17 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->source = (Ecore_X_Window)ev->data.data32[0];
ecore_event_add(ECORE_X_EVENT_XDND_LEAVE, e, NULL, NULL);
}
- else if (ev->type == ECORE_X_ATOM_XDND_DROP)
+ else if (ev->type == ECORE_X_ATOM_XDND_DROP)
{
Ecore_X_Event_Xdnd_Drop *e;
Ecore_X_DND_Target *target;
DBG("Got Xdnd Drop Event");
target = _ecore_xcb_dnd_target_get();
- if ((target->source != (Ecore_X_Window)ev->data.data32[0]) ||
+ if ((target->source != (Ecore_X_Window)ev->data.data32[0]) ||
(target->win != ev->window))
return;
- target->time = (target->version >= 1) ?
+ target->time = (target->version >= 1) ?
(Ecore_X_Time)ev->data.data32[2] : _ecore_xcb_event_last_time;
e = calloc(1, sizeof(Ecore_X_Event_Xdnd_Drop));
@@ -1519,7 +1533,7 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->position.y = target->pos.y;
ecore_event_add(ECORE_X_EVENT_XDND_DROP, e, NULL, NULL);
}
- else if (ev->type == ECORE_X_ATOM_XDND_FINISHED)
+ else if (ev->type == ECORE_X_ATOM_XDND_FINISHED)
{
Ecore_X_Event_Xdnd_Finished *e;
Ecore_X_DND_Source *source;
@@ -1527,19 +1541,19 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
DBG("Got Xdnd Finished Event");
source = _ecore_xcb_dnd_source_get();
- if ((source->win != ev->window) ||
+ if ((source->win != ev->window) ||
(source->dest != (Ecore_X_Window)ev->data.data32[0]))
return;
- if ((source->version < 5) || (ev->data.data32[1] & 0x1UL))
+ if ((source->version < 5) || (ev->data.data32[1] & 0x1UL))
{
ecore_x_selection_xdnd_clear();
source->state = ECORE_X_DND_SOURCE_IDLE;
}
- else if (source->version >= 5)
+ else if (source->version >= 5)
{
completed = EINA_FALSE;
source->state = ECORE_X_DND_SOURCE_CONVERTING;
- /* FIXME: Probably need to add a timer to switch back to idle
+ /* FIXME: Probably need to add a timer to switch back to idle
* and discard the selection data */
}
@@ -1548,19 +1562,19 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->win = source->win;
e->target = source->dest;
e->completed = completed;
- if (source->version >= 5)
+ if (source->version >= 5)
{
source->accepted_action = ev->data.data32[2];
e->action = source->accepted_action;
}
- else
+ else
{
source->accepted_action = 0;
e->action = source->action;
}
ecore_event_add(ECORE_X_EVENT_XDND_FINISHED, e, NULL, NULL);
}
- else if (ev->type == ECORE_X_ATOM_NET_WM_STATE)
+ else if (ev->type == ECORE_X_ATOM_NET_WM_STATE)
{
Ecore_X_Event_Window_State_Request *e;
@@ -1573,18 +1587,18 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->action = ECORE_X_WINDOW_STATE_ACTION_ADD;
else if (ev->data.data32[0] == 2)
e->action = ECORE_X_WINDOW_STATE_ACTION_TOGGLE;
- else
+ else
{
free(e);
return;
}
e->state[0] = _ecore_xcb_netwm_window_state_get(ev->data.data32[1]);
- if (e->state[0] == ECORE_X_WINDOW_STATE_UNKNOWN)
+ if (e->state[0] == ECORE_X_WINDOW_STATE_UNKNOWN)
{
/* FIXME */
}
e->state[1] = _ecore_xcb_netwm_window_state_get(ev->data.data32[2]);
- if (e->state[1] == ECORE_X_WINDOW_STATE_UNKNOWN)
+ if (e->state[1] == ECORE_X_WINDOW_STATE_UNKNOWN)
{
/* FIXME */
}
@@ -1592,11 +1606,11 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_STATE_REQUEST, e, NULL, NULL);
}
#ifdef OLD_XCB_VERSION
- else if ((ev->type == ECORE_X_ATOM_WM_CHANGE_STATE) &&
- (ev->format == 32) && (ev->data.data32[0] == XCB_WM_STATE_ICONIC))
+ else if ((ev->type == ECORE_X_ATOM_WM_CHANGE_STATE) &&
+ (ev->format == 32) && (ev->data.data32[0] == XCB_WM_STATE_ICONIC))
#else
- else if ((ev->type == ECORE_X_ATOM_WM_CHANGE_STATE) && (ev->format == 32) &&
- (ev->data.data32[0] == XCB_ICCCM_WM_STATE_ICONIC))
+ else if ((ev->type == ECORE_X_ATOM_WM_CHANGE_STATE) && (ev->format == 32) &&
+ (ev->data.data32[0] == XCB_ICCCM_WM_STATE_ICONIC))
#endif
{
Ecore_X_Event_Window_State_Request *e;
@@ -1608,7 +1622,7 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->state[0] = ECORE_X_WINDOW_STATE_ICONIFIED;
ecore_event_add(ECORE_X_EVENT_WINDOW_STATE_REQUEST, e, NULL, NULL);
}
- else if ((ev->type == ECORE_X_ATOM_NET_WM_DESKTOP) && (ev->format == 32))
+ else if ((ev->type == ECORE_X_ATOM_NET_WM_DESKTOP) && (ev->format == 32))
{
Ecore_X_Event_Desktop_Change *e;
@@ -1619,7 +1633,7 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->source = ev->data.data32[1];
ecore_event_add(ECORE_X_EVENT_DESKTOP_CHANGE, e, NULL, NULL);
}
- else if (ev->type == ECORE_X_ATOM_NET_REQUEST_FRAME_EXTENTS)
+ else if (ev->type == ECORE_X_ATOM_NET_REQUEST_FRAME_EXTENTS)
{
Ecore_X_Event_Frame_Extents_Request *e;
@@ -1628,9 +1642,9 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
e->win = ev->window;
ecore_event_add(ECORE_X_EVENT_FRAME_EXTENTS_REQUEST, e, NULL, NULL);
}
- else if ((ev->type == ECORE_X_ATOM_WM_PROTOCOLS) &&
- ((Ecore_X_Atom)ev->data.data32[0] == ECORE_X_ATOM_NET_WM_PING) &&
- (ev->format == 32))
+ else if ((ev->type == ECORE_X_ATOM_WM_PROTOCOLS) &&
+ ((Ecore_X_Atom)ev->data.data32[0] == ECORE_X_ATOM_NET_WM_PING) &&
+ (ev->format == 32))
{
Ecore_X_Event_Ping *e;
Ecore_X_Window root = 0;
@@ -1645,39 +1659,39 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
CHECK_XCB_CONN;
count = xcb_setup_roots_length(xcb_get_setup(_ecore_xcb_conn));
- if (count > 1)
+ if (count > 1)
root = ecore_x_window_root_get(e->win);
- else
+ else
root = ((xcb_screen_t *)_ecore_xcb_screen)->root;
- if (ev->window != root)
+ if (ev->window != root)
{
ev->window = root;
- xcb_send_event(_ecore_xcb_conn, 0, root,
- (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
- XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY),
+ xcb_send_event(_ecore_xcb_conn, 0, root,
+ (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
+ XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY),
(const char *)&ev);
// ecore_x_flush();
}
}
- else if ((ev->type == ECORE_X_ATOM_NET_STARTUP_INFO_BEGIN) &&
- (ev->format == 8))
+ else if ((ev->type == ECORE_X_ATOM_NET_STARTUP_INFO_BEGIN) &&
+ (ev->format == 8))
{
_ecore_xcb_netwm_startup_info_begin(ev->window, ev->data.data8[0]);
}
- else if ((ev->type == ECORE_X_ATOM_NET_STARTUP_INFO) && (ev->format == 8))
+ else if ((ev->type == ECORE_X_ATOM_NET_STARTUP_INFO) && (ev->format == 8))
{
_ecore_xcb_netwm_startup_info(ev->window, ev->data.data8[0]);
}
- else if ((ev->type == 27777) && (ev->data.data32[0] == 0x7162534) &&
- (ev->format == 32)) // && (ev->window = _private_window))
+ else if ((ev->type == 27777) && (ev->data.data32[0] == 0x7162534) &&
+ (ev->format == 32)) // && (ev->window = _private_window))
{
if (ev->data.data32[1] == 0x10000001)
_ecore_xcb_window_button_grab_remove(ev->data.data32[2]);
- else if (ev->data.data32[1] == 0x10000002)
+ else if (ev->data.data32[1] == 0x10000002)
_ecore_xcb_window_key_grab_remove(ev->data.data32[2]);
}
- else
+ else
{
Ecore_X_Event_Client_Message *e;
int i = 0;
@@ -1694,8 +1708,8 @@ _ecore_xcb_event_handle_client_message(xcb_generic_event_t *event)
}
}
-static void
-_ecore_xcb_event_handle_mapping_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_mapping_notify(xcb_generic_event_t *event)
{
xcb_mapping_notify_event_t *ev;
Ecore_X_Event_Mapping_Change *e;
@@ -1707,15 +1721,17 @@ _ecore_xcb_event_handle_mapping_notify(xcb_generic_event_t *event)
_ecore_xcb_keymap_refresh(ev);
_ecore_xcb_modifiers_get();
-
- switch (ev->request)
+
+ switch (ev->request)
{
case XCB_MAPPING_MODIFIER:
e->type = ECORE_X_MAPPING_MODIFIER;
break;
+
case XCB_MAPPING_KEYBOARD:
e->type = ECORE_X_MAPPING_KEYBOARD;
break;
+
case XCB_MAPPING_POINTER:
default:
e->type = ECORE_X_MAPPING_MOUSE;
@@ -1727,8 +1743,8 @@ _ecore_xcb_event_handle_mapping_notify(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_MAPPING_CHANGE, e, NULL, NULL);
}
-static void
-_ecore_xcb_event_handle_damage_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_damage_notify(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_DAMAGE
xcb_damage_notify_event_t *ev;
@@ -1759,8 +1775,8 @@ _ecore_xcb_event_handle_damage_notify(xcb_generic_event_t *event)
#endif
}
-static void
-_ecore_xcb_event_handle_randr_change(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_randr_change(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_RANDR
xcb_randr_screen_change_notify_event_t *ev;
@@ -1787,8 +1803,8 @@ _ecore_xcb_event_handle_randr_change(xcb_generic_event_t *event)
#endif
}
-static void
-_ecore_xcb_event_handle_randr_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_randr_notify(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_RANDR
xcb_randr_notify_event_t *ev;
@@ -1797,25 +1813,28 @@ _ecore_xcb_event_handle_randr_notify(xcb_generic_event_t *event)
_ecore_xcb_event_last_mouse_move = EINA_FALSE;
#ifdef ECORE_XCB_RANDR
ev = (xcb_randr_notify_event_t *)event;
- switch (ev->subCode)
+ switch (ev->subCode)
{
case XCB_RANDR_NOTIFY_CRTC_CHANGE:
_ecore_xcb_event_handle_randr_crtc_change(event);
break;
+
case XCB_RANDR_NOTIFY_OUTPUT_CHANGE:
_ecore_xcb_event_handle_randr_output_change(event);
break;
+
case XCB_RANDR_NOTIFY_OUTPUT_PROPERTY:
_ecore_xcb_event_handle_randr_output_property_change(event);
break;
+
default:
break;
}
#endif
}
-static void
-_ecore_xcb_event_handle_randr_crtc_change(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_randr_crtc_change(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_RANDR
xcb_randr_notify_event_t *ev;
@@ -1840,8 +1859,8 @@ _ecore_xcb_event_handle_randr_crtc_change(xcb_generic_event_t *event)
#endif
}
-static void
-_ecore_xcb_event_handle_randr_output_change(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_randr_output_change(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_RANDR
xcb_randr_notify_event_t *ev;
@@ -1865,8 +1884,8 @@ _ecore_xcb_event_handle_randr_output_change(xcb_generic_event_t *event)
#endif
}
-static void
-_ecore_xcb_event_handle_randr_output_property_change(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_randr_output_property_change(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_RANDR
xcb_randr_notify_event_t *ev;
@@ -1891,8 +1910,8 @@ _ecore_xcb_event_handle_randr_output_property_change(xcb_generic_event_t *event)
#endif
}
-static void
-_ecore_xcb_event_handle_screensaver_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_screensaver_notify(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_SCREENSAVER
xcb_screensaver_notify_event_t *ev;
@@ -1914,8 +1933,8 @@ _ecore_xcb_event_handle_screensaver_notify(xcb_generic_event_t *event)
}
#ifdef ECORE_XCB_SHAPE
-static void
-_ecore_xcb_event_handle_shape_change(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_shape_change(xcb_generic_event_t *event)
{
xcb_shape_notify_event_t *ev;
Ecore_X_Event_Window_Shape *e;
@@ -1926,17 +1945,20 @@ _ecore_xcb_event_handle_shape_change(xcb_generic_event_t *event)
e->win = ev->affected_window;
e->time = ev->server_time;
- switch (ev->shape_kind)
+ switch (ev->shape_kind)
{
case XCB_SHAPE_SK_BOUNDING:
e->type = ECORE_X_SHAPE_BOUNDING;
break;
+
case XCB_SHAPE_SK_CLIP:
e->type = ECORE_X_SHAPE_CLIP;
break;
+
case XCB_SHAPE_SK_INPUT:
e->type = ECORE_X_SHAPE_INPUT;
break;
+
default:
break;
}
@@ -1948,10 +1970,11 @@ _ecore_xcb_event_handle_shape_change(xcb_generic_event_t *event)
ecore_event_add(ECORE_X_EVENT_WINDOW_SHAPE, e, NULL, NULL);
}
+
#endif
-static void
-_ecore_xcb_event_handle_sync_counter(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_sync_counter(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_SYNC
xcb_sync_counter_notify_event_t *ev;
@@ -1970,8 +1993,8 @@ _ecore_xcb_event_handle_sync_counter(xcb_generic_event_t *event)
#endif
}
-static void
-_ecore_xcb_event_handle_sync_alarm(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_sync_alarm(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_SYNC
xcb_sync_alarm_notify_event_t *ev;
@@ -1990,8 +2013,8 @@ _ecore_xcb_event_handle_sync_alarm(xcb_generic_event_t *event)
#endif
}
-static void
-_ecore_xcb_event_handle_xfixes_selection_notify(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_xfixes_selection_notify(xcb_generic_event_t *event)
{
#ifdef ECORE_XCB_XFIXES
Ecore_X_Event_Fixes_Selection_Notify *e;
@@ -2024,15 +2047,15 @@ _ecore_xcb_event_handle_xfixes_selection_notify(xcb_generic_event_t *event)
#endif
}
-static void
-_ecore_xcb_event_handle_xfixes_cursor_notify(xcb_generic_event_t *event __UNUSED__)
+static void
+_ecore_xcb_event_handle_xfixes_cursor_notify(xcb_generic_event_t *event __UNUSED__)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
// FIXME: TBD
}
-static void
-_ecore_xcb_event_handle_generic_event(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_generic_event(xcb_generic_event_t *event)
{
xcb_ge_event_t *ev;
Ecore_X_Event_Generic *e;
@@ -2043,7 +2066,7 @@ _ecore_xcb_event_handle_generic_event(xcb_generic_event_t *event)
if (ev->pad0 == _ecore_xcb_event_input)
{
_ecore_xcb_event_handle_input_event(event);
-// FIXME: should we generate generic events as WELL as input events?
+// FIXME: should we generate generic events as WELL as input events?
// return;
}
@@ -2053,9 +2076,9 @@ _ecore_xcb_event_handle_generic_event(xcb_generic_event_t *event)
DBG("Handle Generic Event: %d", ev->event_type);
e->cookie = ev->sequence;
- /* NB: These are bugs in xcb ge_event structure. The struct should have a
- * field for extension & data, but does not.
- *
+ /* NB: These are bugs in xcb ge_event structure. The struct should have a
+ * field for extension & data, but does not.
+ *
* XCB people have been notified of this issue */
e->extension = ev->pad0;
/* e->data = ev->pad1; */
@@ -2068,20 +2091,20 @@ _ecore_xcb_event_handle_generic_event(xcb_generic_event_t *event)
e->evtype = ev->event_type;
- ecore_event_add(ECORE_X_EVENT_GENERIC, e,
+ ecore_event_add(ECORE_X_EVENT_GENERIC, e,
_ecore_xcb_event_generic_event_free, e->data);
}
-static void
-_ecore_xcb_event_handle_input_event(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_handle_input_event(xcb_generic_event_t *event)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
_ecore_xcb_input_handle_event(event);
}
-static void
-_ecore_xcb_event_key_press(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_key_press(xcb_generic_event_t *event)
{
Ecore_Event_Key *e;
xcb_keysym_t sym = XCB_NO_SYMBOL;
@@ -2099,7 +2122,7 @@ _ecore_xcb_event_key_press(xcb_generic_event_t *event)
sym = _ecore_xcb_keymap_keycode_to_keysym(keycode, xevent->state);
keyname = _ecore_xcb_keymap_keysym_to_string(sym);
- if (!keyname)
+ if (!keyname)
{
char buff[256];
@@ -2107,13 +2130,13 @@ _ecore_xcb_event_key_press(xcb_generic_event_t *event)
keyname = buff;
}
- val =
- _ecore_xcb_keymap_lookup_string(keycode, xevent->state, compose_buffer,
+ val =
+ _ecore_xcb_keymap_lookup_string(keycode, xevent->state, compose_buffer,
sizeof(compose_buffer), &sym);
- if (val > 0)
+ if (val > 0)
{
compose_buffer[val] = 0;
- compose =
+ compose =
eina_str_convert(nl_langinfo(CODESET), "UTF-8", compose_buffer);
// tmp = compose;
}
@@ -2121,9 +2144,9 @@ _ecore_xcb_event_key_press(xcb_generic_event_t *event)
key = _ecore_xcb_keymap_keysym_to_string(sym);
if (!key) key = keyname;
- e = malloc(sizeof(Ecore_Event_Key) + strlen(key) + strlen(keyname) +
+ e = malloc(sizeof(Ecore_Event_Key) + strlen(key) + strlen(keyname) +
(compose ? strlen(compose) : 0) + 3);
- if (e)
+ if (e)
{
e->keyname = (char *)(e + 1);
e->key = e->keyname + strlen(keyname) + 1;
@@ -2149,8 +2172,8 @@ _ecore_xcb_event_key_press(xcb_generic_event_t *event)
_ecore_xcb_event_last_time = xevent->time;
}
-static void
-_ecore_xcb_event_key_release(xcb_generic_event_t *event)
+static void
+_ecore_xcb_event_key_release(xcb_generic_event_t *event)
{
Ecore_Event_Key *e;
xcb_keysym_t sym = XCB_NO_SYMBOL;
@@ -2168,7 +2191,7 @@ _ecore_xcb_event_key_release(xcb_generic_event_t *event)
sym = _ecore_xcb_keymap_keycode_to_keysym(keycode, xevent->state);
keyname = _ecore_xcb_keymap_keysym_to_string(sym);
- if (!keyname)
+ if (!keyname)
{
char buff[256];
@@ -2176,13 +2199,13 @@ _ecore_xcb_event_key_release(xcb_generic_event_t *event)
keyname = buff;
}
- val =
- _ecore_xcb_keymap_lookup_string(keycode, xevent->state, compose_buffer,
+ val =
+ _ecore_xcb_keymap_lookup_string(keycode, xevent->state, compose_buffer,
sizeof(compose_buffer), &sym);
- if (val > 0)
+ if (val > 0)
{
compose_buffer[val] = 0;
- compose =
+ compose =
eina_str_convert(nl_langinfo(CODESET), "UTF-8", compose_buffer);
// tmp = compose;
}
@@ -2190,9 +2213,9 @@ _ecore_xcb_event_key_release(xcb_generic_event_t *event)
key = _ecore_xcb_keymap_keysym_to_string(sym);
if (!key) key = keyname;
- e = malloc(sizeof(Ecore_Event_Key) + strlen(key) + strlen(keyname) +
+ e = malloc(sizeof(Ecore_Event_Key) + strlen(key) + strlen(keyname) +
(compose ? strlen(compose) : 0) + 3);
- if (e)
+ if (e)
{
e->keyname = (char *)(e + 1);
e->key = e->keyname + strlen(keyname) + 1;
@@ -2217,8 +2240,26 @@ _ecore_xcb_event_key_release(xcb_generic_event_t *event)
_ecore_xcb_event_last_time = xevent->time;
}
-void
-_ecore_xcb_event_mouse_move(uint16_t timestamp, uint16_t modifiers, int16_t x, int16_t y, int16_t root_x, int16_t root_y, xcb_window_t event_win, xcb_window_t win, xcb_window_t root_win, uint8_t same_screen, int dev, double radx, double rady, double pressure, double angle, int16_t mx, int16_t my, int16_t mrx, int16_t mry)
+void
+_ecore_xcb_event_mouse_move(uint16_t timestamp,
+ uint16_t modifiers,
+ int16_t x,
+ int16_t y,
+ int16_t root_x,
+ int16_t root_y,
+ xcb_window_t event_win,
+ xcb_window_t win,
+ xcb_window_t root_win,
+ uint8_t same_screen,
+ int dev,
+ double radx,
+ double rady,
+ double pressure,
+ double angle,
+ int16_t mx,
+ int16_t my,
+ int16_t mrx,
+ int16_t mry)
{
Ecore_Event_Mouse_Move *e;
Ecore_Event *event;
@@ -2246,7 +2287,7 @@ _ecore_xcb_event_mouse_move(uint16_t timestamp, uint16_t modifiers, int16_t x, i
e->multi.root.x = mrx;
e->multi.root.y = mry;
- event = ecore_event_add(ECORE_EVENT_MOUSE_MOVE, e,
+ event = ecore_event_add(ECORE_EVENT_MOUSE_MOVE, e,
_ecore_xcb_event_mouse_move_free, NULL);
_ecore_xcb_event_last_time = e->timestamp;
@@ -2256,13 +2297,14 @@ _ecore_xcb_event_mouse_move(uint16_t timestamp, uint16_t modifiers, int16_t x, i
// _ecore_xcb_event_last_mouse_move_event = event;
}
-static void
-_ecore_xcb_event_mouse_move_free(void *data __UNUSED__, void *event)
+static void
+_ecore_xcb_event_mouse_move_free(void *data __UNUSED__,
+ void *event)
{
Ecore_Event_Mouse_Move *ev;
ev = event;
-// if (_ecore_xcb_event_last_mouse_move_event)
+// if (_ecore_xcb_event_last_mouse_move_event)
// {
// _ecore_xcb_event_last_mouse_move = EINA_FALSE;
// _ecore_xcb_event_last_mouse_move_event = NULL;
@@ -2271,7 +2313,27 @@ _ecore_xcb_event_mouse_move_free(void *data __UNUSED__, void *event)
}
Ecore_Event_Mouse_Button *
-_ecore_xcb_event_mouse_button(int event, uint16_t timestamp, uint16_t modifiers, xcb_button_t buttons, int16_t x, int16_t y, int16_t root_x, int16_t root_y, xcb_window_t event_win, xcb_window_t win, xcb_window_t root_win, uint8_t same_screen, int dev, double radx, double rady, double pressure, double angle, int16_t mx, int16_t my, int16_t mrx, int16_t mry)
+_ecore_xcb_event_mouse_button(int event,
+ uint16_t timestamp,
+ uint16_t modifiers,
+ xcb_button_t buttons,
+ int16_t x,
+ int16_t y,
+ int16_t root_x,
+ int16_t root_y,
+ xcb_window_t event_win,
+ xcb_window_t win,
+ xcb_window_t root_win,
+ uint8_t same_screen,
+ int dev,
+ double radx,
+ double rady,
+ double pressure,
+ double angle,
+ int16_t mx,
+ int16_t my,
+ int16_t mrx,
+ int16_t mry)
{
Ecore_Event_Mouse_Button *e;
Ecore_X_Mouse_Down_Info *info = NULL;
@@ -2292,9 +2354,9 @@ _ecore_xcb_event_mouse_button(int event, uint16_t timestamp, uint16_t modifiers,
e->root.x = root_x;
e->root.y = root_y;
- if ((info = _ecore_xcb_event_mouse_down_info_get(dev)))
+ if ((info = _ecore_xcb_event_mouse_down_info_get(dev)))
{
- if ((event == ECORE_EVENT_MOUSE_BUTTON_DOWN) &&
+ if ((event == ECORE_EVENT_MOUSE_BUTTON_DOWN) &&
(info->did_triple))
{
info->last_win = 0;
@@ -2303,37 +2365,37 @@ _ecore_xcb_event_mouse_button(int event, uint16_t timestamp, uint16_t modifiers,
info->last_time = 0;
info->last_last_time = 0;
}
- if (event_win == win)
+ if (event_win == win)
{
- if (event == ECORE_EVENT_MOUSE_BUTTON_DOWN)
+ if (event == ECORE_EVENT_MOUSE_BUTTON_DOWN)
{
- if (((int)(timestamp - info->last_time) <=
- (int)(1000 * _ecore_xcb_double_click_time)) &&
- (win == info->last_win) &&
- (event_win == info->last_event_win))
+ if (((int)(timestamp - info->last_time) <=
+ (int)(1000 * _ecore_xcb_double_click_time)) &&
+ (win == info->last_win) &&
+ (event_win == info->last_event_win))
{
e->double_click = 1;
info->did_double = EINA_TRUE;
}
- else
+ else
{
info->did_double = EINA_FALSE;
info->did_triple = EINA_FALSE;
}
- if (((int)(timestamp - info->last_last_time) <=
- (int)(2 * 1000 * _ecore_xcb_double_click_time)) &&
- (win == info->last_win) &&
- (win == info->last_last_win) &&
- (event_win == info->last_event_win) &&
+ if (((int)(timestamp - info->last_last_time) <=
+ (int)(2 * 1000 * _ecore_xcb_double_click_time)) &&
+ (win == info->last_win) &&
+ (win == info->last_last_win) &&
+ (event_win == info->last_event_win) &&
(event_win == info->last_last_event_win))
{
e->triple_click = 1;
info->did_triple = EINA_TRUE;
}
- else
+ else
info->did_triple = EINA_FALSE;
}
- else
+ else
{
if (info->did_double) e->double_click = 1;
if (info->did_triple) e->triple_click = 1;
@@ -2366,8 +2428,8 @@ _ecore_xcb_event_mouse_button(int event, uint16_t timestamp, uint16_t modifiers,
ecore_event_add(event, e, NULL, NULL);
- if ((info) && (event == ECORE_EVENT_MOUSE_BUTTON_DOWN) &&
- (win == event_win) && (!info->did_triple))
+ if ((info) && (event == ECORE_EVENT_MOUSE_BUTTON_DOWN) &&
+ (win == event_win) && (!info->did_triple))
{
info->last_last_win = info->last_win;
info->last_win = win;
@@ -2380,51 +2442,63 @@ _ecore_xcb_event_mouse_button(int event, uint16_t timestamp, uint16_t modifiers,
return e;
}
-static Ecore_X_Event_Mode
-_ecore_xcb_event_mode_get(uint8_t mode)
+static Ecore_X_Event_Mode
+_ecore_xcb_event_mode_get(uint8_t mode)
{
- switch (mode)
+ switch (mode)
{
case XCB_NOTIFY_MODE_NORMAL:
return ECORE_X_EVENT_MODE_NORMAL;
+
case XCB_NOTIFY_MODE_WHILE_GRABBED:
return ECORE_X_EVENT_MODE_WHILE_GRABBED;
+
case XCB_NOTIFY_MODE_GRAB:
return ECORE_X_EVENT_MODE_GRAB;
+
case XCB_NOTIFY_MODE_UNGRAB:
return ECORE_X_EVENT_MODE_UNGRAB;
+
default:
return ECORE_X_EVENT_MODE_NORMAL;
}
}
-static Ecore_X_Event_Detail
-_ecore_xcb_event_detail_get(uint8_t detail)
+static Ecore_X_Event_Detail
+_ecore_xcb_event_detail_get(uint8_t detail)
{
- switch (detail)
+ switch (detail)
{
case XCB_NOTIFY_DETAIL_ANCESTOR:
return ECORE_X_EVENT_DETAIL_ANCESTOR;
+
case XCB_NOTIFY_DETAIL_VIRTUAL:
return ECORE_X_EVENT_DETAIL_VIRTUAL;
+
case XCB_NOTIFY_DETAIL_INFERIOR:
return ECORE_X_EVENT_DETAIL_INFERIOR;
+
case XCB_NOTIFY_DETAIL_NONLINEAR:
return ECORE_X_EVENT_DETAIL_NON_LINEAR;
+
case XCB_NOTIFY_DETAIL_NONLINEAR_VIRTUAL:
return ECORE_X_EVENT_DETAIL_NON_LINEAR_VIRTUAL;
+
case XCB_NOTIFY_DETAIL_POINTER:
return ECORE_X_EVENT_DETAIL_POINTER;
+
case XCB_NOTIFY_DETAIL_POINTER_ROOT:
return ECORE_X_EVENT_DETAIL_POINTER_ROOT;
+
case XCB_NOTIFY_DETAIL_NONE:
default:
return ECORE_X_EVENT_DETAIL_ANCESTOR;
}
}
-static void
-_ecore_xcb_event_xdnd_enter_free(void *data __UNUSED__, void *event)
+static void
+_ecore_xcb_event_xdnd_enter_free(void *data __UNUSED__,
+ void *event)
{
Ecore_X_Event_Xdnd_Enter *e;
int i = 0;
@@ -2436,8 +2510,9 @@ _ecore_xcb_event_xdnd_enter_free(void *data __UNUSED__, void *event)
free(e);
}
-static void
-_ecore_xcb_event_selection_notify_free(void *data __UNUSED__, void *event)
+static void
+_ecore_xcb_event_selection_notify_free(void *data __UNUSED__,
+ void *event)
{
Ecore_X_Event_Selection_Notify *e;
Ecore_X_Selection_Data *sel;
@@ -2449,8 +2524,9 @@ _ecore_xcb_event_selection_notify_free(void *data __UNUSED__, void *event)
free(e);
}
-static void
-_ecore_xcb_event_generic_event_free(void *data, void *event)
+static void
+_ecore_xcb_event_generic_event_free(void *data,
+ void *event)
{
Ecore_X_Event_Generic *e;
@@ -2459,14 +2535,14 @@ _ecore_xcb_event_generic_event_free(void *data, void *event)
free(e);
}
-static void
-_ecore_xcb_event_mouse_down_info_clear(void)
+static void
+_ecore_xcb_event_mouse_down_info_clear(void)
{
Eina_Inlist *l;
Ecore_X_Mouse_Down_Info *info = NULL;
l = _ecore_xcb_mouse_down_info_list;
- while (l)
+ while (l)
{
info = EINA_INLIST_CONTAINER_GET(l, Ecore_X_Mouse_Down_Info);
l = eina_inlist_remove(l, l);
@@ -2476,7 +2552,7 @@ _ecore_xcb_event_mouse_down_info_clear(void)
}
static Ecore_X_Mouse_Down_Info *
-_ecore_xcb_event_mouse_down_info_get(int dev)
+_ecore_xcb_event_mouse_down_info_get(int dev)
{
Eina_Inlist *l;
Ecore_X_Mouse_Down_Info *info = NULL;
@@ -2493,3 +2569,4 @@ _ecore_xcb_event_mouse_down_info_get(int dev)
return info;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_extensions.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_extensions.c
index 7a73f2b8ed..511a591631 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_extensions.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_extensions.c
@@ -1,7 +1,7 @@
#include "ecore_xcb_private.h"
-void
-_ecore_xcb_extensions_init(void)
+void
+_ecore_xcb_extensions_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -71,8 +71,8 @@ _ecore_xcb_extensions_init(void)
xcb_prefetch_maximum_request_length(_ecore_xcb_conn);
}
-void
-_ecore_xcb_extensions_finalize(void)
+void
+_ecore_xcb_extensions_finalize(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -137,3 +137,4 @@ _ecore_xcb_extensions_finalize(void)
xcb_get_maximum_request_length(_ecore_xcb_conn);
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_gc.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_gc.c
index ae52e6f0a6..d811b54594 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_gc.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_gc.c
@@ -10,8 +10,10 @@
* same than the corresponding bitmaks.
* @return The new default graphics context.
*/
-EAPI Ecore_X_GC
-ecore_x_gc_new(Ecore_X_Drawable drawable, Ecore_X_GC_Value_Mask value_mask, const unsigned int *value_list)
+EAPI Ecore_X_GC
+ecore_x_gc_new(Ecore_X_Drawable drawable,
+ Ecore_X_GC_Value_Mask value_mask,
+ const unsigned int *value_list)
{
xcb_gcontext_t gc;
uint32_t vmask = 0;
@@ -22,76 +24,98 @@ ecore_x_gc_new(Ecore_X_Drawable drawable, Ecore_X_GC_Value_Mask value_mask, cons
if (!drawable) drawable = ((xcb_screen_t *)_ecore_xcb_screen)->root;
- for (i = 0, mask = 1; i <= 22; i++, mask <<= 1)
+ for (i = 0, mask = 1; i <= 22; i++, mask <<= 1)
{
- switch (mask & value_mask)
+ switch (mask & value_mask)
{
case ECORE_X_GC_VALUE_MASK_FUNCTION:
vmask |= XCB_GC_FUNCTION;
break;
+
case ECORE_X_GC_VALUE_MASK_PLANE_MASK:
vmask |= XCB_GC_PLANE_MASK;
break;
+
case ECORE_X_GC_VALUE_MASK_FOREGROUND:
vmask |= XCB_GC_FOREGROUND;
break;
+
case ECORE_X_GC_VALUE_MASK_BACKGROUND:
vmask |= XCB_GC_BACKGROUND;
break;
+
case ECORE_X_GC_VALUE_MASK_LINE_WIDTH:
vmask |= XCB_GC_LINE_WIDTH;
break;
+
case ECORE_X_GC_VALUE_MASK_LINE_STYLE:
vmask |= XCB_GC_LINE_STYLE;
break;
+
case ECORE_X_GC_VALUE_MASK_CAP_STYLE:
vmask |= XCB_GC_CAP_STYLE;
break;
+
case ECORE_X_GC_VALUE_MASK_JOIN_STYLE:
vmask |= XCB_GC_JOIN_STYLE;
break;
+
case ECORE_X_GC_VALUE_MASK_FILL_STYLE:
vmask |= XCB_GC_FILL_STYLE;
break;
+
case ECORE_X_GC_VALUE_MASK_FILL_RULE:
vmask |= XCB_GC_FILL_RULE;
break;
+
case ECORE_X_GC_VALUE_MASK_TILE:
vmask |= XCB_GC_TILE;
break;
+
case ECORE_X_GC_VALUE_MASK_STIPPLE:
vmask |= XCB_GC_STIPPLE;
break;
+
case ECORE_X_GC_VALUE_MASK_TILE_STIPPLE_ORIGIN_X:
vmask |= XCB_GC_TILE_STIPPLE_ORIGIN_X;
break;
+
case ECORE_X_GC_VALUE_MASK_TILE_STIPPLE_ORIGIN_Y:
vmask |= XCB_GC_TILE_STIPPLE_ORIGIN_Y;
break;
+
case ECORE_X_GC_VALUE_MASK_FONT:
vmask |= XCB_GC_FONT;
break;
+
case ECORE_X_GC_VALUE_MASK_SUBWINDOW_MODE:
vmask |= XCB_GC_SUBWINDOW_MODE;
break;
+
case ECORE_X_GC_VALUE_MASK_GRAPHICS_EXPOSURES:
vmask |= XCB_GC_GRAPHICS_EXPOSURES;
break;
+
case ECORE_X_GC_VALUE_MASK_CLIP_ORIGIN_X:
vmask |= XCB_GC_CLIP_ORIGIN_X;
break;
+
case ECORE_X_GC_VALUE_MASK_CLIP_ORIGIN_Y:
vmask |= XCB_GC_CLIP_ORIGIN_Y;
break;
+
case ECORE_X_GC_VALUE_MASK_CLIP_MASK:
vmask |= XCB_GC_CLIP_MASK;
break;
+
case ECORE_X_GC_VALUE_MASK_DASH_OFFSET:
vmask |= XCB_GC_DASH_OFFSET;
break;
+
case ECORE_X_GC_VALUE_MASK_DASH_LIST:
vmask |= XCB_GC_DASH_LIST;
break;
+
case ECORE_X_GC_VALUE_MASK_ARC_MODE:
vmask |= XCB_GC_ARC_MODE;
break;
@@ -109,8 +133,8 @@ ecore_x_gc_new(Ecore_X_Drawable drawable, Ecore_X_GC_Value_Mask value_mask, cons
* Deletes and frees the given graphics context.
* @param gc The given graphics context.
*/
-EAPI void
-ecore_x_gc_free(Ecore_X_GC gc)
+EAPI void
+ecore_x_gc_free(Ecore_X_GC gc)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -119,8 +143,9 @@ ecore_x_gc_free(Ecore_X_GC gc)
// ecore_x_flush();
}
-EAPI void
-ecore_x_gc_foreground_set(Ecore_X_GC gc, unsigned long foreground)
+EAPI void
+ecore_x_gc_foreground_set(Ecore_X_GC gc,
+ unsigned long foreground)
{
uint32_t list;
@@ -132,8 +157,9 @@ ecore_x_gc_foreground_set(Ecore_X_GC gc, unsigned long foreground)
// ecore_x_flush();
}
-EAPI void
-ecore_x_gc_background_set(Ecore_X_GC gc, unsigned long background)
+EAPI void
+ecore_x_gc_background_set(Ecore_X_GC gc,
+ unsigned long background)
{
uint32_t list;
@@ -144,3 +170,4 @@ ecore_x_gc_background_set(Ecore_X_GC gc, unsigned long background)
xcb_change_gc(_ecore_xcb_conn, gc, XCB_GC_BACKGROUND, &list);
// ecore_x_flush();
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_icccm.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_icccm.c
index d61e91ceb9..af0446eb30 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_icccm.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_icccm.c
@@ -1,10 +1,9 @@
#include "ecore_xcb_private.h"
#include <xcb/xcb_icccm.h>
-EAPI void
-ecore_x_icccm_init(void)
+EAPI void
+ecore_x_icccm_init(void)
{
-
}
/**
@@ -14,8 +13,10 @@ ecore_x_icccm_init(void)
* @param argc Number of arguments.
* @param argv Arguments.
*/
-EAPI void
-ecore_x_icccm_command_set(Ecore_X_Window win, int argc, char **argv)
+EAPI void
+ecore_x_icccm_command_set(Ecore_X_Window win,
+ int argc,
+ char **argv)
{
void *buf;
char *b;
@@ -41,8 +42,8 @@ ecore_x_icccm_command_set(Ecore_X_Window win, int argc, char **argv)
else
*b++ = '\0';
}
- xcb_change_property(_ecore_xcb_conn, XCB_PROP_MODE_REPLACE, win,
- ECORE_X_ATOM_WM_COMMAND, ECORE_X_ATOM_STRING, 8,
+ xcb_change_property(_ecore_xcb_conn, XCB_PROP_MODE_REPLACE, win,
+ ECORE_X_ATOM_WM_COMMAND, ECORE_X_ATOM_STRING, 8,
nbytes, buf);
free(buf);
}
@@ -56,8 +57,10 @@ ecore_x_icccm_command_set(Ecore_X_Window win, int argc, char **argv)
* @param argc Number of arguments.
* @param argv Arguments.
*/
-EAPI void
-ecore_x_icccm_command_get(Ecore_X_Window win, int *argc, char ***argv)
+EAPI void
+ecore_x_icccm_command_get(Ecore_X_Window win,
+ int *argc,
+ char ***argv)
{
xcb_get_property_cookie_t cookie;
xcb_get_property_reply_t *reply;
@@ -78,14 +81,14 @@ ecore_x_icccm_command_get(Ecore_X_Window win, int *argc, char ***argv)
reply = xcb_get_property_reply(_ecore_xcb_conn, cookie, NULL);
if (!reply) return;
- if ((reply->type != ECORE_X_ATOM_STRING) || (reply->format != 8))
+ if ((reply->type != ECORE_X_ATOM_STRING) || (reply->format != 8))
{
free(reply);
return;
}
len = reply->value_len;
- if (len < 1)
+ if (len < 1)
{
free(reply);
return;
@@ -100,7 +103,7 @@ ecore_x_icccm_command_get(Ecore_X_Window win, int *argc, char ***argv)
if (*cp == '\0') c++;
v = (char **)malloc((c + 1) * sizeof(char *));
- if (!v)
+ if (!v)
{
free(reply);
return;
@@ -116,7 +119,7 @@ ecore_x_icccm_command_get(Ecore_X_Window win, int *argc, char ***argv)
memcpy(start, (char *)data, len);
start[len] = '\0';
- for (cp = start, i = len + 1, j = 0; i > 0; cp++, i--)
+ for (cp = start, i = len + 1, j = 0; i > 0; cp++, i--)
{
if (*cp == '\0')
{
@@ -160,7 +163,7 @@ ecore_x_icccm_command_get(Ecore_X_Window win, int *argc, char ***argv)
}
EAPI char *
-ecore_x_icccm_title_get(Ecore_X_Window win)
+ecore_x_icccm_title_get(Ecore_X_Window win)
{
xcb_get_property_cookie_t cookie;
#ifdef OLD_XCB_VERSION
@@ -183,7 +186,7 @@ ecore_x_icccm_title_get(Ecore_X_Window win)
ret = xcb_icccm_get_wm_name_reply(_ecore_xcb_conn, cookie, &prop, NULL);
#endif
if (ret == 0) return NULL;
- if (prop.name_len < 1)
+ if (prop.name_len < 1)
{
#ifdef OLD_XCB_VERSION
xcb_get_text_property_reply_wipe(&prop);
@@ -194,7 +197,7 @@ ecore_x_icccm_title_get(Ecore_X_Window win)
}
if (!(title = malloc((prop.name_len + 1) * sizeof(char *))))
- {
+ {
#ifdef OLD_XCB_VERSION
xcb_get_text_property_reply_wipe(&prop);
#else
@@ -205,7 +208,7 @@ ecore_x_icccm_title_get(Ecore_X_Window win)
memcpy(title, prop.name, sizeof(char *) * prop.name_len);
title[prop.name_len] = '\0';
- if (prop.encoding != ECORE_X_ATOM_UTF8_STRING)
+ if (prop.encoding != ECORE_X_ATOM_UTF8_STRING)
{
Ecore_Xcb_Textproperty tp;
int count = 0;
@@ -237,8 +240,9 @@ ecore_x_icccm_title_get(Ecore_X_Window win)
return title;
}
-EAPI void
-ecore_x_icccm_title_set(Ecore_X_Window win, const char *title)
+EAPI void
+ecore_x_icccm_title_set(Ecore_X_Window win,
+ const char *title)
{
Ecore_Xcb_Textproperty prop;
char *list[1];
@@ -253,31 +257,31 @@ ecore_x_icccm_title_set(Ecore_X_Window win, const char *title)
list[0] = strdup(title);
#ifdef HAVE_ICONV
- ret = _ecore_xcb_utf8_textlist_to_textproperty(list, 1, XcbUTF8StringStyle,
+ ret = _ecore_xcb_utf8_textlist_to_textproperty(list, 1, XcbUTF8StringStyle,
&prop);
#else
- ret = _ecore_xcb_mb_textlist_to_textproperty(list, 1, XcbStdICCTextStyle,
+ ret = _ecore_xcb_mb_textlist_to_textproperty(list, 1, XcbStdICCTextStyle,
&prop);
#endif
- if (ret)
+ if (ret)
{
#ifdef OLD_XCB_VERSION
- xcb_set_wm_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
+ xcb_set_wm_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
strlen(prop.value), prop.value);
#else
- xcb_icccm_set_wm_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING, 8,
+ xcb_icccm_set_wm_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING, 8,
strlen(prop.value), prop.value);
#endif
if (prop.value) free(prop.value);
}
- else
+ else
#ifdef OLD_XCB_VERSION
- xcb_set_wm_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
- strlen(title), title);
+ xcb_set_wm_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
+ strlen(title), title);
#else
- xcb_icccm_set_wm_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING, 8,
- strlen(title), title);
+ xcb_icccm_set_wm_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING, 8,
+ strlen(title), title);
#endif
free(list[0]);
}
@@ -290,8 +294,10 @@ ecore_x_icccm_title_set(Ecore_X_Window win, const char *title)
*
* Get a window name * class
*/
-EAPI void
-ecore_x_icccm_name_class_get(Ecore_X_Window win, char **name, char **class)
+EAPI void
+ecore_x_icccm_name_class_get(Ecore_X_Window win,
+ char **name,
+ char **class)
{
xcb_get_property_cookie_t cookie;
#ifdef OLD_XCB_VERSION
@@ -334,8 +340,10 @@ ecore_x_icccm_name_class_get(Ecore_X_Window win, char **name, char **class)
*
* Set a window name * class
*/
-EAPI void
-ecore_x_icccm_name_class_set(Ecore_X_Window win, const char *name, const char *class)
+EAPI void
+ecore_x_icccm_name_class_set(Ecore_X_Window win,
+ const char *name,
+ const char *class)
{
char *class_string, *s;
int length_name, length_class;
@@ -345,7 +353,7 @@ ecore_x_icccm_name_class_set(Ecore_X_Window win, const char *name, const char *c
length_name = strlen(name);
length_class = strlen(class);
- class_string =
+ class_string =
(char *)malloc(sizeof(char) * (length_name + length_class + 2));
if (!class_string) return;
@@ -356,7 +364,7 @@ ecore_x_icccm_name_class_set(Ecore_X_Window win, const char *name, const char *c
s += length_name + 1;
}
else
- *s++ = '\0';
+ *s++ = '\0';
if (length_class)
strcpy(s, class);
@@ -374,14 +382,15 @@ ecore_x_icccm_name_class_set(Ecore_X_Window win, const char *name, const char *c
* @param win the transient window
* @param forwin the toplevel window
*/
-EAPI void
-ecore_x_icccm_transient_for_set(Ecore_X_Window win, Ecore_X_Window forwindow)
+EAPI void
+ecore_x_icccm_transient_for_set(Ecore_X_Window win,
+ Ecore_X_Window forwindow)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- xcb_change_property(_ecore_xcb_conn, XCB_PROP_MODE_REPLACE, win,
- ECORE_X_ATOM_WM_TRANSIENT_FOR, ECORE_X_ATOM_WINDOW, 32,
+ xcb_change_property(_ecore_xcb_conn, XCB_PROP_MODE_REPLACE, win,
+ ECORE_X_ATOM_WM_TRANSIENT_FOR, ECORE_X_ATOM_WINDOW, 32,
1, (void *)&forwindow);
}
@@ -389,8 +398,8 @@ ecore_x_icccm_transient_for_set(Ecore_X_Window win, Ecore_X_Window forwindow)
* Remove the transient_for setting from a window.
* @param The window
*/
-EAPI void
-ecore_x_icccm_transient_for_unset(Ecore_X_Window win)
+EAPI void
+ecore_x_icccm_transient_for_unset(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -402,8 +411,8 @@ ecore_x_icccm_transient_for_unset(Ecore_X_Window win)
* @param win The window to check
* @return The window ID of the top-level window, or 0 if the property does not exist.
*/
-EAPI Ecore_X_Window
-ecore_x_icccm_transient_for_get(Ecore_X_Window win)
+EAPI Ecore_X_Window
+ecore_x_icccm_transient_for_get(Ecore_X_Window win)
{
Ecore_X_Window forwin = 0;
xcb_get_property_cookie_t cookie;
@@ -428,7 +437,7 @@ ecore_x_icccm_transient_for_get(Ecore_X_Window win)
* @return The window's role string.
*/
EAPI char *
-ecore_x_icccm_window_role_get(Ecore_X_Window win)
+ecore_x_icccm_window_role_get(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -440,8 +449,9 @@ ecore_x_icccm_window_role_get(Ecore_X_Window win)
* @param win The window
* @param role The role string
*/
-EAPI void
-ecore_x_icccm_window_role_set(Ecore_X_Window win, const char *role)
+EAPI void
+ecore_x_icccm_window_role_set(Ecore_X_Window win,
+ const char *role)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -453,14 +463,14 @@ ecore_x_icccm_window_role_set(Ecore_X_Window win, const char *role)
* @param win The window
* @return The window's client leader window, or 0 if unset
*/
-EAPI Ecore_X_Window
-ecore_x_icccm_client_leader_get(Ecore_X_Window win)
+EAPI Ecore_X_Window
+ecore_x_icccm_client_leader_get(Ecore_X_Window win)
{
Ecore_X_Window leader;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (ecore_x_window_prop_window_get(win, ECORE_X_ATOM_WM_CLIENT_LEADER,
+ if (ecore_x_window_prop_window_get(win, ECORE_X_ATOM_WM_CLIENT_LEADER,
&leader, 1) > 0)
return leader;
@@ -475,17 +485,18 @@ ecore_x_icccm_client_leader_get(Ecore_X_Window win)
* All non-transient top-level windows created by an app other than
* the main window must have this property set to the app's main window.
*/
-EAPI void
-ecore_x_icccm_client_leader_set(Ecore_X_Window win, Ecore_X_Window leader)
+EAPI void
+ecore_x_icccm_client_leader_set(Ecore_X_Window win,
+ Ecore_X_Window leader)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_window_set(win, ECORE_X_ATOM_WM_CLIENT_LEADER,
+ ecore_x_window_prop_window_set(win, ECORE_X_ATOM_WM_CLIENT_LEADER,
&leader, 1);
}
-EAPI Ecore_X_Window_State_Hint
-ecore_x_icccm_state_get(Ecore_X_Window win)
+EAPI Ecore_X_Window_State_Hint
+ecore_x_icccm_state_get(Ecore_X_Window win)
{
xcb_get_property_cookie_t cookie;
xcb_get_property_reply_t *reply;
@@ -495,13 +506,13 @@ ecore_x_icccm_state_get(Ecore_X_Window win)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- cookie =
- xcb_get_property_unchecked(_ecore_xcb_conn, 0, win,
- ECORE_X_ATOM_WM_STATE, ECORE_X_ATOM_WM_STATE,
+ cookie =
+ xcb_get_property_unchecked(_ecore_xcb_conn, 0, win,
+ ECORE_X_ATOM_WM_STATE, ECORE_X_ATOM_WM_STATE,
0L, 0x7fffffff);
reply = xcb_get_property_reply(_ecore_xcb_conn, cookie, NULL);
if (!reply) return hint;
- if ((reply->type == 0) || (reply->format != 8) || (reply->value_len != 2))
+ if ((reply->type == 0) || (reply->format != 8) || (reply->value_len != 2))
{
free(reply);
return hint;
@@ -509,32 +520,38 @@ ecore_x_icccm_state_get(Ecore_X_Window win)
prop = (uint8_t *)xcb_get_property_value(reply);
#ifdef OLD_XCB_VERSION
- switch (prop[0])
+ switch (prop[0])
{
case XCB_WM_STATE_WITHDRAWN:
hint = ECORE_X_WINDOW_STATE_HINT_WITHDRAWN;
break;
+
case XCB_WM_STATE_NORMAL:
hint = ECORE_X_WINDOW_STATE_HINT_NORMAL;
break;
+
case XCB_WM_STATE_ICONIC:
hint = ECORE_X_WINDOW_STATE_HINT_ICONIC;
break;
+
default:
break;
}
#else
- switch (prop[0])
+ switch (prop[0])
{
case XCB_ICCCM_WM_STATE_WITHDRAWN:
hint = ECORE_X_WINDOW_STATE_HINT_WITHDRAWN;
break;
+
case XCB_ICCCM_WM_STATE_NORMAL:
hint = ECORE_X_WINDOW_STATE_HINT_NORMAL;
break;
+
case XCB_ICCCM_WM_STATE_ICONIC:
hint = ECORE_X_WINDOW_STATE_HINT_ICONIC;
break;
+
default:
break;
}
@@ -544,8 +561,9 @@ ecore_x_icccm_state_get(Ecore_X_Window win)
return hint;
}
-EAPI void
-ecore_x_icccm_state_set(Ecore_X_Window win, Ecore_X_Window_State_Hint state)
+EAPI void
+ecore_x_icccm_state_set(Ecore_X_Window win,
+ Ecore_X_Window_State_Hint state)
{
#ifdef OLD_XCB_VERSION
xcb_wm_hints_t hints;
@@ -583,20 +601,27 @@ ecore_x_icccm_state_set(Ecore_X_Window win, Ecore_X_Window_State_Hint state)
xcb_icccm_set_wm_hints(_ecore_xcb_conn, win, &hints);
#endif
-
}
-EAPI void
-ecore_x_icccm_delete_window_send(Ecore_X_Window win, Ecore_X_Time t)
+EAPI void
+ecore_x_icccm_delete_window_send(Ecore_X_Window win,
+ Ecore_X_Time t)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_WM_PROTOCOLS,
- ECORE_X_EVENT_MASK_NONE,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_WM_PROTOCOLS,
+ ECORE_X_EVENT_MASK_NONE,
ECORE_X_ATOM_WM_DELETE_WINDOW, t, 0, 0, 0);
}
-EAPI void
-ecore_x_icccm_hints_set(Ecore_X_Window win, Eina_Bool accepts_focus, Ecore_X_Window_State_Hint initial_state, Ecore_X_Pixmap icon_pixmap, Ecore_X_Pixmap icon_mask, Ecore_X_Window icon_window, Ecore_X_Window window_group, Eina_Bool is_urgent)
+EAPI void
+ecore_x_icccm_hints_set(Ecore_X_Window win,
+ Eina_Bool accepts_focus,
+ Ecore_X_Window_State_Hint initial_state,
+ Ecore_X_Pixmap icon_pixmap,
+ Ecore_X_Pixmap icon_mask,
+ Ecore_X_Window icon_window,
+ Ecore_X_Window window_group,
+ Eina_Bool is_urgent)
{
#ifdef OLD_XCB_VERSION
xcb_wm_hints_t hints;
@@ -636,23 +661,30 @@ ecore_x_icccm_hints_set(Ecore_X_Window win, Eina_Bool accepts_focus, Ecore_X_Win
else if (initial_state == ECORE_X_WINDOW_STATE_HINT_ICONIC)
xcb_icccm_wm_hints_set_iconic(&hints);
- if (icon_pixmap != 0)
+ if (icon_pixmap != 0)
xcb_icccm_wm_hints_set_icon_pixmap(&hints, icon_pixmap);
- if (icon_mask != 0)
+ if (icon_mask != 0)
xcb_icccm_wm_hints_set_icon_mask(&hints, icon_mask);
- if (icon_window != 0)
+ if (icon_window != 0)
xcb_icccm_wm_hints_set_icon_window(&hints, icon_window);
- if (window_group != 0)
+ if (window_group != 0)
xcb_icccm_wm_hints_set_window_group(&hints, window_group);
- if (is_urgent)
+ if (is_urgent)
xcb_icccm_wm_hints_set_urgency(&hints);
xcb_icccm_set_wm_hints(_ecore_xcb_conn, win, &hints);
#endif
}
-EAPI Eina_Bool
-ecore_x_icccm_hints_get(Ecore_X_Window win, Eina_Bool *accepts_focus, Ecore_X_Window_State_Hint *initial_state, Ecore_X_Pixmap *icon_pixmap, Ecore_X_Pixmap *icon_mask, Ecore_X_Window *icon_window, Ecore_X_Window *window_group, Eina_Bool *is_urgent)
+EAPI Eina_Bool
+ecore_x_icccm_hints_get(Ecore_X_Window win,
+ Eina_Bool *accepts_focus,
+ Ecore_X_Window_State_Hint *initial_state,
+ Ecore_X_Pixmap *icon_pixmap,
+ Ecore_X_Pixmap *icon_mask,
+ Ecore_X_Window *icon_window,
+ Ecore_X_Window *window_group,
+ Eina_Bool *is_urgent)
{
xcb_get_property_cookie_t cookie;
#ifdef OLD_XCB_VERSION
@@ -759,7 +791,7 @@ ecore_x_icccm_hints_get(Ecore_X_Window win, Eina_Bool *accepts_focus, Ecore_X_Wi
* Return the icon name of a window. String must be free'd when done with.
*/
EAPI char *
-ecore_x_icccm_icon_name_get(Ecore_X_Window win)
+ecore_x_icccm_icon_name_get(Ecore_X_Window win)
{
xcb_get_property_cookie_t cookie;
#ifdef OLD_XCB_VERSION
@@ -784,7 +816,7 @@ ecore_x_icccm_icon_name_get(Ecore_X_Window win)
#endif
if (ret == 0) return NULL;
- if (prop.name_len < 1)
+ if (prop.name_len < 1)
{
#ifdef OLD_XCB_VERSION
xcb_get_text_property_reply_wipe(&prop);
@@ -795,7 +827,7 @@ ecore_x_icccm_icon_name_get(Ecore_X_Window win)
}
if (!(tmp = malloc((prop.name_len + 1) * sizeof(char *))))
- {
+ {
#ifdef OLD_XCB_VERSION
xcb_get_text_property_reply_wipe(&prop);
#else
@@ -806,7 +838,7 @@ ecore_x_icccm_icon_name_get(Ecore_X_Window win)
memcpy(tmp, prop.name, sizeof(char *) * prop.name_len);
tmp[prop.name_len] = '\0';
- if (prop.encoding != ECORE_X_ATOM_UTF8_STRING)
+ if (prop.encoding != ECORE_X_ATOM_UTF8_STRING)
{
Ecore_Xcb_Textproperty tp;
int count = 0;
@@ -845,8 +877,9 @@ ecore_x_icccm_icon_name_get(Ecore_X_Window win)
*
* Set a window icon name
*/
-EAPI void
-ecore_x_icccm_icon_name_set(Ecore_X_Window win, const char *name)
+EAPI void
+ecore_x_icccm_icon_name_set(Ecore_X_Window win,
+ const char *name)
{
Ecore_Xcb_Textproperty prop;
char *list[1];
@@ -861,38 +894,39 @@ ecore_x_icccm_icon_name_set(Ecore_X_Window win, const char *name)
list[0] = strdup(name);
#ifdef HAVE_ICONV
- ret = _ecore_xcb_utf8_textlist_to_textproperty(list, 1, XcbUTF8StringStyle,
+ ret = _ecore_xcb_utf8_textlist_to_textproperty(list, 1, XcbUTF8StringStyle,
&prop);
#else
- ret = _ecore_xcb_mb_textlist_to_textproperty(list, 1, XcbStdICCTextStyle,
+ ret = _ecore_xcb_mb_textlist_to_textproperty(list, 1, XcbStdICCTextStyle,
&prop);
#endif
- if (ret)
+ if (ret)
{
#ifdef OLD_XCB_VERSION
- xcb_set_wm_icon_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
+ xcb_set_wm_icon_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
strlen(prop.value), prop.value);
#else
- xcb_icccm_set_wm_icon_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
+ xcb_icccm_set_wm_icon_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
8, strlen(prop.value), prop.value);
#endif
if (prop.value) free(prop.value);
}
- else
+ else
#ifdef OLD_XCB_VERSION
- xcb_set_wm_icon_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
+ xcb_set_wm_icon_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
strlen(name), name);
#else
- xcb_icccm_set_wm_icon_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
+ xcb_icccm_set_wm_icon_name(_ecore_xcb_conn, win, ECORE_X_ATOM_STRING,
8, strlen(name), name);
#endif
free(list[0]);
}
-EAPI void
-ecore_x_icccm_iconic_request_send(Ecore_X_Window win, Ecore_X_Window root)
+EAPI void
+ecore_x_icccm_iconic_request_send(Ecore_X_Window win,
+ Ecore_X_Window root)
{
xcb_client_message_event_t ev;
@@ -914,9 +948,9 @@ ecore_x_icccm_iconic_request_send(Ecore_X_Window win, Ecore_X_Window root)
ev.data.data32[0] = XCB_ICCCM_WM_STATE_ICONIC;
#endif
- xcb_send_event(_ecore_xcb_conn, 0, root,
- (XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY |
- XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT),
+ xcb_send_event(_ecore_xcb_conn, 0, root,
+ (XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY |
+ XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT),
(const char *)&ev);
// ecore_x_flush();
}
@@ -927,8 +961,10 @@ ecore_x_icccm_iconic_request_send(Ecore_X_Window win, Ecore_X_Window root)
* @param protocol The protocol to enable/disable
* @param on On/Off
*/
-EAPI void
-ecore_x_icccm_protocol_set(Ecore_X_Window win, Ecore_X_WM_Protocol protocol, Eina_Bool on)
+EAPI void
+ecore_x_icccm_protocol_set(Ecore_X_Window win,
+ Ecore_X_WM_Protocol protocol,
+ Eina_Bool on)
{
Ecore_X_Atom proto;
xcb_get_property_cookie_t cookie;
@@ -955,65 +991,65 @@ ecore_x_icccm_protocol_set(Ecore_X_Window win, Ecore_X_WM_Protocol protocol, Ein
else
count = protos.atoms_len;
- for (i = 0; i < count; i++)
+ for (i = 0; i < count; i++)
{
- if (protos.atoms[i] == proto)
+ if (protos.atoms[i] == proto)
{
set = 1;
break;
}
}
- if (on)
+ if (on)
{
- if (!set)
+ if (!set)
{
Ecore_X_Atom *atoms = NULL;
atoms = malloc((count + 1) * sizeof(Ecore_X_Atom));
- if (atoms)
+ if (atoms)
{
for (i = 0; i < count; i++)
atoms[i] = protos.atoms[i];
atoms[count] = proto;
#ifdef OLD_XCB_VERSION
- xcb_set_wm_protocols(_ecore_xcb_conn,
- ECORE_X_ATOM_WM_PROTOCOLS,
+ xcb_set_wm_protocols(_ecore_xcb_conn,
+ ECORE_X_ATOM_WM_PROTOCOLS,
win, count, atoms);
#else
- xcb_icccm_set_wm_protocols(_ecore_xcb_conn,
- ECORE_X_ATOM_WM_PROTOCOLS,
+ xcb_icccm_set_wm_protocols(_ecore_xcb_conn,
+ ECORE_X_ATOM_WM_PROTOCOLS,
win, count, atoms);
#endif
free(atoms);
}
}
}
- else
+ else
{
- if (set)
+ if (set)
{
- for (i = 0; i < count; i++)
+ for (i = 0; i < count; i++)
{
- if (protos.atoms[i] == proto)
+ if (protos.atoms[i] == proto)
{
int j = 0;
for (j = (i + 1); j < count; j++)
protos.atoms[j - 1] = protos.atoms[j];
- if (count > 1)
+ if (count > 1)
#ifdef OLD_XCB_VERSION
- xcb_set_wm_protocols(_ecore_xcb_conn,
- ECORE_X_ATOM_WM_PROTOCOLS,
+ xcb_set_wm_protocols(_ecore_xcb_conn,
+ ECORE_X_ATOM_WM_PROTOCOLS,
win, count - 1, protos.atoms);
#else
- xcb_icccm_set_wm_protocols(_ecore_xcb_conn,
- ECORE_X_ATOM_WM_PROTOCOLS,
- win, count - 1,
+ xcb_icccm_set_wm_protocols(_ecore_xcb_conn,
+ ECORE_X_ATOM_WM_PROTOCOLS,
+ win, count - 1,
protos.atoms);
#endif
else
- ecore_x_window_prop_property_del(win,
+ ecore_x_window_prop_property_del(win,
ECORE_X_ATOM_WM_PROTOCOLS);
break;
}
@@ -1034,8 +1070,9 @@ ecore_x_icccm_protocol_set(Ecore_X_Window win, Ecore_X_WM_Protocol protocol, Ein
* @param protocol The protocol to query
* @return 1 if the protocol is set, else 0.
*/
-EAPI Eina_Bool
-ecore_x_icccm_protocol_isset(Ecore_X_Window win, Ecore_X_WM_Protocol protocol)
+EAPI Eina_Bool
+ecore_x_icccm_protocol_isset(Ecore_X_Window win,
+ Ecore_X_WM_Protocol protocol)
{
Ecore_X_Atom proto;
Eina_Bool ret = EINA_FALSE;
@@ -1064,7 +1101,7 @@ ecore_x_icccm_protocol_isset(Ecore_X_Window win, Ecore_X_WM_Protocol protocol)
if (!val) return EINA_FALSE;
for (i = 0; i < reply.atoms_len; i++)
- if (reply.atoms[i] == proto)
+ if (reply.atoms[i] == proto)
{
ret = EINA_TRUE;
break;
@@ -1085,27 +1122,40 @@ ecore_x_icccm_protocol_isset(Ecore_X_Window win, Ecore_X_WM_Protocol protocol)
* @param protos An array of protocol atoms
* @param num the number of members of the array
*/
-EAPI void
-ecore_x_icccm_protocol_atoms_set(Ecore_X_Window win, Ecore_X_Atom *protos, int num)
+EAPI void
+ecore_x_icccm_protocol_atoms_set(Ecore_X_Window win,
+ Ecore_X_Atom *protos,
+ int num)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- if (num > 0)
+ if (num > 0)
#ifdef OLD_XCB_VERSION
- xcb_set_wm_protocols(_ecore_xcb_conn, ECORE_X_ATOM_WM_PROTOCOLS,
+ xcb_set_wm_protocols(_ecore_xcb_conn, ECORE_X_ATOM_WM_PROTOCOLS,
win, num, protos);
#else
- xcb_icccm_set_wm_protocols(_ecore_xcb_conn, ECORE_X_ATOM_WM_PROTOCOLS,
+ xcb_icccm_set_wm_protocols(_ecore_xcb_conn, ECORE_X_ATOM_WM_PROTOCOLS,
win, num, protos);
#endif
- else
+ else
ecore_x_window_prop_property_del(win, ECORE_X_ATOM_WM_PROTOCOLS);
-
}
-EAPI Eina_Bool
-ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win, Eina_Bool *request_pos, Ecore_X_Gravity *gravity, int *min_w, int *min_h, int *max_w, int *max_h, int *base_w, int *base_h, int *step_x, int *step_y, double *min_aspect, double *max_aspect)
+EAPI Eina_Bool
+ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win,
+ Eina_Bool *request_pos,
+ Ecore_X_Gravity *gravity,
+ int *min_w,
+ int *min_h,
+ int *max_w,
+ int *max_h,
+ int *base_w,
+ int *base_h,
+ int *step_x,
+ int *step_y,
+ double *min_aspect,
+ double *max_aspect)
{
xcb_size_hints_t hints;
xcb_get_property_cookie_t cookie;
@@ -1137,17 +1187,17 @@ ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win, Eina_Bool *request_pos, Eco
ret = xcb_get_wm_normal_hints_reply(_ecore_xcb_conn, cookie, &hints, NULL);
#else
cookie = xcb_icccm_get_wm_normal_hints_unchecked(_ecore_xcb_conn, win);
- ret = xcb_icccm_get_wm_normal_hints_reply(_ecore_xcb_conn, cookie,
+ ret = xcb_icccm_get_wm_normal_hints_reply(_ecore_xcb_conn, cookie,
&hints, NULL);
#endif
if (!ret) return EINA_FALSE;
#ifdef OLD_XCB_VERSION
- if ((hints.flags & XCB_SIZE_HINT_US_POSITION) ||
- (hints.flags & XCB_SIZE_HINT_P_POSITION))
+ if ((hints.flags & XCB_SIZE_HINT_US_POSITION) ||
+ (hints.flags & XCB_SIZE_HINT_P_POSITION))
#else
- if ((hints.flags & XCB_ICCCM_SIZE_HINT_US_POSITION) ||
- (hints.flags & XCB_ICCCM_SIZE_HINT_P_POSITION))
+ if ((hints.flags & XCB_ICCCM_SIZE_HINT_US_POSITION) ||
+ (hints.flags & XCB_ICCCM_SIZE_HINT_P_POSITION))
#endif
{
if (request_pos) *request_pos = EINA_TRUE;
@@ -1236,7 +1286,19 @@ ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win, Eina_Bool *request_pos, Eco
}
EAPI void
-ecore_x_icccm_size_pos_hints_set(Ecore_X_Window win, Eina_Bool request_pos, Ecore_X_Gravity gravity, int min_w, int min_h, int max_w, int max_h, int base_w, int base_h, int step_x, int step_y, double min_aspect, double max_aspect)
+ecore_x_icccm_size_pos_hints_set(Ecore_X_Window win,
+ Eina_Bool request_pos,
+ Ecore_X_Gravity gravity,
+ int min_w,
+ int min_h,
+ int max_w,
+ int max_h,
+ int base_w,
+ int base_h,
+ int step_x,
+ int step_y,
+ double min_aspect,
+ double max_aspect)
{
xcb_get_property_cookie_t cookie;
xcb_size_hints_t hints;
@@ -1250,7 +1312,7 @@ ecore_x_icccm_size_pos_hints_set(Ecore_X_Window win, Eina_Bool request_pos, Ecor
ret = xcb_get_wm_normal_hints_reply(_ecore_xcb_conn, cookie, &hints, NULL);
#else
cookie = xcb_icccm_get_wm_normal_hints_unchecked(_ecore_xcb_conn, win);
- ret = xcb_icccm_get_wm_normal_hints_reply(_ecore_xcb_conn, cookie,
+ ret = xcb_icccm_get_wm_normal_hints_reply(_ecore_xcb_conn, cookie,
&hints, NULL);
#endif
if (!ret) memset(&hints, 0, sizeof(xcb_size_hints_t));
@@ -1258,50 +1320,54 @@ ecore_x_icccm_size_pos_hints_set(Ecore_X_Window win, Eina_Bool request_pos, Ecor
hints.flags = 0;
#ifdef OLD_XCB_VERSION
- if (request_pos)
+ if (request_pos)
hints.flags |= XCB_SIZE_HINT_US_POSITION;
if (gravity != ECORE_X_GRAVITY_NW)
xcb_size_hints_set_win_gravity(&hints, gravity);
- if ((min_w > 0) || (min_h > 0))
+ if ((min_w > 0) || (min_h > 0))
xcb_size_hints_set_min_size(&hints, min_w, min_h);
if ((max_w > 0) || (max_h > 0))
xcb_size_hints_set_max_size(&hints, max_w, max_h);
- if ((base_w > 0) || (base_h > 0))
+ if ((base_w > 0) || (base_h > 0))
xcb_size_hints_set_base_size(&hints, base_w, base_h);
- if ((step_x > 1) || (step_y > 1))
+ if ((step_x > 1) || (step_y > 1))
xcb_size_hints_set_resize_inc(&hints, step_x, step_y);
- if ((min_aspect > 0.0) || (max_aspect > 0.0))
- xcb_size_hints_set_aspect(&hints,
- (int32_t)(min_aspect * 10000), 10000,
+ if ((min_aspect > 0.0) || (max_aspect > 0.0))
+ xcb_size_hints_set_aspect(&hints,
+ (int32_t)(min_aspect * 10000), 10000,
(int32_t)(max_aspect * 10000), 10000);
xcb_set_wm_normal_hints(_ecore_xcb_conn, win, &hints);
#else
- if (request_pos)
+ if (request_pos)
hints.flags |= XCB_ICCCM_SIZE_HINT_US_POSITION;
if (gravity != ECORE_X_GRAVITY_NW)
xcb_icccm_size_hints_set_win_gravity(&hints, gravity);
- if ((min_w > 0) || (min_h > 0))
+ if ((min_w > 0) || (min_h > 0))
xcb_icccm_size_hints_set_min_size(&hints, min_w, min_h);
if ((max_w > 0) || (max_h > 0))
xcb_icccm_size_hints_set_max_size(&hints, max_w, max_h);
- if ((base_w > 0) || (base_h > 0))
+ if ((base_w > 0) || (base_h > 0))
xcb_icccm_size_hints_set_base_size(&hints, base_w, base_h);
- if ((step_x > 1) || (step_y > 1))
+ if ((step_x > 1) || (step_y > 1))
xcb_icccm_size_hints_set_resize_inc(&hints, step_x, step_y);
- if ((min_aspect > 0.0) || (max_aspect > 0.0))
- xcb_icccm_size_hints_set_aspect(&hints,
- (int32_t)(min_aspect * 10000), 10000,
+ if ((min_aspect > 0.0) || (max_aspect > 0.0))
+ xcb_icccm_size_hints_set_aspect(&hints,
+ (int32_t)(min_aspect * 10000), 10000,
(int32_t)(max_aspect * 10000), 10000);
xcb_icccm_set_wm_normal_hints(_ecore_xcb_conn, win, &hints);
#endif
}
-EAPI void
-ecore_x_icccm_move_resize_send(Ecore_X_Window win, int x, int y, int w, int h)
+EAPI void
+ecore_x_icccm_move_resize_send(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h)
{
xcb_configure_notify_event_t ev;
@@ -1323,7 +1389,7 @@ ecore_x_icccm_move_resize_send(Ecore_X_Window win, int x, int y, int w, int h)
ev.border_width = 0;
ev.override_redirect = 0;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_STRUCTURE_NOTIFY, (const char *)&ev);
// ecore_x_flush();
}
@@ -1336,7 +1402,7 @@ ecore_x_icccm_move_resize_send(Ecore_X_Window win, int x, int y, int w, int h)
* Return the client machine of a window. String must be free'd when done with.
*/
EAPI char *
-ecore_x_icccm_client_machine_get(Ecore_X_Window win)
+ecore_x_icccm_client_machine_get(Ecore_X_Window win)
{
xcb_get_property_cookie_t cookie;
#ifdef OLD_XCB_VERSION
@@ -1355,14 +1421,14 @@ ecore_x_icccm_client_machine_get(Ecore_X_Window win)
ret = xcb_get_wm_client_machine_reply(_ecore_xcb_conn, cookie, &prop, NULL);
#else
cookie = xcb_icccm_get_wm_client_machine_unchecked(_ecore_xcb_conn, win);
- ret = xcb_icccm_get_wm_client_machine_reply(_ecore_xcb_conn, cookie,
+ ret = xcb_icccm_get_wm_client_machine_reply(_ecore_xcb_conn, cookie,
&prop, NULL);
#endif
if (ret == 0) return NULL;
tmp = malloc((prop.name_len + 1) * sizeof(char *));
- if (!tmp)
- {
+ if (!tmp)
+ {
#ifdef OLD_XCB_VERSION
xcb_get_text_property_reply_wipe(&prop);
#else
@@ -1382,22 +1448,24 @@ ecore_x_icccm_client_machine_get(Ecore_X_Window win)
return tmp;
}
-EAPI void
-ecore_x_icccm_take_focus_send(Ecore_X_Window win, Ecore_X_Time t)
+EAPI void
+ecore_x_icccm_take_focus_send(Ecore_X_Window win,
+ Ecore_X_Time t)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_WM_PROTOCOLS,
- XCB_EVENT_MASK_NO_EVENT,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_WM_PROTOCOLS,
+ XCB_EVENT_MASK_NO_EVENT,
ECORE_X_ATOM_WM_TAKE_FOCUS, t, 0, 0, 0);
}
-EAPI void
-ecore_x_icccm_save_yourself_send(Ecore_X_Window win, Ecore_X_Time t)
+EAPI void
+ecore_x_icccm_save_yourself_send(Ecore_X_Window win,
+ Ecore_X_Time t)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_client_message32_send(win, ECORE_X_ATOM_WM_PROTOCOLS,
- XCB_EVENT_MASK_NO_EVENT,
+ ecore_x_client_message32_send(win, ECORE_X_ATOM_WM_PROTOCOLS,
+ XCB_EVENT_MASK_NO_EVENT,
ECORE_X_ATOM_WM_SAVE_YOURSELF, t, 0, 0, 0);
}
@@ -1406,8 +1474,9 @@ ecore_x_icccm_save_yourself_send(Ecore_X_Window win, Ecore_X_Time t)
* @param win The toplevel window
* @param subwin The subwindow to be added to the colormap windows list
*/
-EAPI void
-ecore_x_icccm_colormap_window_set(Ecore_X_Window win, Ecore_X_Window subwin)
+EAPI void
+ecore_x_icccm_colormap_window_set(Ecore_X_Window win,
+ Ecore_X_Window subwin)
{
int num = 0, i = 0;
unsigned char *odata = NULL, *data = NULL;
@@ -1415,21 +1484,21 @@ ecore_x_icccm_colormap_window_set(Ecore_X_Window win, Ecore_X_Window subwin)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_property_get(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS,
- ECORE_X_ATOM_WINDOW, 32, &odata, &num))
+ if (!ecore_x_window_prop_property_get(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS,
+ ECORE_X_ATOM_WINDOW, 32, &odata, &num))
{
if (!(newset = calloc(1, sizeof(Ecore_X_Window)))) return;
newset[0] = subwin;
num = 1;
data = (unsigned char *)newset;
}
- else
+ else
{
if (!(newset = calloc(num + 1, sizeof(Ecore_X_Window)))) return;
oldset = (Ecore_X_Window *)odata;
- for (i = 0; i < num; i++)
+ for (i = 0; i < num; i++)
{
- if (oldset[i] == subwin)
+ if (oldset[i] == subwin)
{
if (odata) free(odata);
odata = NULL;
@@ -1442,7 +1511,7 @@ ecore_x_icccm_colormap_window_set(Ecore_X_Window win, Ecore_X_Window subwin)
if (odata) free(odata);
data = (unsigned char *)newset;
}
- ecore_x_window_prop_property_set(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS,
+ ecore_x_window_prop_property_set(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS,
ECORE_X_ATOM_WINDOW, 32, data, num);
free(newset);
}
@@ -1452,8 +1521,9 @@ ecore_x_icccm_colormap_window_set(Ecore_X_Window win, Ecore_X_Window subwin)
* @param win The toplevel window
* @param subwin The window to be removed from the colormap window list.
*/
-EAPI void
-ecore_x_icccm_colormap_window_unset(Ecore_X_Window win, Ecore_X_Window subwin)
+EAPI void
+ecore_x_icccm_colormap_window_unset(Ecore_X_Window win,
+ Ecore_X_Window subwin)
{
int num = 0, i = 0, j = 0, k = 0;
unsigned char *odata = NULL, *data = NULL;
@@ -1461,23 +1531,23 @@ ecore_x_icccm_colormap_window_unset(Ecore_X_Window win, Ecore_X_Window subwin)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_property_get(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS,
- ECORE_X_ATOM_WINDOW, 32, &odata, &num))
+ if (!ecore_x_window_prop_property_get(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS,
+ ECORE_X_ATOM_WINDOW, 32, &odata, &num))
return;
oldset = (Ecore_X_Window *)odata;
- for (i = 0; i < num; i++)
+ for (i = 0; i < num; i++)
{
- if (oldset[i] == subwin)
+ if (oldset[i] == subwin)
{
- if (num == 1)
+ if (num == 1)
{
ecore_x_window_prop_property_del(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS);
if (odata) free(odata);
odata = NULL;
return;
}
- else
+ else
{
newset = calloc(num - 1, sizeof(Ecore_X_Window));
data = (unsigned char *)newset;
@@ -1485,7 +1555,7 @@ ecore_x_icccm_colormap_window_unset(Ecore_X_Window win, Ecore_X_Window subwin)
if (oldset[j] != subwin)
newset[k++] = oldset[j];
- ecore_x_window_prop_property_set(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS,
+ ecore_x_window_prop_property_set(win, ECORE_X_ATOM_WM_COLORMAP_WINDOWS,
ECORE_X_ATOM_WINDOW, 32, data, k);
if (odata) free(odata);
odata = NULL;
@@ -1496,3 +1566,4 @@ ecore_x_icccm_colormap_window_unset(Ecore_X_Window win, Ecore_X_Window subwin)
}
if (odata) free(odata);
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_image.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_image.c
index afec5f1a6a..6789b94db2 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_image.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_image.c
@@ -4,27 +4,31 @@
#include <xcb/xcb_event.h>
#include <xcb/shm.h>
-struct _Ecore_X_Image
+struct _Ecore_X_Image
{
xcb_shm_segment_info_t shminfo;
- xcb_image_t *xim;
- Ecore_X_Visual vis;
- int depth, w, h;
- int bpl, bpp, rows;
- unsigned char *data;
- Eina_Bool shm : 1;
+ xcb_image_t *xim;
+ Ecore_X_Visual vis;
+ int depth, w, h;
+ int bpl, bpp, rows;
+ unsigned char *data;
+ Eina_Bool shm : 1;
};
/* local function prototypes */
-static void _ecore_xcb_image_shm_check(void);
-static void _ecore_xcb_image_shm_create(Ecore_X_Image *im);
-static xcb_format_t *_ecore_xcb_image_find_format(const xcb_setup_t *setup, uint8_t depth);
+static void _ecore_xcb_image_shm_check(void);
+static void _ecore_xcb_image_shm_create(Ecore_X_Image *im);
+static xcb_format_t *_ecore_xcb_image_find_format(const xcb_setup_t *setup,
+ uint8_t depth);
/* local variables */
static int _ecore_xcb_image_shm_can = -1;
EAPI Ecore_X_Image *
-ecore_x_image_new(int w, int h, Ecore_X_Visual vis, int depth)
+ecore_x_image_new(int w,
+ int h,
+ Ecore_X_Visual vis,
+ int depth)
{
Ecore_X_Image *im;
@@ -40,16 +44,16 @@ ecore_x_image_new(int w, int h, Ecore_X_Visual vis, int depth)
return im;
}
-EAPI void
-ecore_x_image_free(Ecore_X_Image *im)
+EAPI void
+ecore_x_image_free(Ecore_X_Image *im)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
if (!im) return;
- if (im->shm)
+ if (im->shm)
{
- if (im->xim)
+ if (im->xim)
{
xcb_shm_detach(_ecore_xcb_conn, im->shminfo.shmseg);
xcb_image_destroy(im->xim);
@@ -57,7 +61,7 @@ ecore_x_image_free(Ecore_X_Image *im)
shmctl(im->shminfo.shmid, IPC_RMID, 0);
}
}
- else if (im->xim)
+ else if (im->xim)
{
if (im->xim->data) free(im->xim->data);
im->xim->data = NULL;
@@ -68,29 +72,36 @@ ecore_x_image_free(Ecore_X_Image *im)
// ecore_x_flush();
}
-EAPI Eina_Bool
-ecore_x_image_get(Ecore_X_Image *im, Ecore_X_Drawable draw, int x, int y, int sx, int sy, int w, int h)
+EAPI Eina_Bool
+ecore_x_image_get(Ecore_X_Image *im,
+ Ecore_X_Drawable draw,
+ int x,
+ int y,
+ int sx,
+ int sy,
+ int w,
+ int h)
{
Eina_Bool ret = EINA_TRUE;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- if (im->shm)
+ if (im->shm)
{
if (!im->xim) _ecore_xcb_image_shm_create(im);
if (!im->xim) return EINA_FALSE;
- if ((sx == 0) && (w == im->w))
+ if ((sx == 0) && (w == im->w))
{
- im->xim->data = (uint8_t *)im->data + (im->xim->stride * sy) +
+ im->xim->data = (uint8_t *)im->data + (im->xim->stride * sy) +
(sx * im->bpp);
im->xim->width = w;
im->xim->height = h;
ecore_x_grab();
- if (!xcb_image_shm_get(_ecore_xcb_conn, draw, im->xim,
- im->shminfo, x, y, 0xffffffff))
+ if (!xcb_image_shm_get(_ecore_xcb_conn, draw, im->xim,
+ im->shminfo, x, y, 0xffffffff))
{
DBG("\tImage Shm Get Failed");
ret = EINA_FALSE;
@@ -98,31 +109,31 @@ ecore_x_image_get(Ecore_X_Image *im, Ecore_X_Drawable draw, int x, int y, int sx
ecore_x_ungrab();
ecore_x_sync(); // needed
}
- else
+ else
{
Ecore_X_Image *tim;
tim = ecore_x_image_new(w, h, im->vis, im->depth);
- if (tim)
+ if (tim)
{
ret = ecore_x_image_get(tim, draw, x, y, 0, 0, w, h);
- if (ret)
+ if (ret)
{
unsigned char *spixels, *pixels;
int sbpp = 0, sbpl = 0, srows = 0;
int bpp = 0, bpl = 0, rows = 0;
- spixels =
+ spixels =
ecore_x_image_data_get(tim, &sbpl, &srows, &sbpp);
pixels = ecore_x_image_data_get(im, &bpl, &rows, &bpp);
- if ((spixels) && (pixels))
+ if ((spixels) && (pixels))
{
unsigned char *p, *sp;
int r = 0;
p = (pixels + (sy * bpl) + (sx * bpp));
sp = spixels;
- for (r = srows; r > 0; r--)
+ for (r = srows; r > 0; r--)
{
memcpy(p, sp, sbpl);
p += bpl;
@@ -134,18 +145,18 @@ ecore_x_image_get(Ecore_X_Image *im, Ecore_X_Drawable draw, int x, int y, int sx
}
}
}
- else
+ else
{
ret = EINA_FALSE;
ecore_x_grab();
- im->xim =
- xcb_image_get(_ecore_xcb_conn, draw, x, y, w, h,
+ im->xim =
+ xcb_image_get(_ecore_xcb_conn, draw, x, y, w, h,
0xffffffff, XCB_IMAGE_FORMAT_Z_PIXMAP);
if (!im->xim) ret = EINA_FALSE;
ecore_x_ungrab();
ecore_x_sync(); // needed
- if (im->xim)
+ if (im->xim)
{
im->data = (unsigned char *)im->xim->data;
im->bpl = im->xim->stride;
@@ -163,7 +174,10 @@ ecore_x_image_get(Ecore_X_Image *im, Ecore_X_Drawable draw, int x, int y, int sx
}
EAPI void *
-ecore_x_image_data_get(Ecore_X_Image *im, int *bpl, int *rows, int *bpp)
+ecore_x_image_data_get(Ecore_X_Image *im,
+ int *bpl,
+ int *rows,
+ int *bpp)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -178,15 +192,23 @@ ecore_x_image_data_get(Ecore_X_Image *im, int *bpl, int *rows, int *bpp)
return im->data;
}
-EAPI void
-ecore_x_image_put(Ecore_X_Image *im, Ecore_X_Drawable draw, Ecore_X_GC gc, int x, int y, int sx, int sy, int w, int h)
+EAPI void
+ecore_x_image_put(Ecore_X_Image *im,
+ Ecore_X_Drawable draw,
+ Ecore_X_GC gc,
+ int x,
+ int y,
+ int sx,
+ int sy,
+ int w,
+ int h)
{
Ecore_X_GC tgc = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- if (!gc)
+ if (!gc)
{
uint32_t mask, values[1];
@@ -197,26 +219,25 @@ ecore_x_image_put(Ecore_X_Image *im, Ecore_X_Drawable draw, Ecore_X_GC gc, int x
gc = tgc;
}
if (!im->xim) _ecore_xcb_image_shm_create(im);
- if (im->xim)
+ if (im->xim)
{
- if (im->shm)
- xcb_shm_put_image(_ecore_xcb_conn, draw, gc, im->xim->width,
- im->xim->height, sx, sy, w, h, x, y,
- im->xim->depth, im->xim->format, 0,
- im->shminfo.shmseg,
+ if (im->shm)
+ xcb_shm_put_image(_ecore_xcb_conn, draw, gc, im->xim->width,
+ im->xim->height, sx, sy, w, h, x, y,
+ im->xim->depth, im->xim->format, 0,
+ im->shminfo.shmseg,
im->xim->data - im->shminfo.shmaddr);
-// xcb_image_shm_put(_ecore_xcb_conn, draw, gc, im->xim,
+// xcb_image_shm_put(_ecore_xcb_conn, draw, gc, im->xim,
// im->shminfo, sx, sy, x, y, w, h, 0);
- else
+ else
xcb_image_put(_ecore_xcb_conn, draw, gc, im->xim, sx, sy, 0);
-
}
if (tgc) ecore_x_gc_free(tgc);
ecore_x_sync();
}
-EAPI Eina_Bool
-ecore_x_image_is_argb32_get(Ecore_X_Image *im)
+EAPI Eina_Bool
+ecore_x_image_is_argb32_get(Ecore_X_Image *im)
{
xcb_visualtype_t *vis;
@@ -226,16 +247,16 @@ ecore_x_image_is_argb32_get(Ecore_X_Image *im)
vis = (xcb_visualtype_t *)im->vis;
if (!im->xim) _ecore_xcb_image_shm_create(im);
- if (((vis->_class == XCB_VISUAL_CLASS_TRUE_COLOR) ||
- (vis->_class == XCB_VISUAL_CLASS_DIRECT_COLOR)) &&
- (im->depth >= 24) && (vis->red_mask == 0xff0000) &&
+ if (((vis->_class == XCB_VISUAL_CLASS_TRUE_COLOR) ||
+ (vis->_class == XCB_VISUAL_CLASS_DIRECT_COLOR)) &&
+ (im->depth >= 24) && (vis->red_mask == 0xff0000) &&
(vis->green_mask == 0x00ff00) && (vis->blue_mask == 0x0000ff))
{
#ifdef WORDS_BIGENDIAN
- if (im->xim->byte_order == XCB_IMAGE_ORDER_LSB_FIRST)
+ if (im->xim->byte_order == XCB_IMAGE_ORDER_LSB_FIRST)
return EINA_TRUE;
#else
- if (im->xim->byte_order == XCB_IMAGE_ORDER_MSB_FIRST)
+ if (im->xim->byte_order == XCB_IMAGE_ORDER_MSB_FIRST)
return EINA_TRUE;
#endif
}
@@ -243,25 +264,37 @@ ecore_x_image_is_argb32_get(Ecore_X_Image *im)
return EINA_FALSE;
}
-EAPI Eina_Bool
-ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c, Ecore_X_Visual v, int x, int y, int w, int h, unsigned int *dst, int dbpl, int dx, int dy)
+EAPI Eina_Bool
+ecore_x_image_to_argb_convert(void *src,
+ int sbpp,
+ int sbpl,
+ Ecore_X_Colormap c,
+ Ecore_X_Visual v,
+ int x,
+ int y,
+ int w,
+ int h,
+ unsigned int *dst,
+ int dbpl,
+ int dx,
+ int dy)
{
xcb_visualtype_t *vis;
uint32_t *cols;
int n = 0, nret = 0, i, row, mode = 0;
unsigned int pal[256], r, g, b;
enum
- {
- rgbnone = 0,
- rgb565,
- bgr565,
- rgbx555,
- argbx888,
- abgrx888,
- rgba888x,
- bgra888x,
- argbx666
- };
+ {
+ rgbnone = 0,
+ rgb565,
+ bgr565,
+ rgbx555,
+ argbx888,
+ abgrx888,
+ rgba888x,
+ bgra888x,
+ argbx666
+ };
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -272,14 +305,14 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
n = vis->colormap_entries;
if ((n <= 256) &&
((vis->_class == XCB_VISUAL_CLASS_PSEUDO_COLOR) ||
- (vis->_class == XCB_VISUAL_CLASS_STATIC_COLOR) ||
- (vis->_class == XCB_VISUAL_CLASS_GRAY_SCALE) ||
- (vis->_class == XCB_VISUAL_CLASS_STATIC_GRAY)))
+ (vis->_class == XCB_VISUAL_CLASS_STATIC_COLOR) ||
+ (vis->_class == XCB_VISUAL_CLASS_GRAY_SCALE) ||
+ (vis->_class == XCB_VISUAL_CLASS_STATIC_GRAY)))
{
xcb_query_colors_cookie_t cookie;
xcb_query_colors_reply_t *reply;
- if (!c)
+ if (!c)
{
c = (xcb_colormap_t)((xcb_screen_t *)
_ecore_xcb_screen)->default_colormap;
@@ -291,61 +324,61 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
cookie = xcb_query_colors_unchecked(_ecore_xcb_conn, c, n, cols);
reply = xcb_query_colors_reply(_ecore_xcb_conn, cookie, NULL);
- if (reply)
+ if (reply)
{
xcb_rgb_iterator_t iter;
xcb_rgb_t *ret;
iter = xcb_query_colors_colors_iterator(reply);
ret = xcb_query_colors_colors(reply);
- if (ret)
+ if (ret)
{
- for (i = 0; iter.rem; xcb_rgb_next(&iter), i++)
+ for (i = 0; iter.rem; xcb_rgb_next(&iter), i++)
{
- pal[i] = 0xff000000 |
- ((iter.data->red >> 8) << 16) |
+ pal[i] = 0xff000000 |
+ ((iter.data->red >> 8) << 16) |
((iter.data->green >> 8) << 8) |
- ((iter.data->blue >> 8));
+ ((iter.data->blue >> 8));
}
nret = n;
}
free(reply);
}
}
- else if ((vis->_class == XCB_VISUAL_CLASS_TRUE_COLOR) ||
+ else if ((vis->_class == XCB_VISUAL_CLASS_TRUE_COLOR) ||
(vis->_class == XCB_VISUAL_CLASS_DIRECT_COLOR))
{
- if ((vis->red_mask == 0x00ff0000) &&
+ if ((vis->red_mask == 0x00ff0000) &&
(vis->green_mask == 0x0000ff00) &&
- (vis->blue_mask == 0x000000ff))
+ (vis->blue_mask == 0x000000ff))
mode = argbx888;
- else if ((vis->red_mask == 0x000000ff) &&
+ else if ((vis->red_mask == 0x000000ff) &&
(vis->green_mask == 0x0000ff00) &&
- (vis->blue_mask == 0x00ff0000))
+ (vis->blue_mask == 0x00ff0000))
mode = abgrx888;
- else if ((vis->red_mask == 0xff000000) &&
+ else if ((vis->red_mask == 0xff000000) &&
(vis->green_mask == 0x00ff0000) &&
- (vis->blue_mask == 0x0000ff00))
+ (vis->blue_mask == 0x0000ff00))
mode = rgba888x;
- else if ((vis->red_mask == 0x0000ff00) &&
+ else if ((vis->red_mask == 0x0000ff00) &&
(vis->green_mask == 0x00ff0000) &&
- (vis->blue_mask == 0xff000000))
+ (vis->blue_mask == 0xff000000))
mode = bgra888x;
- else if ((vis->red_mask == 0x0003f000) &&
+ else if ((vis->red_mask == 0x0003f000) &&
(vis->green_mask == 0x00000fc0) &&
- (vis->blue_mask == 0x0000003f))
+ (vis->blue_mask == 0x0000003f))
mode = argbx666;
- else if ((vis->red_mask == 0x0000f800) &&
+ else if ((vis->red_mask == 0x0000f800) &&
(vis->green_mask == 0x000007e0) &&
- (vis->blue_mask == 0x0000001f))
+ (vis->blue_mask == 0x0000001f))
mode = rgb565;
- else if ((vis->red_mask == 0x0000001f) &&
+ else if ((vis->red_mask == 0x0000001f) &&
(vis->green_mask == 0x000007e0) &&
- (vis->blue_mask == 0x0000f800))
+ (vis->blue_mask == 0x0000f800))
mode = bgr565;
- else if ((vis->red_mask == 0x00007c00) &&
+ else if ((vis->red_mask == 0x00007c00) &&
(vis->green_mask == 0x000003e0) &&
- (vis->blue_mask == 0x0000001f))
+ (vis->blue_mask == 0x0000001f))
mode = rgbx555;
else
return EINA_FALSE;
@@ -356,13 +389,13 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
unsigned short *s16;
unsigned int *s32, *dp, *de;
- dp = ((unsigned int *)(((unsigned char *)dst) +
+ dp = ((unsigned int *)(((unsigned char *)dst) +
((dy + row) * dbpl))) + dx;
de = dp + w;
switch (sbpp)
{
case 8:
- s8 = ((unsigned char *)(((unsigned char *)src) +
+ s8 = ((unsigned char *)(((unsigned char *)src) +
((y + row) * sbpl))) + x;
if (nret > 0)
{
@@ -375,8 +408,9 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
else
return EINA_FALSE;
break;
+
case 16:
- s16 = ((unsigned short *)(((unsigned char *)src) +
+ s16 = ((unsigned short *)(((unsigned char *)src) +
((y + row) * sbpl))) + x;
switch (mode)
{
@@ -393,6 +427,7 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
s16++; dp++;
}
break;
+
case bgr565:
while (dp < de)
{
@@ -406,6 +441,7 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
s16++; dp++;
}
break;
+
case rgbx555:
while (dp < de)
{
@@ -419,14 +455,16 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
s16++; dp++;
}
break;
+
default:
return EINA_FALSE;
break;
}
break;
+
case 24:
case 32:
- s32 = ((unsigned int *)(((unsigned char *)src) +
+ s32 = ((unsigned int *)(((unsigned char *)src) +
((y + row) * sbpl))) + x;
switch (mode)
{
@@ -437,6 +475,7 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
s32++; dp++;
}
break;
+
case abgrx888:
while (dp < de)
{
@@ -447,6 +486,7 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
s32++; dp++;
}
break;
+
case rgba888x:
while (dp < de)
{
@@ -454,6 +494,7 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
s32++; dp++;
}
break;
+
case bgra888x:
while (dp < de)
{
@@ -464,6 +505,7 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
s32++; dp++;
}
break;
+
case argbx666:
while (dp < de)
{
@@ -477,12 +519,14 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
s32++; dp++;
}
break;
+
default:
return EINA_FALSE;
break;
}
break;
break;
+
default:
return EINA_FALSE;
break;
@@ -492,107 +536,107 @@ ecore_x_image_to_argb_convert(void *src, int sbpp, int sbpl, Ecore_X_Colormap c,
}
/* local functions */
-static void
-_ecore_xcb_image_shm_check(void)
+static void
+_ecore_xcb_image_shm_check(void)
{
// xcb_shm_query_version_reply_t *reply;
- xcb_shm_segment_info_t shminfo;
- xcb_shm_get_image_cookie_t cookie;
- xcb_shm_get_image_reply_t *ireply;
- xcb_image_t *img = 0;
- uint8_t depth = 0;
-
- if (_ecore_xcb_image_shm_can != -1) return;
- CHECK_XCB_CONN;
-
- /* reply = */
- /* xcb_shm_query_version_reply(_ecore_xcb_conn, */
- /* xcb_shm_query_version(_ecore_xcb_conn), NULL); */
- /* if (!reply) */
- /* { */
- /* _ecore_xcb_image_shm_can = 0; */
- /* return; */
- /* } */
-
- /* if ((reply->major_version < 1) || */
- /* ((reply->major_version == 1) && (reply->minor_version == 0))) */
- /* { */
- /* _ecore_xcb_image_shm_can = 0; */
- /* free(reply); */
- /* return; */
- /* } */
-
- /* free(reply); */
-
- depth = ((xcb_screen_t *)_ecore_xcb_screen)->root_depth;
-
- ecore_x_sync(); // needed
-
- img = _ecore_xcb_image_create_native(1, 1, XCB_IMAGE_FORMAT_Z_PIXMAP,
- depth, NULL, ~0, NULL);
- if (!img)
- {
- _ecore_xcb_image_shm_can = 0;
- return;
- }
-
- shminfo.shmid =
- shmget(IPC_PRIVATE, img->stride * img->height, (IPC_CREAT | 0666));
- if (shminfo.shmid == (uint32_t)-1)
- {
- xcb_image_destroy(img);
- _ecore_xcb_image_shm_can = 0;
- return;
- }
-
- shminfo.shmaddr = shmat(shminfo.shmid, 0, 0);
- img->data = shminfo.shmaddr;
- if (img->data == (uint8_t *)-1)
- {
- xcb_image_destroy(img);
- _ecore_xcb_image_shm_can = 0;
- return;
- }
-
- shminfo.shmseg = xcb_generate_id(_ecore_xcb_conn);
- xcb_shm_attach(_ecore_xcb_conn, shminfo.shmseg, shminfo.shmid, 0);
-
- cookie =
- xcb_shm_get_image(_ecore_xcb_conn,
- ((xcb_screen_t *)_ecore_xcb_screen)->root,
- 0, 0, img->width, img->height,
- 0xffffffff, img->format,
- shminfo.shmseg, img->data - shminfo.shmaddr);
-
- ecore_x_sync(); // needed
-
- ireply = xcb_shm_get_image_reply(_ecore_xcb_conn, cookie, NULL);
- if (ireply)
- {
- _ecore_xcb_image_shm_can = 1;
- free(ireply);
- }
- else
- _ecore_xcb_image_shm_can = 0;
-
- xcb_shm_detach(_ecore_xcb_conn, shminfo.shmseg);
- xcb_image_destroy(img);
- shmdt(shminfo.shmaddr);
- shmctl(shminfo.shmid, IPC_RMID, 0);
+ xcb_shm_segment_info_t shminfo;
+ xcb_shm_get_image_cookie_t cookie;
+ xcb_shm_get_image_reply_t *ireply;
+ xcb_image_t *img = 0;
+ uint8_t depth = 0;
+
+ if (_ecore_xcb_image_shm_can != -1) return;
+ CHECK_XCB_CONN;
+
+ /* reply = */
+ /* xcb_shm_query_version_reply(_ecore_xcb_conn, */
+ /* xcb_shm_query_version(_ecore_xcb_conn), NULL); */
+ /* if (!reply) */
+ /* { */
+ /* _ecore_xcb_image_shm_can = 0; */
+ /* return; */
+ /* } */
+
+ /* if ((reply->major_version < 1) || */
+ /* ((reply->major_version == 1) && (reply->minor_version == 0))) */
+ /* { */
+ /* _ecore_xcb_image_shm_can = 0; */
+ /* free(reply); */
+ /* return; */
+ /* } */
+
+ /* free(reply); */
+
+ depth = ((xcb_screen_t *)_ecore_xcb_screen)->root_depth;
+
+ ecore_x_sync(); // needed
+
+ img = _ecore_xcb_image_create_native(1, 1, XCB_IMAGE_FORMAT_Z_PIXMAP,
+ depth, NULL, ~0, NULL);
+ if (!img)
+ {
+ _ecore_xcb_image_shm_can = 0;
+ return;
+ }
+
+ shminfo.shmid =
+ shmget(IPC_PRIVATE, img->stride * img->height, (IPC_CREAT | 0666));
+ if (shminfo.shmid == (uint32_t)-1)
+ {
+ xcb_image_destroy(img);
+ _ecore_xcb_image_shm_can = 0;
+ return;
+ }
+
+ shminfo.shmaddr = shmat(shminfo.shmid, 0, 0);
+ img->data = shminfo.shmaddr;
+ if (img->data == (uint8_t *)-1)
+ {
+ xcb_image_destroy(img);
+ _ecore_xcb_image_shm_can = 0;
+ return;
+ }
+
+ shminfo.shmseg = xcb_generate_id(_ecore_xcb_conn);
+ xcb_shm_attach(_ecore_xcb_conn, shminfo.shmseg, shminfo.shmid, 0);
+
+ cookie =
+ xcb_shm_get_image(_ecore_xcb_conn,
+ ((xcb_screen_t *)_ecore_xcb_screen)->root,
+ 0, 0, img->width, img->height,
+ 0xffffffff, img->format,
+ shminfo.shmseg, img->data - shminfo.shmaddr);
+
+ ecore_x_sync(); // needed
+
+ ireply = xcb_shm_get_image_reply(_ecore_xcb_conn, cookie, NULL);
+ if (ireply)
+ {
+ _ecore_xcb_image_shm_can = 1;
+ free(ireply);
+ }
+ else
+ _ecore_xcb_image_shm_can = 0;
+
+ xcb_shm_detach(_ecore_xcb_conn, shminfo.shmseg);
+ xcb_image_destroy(img);
+ shmdt(shminfo.shmaddr);
+ shmctl(shminfo.shmid, IPC_RMID, 0);
}
-static void
-_ecore_xcb_image_shm_create(Ecore_X_Image *im)
+static void
+_ecore_xcb_image_shm_create(Ecore_X_Image *im)
{
CHECK_XCB_CONN;
- im->xim =
- _ecore_xcb_image_create_native(im->w, im->h, XCB_IMAGE_FORMAT_Z_PIXMAP,
+ im->xim =
+ _ecore_xcb_image_create_native(im->w, im->h, XCB_IMAGE_FORMAT_Z_PIXMAP,
im->depth, NULL, ~0, NULL);
if (!im->xim) return;
im->shminfo.shmid = shmget(IPC_PRIVATE, im->xim->size, (IPC_CREAT | 0666));
- if (im->shminfo.shmid == (uint32_t)-1)
+ if (im->shminfo.shmid == (uint32_t)-1)
{
xcb_image_destroy(im->xim);
return;
@@ -624,7 +668,13 @@ _ecore_xcb_image_shm_create(Ecore_X_Image *im)
}
xcb_image_t *
-_ecore_xcb_image_create_native(int w, int h, xcb_image_format_t format, uint8_t depth, void *base, uint32_t bytes, uint8_t *data)
+_ecore_xcb_image_create_native(int w,
+ int h,
+ xcb_image_format_t format,
+ uint8_t depth,
+ void *base,
+ uint32_t bytes,
+ uint8_t *data)
{
static uint8_t dpth = 0;
static xcb_format_t *fmt = NULL;
@@ -633,8 +683,8 @@ _ecore_xcb_image_create_native(int w, int h, xcb_image_format_t format, uint8_t
CHECK_XCB_CONN;
- /* NB: We cannot use xcb_image_create_native as it only creates images
- * using MSB_FIRST, so this routine recreates that function and uses
+ /* NB: We cannot use xcb_image_create_native as it only creates images
+ * using MSB_FIRST, so this routine recreates that function and uses
* the endian-ness of the server setup */
setup = xcb_get_setup(_ecore_xcb_conn);
xif = format;
@@ -642,26 +692,28 @@ _ecore_xcb_image_create_native(int w, int h, xcb_image_format_t format, uint8_t
if ((xif == XCB_IMAGE_FORMAT_Z_PIXMAP) && (depth == 1))
xif = XCB_IMAGE_FORMAT_XY_PIXMAP;
- if (dpth != depth)
+ if (dpth != depth)
{
dpth = depth;
fmt = _ecore_xcb_image_find_format(setup, depth);
if (!fmt) return 0;
}
- switch (xif)
+ switch (xif)
{
case XCB_IMAGE_FORMAT_XY_BITMAP:
if (depth != 1) return 0;
+
case XCB_IMAGE_FORMAT_XY_PIXMAP:
case XCB_IMAGE_FORMAT_Z_PIXMAP:
- return xcb_image_create(w, h, xif,
- fmt->scanline_pad,
- fmt->depth, fmt->bits_per_pixel,
- setup->bitmap_format_scanline_unit,
- setup->image_byte_order,
- setup->bitmap_format_bit_order,
+ return xcb_image_create(w, h, xif,
+ fmt->scanline_pad,
+ fmt->depth, fmt->bits_per_pixel,
+ setup->bitmap_format_scanline_unit,
+ setup->image_byte_order,
+ setup->bitmap_format_bit_order,
base, bytes, data);
+
default:
break;
}
@@ -670,7 +722,8 @@ _ecore_xcb_image_create_native(int w, int h, xcb_image_format_t format, uint8_t
}
static xcb_format_t *
-_ecore_xcb_image_find_format(const xcb_setup_t *setup, uint8_t depth)
+_ecore_xcb_image_find_format(const xcb_setup_t *setup,
+ uint8_t depth)
{
xcb_format_t *fmt, *fmtend;
@@ -679,8 +732,9 @@ _ecore_xcb_image_find_format(const xcb_setup_t *setup, uint8_t depth)
fmt = xcb_setup_pixmap_formats(setup);
fmtend = fmt + xcb_setup_pixmap_formats_length(setup);
for (; fmt != fmtend; ++fmt)
- if (fmt->depth == depth)
+ if (fmt->depth == depth)
return fmt;
return 0;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_input.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_input.c
index 83a51ff558..c0338c22a5 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_input.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_input.c
@@ -27,8 +27,8 @@ static Eina_Bool _input_avail = EINA_FALSE;
/* external variables */
int _ecore_xcb_event_input = 0;
-void
-_ecore_xcb_input_init(void)
+void
+_ecore_xcb_input_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -37,8 +37,8 @@ _ecore_xcb_input_init(void)
#endif
}
-void
-_ecore_xcb_input_finalize(void)
+void
+_ecore_xcb_input_finalize(void)
{
#ifdef ECORE_XCB_XINPUT
xcb_input_get_extension_version_cookie_t cookie;
@@ -49,38 +49,38 @@ _ecore_xcb_input_finalize(void)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
#ifdef ECORE_XCB_XINPUT
- cookie =
+ cookie =
xcb_input_get_extension_version_unchecked(_ecore_xcb_conn, 127, buff);
- reply =
+ reply =
xcb_input_get_extension_version_reply(_ecore_xcb_conn, cookie, NULL);
- if (reply)
+ if (reply)
{
_input_avail = EINA_TRUE;
free(reply);
}
- if (_input_avail)
+ if (_input_avail)
{
const xcb_query_extension_reply_t *ext_reply;
ext_reply = xcb_get_extension_data(_ecore_xcb_conn, &xcb_input_id);
- if (ext_reply)
+ if (ext_reply)
_ecore_xcb_event_input = ext_reply->first_event;
}
#endif
}
-void
-_ecore_xcb_input_shutdown(void)
+void
+_ecore_xcb_input_shutdown(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
}
-void
+void
#ifdef ECORE_XCB_XINPUT
-_ecore_xcb_input_handle_event(xcb_generic_event_t *event)
+_ecore_xcb_input_handle_event(xcb_generic_event_t *event)
#else
-_ecore_xcb_input_handle_event(xcb_generic_event_t *event __UNUSED__)
+_ecore_xcb_input_handle_event(xcb_generic_event_t * event __UNUSED__)
#endif
{
#ifdef ECORE_XCB_XINPUT
@@ -94,120 +94,126 @@ _ecore_xcb_input_handle_event(xcb_generic_event_t *event __UNUSED__)
* xcb-input lib to test with */
#ifdef ECORE_XCB_XINPUT
ev = (xcb_ge_event_t *)event;
- switch (ev->event_type)
+ switch (ev->event_type)
{
- case XCB_INPUT_DEVICE_MOTION_NOTIFY:
- {
- xcb_input_device_motion_notify_event_t *de;
- unsigned int child_win = 0;
-
- de = (xcb_input_device_motion_notify_event_t *)ev->pad1;
- child_win = (de->child ? de->child : de->event);
- _ecore_xcb_event_mouse_move(de->time, de->state, de->event_x,
- de->event_y, de->root_x, de->root_y,
- de->event, child_win, de->root,
- de->same_screen, de->device_id,
- 1, 1, 1.0, 0.0,
- de->event_x, de->event_y,
- de->root_x, de->root_y);
- }
- break;
- case XCB_INPUT_DEVICE_BUTTON_PRESS:
- {
- xcb_input_device_button_press_event_t *de;
- unsigned int child_win = 0;
-
- de = (xcb_input_device_button_press_event_t *)ev->pad1;
- child_win = (de->child ? de->child : de->event);
- _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_DOWN,
- de->time, de->state, de->detail,
- de->event_x, de->event_y,
- de->root_x, de->root_y, de->event,
- child_win, de->root,
- de->same_screen, de->device_id,
- 1, 1, 1.0, 0.0,
- de->event_x, de->event_y,
- de->root_x, de->root_y);
- }
- break;
- case XCB_INPUT_DEVICE_BUTTON_RELEASE:
- {
- xcb_input_device_button_release_event_t *de;
- unsigned int child_win = 0;
-
- de = (xcb_input_device_button_release_event_t *)ev->pad1;
- child_win = (de->child ? de->child : de->event);
- _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_UP,
- de->time, de->state, de->detail,
- de->event_x, de->event_y,
- de->root_x, de->root_y, de->event,
- child_win, de->root,
- de->same_screen, de->device_id,
- 1, 1, 1.0, 0.0,
- de->event_x, de->event_y,
- de->root_x, de->root_y);
- }
- break;
+ case XCB_INPUT_DEVICE_MOTION_NOTIFY:
+ {
+ xcb_input_device_motion_notify_event_t *de;
+ unsigned int child_win = 0;
+
+ de = (xcb_input_device_motion_notify_event_t *)ev->pad1;
+ child_win = (de->child ? de->child : de->event);
+ _ecore_xcb_event_mouse_move(de->time, de->state, de->event_x,
+ de->event_y, de->root_x, de->root_y,
+ de->event, child_win, de->root,
+ de->same_screen, de->device_id,
+ 1, 1, 1.0, 0.0,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y);
+ }
+ break;
+
+ case XCB_INPUT_DEVICE_BUTTON_PRESS:
+ {
+ xcb_input_device_button_press_event_t *de;
+ unsigned int child_win = 0;
+
+ de = (xcb_input_device_button_press_event_t *)ev->pad1;
+ child_win = (de->child ? de->child : de->event);
+ _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_DOWN,
+ de->time, de->state, de->detail,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y, de->event,
+ child_win, de->root,
+ de->same_screen, de->device_id,
+ 1, 1, 1.0, 0.0,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y);
+ }
+ break;
+
+ case XCB_INPUT_DEVICE_BUTTON_RELEASE:
+ {
+ xcb_input_device_button_release_event_t *de;
+ unsigned int child_win = 0;
+
+ de = (xcb_input_device_button_release_event_t *)ev->pad1;
+ child_win = (de->child ? de->child : de->event);
+ _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_UP,
+ de->time, de->state, de->detail,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y, de->event,
+ child_win, de->root,
+ de->same_screen, de->device_id,
+ 1, 1, 1.0, 0.0,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y);
+ }
+ break;
+
case XCB_INPUT_DEVICE_TOUCH_UPDATE:
- {
- xcb_input_device_motion_notify_event_t *de;
- unsigned int child_win = 0;
-
- de = (xcb_input_device_motion_notify_event_t *)ev->pad1;
- child_win = (de->child ? de->child : de->event);
- _ecore_xcb_event_mouse_move(de->time, de->state, de->event_x,
- de->event_y, de->root_x, de->root_y,
- de->event, child_win, de->root,
- de->same_screen, de->device_id,
- 1, 1, 1.0, 0.0,
- de->event_x, de->event_y,
- de->root_x, de->root_y);
- }
- break;
+ {
+ xcb_input_device_motion_notify_event_t *de;
+ unsigned int child_win = 0;
+
+ de = (xcb_input_device_motion_notify_event_t *)ev->pad1;
+ child_win = (de->child ? de->child : de->event);
+ _ecore_xcb_event_mouse_move(de->time, de->state, de->event_x,
+ de->event_y, de->root_x, de->root_y,
+ de->event, child_win, de->root,
+ de->same_screen, de->device_id,
+ 1, 1, 1.0, 0.0,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y);
+ }
+ break;
+
case XCB_INPUT_DEVICE_TOUCH_BEGIN:
- {
- xcb_input_device_button_press_event_t *de;
- unsigned int child_win = 0;
-
- de = (xcb_input_device_button_press_event_t *)ev->pad1;
- child_win = (de->child ? de->child : de->event);
- _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_DOWN,
- de->time, de->state, de->detail,
- de->event_x, de->event_y,
- de->root_x, de->root_y, de->event,
- child_win, de->root,
- de->same_screen, de->device_id,
- 1, 1, 1.0, 0.0,
- de->event_x, de->event_y,
- de->root_x, de->root_y);
- }
- break;
+ {
+ xcb_input_device_button_press_event_t *de;
+ unsigned int child_win = 0;
+
+ de = (xcb_input_device_button_press_event_t *)ev->pad1;
+ child_win = (de->child ? de->child : de->event);
+ _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_DOWN,
+ de->time, de->state, de->detail,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y, de->event,
+ child_win, de->root,
+ de->same_screen, de->device_id,
+ 1, 1, 1.0, 0.0,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y);
+ }
+ break;
+
case XCB_INPUT_DEVICE_TOUCH_END:
- {
- xcb_input_device_button_release_event_t *de;
- unsigned int child_win = 0;
-
- de = (xcb_input_device_button_release_event_t *)ev->pad1;
- child_win = (de->child ? de->child : de->event);
- _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_UP,
- de->time, de->state, de->detail,
- de->event_x, de->event_y,
- de->root_x, de->root_y, de->event,
- child_win, de->root,
- de->same_screen, de->device_id,
- 1, 1, 1.0, 0.0,
- de->event_x, de->event_y,
- de->root_x, de->root_y);
- }
- break;
+ {
+ xcb_input_device_button_release_event_t *de;
+ unsigned int child_win = 0;
+
+ de = (xcb_input_device_button_release_event_t *)ev->pad1;
+ child_win = (de->child ? de->child : de->event);
+ _ecore_xcb_event_mouse_button(ECORE_EVENT_MOUSE_BUTTON_UP,
+ de->time, de->state, de->detail,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y, de->event,
+ child_win, de->root,
+ de->same_screen, de->device_id,
+ 1, 1, 1.0, 0.0,
+ de->event_x, de->event_y,
+ de->root_x, de->root_y);
+ }
+ break;
+
default:
break;
}
#endif
}
-EAPI Eina_Bool
-ecore_x_input_multi_select(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_input_multi_select(Ecore_X_Window win)
{
Eina_Bool find = EINA_FALSE;
#ifdef ECORE_XCB_XINPUT
@@ -226,33 +232,33 @@ ecore_x_input_multi_select(Ecore_X_Window win)
* when we can */
#ifdef ECORE_XCB_XINPUT
dcookie = xcb_input_list_input_devices_unchecked(_ecore_xcb_conn);
- dreply =
+ dreply =
xcb_input_list_input_devices_reply(_ecore_xcb_conn, dcookie, NULL);
if (!dreply) return EINA_FALSE;
diter = xcb_input_list_input_devices_devices_iterator(dreply);
- while (diter.rem)
+ while (diter.rem)
{
xcb_input_device_info_t *dev;
- const xcb_input_event_class_t iclass[] =
- {
- XCB_INPUT_DEVICE_BUTTON_PRESS,
- XCB_INPUT_DEVICE_BUTTON_RELEASE,
- XCB_INPUT_DEVICE_MOTION_NOTIFY,
- XCB_INPUT_DEVICE_TOUCH_BEGIN,
- XCB_INPUT_DEVICE_TOUCH_END,
- XCB_INPUT_DEVICE_TOUCH_UPDATE
- };
+ const xcb_input_event_class_t iclass[] =
+ {
+ XCB_INPUT_DEVICE_BUTTON_PRESS,
+ XCB_INPUT_DEVICE_BUTTON_RELEASE,
+ XCB_INPUT_DEVICE_MOTION_NOTIFY,
+ XCB_INPUT_DEVICE_TOUCH_BEGIN,
+ XCB_INPUT_DEVICE_TOUCH_END,
+ XCB_INPUT_DEVICE_TOUCH_UPDATE
+ };
dev = diter.data;
- if (dev->device_use == XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_DEVICE)
+ if (dev->device_use == XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_DEVICE)
{
DBG("Device %d", dev->device_id);
DBG("\tType: %d", dev->device_type);
DBG("\tNum Classes: %d", dev->num_class_info);
DBG("\tUse: %d", dev->device_use);
- xcb_input_select_extension_event(_ecore_xcb_conn, win,
+ xcb_input_select_extension_event(_ecore_xcb_conn, win,
sizeof(iclass) / sizeof(xcb_input_event_class_t),
iclass);
find = EINA_TRUE;
@@ -265,3 +271,4 @@ ecore_x_input_multi_select(Ecore_X_Window win)
return find;
win = 0;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_keymap.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_keymap.c
index 83f51c3ea6..40304df9cc 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_keymap.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_keymap.c
@@ -6,10 +6,17 @@
#include <X11/keysym.h>
/* local function prototypes */
-static int _ecore_xcb_keymap_mask_get(void *reply, xcb_keysym_t sym);
+static int _ecore_xcb_keymap_mask_get(void *reply,
+ xcb_keysym_t sym);
static xcb_keysym_t _ecore_xcb_keymap_string_to_keysym(const char *str);
-static int _ecore_xcb_keymap_translate_key(xcb_keycode_t keycode, unsigned int modifiers, unsigned int *modifiers_return, xcb_keysym_t *keysym_return);
-static int _ecore_xcb_keymap_translate_keysym(xcb_keysym_t keysym, unsigned int modifiers, char *buffer, int bytes);
+static int _ecore_xcb_keymap_translate_key(xcb_keycode_t keycode,
+ unsigned int modifiers,
+ unsigned int *modifiers_return,
+ xcb_keysym_t *keysym_return);
+static int _ecore_xcb_keymap_translate_keysym(xcb_keysym_t keysym,
+ unsigned int modifiers,
+ char *buffer,
+ int bytes);
/* local variables */
static xcb_key_symbols_t *_ecore_xcb_keysyms;
@@ -25,16 +32,16 @@ EAPI int ECORE_X_LOCK_NUM = 0;
EAPI int ECORE_X_LOCK_CAPS = 0;
EAPI int ECORE_X_LOCK_SHIFT = 0;
-void
-_ecore_xcb_keymap_init(void)
+void
+_ecore_xcb_keymap_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
_ecore_xcb_keysyms = xcb_key_symbols_alloc(_ecore_xcb_conn);
}
-void
-_ecore_xcb_keymap_finalize(void)
+void
+_ecore_xcb_keymap_finalize(void)
{
xcb_get_modifier_mapping_cookie_t cookie;
xcb_get_modifier_mapping_reply_t *reply;
@@ -84,33 +91,34 @@ _ecore_xcb_modifiers_get(void)
_ecore_xcb_keymap_finalize();
}
-void
-_ecore_xcb_keymap_shutdown(void)
+void
+_ecore_xcb_keymap_shutdown(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
if (_ecore_xcb_keysyms) xcb_key_symbols_free(_ecore_xcb_keysyms);
}
-void
-_ecore_xcb_keymap_refresh(xcb_mapping_notify_event_t *event)
+void
+_ecore_xcb_keymap_refresh(xcb_mapping_notify_event_t *event)
{
CHECK_XCB_CONN;
xcb_refresh_keyboard_mapping(_ecore_xcb_keysyms, event);
}
-xcb_keysym_t
-_ecore_xcb_keymap_keycode_to_keysym(xcb_keycode_t keycode, int col)
+xcb_keysym_t
+_ecore_xcb_keymap_keycode_to_keysym(xcb_keycode_t keycode,
+ int col)
{
xcb_keysym_t key0, key1;
CHECK_XCB_CONN;
- if (col & _ecore_xcb_mode_switch)
+ if (col & _ecore_xcb_mode_switch)
{
key0 = xcb_key_symbols_get_keysym(_ecore_xcb_keysyms, keycode, 4);
key1 = xcb_key_symbols_get_keysym(_ecore_xcb_keysyms, keycode, 5);
}
- else
+ else
{
key0 = xcb_key_symbols_get_keysym(_ecore_xcb_keysyms, keycode, 0);
key1 = xcb_key_symbols_get_keysym(_ecore_xcb_keysyms, keycode, 1);
@@ -119,24 +127,24 @@ _ecore_xcb_keymap_keycode_to_keysym(xcb_keycode_t keycode, int col)
if (key1 == XCB_NO_SYMBOL)
key1 = key0;
- if ((col & ECORE_X_LOCK_NUM) &&
+ if ((col & ECORE_X_LOCK_NUM) &&
((xcb_is_keypad_key(key1)) || (xcb_is_private_keypad_key(key1))))
{
- if ((col & XCB_MOD_MASK_SHIFT) ||
+ if ((col & XCB_MOD_MASK_SHIFT) ||
((col & XCB_MOD_MASK_LOCK) && (col & ECORE_X_LOCK_SHIFT)))
return key0;
else
return key1;
}
- else if (!(col & XCB_MOD_MASK_SHIFT) && !(col & XCB_MOD_MASK_LOCK))
+ else if (!(col & XCB_MOD_MASK_SHIFT) && !(col & XCB_MOD_MASK_LOCK))
return key0;
- else if (!(col & XCB_MOD_MASK_SHIFT) &&
+ else if (!(col & XCB_MOD_MASK_SHIFT) &&
(col & XCB_MOD_MASK_LOCK && (col & ECORE_X_LOCK_CAPS)))
return key1;
- else if ((col & XCB_MOD_MASK_SHIFT) &&
+ else if ((col & XCB_MOD_MASK_SHIFT) &&
(col & XCB_MOD_MASK_LOCK) && (col & ECORE_X_LOCK_CAPS))
return key0;
- else if ((col & XCB_MOD_MASK_SHIFT) ||
+ else if ((col & XCB_MOD_MASK_SHIFT) ||
(col & XCB_MOD_MASK_LOCK && (col & ECORE_X_LOCK_SHIFT)))
return key1;
@@ -144,14 +152,14 @@ _ecore_xcb_keymap_keycode_to_keysym(xcb_keycode_t keycode, int col)
}
xcb_keycode_t *
-_ecore_xcb_keymap_keysym_to_keycode(xcb_keysym_t keysym)
+_ecore_xcb_keymap_keysym_to_keycode(xcb_keysym_t keysym)
{
CHECK_XCB_CONN;
return xcb_key_symbols_get_keycode(_ecore_xcb_keysyms, keysym);
}
char *
-_ecore_xcb_keymap_keysym_to_string(xcb_keysym_t keysym)
+_ecore_xcb_keymap_keysym_to_string(xcb_keysym_t keysym)
{
int i = 0, n = 0, h = 0, idx = 0;
const unsigned char *entry;
@@ -160,7 +168,7 @@ _ecore_xcb_keymap_keysym_to_string(xcb_keysym_t keysym)
CHECK_XCB_CONN;
if (!keysym) return NULL;
if (keysym == XK_VoidSymbol) keysym = 0;
- if (keysym <= 0x1fffffff)
+ if (keysym <= 0x1fffffff)
{
val1 = (keysym >> 24);
val2 = ((keysym >> 16) & 0xff);
@@ -169,26 +177,26 @@ _ecore_xcb_keymap_keysym_to_string(xcb_keysym_t keysym)
i = keysym % VTABLESIZE;
h = i + 1;
n = VMAXHASH;
- while ((idx = hashKeysym[i]))
+ while ((idx = hashKeysym[i]))
{
entry = &_ecore_xcb_keytable[idx];
- if ((entry[0] == val1) && (entry[1] == val2) &&
+ if ((entry[0] == val1) && (entry[1] == val2) &&
(entry[2] == val3) && (entry[3] == val4))
- return ((char *)entry + 4);
+ return (char *)entry + 4;
if (!--n) break;
i += h;
if (i >= VTABLESIZE) i -= VTABLESIZE;
}
}
- if ((keysym >= 0x01000100) && (keysym <= 0x0110ffff))
+ if ((keysym >= 0x01000100) && (keysym <= 0x0110ffff))
{
xcb_keysym_t val;
char *s = NULL;
int i = 0;
val = (keysym & 0xffffff);
- if (val & 0xff0000)
+ if (val & 0xff0000)
i = 10;
else
i = 6;
@@ -196,7 +204,7 @@ _ecore_xcb_keymap_keysym_to_string(xcb_keysym_t keysym)
if (!(s = malloc(i))) return NULL;
i--;
s[i--] = '\0';
- for (; i; i--)
+ for (; i; i--)
{
val1 = (val & 0xf);
val >>= 4;
@@ -212,12 +220,12 @@ _ecore_xcb_keymap_keysym_to_string(xcb_keysym_t keysym)
return NULL;
}
-xcb_keycode_t
-_ecore_xcb_keymap_string_to_keycode(const char *key)
+xcb_keycode_t
+_ecore_xcb_keymap_string_to_keycode(const char *key)
{
if (!strncmp(key, "Keycode-", 8))
return atoi(key + 8);
- else
+ else
{
xcb_keysym_t keysym = XCB_NO_SYMBOL;
xcb_keycode_t *keycodes, keycode = 0;
@@ -231,9 +239,9 @@ _ecore_xcb_keymap_string_to_keycode(const char *key)
keycodes = _ecore_xcb_keymap_keysym_to_keycode(keysym);
if (!keycodes) return XCB_NO_SYMBOL;
- while (keycodes[i] != XCB_NO_SYMBOL)
+ while (keycodes[i] != XCB_NO_SYMBOL)
{
- if (keycodes[i] != 0)
+ if (keycodes[i] != 0)
{
keycode = keycodes[i];
break;
@@ -244,8 +252,12 @@ _ecore_xcb_keymap_string_to_keycode(const char *key)
}
}
-int
-_ecore_xcb_keymap_lookup_string(xcb_keycode_t keycode, int state, char *buffer, int bytes, xcb_keysym_t *sym)
+int
+_ecore_xcb_keymap_lookup_string(xcb_keycode_t keycode,
+ int state,
+ char *buffer,
+ int bytes,
+ xcb_keysym_t *sym)
{
unsigned int modifiers = 0;
xcb_keysym_t keysym;
@@ -260,7 +272,7 @@ _ecore_xcb_keymap_lookup_string(xcb_keycode_t keycode, int state, char *buffer,
}
EAPI const char *
-ecore_x_keysym_string_get(int keysym)
+ecore_x_keysym_string_get(int keysym)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -268,18 +280,19 @@ ecore_x_keysym_string_get(int keysym)
}
/* local functions */
-static int
-_ecore_xcb_keymap_mask_get(void *reply, xcb_keysym_t sym)
+static int
+_ecore_xcb_keymap_mask_get(void *reply,
+ xcb_keysym_t sym)
{
xcb_get_modifier_mapping_reply_t *rep;
xcb_keysym_t sym2;
int mask = 0;
- const int masks[8] =
- {
- XCB_MOD_MASK_SHIFT, XCB_MOD_MASK_LOCK, XCB_MOD_MASK_CONTROL,
- XCB_MOD_MASK_1, XCB_MOD_MASK_2, XCB_MOD_MASK_3, XCB_MOD_MASK_4,
- XCB_MOD_MASK_5
- };
+ const int masks[8] =
+ {
+ XCB_MOD_MASK_SHIFT, XCB_MOD_MASK_LOCK, XCB_MOD_MASK_CONTROL,
+ XCB_MOD_MASK_1, XCB_MOD_MASK_2, XCB_MOD_MASK_3, XCB_MOD_MASK_4,
+ XCB_MOD_MASK_5
+ };
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -291,18 +304,18 @@ _ecore_xcb_keymap_mask_get(void *reply, xcb_keysym_t sym)
xcb_keycode_t *modmap;
modmap = xcb_get_modifier_mapping_keycodes(rep);
- for (i = 0; i < (8 * rep->keycodes_per_modifier); i++)
+ for (i = 0; i < (8 * rep->keycodes_per_modifier); i++)
{
int j = 0;
- for (j = 0; j < 8; j++)
+ for (j = 0; j < 8; j++)
{
- sym2 =
- xcb_key_symbols_get_keysym(_ecore_xcb_keysyms,
+ sym2 =
+ xcb_key_symbols_get_keysym(_ecore_xcb_keysyms,
modmap[i], j);
if (sym2 != 0) break;
}
- if (sym2 == sym)
+ if (sym2 == sym)
{
mask = masks[i / rep->keycodes_per_modifier];
break;
@@ -313,8 +326,8 @@ _ecore_xcb_keymap_mask_get(void *reply, xcb_keysym_t sym)
return mask;
}
-static xcb_keysym_t
-_ecore_xcb_keymap_string_to_keysym(const char *str)
+static xcb_keysym_t
+_ecore_xcb_keymap_string_to_keysym(const char *str)
{
int i = 0, n = 0, h = 0;
unsigned long sig = 0;
@@ -334,26 +347,26 @@ _ecore_xcb_keymap_string_to_keysym(const char *str)
sig2 = sig & 0xff;
n = KMAXHASH;
- while ((idx = hashString[i]))
+ while ((idx = hashString[i]))
{
entry = &_ecore_xcb_keytable[idx];
- if ((entry[0] == sig1) && (entry[1] == sig2) &&
+ if ((entry[0] == sig1) && (entry[1] == sig2) &&
!strcmp(str, (char *)entry + 6))
{
- val = ((entry[2] << 24) | (entry[3] << 16) |
+ val = ((entry[2] << 24) | (entry[3] << 16) |
(entry[4] << 8) | (entry[5]));
if (!val) val = 0xffffff;
return val;
}
if (!--n) break;
i += h;
- if (i >= KTABLESIZE) i-= KTABLESIZE;
+ if (i >= KTABLESIZE) i -= KTABLESIZE;
}
- if (*str == 'U')
+ if (*str == 'U')
{
val = 0;
- for (p = &str[1]; *p; p++)
+ for (p = &str[1]; *p; p++)
{
c = *p;
if (('0' <= c) && (c <= '9'))
@@ -369,10 +382,10 @@ _ecore_xcb_keymap_string_to_keysym(const char *str)
if ((val < 0x20) || ((val > 0x7e) && (val < 0xa0)))
return XCB_NO_SYMBOL;
if (val < 0x100) return val;
- return (val | 0x01000000);
+ return val | 0x01000000;
}
- if ((strlen(str) > 2) && (str[0] == '0') && (str[1] == 'x'))
+ if ((strlen(str) > 2) && (str[0] == '0') && (str[1] == 'x'))
{
char *tmp = NULL;
@@ -383,7 +396,7 @@ _ecore_xcb_keymap_string_to_keysym(const char *str)
return val;
}
- if (!strncmp(str, "XF86_", 5))
+ if (!strncmp(str, "XF86_", 5))
{
long unsigned int ret;
char *tmp;
@@ -399,8 +412,11 @@ _ecore_xcb_keymap_string_to_keysym(const char *str)
return XCB_NO_SYMBOL;
}
-static int
-_ecore_xcb_keymap_translate_key(xcb_keycode_t keycode, unsigned int modifiers, unsigned int *modifiers_return, xcb_keysym_t *keysym_return)
+static int
+_ecore_xcb_keymap_translate_key(xcb_keycode_t keycode,
+ unsigned int modifiers,
+ unsigned int *modifiers_return,
+ xcb_keysym_t *keysym_return)
{
xcb_keysym_t sym;
@@ -409,7 +425,7 @@ _ecore_xcb_keymap_translate_key(xcb_keycode_t keycode, unsigned int modifiers, u
sym = _ecore_xcb_keymap_keycode_to_keysym(keycode, modifiers);
if (modifiers_return)
- *modifiers_return = ((XCB_MOD_MASK_SHIFT | XCB_MOD_MASK_LOCK) |
+ *modifiers_return = ((XCB_MOD_MASK_SHIFT | XCB_MOD_MASK_LOCK) |
_ecore_xcb_mode_switch | ECORE_X_LOCK_NUM);
if (keysym_return)
*keysym_return = sym;
@@ -417,8 +433,11 @@ _ecore_xcb_keymap_translate_key(xcb_keycode_t keycode, unsigned int modifiers, u
return 1;
}
-static int
-_ecore_xcb_keymap_translate_keysym(xcb_keysym_t keysym, unsigned int modifiers, char *buffer, int bytes)
+static int
+_ecore_xcb_keymap_translate_keysym(xcb_keysym_t keysym,
+ unsigned int modifiers,
+ char *buffer,
+ int bytes)
{
unsigned long hbytes = 0;
unsigned char c;
@@ -427,14 +446,14 @@ _ecore_xcb_keymap_translate_keysym(xcb_keysym_t keysym, unsigned int modifiers,
hbytes = (keysym >> 8);
if (!(bytes &&
- ((hbytes == 0) ||
- ((hbytes == 0xFF) &&
- (((keysym >= XK_BackSpace) && (keysym <= XK_Clear)) ||
- (keysym == XK_Return) || (keysym == XK_Escape) ||
- (keysym == XK_KP_Space) || (keysym == XK_KP_Tab) ||
- (keysym == XK_KP_Enter) ||
- ((keysym >= XK_KP_Multiply) && (keysym <= XK_KP_9)) ||
- (keysym == XK_KP_Equal) || (keysym == XK_Delete))))))
+ ((hbytes == 0) ||
+ ((hbytes == 0xFF) &&
+ (((keysym >= XK_BackSpace) && (keysym <= XK_Clear)) ||
+ (keysym == XK_Return) || (keysym == XK_Escape) ||
+ (keysym == XK_KP_Space) || (keysym == XK_KP_Tab) ||
+ (keysym == XK_KP_Enter) ||
+ ((keysym >= XK_KP_Multiply) && (keysym <= XK_KP_9)) ||
+ (keysym == XK_KP_Equal) || (keysym == XK_Delete))))))
return 0;
if (keysym == XK_KP_Space)
@@ -444,19 +463,20 @@ _ecore_xcb_keymap_translate_keysym(xcb_keysym_t keysym, unsigned int modifiers,
else
c = (keysym & 0xFF);
- if (modifiers & ECORE_X_MODIFIER_CTRL)
+ if (modifiers & ECORE_X_MODIFIER_CTRL)
{
if (((c >= '@') && (c < '\177')) || c == ' ')
c &= 0x1F;
- else if (c == '2')
+ else if (c == '2')
c = '\000';
else if ((c >= '3') && (c <= '7'))
c -= ('3' - '\033');
- else if (c == '8')
+ else if (c == '8')
c = '\177';
- else if (c == '/')
+ else if (c == '/')
c = '_' & 0x1F;
}
buffer[0] = c;
return 1;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_mwm.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_mwm.c
index cd89fd77e4..5111db4b86 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_mwm.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_mwm.c
@@ -1,17 +1,17 @@
#include "ecore_xcb_private.h"
//#include "Ecore_X_Atoms.h"
-#define ECORE_X_MWM_HINTS_FUNCTIONS (1 << 0)
+#define ECORE_X_MWM_HINTS_FUNCTIONS (1 << 0)
#define ECORE_X_MWM_HINTS_DECORATIONS (1 << 1)
-#define ECORE_X_MWM_HINTS_INPUT_MODE (1 << 2)
-#define ECORE_X_MWM_HINTS_STATUS (1 << 3)
+#define ECORE_X_MWM_HINTS_INPUT_MODE (1 << 2)
+#define ECORE_X_MWM_HINTS_STATUS (1 << 3)
typedef struct _mwmhints
{
uint32_t flags;
uint32_t functions;
uint32_t decorations;
- int32_t inputmode;
+ int32_t inputmode;
uint32_t status;
} MWMHints;
@@ -23,14 +23,15 @@ typedef struct _mwmhints
/**
* Sets the borderless flag of a window using MWM.
- *
+ *
* @param win The window.
* @param borderless The borderless flag.
- *
+ *
* @ingroup Ecore_X_MWM_Group
*/
-EAPI void
-ecore_x_mwm_borderless_set(Ecore_X_Window win, Eina_Bool borderless)
+EAPI void
+ecore_x_mwm_borderless_set(Ecore_X_Window win,
+ Eina_Bool borderless)
{
uint32_t data[5] = { 0, 0, 0, 0, 0 };
@@ -39,14 +40,17 @@ ecore_x_mwm_borderless_set(Ecore_X_Window win, Eina_Bool borderless)
data[0] = 2;
data[2] = !borderless;
- ecore_x_window_prop_property_set(win,
- ECORE_X_ATOM_MOTIF_WM_HINTS,
- ECORE_X_ATOM_MOTIF_WM_HINTS, 32,
+ ecore_x_window_prop_property_set(win,
+ ECORE_X_ATOM_MOTIF_WM_HINTS,
+ ECORE_X_ATOM_MOTIF_WM_HINTS, 32,
(void *)data, 5);
}
-EAPI Eina_Bool
-ecore_x_mwm_hints_get(Ecore_X_Window win, Ecore_X_MWM_Hint_Func *fhint, Ecore_X_MWM_Hint_Decor *dhint, Ecore_X_MWM_Hint_Input *ihint)
+EAPI Eina_Bool
+ecore_x_mwm_hints_get(Ecore_X_Window win,
+ Ecore_X_MWM_Hint_Func *fhint,
+ Ecore_X_MWM_Hint_Decor *dhint,
+ Ecore_X_MWM_Hint_Input *ihint)
{
xcb_get_property_cookie_t cookie;
xcb_get_property_reply_t *reply;
@@ -56,36 +60,36 @@ ecore_x_mwm_hints_get(Ecore_X_Window win, Ecore_X_MWM_Hint_Func *fhint, Ecore_X_
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
- cookie =
- xcb_get_property_unchecked(_ecore_xcb_conn, 0, win,
- ECORE_X_ATOM_MOTIF_WM_HINTS,
+ cookie =
+ xcb_get_property_unchecked(_ecore_xcb_conn, 0, win,
+ ECORE_X_ATOM_MOTIF_WM_HINTS,
ECORE_X_ATOM_MOTIF_WM_HINTS, 0, LONG_MAX);
reply = xcb_get_property_reply(_ecore_xcb_conn, cookie, NULL);
if (!reply) return EINA_FALSE;
- if ((reply->format != 32) || (reply->value_len == 0))
+ if ((reply->format != 32) || (reply->value_len == 0))
{
free(reply);
return EINA_FALSE;
}
mwmhints = xcb_get_property_value(reply);
- if (reply->value_len >= 4)
+ if (reply->value_len >= 4)
{
- if (dhint)
+ if (dhint)
{
if (mwmhints->flags & ECORE_X_MWM_HINTS_DECORATIONS)
*dhint = mwmhints->decorations;
else
*dhint = ECORE_X_MWM_HINT_DECOR_ALL;
}
- if (fhint)
+ if (fhint)
{
if (mwmhints->flags & ECORE_X_MWM_HINTS_FUNCTIONS)
*fhint = mwmhints->functions;
else
*fhint = ECORE_X_MWM_HINT_FUNC_ALL;
}
- if (ihint)
+ if (ihint)
{
if (mwmhints->flags & ECORE_X_MWM_HINTS_INPUT_MODE)
*ihint = mwmhints->inputmode;
@@ -97,3 +101,4 @@ ecore_x_mwm_hints_get(Ecore_X_Window win, Ecore_X_MWM_Hint_Func *fhint, Ecore_X_
free(reply);
return ret;
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_netwm.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_netwm.c
index 6ac8805b34..1d041d3a41 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_netwm.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_netwm.c
@@ -2,43 +2,43 @@
/* local function prototypes */
/* static void _ecore_xcb_netwm_startup_info_free(void *data); */
-static Ecore_X_Atom _ecore_xcb_netwm_window_type_atom_get(Ecore_X_Window_Type type);
+static Ecore_X_Atom _ecore_xcb_netwm_window_type_atom_get(Ecore_X_Window_Type type);
static Ecore_X_Window_Type _ecore_xcb_netwm_window_type_type_get(Ecore_X_Atom atom);
-static Ecore_X_Atom _ecore_xcb_netwm_window_state_atom_get(Ecore_X_Window_State state);
-static Ecore_X_Atom _ecore_xcb_netwm_action_atom_get(Ecore_X_Action action);
+static Ecore_X_Atom _ecore_xcb_netwm_window_state_atom_get(Ecore_X_Window_State state);
+static Ecore_X_Atom _ecore_xcb_netwm_action_atom_get(Ecore_X_Action action);
/* local variables */
//static Eina_Hash *_startup_info = NULL;
/* local structures */
typedef struct _Ecore_Xcb_Startup_Info Ecore_Xcb_Startup_Info;
-struct _Ecore_Xcb_Startup_Info
+struct _Ecore_Xcb_Startup_Info
{
Ecore_X_Window win;
- int init, size;
- char *buffer;
- int length;
+ int init, size;
+ char *buffer;
+ int length;
/* sequence info fields */
- char *id, *name;
- int screen;
- char *bin, *icon;
- int desktop, timestamp;
- char *description, *wmclass;
- int silent;
+ char *id, *name;
+ int screen;
+ char *bin, *icon;
+ int desktop, timestamp;
+ char *description, *wmclass;
+ int silent;
};
-EAPI void
-ecore_x_netwm_init(void)
+EAPI void
+ecore_x_netwm_init(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
-// _startup_info =
+// _startup_info =
// eina_hash_string_superfast_new(_ecore_xcb_netwm_startup_info_free);
}
-EAPI void
-ecore_x_netwm_shutdown(void)
+EAPI void
+ecore_x_netwm_shutdown(void)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -46,8 +46,9 @@ ecore_x_netwm_shutdown(void)
// _startup_info = NULL;
}
-EAPI Eina_Bool
-ecore_x_netwm_pid_get(Ecore_X_Window win, int *pid)
+EAPI Eina_Bool
+ecore_x_netwm_pid_get(Ecore_X_Window win,
+ int *pid)
{
uint32_t tmp;
@@ -61,8 +62,9 @@ ecore_x_netwm_pid_get(Ecore_X_Window win, int *pid)
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_pid_set(Ecore_X_Window win, int pid)
+EAPI void
+ecore_x_netwm_pid_set(Ecore_X_Window win,
+ int pid)
{
unsigned int tmp;
@@ -72,8 +74,9 @@ ecore_x_netwm_pid_set(Ecore_X_Window win, int pid)
ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_PID, &tmp, 1);
}
-EAPI Eina_Bool
-ecore_x_netwm_window_type_get(Ecore_X_Window win, Ecore_X_Window_Type *type)
+EAPI Eina_Bool
+ecore_x_netwm_window_type_get(Ecore_X_Window win,
+ Ecore_X_Window_Type *type)
{
Ecore_X_Atom *atoms;
int num = 0;
@@ -82,8 +85,8 @@ ecore_x_netwm_window_type_get(Ecore_X_Window win, Ecore_X_Window_Type *type)
if (type) *type = ECORE_X_WINDOW_TYPE_NORMAL;
- num =
- ecore_x_window_prop_atom_list_get(win,
+ num =
+ ecore_x_window_prop_atom_list_get(win,
ECORE_X_ATOM_NET_WM_WINDOW_TYPE, &atoms);
if ((type) && (num >= 1) && (atoms))
*type = _ecore_xcb_netwm_window_type_type_get(atoms[0]);
@@ -94,8 +97,9 @@ ecore_x_netwm_window_type_get(Ecore_X_Window win, Ecore_X_Window_Type *type)
return EINA_FALSE;
}
-EAPI void
-ecore_x_netwm_window_type_set(Ecore_X_Window win, Ecore_X_Window_Type type)
+EAPI void
+ecore_x_netwm_window_type_set(Ecore_X_Window win,
+ Ecore_X_Window_Type type)
{
Ecore_X_Atom atom;
@@ -105,8 +109,9 @@ ecore_x_netwm_window_type_set(Ecore_X_Window win, Ecore_X_Window_Type type)
ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_NET_WM_WINDOW_TYPE, &atom, 1);
}
-EAPI int
-ecore_x_netwm_window_types_get(Ecore_X_Window win, Ecore_X_Window_Type **types)
+EAPI int
+ecore_x_netwm_window_types_get(Ecore_X_Window win,
+ Ecore_X_Window_Type **types)
{
int num = 0, i = 0;
Ecore_X_Atom *atoms = NULL;
@@ -115,17 +120,17 @@ ecore_x_netwm_window_types_get(Ecore_X_Window win, Ecore_X_Window_Type **types)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
if (types) *types = NULL;
- num =
- ecore_x_window_prop_atom_list_get(win, ECORE_X_ATOM_NET_WM_WINDOW_TYPE,
+ num =
+ ecore_x_window_prop_atom_list_get(win, ECORE_X_ATOM_NET_WM_WINDOW_TYPE,
&atoms);
- if ((num <= 0) || (!atoms))
+ if ((num <= 0) || (!atoms))
{
if (atoms) free(atoms);
return 0;
}
atoms2 = malloc(num * sizeof(Ecore_X_Window_Type));
- if (!atoms2)
+ if (!atoms2)
{
if (atoms) free(atoms);
return 0;
@@ -135,7 +140,7 @@ ecore_x_netwm_window_types_get(Ecore_X_Window win, Ecore_X_Window_Type **types)
atoms2[i] = _ecore_xcb_netwm_window_type_type_get(atoms[i]);
if (atoms) free(atoms);
- if (types)
+ if (types)
*types = atoms2;
else
free(atoms2);
@@ -143,41 +148,45 @@ ecore_x_netwm_window_types_get(Ecore_X_Window win, Ecore_X_Window_Type **types)
return num;
}
-EAPI int
-ecore_x_netwm_name_get(Ecore_X_Window win, char **name)
+EAPI int
+ecore_x_netwm_name_get(Ecore_X_Window win,
+ char **name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (name)
+ if (name)
*name = ecore_x_window_prop_string_get(win, ECORE_X_ATOM_NET_WM_NAME);
return 1;
}
-EAPI void
-ecore_x_netwm_name_set(Ecore_X_Window win, const char *name)
+EAPI void
+ecore_x_netwm_name_set(Ecore_X_Window win,
+ const char *name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
ecore_x_window_prop_string_set(win, ECORE_X_ATOM_NET_WM_NAME, name);
}
-EAPI void
-ecore_x_netwm_opacity_set(Ecore_X_Window win, unsigned int opacity)
+EAPI void
+ecore_x_netwm_opacity_set(Ecore_X_Window win,
+ unsigned int opacity)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_WINDOW_OPACITY,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_WINDOW_OPACITY,
&opacity, 1);
}
-EAPI Eina_Bool
-ecore_x_netwm_opacity_get(Ecore_X_Window win, unsigned int *opacity)
+EAPI Eina_Bool
+ecore_x_netwm_opacity_get(Ecore_X_Window win,
+ unsigned int *opacity)
{
unsigned int tmp = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_WINDOW_OPACITY,
+ if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_WINDOW_OPACITY,
&tmp, 1))
return EINA_FALSE;
@@ -186,30 +195,36 @@ ecore_x_netwm_opacity_get(Ecore_X_Window win, unsigned int *opacity)
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_wm_identify(Ecore_X_Window root, Ecore_X_Window check, const char *wm_name)
+EAPI void
+ecore_x_netwm_wm_identify(Ecore_X_Window root,
+ Ecore_X_Window check,
+ const char *wm_name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_window_set(root, ECORE_X_ATOM_NET_SUPPORTING_WM_CHECK,
+ ecore_x_window_prop_window_set(root, ECORE_X_ATOM_NET_SUPPORTING_WM_CHECK,
&check, 1);
- ecore_x_window_prop_window_set(check, ECORE_X_ATOM_NET_SUPPORTING_WM_CHECK,
+ ecore_x_window_prop_window_set(check, ECORE_X_ATOM_NET_SUPPORTING_WM_CHECK,
&check, 1);
ecore_x_window_prop_string_set(check, ECORE_X_ATOM_NET_WM_NAME, wm_name);
ecore_x_window_prop_string_set(root, ECORE_X_ATOM_NET_WM_NAME, wm_name);
}
-EAPI void
-ecore_x_netwm_supported_set(Ecore_X_Window root, Ecore_X_Atom *supported, int num)
+EAPI void
+ecore_x_netwm_supported_set(Ecore_X_Window root,
+ Ecore_X_Atom *supported,
+ int num)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_atom_set(root, ECORE_X_ATOM_NET_SUPPORTED,
+ ecore_x_window_prop_atom_set(root, ECORE_X_ATOM_NET_SUPPORTED,
supported, num);
}
-EAPI Eina_Bool
-ecore_x_netwm_supported_get(Ecore_X_Window root, Ecore_X_Atom **supported, int *num)
+EAPI Eina_Bool
+ecore_x_netwm_supported_get(Ecore_X_Window root,
+ Ecore_X_Atom **supported,
+ int *num)
{
int num_ret = 0;
@@ -218,8 +233,8 @@ ecore_x_netwm_supported_get(Ecore_X_Window root, Ecore_X_Atom **supported, int *
if (num) *num = 0;
if (supported) *supported = NULL;
- num_ret =
- ecore_x_window_prop_atom_list_get(root, ECORE_X_ATOM_NET_SUPPORTED,
+ num_ret =
+ ecore_x_window_prop_atom_list_get(root, ECORE_X_ATOM_NET_SUPPORTED,
supported);
if (num_ret <= 0) return EINA_FALSE;
if (num) *num = num_ret;
@@ -227,26 +242,31 @@ ecore_x_netwm_supported_get(Ecore_X_Window root, Ecore_X_Atom **supported, int *
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_desk_count_set(Ecore_X_Window root, unsigned int n_desks)
+EAPI void
+ecore_x_netwm_desk_count_set(Ecore_X_Window root,
+ unsigned int n_desks)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_NUMBER_OF_DESKTOPS,
+ ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_NUMBER_OF_DESKTOPS,
&n_desks, 1);
}
-EAPI void
-ecore_x_netwm_desk_roots_set(Ecore_X_Window root, Ecore_X_Window *vroots, unsigned int n_desks)
+EAPI void
+ecore_x_netwm_desk_roots_set(Ecore_X_Window root,
+ Ecore_X_Window *vroots,
+ unsigned int n_desks)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_window_set(root, ECORE_X_ATOM_NET_VIRTUAL_ROOTS,
+ ecore_x_window_prop_window_set(root, ECORE_X_ATOM_NET_VIRTUAL_ROOTS,
vroots, n_desks);
}
-EAPI void
-ecore_x_netwm_desk_names_set(Ecore_X_Window root, const char **names, unsigned int n_desks)
+EAPI void
+ecore_x_netwm_desk_names_set(Ecore_X_Window root,
+ const char **names,
+ unsigned int n_desks)
{
char ss[32], *buf = NULL, *t = NULL;
const char *s;
@@ -261,13 +281,13 @@ ecore_x_netwm_desk_names_set(Ecore_X_Window root, const char **names, unsigned i
if (!s)
{
/* Default to "Desk-<number>" */
- sprintf(ss, "Desk-%d", i);
- s = ss;
+ sprintf(ss, "Desk-%d", i);
+ s = ss;
}
l = strlen(s) + 1;
t = realloc(buf, len + 1);
- if (t)
+ if (t)
{
buf = t;
memcpy(buf + len, s, l);
@@ -276,14 +296,16 @@ ecore_x_netwm_desk_names_set(Ecore_X_Window root, const char **names, unsigned i
}
xcb_change_property(_ecore_xcb_conn, XCB_PROP_MODE_REPLACE, root,
- ECORE_X_ATOM_NET_DESKTOP_NAMES,
+ ECORE_X_ATOM_NET_DESKTOP_NAMES,
ECORE_X_ATOM_UTF8_STRING, 8, len, (const void *)buf);
// ecore_x_flush();
free(buf);
}
-EAPI void
-ecore_x_netwm_desk_size_set(Ecore_X_Window root, unsigned int width, unsigned int height)
+EAPI void
+ecore_x_netwm_desk_size_set(Ecore_X_Window root,
+ unsigned int width,
+ unsigned int height)
{
uint32_t size[2];
@@ -291,21 +313,27 @@ ecore_x_netwm_desk_size_set(Ecore_X_Window root, unsigned int width, unsigned in
size[0] = width;
size[1] = height;
- ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_DESKTOP_GEOMETRY,
+ ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_DESKTOP_GEOMETRY,
size, 2);
}
-EAPI void
-ecore_x_netwm_desk_viewports_set(Ecore_X_Window root, unsigned int *origins, unsigned int n_desks)
+EAPI void
+ecore_x_netwm_desk_viewports_set(Ecore_X_Window root,
+ unsigned int *origins,
+ unsigned int n_desks)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_DESKTOP_VIEWPORT,
+ ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_DESKTOP_VIEWPORT,
origins, (2 * n_desks));
}
-EAPI void
-ecore_x_netwm_desk_layout_set(Ecore_X_Window root, int orientation, int columns, int rows, int starting_corner)
+EAPI void
+ecore_x_netwm_desk_layout_set(Ecore_X_Window root,
+ int orientation,
+ int columns,
+ int rows,
+ int starting_corner)
{
unsigned int layout[4];
@@ -315,64 +343,74 @@ ecore_x_netwm_desk_layout_set(Ecore_X_Window root, int orientation, int columns,
layout[1] = columns;
layout[2] = rows;
layout[3] = starting_corner;
- ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_DESKTOP_LAYOUT,
+ ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_DESKTOP_LAYOUT,
layout, 4);
}
-EAPI void
-ecore_x_netwm_desk_workareas_set(Ecore_X_Window root, unsigned int *areas, unsigned int n_desks)
+EAPI void
+ecore_x_netwm_desk_workareas_set(Ecore_X_Window root,
+ unsigned int *areas,
+ unsigned int n_desks)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_WORKAREA, areas,
+ ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_WORKAREA, areas,
4 * n_desks);
}
-EAPI void
-ecore_x_netwm_desk_current_set(Ecore_X_Window root, unsigned int desk)
+EAPI void
+ecore_x_netwm_desk_current_set(Ecore_X_Window root,
+ unsigned int desk)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_CURRENT_DESKTOP,
+ ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_CURRENT_DESKTOP,
&desk, 1);
}
-EAPI void
-ecore_x_netwm_showing_desktop_set(Ecore_X_Window root, Eina_Bool on)
+EAPI void
+ecore_x_netwm_showing_desktop_set(Ecore_X_Window root,
+ Eina_Bool on)
{
unsigned int val = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
val = ((on) ? 1 : 0);
- ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_SHOWING_DESKTOP,
+ ecore_x_window_prop_card32_set(root, ECORE_X_ATOM_NET_SHOWING_DESKTOP,
&val, 1);
}
-EAPI int
-ecore_x_netwm_startup_id_get(Ecore_X_Window win, char **id)
+EAPI int
+ecore_x_netwm_startup_id_get(Ecore_X_Window win,
+ char **id)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (id)
+ if (id)
{
- *id =
+ *id =
ecore_x_window_prop_string_get(win, ECORE_X_ATOM_NET_STARTUP_ID);
}
return 1;
}
-EAPI void
-ecore_x_netwm_startup_id_set(Ecore_X_Window win, const char *id)
+EAPI void
+ecore_x_netwm_startup_id_set(Ecore_X_Window win,
+ const char *id)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
ecore_x_window_prop_string_set(win, ECORE_X_ATOM_NET_STARTUP_ID, id);
}
-EAPI void
-ecore_x_netwm_state_request_send(Ecore_X_Window win, Ecore_X_Window root, Ecore_X_Window_State s1, Ecore_X_Window_State s2, Eina_Bool set)
+EAPI void
+ecore_x_netwm_state_request_send(Ecore_X_Window win,
+ Ecore_X_Window root,
+ Ecore_X_Window_State s1,
+ Ecore_X_Window_State s2,
+ Eina_Bool set)
{
xcb_client_message_event_t ev;
@@ -393,21 +431,23 @@ ecore_x_netwm_state_request_send(Ecore_X_Window win, Ecore_X_Window root, Ecore_
ev.data.data32[3] = 1;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, root,
- (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
- XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
+ xcb_send_event(_ecore_xcb_conn, 0, root,
+ (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
+ XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_netwm_window_state_set(Ecore_X_Window win, Ecore_X_Window_State *state, unsigned int num)
+EAPI void
+ecore_x_netwm_window_state_set(Ecore_X_Window win,
+ Ecore_X_Window_State *state,
+ unsigned int num)
{
Ecore_X_Atom *set;
unsigned int i = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!num)
+ if (!num)
{
ecore_x_window_prop_property_del(win, ECORE_X_ATOM_NET_WM_STATE);
return;
@@ -416,15 +456,17 @@ ecore_x_netwm_window_state_set(Ecore_X_Window win, Ecore_X_Window_State *state,
set = malloc(num * sizeof(Ecore_X_Atom));
if (!set) return;
- for (i = 0; i < num; i++)
+ for (i = 0; i < num; i++)
set[i] = _ecore_xcb_netwm_window_state_atom_get(state[i]);
ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_NET_WM_STATE, set, num);
free(set);
}
-EAPI Eina_Bool
-ecore_x_netwm_window_state_get(Ecore_X_Window win, Ecore_X_Window_State **state, unsigned int *num)
+EAPI Eina_Bool
+ecore_x_netwm_window_state_get(Ecore_X_Window win,
+ Ecore_X_Window_State **state,
+ unsigned int *num)
{
Ecore_X_Atom *atoms;
int ret = 0;
@@ -434,15 +476,15 @@ ecore_x_netwm_window_state_get(Ecore_X_Window win, Ecore_X_Window_State **state,
if (num) *num = 0;
if (state) *state = NULL;
- ret =
+ ret =
ecore_x_window_prop_atom_list_get(win, ECORE_X_ATOM_NET_WM_STATE, &atoms);
if (ret <= 0) return EINA_FALSE;
- if (state)
+ if (state)
{
*state = malloc(ret * sizeof(Ecore_X_Window_State));
- if (*state)
+ if (*state)
{
int i = 0;
@@ -457,17 +499,21 @@ ecore_x_netwm_window_state_get(Ecore_X_Window win, Ecore_X_Window_State **state,
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_client_active_set(Ecore_X_Window root, Ecore_X_Window win)
+EAPI void
+ecore_x_netwm_client_active_set(Ecore_X_Window root,
+ Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_window_set(root,
+ ecore_x_window_prop_window_set(root,
ECORE_X_ATOM_NET_ACTIVE_WINDOW, &win, 1);
}
-EAPI void
-ecore_x_netwm_client_active_request(Ecore_X_Window root, Ecore_X_Window win, int type, Ecore_X_Window current_win)
+EAPI void
+ecore_x_netwm_client_active_request(Ecore_X_Window root,
+ Ecore_X_Window win,
+ int type,
+ Ecore_X_Window current_win)
{
xcb_client_message_event_t ev;
@@ -486,32 +532,36 @@ ecore_x_netwm_client_active_request(Ecore_X_Window root, Ecore_X_Window win, int
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, root,
- (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
- XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
+ xcb_send_event(_ecore_xcb_conn, 0, root,
+ (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
+ XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_netwm_client_list_set(Ecore_X_Window root, Ecore_X_Window *p_clients, unsigned int n_clients)
+EAPI void
+ecore_x_netwm_client_list_set(Ecore_X_Window root,
+ Ecore_X_Window *p_clients,
+ unsigned int n_clients)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_window_set(root, ECORE_X_ATOM_NET_CLIENT_LIST,
+ ecore_x_window_prop_window_set(root, ECORE_X_ATOM_NET_CLIENT_LIST,
p_clients, n_clients);
}
-EAPI void
-ecore_x_netwm_client_list_stacking_set(Ecore_X_Window root, Ecore_X_Window *p_clients, unsigned int n_clients)
+EAPI void
+ecore_x_netwm_client_list_stacking_set(Ecore_X_Window root,
+ Ecore_X_Window *p_clients,
+ unsigned int n_clients)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_window_set(root, ECORE_X_ATOM_NET_CLIENT_LIST_STACKING,
+ ecore_x_window_prop_window_set(root, ECORE_X_ATOM_NET_CLIENT_LIST_STACKING,
p_clients, n_clients);
}
-EAPI Eina_Bool
-ecore_x_screen_is_composited(int screen)
+EAPI Eina_Bool
+ecore_x_screen_is_composited(int screen)
{
char buff[32];
xcb_get_selection_owner_cookie_t ocookie;
@@ -524,12 +574,12 @@ ecore_x_screen_is_composited(int screen)
snprintf(buff, sizeof(buff), "_NET_WM_CM_S%i", screen);
- if (atom == XCB_NONE)
+ if (atom == XCB_NONE)
{
xcb_intern_atom_cookie_t acookie;
xcb_intern_atom_reply_t *areply;
- acookie =
+ acookie =
xcb_intern_atom_unchecked(_ecore_xcb_conn, 0, strlen(buff), buff);
areply = xcb_intern_atom_reply(_ecore_xcb_conn, acookie, NULL);
if (!areply) return EINA_FALSE;
@@ -547,8 +597,9 @@ ecore_x_screen_is_composited(int screen)
return (win != XCB_NONE) ? EINA_TRUE : EINA_FALSE;
}
-EAPI void
-ecore_x_screen_is_composited_set(int screen, Ecore_X_Window win)
+EAPI void
+ecore_x_screen_is_composited_set(int screen,
+ Ecore_X_Window win)
{
static Ecore_X_Atom atom = XCB_NONE;
char buff[32];
@@ -557,12 +608,12 @@ ecore_x_screen_is_composited_set(int screen, Ecore_X_Window win)
CHECK_XCB_CONN;
snprintf(buff, sizeof(buff), "_NET_WM_CM_S%i", screen);
- if (atom == XCB_NONE)
+ if (atom == XCB_NONE)
{
xcb_intern_atom_cookie_t acookie;
xcb_intern_atom_reply_t *areply;
- acookie =
+ acookie =
xcb_intern_atom_unchecked(_ecore_xcb_conn, 0, strlen(buff), buff);
areply = xcb_intern_atom_reply(_ecore_xcb_conn, acookie, NULL);
if (!areply) return;
@@ -570,12 +621,12 @@ ecore_x_screen_is_composited_set(int screen, Ecore_X_Window win)
free(areply);
}
if (atom == XCB_NONE) return;
- xcb_set_selection_owner(_ecore_xcb_conn, win, atom,
+ xcb_set_selection_owner(_ecore_xcb_conn, win, atom,
_ecore_xcb_events_last_time_get());
}
-EAPI void
-ecore_x_netwm_ping_send(Ecore_X_Window win)
+EAPI void
+ecore_x_netwm_ping_send(Ecore_X_Window win)
{
xcb_client_message_event_t ev;
@@ -594,13 +645,17 @@ ecore_x_netwm_ping_send(Ecore_X_Window win)
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_netwm_frame_size_set(Ecore_X_Window win, int fl, int fr, int ft, int fb)
+EAPI void
+ecore_x_netwm_frame_size_set(Ecore_X_Window win,
+ int fl,
+ int fr,
+ int ft,
+ int fb)
{
uint32_t frames[4];
@@ -610,19 +665,23 @@ ecore_x_netwm_frame_size_set(Ecore_X_Window win, int fl, int fr, int ft, int fb)
frames[1] = fr;
frames[2] = ft;
frames[3] = fb;
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_FRAME_EXTENTS,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_FRAME_EXTENTS,
frames, 4);
}
-EAPI Eina_Bool
-ecore_x_netwm_frame_size_get(Ecore_X_Window win, int *fl, int *fr, int *ft, int *fb)
+EAPI Eina_Bool
+ecore_x_netwm_frame_size_get(Ecore_X_Window win,
+ int *fl,
+ int *fr,
+ int *ft,
+ int *fb)
{
int ret = 0;
unsigned int frames[4];
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ret = ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_FRAME_EXTENTS,
+ ret = ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_FRAME_EXTENTS,
frames, 4);
if (ret != 4) return EINA_FALSE;
@@ -634,8 +693,9 @@ ecore_x_netwm_frame_size_get(Ecore_X_Window win, int *fl, int *fr, int *ft, int
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_sync_request_send(Ecore_X_Window win, unsigned int serial)
+EAPI void
+ecore_x_netwm_sync_request_send(Ecore_X_Window win,
+ unsigned int serial)
{
xcb_client_message_event_t ev;
@@ -657,27 +717,29 @@ ecore_x_netwm_sync_request_send(Ecore_X_Window win, unsigned int serial)
ev.data.data32[3] = 0;
ev.data.data32[4] = 0;
- xcb_send_event(_ecore_xcb_conn, 0, win,
+ xcb_send_event(_ecore_xcb_conn, 0, win,
XCB_EVENT_MASK_NO_EVENT, (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_netwm_desktop_set(Ecore_X_Window win, unsigned int desk)
+EAPI void
+ecore_x_netwm_desktop_set(Ecore_X_Window win,
+ unsigned int desk)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_DESKTOP, &desk, 1);
}
-EAPI Eina_Bool
-ecore_x_netwm_desktop_get(Ecore_X_Window win, unsigned int *desk)
+EAPI Eina_Bool
+ecore_x_netwm_desktop_get(Ecore_X_Window win,
+ unsigned int *desk)
{
unsigned int tmp = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_DESKTOP,
+ if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_DESKTOP,
&tmp, 1))
return EINA_FALSE;
@@ -686,8 +748,10 @@ ecore_x_netwm_desktop_get(Ecore_X_Window win, unsigned int *desk)
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_desktop_request_send(Ecore_X_Window win, Ecore_X_Window root, unsigned int desktop)
+EAPI void
+ecore_x_netwm_desktop_request_send(Ecore_X_Window win,
+ Ecore_X_Window root,
+ unsigned int desktop)
{
xcb_client_message_event_t ev;
@@ -704,57 +768,61 @@ ecore_x_netwm_desktop_request_send(Ecore_X_Window win, Ecore_X_Window root, unsi
ev.type = ECORE_X_ATOM_NET_WM_DESKTOP;
ev.data.data32[0] = desktop;
- xcb_send_event(_ecore_xcb_conn, 0, root,
- (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
- XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
+ xcb_send_event(_ecore_xcb_conn, 0, root,
+ (XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT |
+ XCB_EVENT_MASK_SUBSTRUCTURE_NOTIFY), (const char *)&ev);
// ecore_x_flush();
}
-EAPI void
-ecore_x_netwm_handled_icons_set(Ecore_X_Window win)
+EAPI void
+ecore_x_netwm_handled_icons_set(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_HANDLED_ICONS,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_HANDLED_ICONS,
NULL, 0);
}
-EAPI Eina_Bool
-ecore_x_netwm_handled_icons_get(Ecore_X_Window win)
+EAPI Eina_Bool
+ecore_x_netwm_handled_icons_get(Ecore_X_Window win)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_HANDLED_ICONS,
+ if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_HANDLED_ICONS,
NULL, 0))
return EINA_FALSE;
return EINA_TRUE;
}
-EAPI int
-ecore_x_netwm_icon_name_get(Ecore_X_Window win, char **name)
+EAPI int
+ecore_x_netwm_icon_name_get(Ecore_X_Window win,
+ char **name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (name)
+ if (name)
{
- *name =
+ *name =
ecore_x_window_prop_string_get(win, ECORE_X_ATOM_NET_WM_ICON_NAME);
}
return 1;
}
-EAPI void
-ecore_x_netwm_icon_name_set(Ecore_X_Window win, const char *name)
+EAPI void
+ecore_x_netwm_icon_name_set(Ecore_X_Window win,
+ const char *name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
ecore_x_window_prop_string_set(win, ECORE_X_ATOM_NET_WM_ICON_NAME, name);
}
-EAPI Eina_Bool
-ecore_x_netwm_icons_get(Ecore_X_Window win, Ecore_X_Icon **icon, int *num)
+EAPI Eina_Bool
+ecore_x_netwm_icons_get(Ecore_X_Window win,
+ Ecore_X_Icon **icon,
+ int *num)
{
int num_ret = 0;
unsigned int i = 0, len = 0, icons = 0;
@@ -765,15 +833,15 @@ ecore_x_netwm_icons_get(Ecore_X_Window win, Ecore_X_Icon **icon, int *num)
if (num) *num = 0;
if (icon) *icon = NULL;
- num_ret =
+ num_ret =
ecore_x_window_prop_card32_list_get(win, ECORE_X_ATOM_NET_WM_ICON, &data);
- if ((num_ret <= 0) || (!data))
+ if ((num_ret <= 0) || (!data))
{
if (data) free(data);
return EINA_FALSE;
}
- if (num_ret < 2)
+ if (num_ret < 2)
{
if (data) free(data);
return EINA_FALSE;
@@ -781,11 +849,11 @@ ecore_x_netwm_icons_get(Ecore_X_Window win, Ecore_X_Icon **icon, int *num)
icons = 0;
p = data;
- while (p)
+ while (p)
{
len = (p[0] * p[1]);
p += (len + 2);
- if ((p - data) > num_ret)
+ if ((p - data) > num_ret)
{
if (data) free(data);
return EINA_FALSE;
@@ -794,14 +862,14 @@ ecore_x_netwm_icons_get(Ecore_X_Window win, Ecore_X_Icon **icon, int *num)
if ((p - data) == num_ret) p = NULL;
}
if (num) *num = icons;
- if (!icon)
+ if (!icon)
{
if (data) free(data);
return EINA_TRUE;
}
*icon = malloc(icons * sizeof(Ecore_X_Icon));
- if (!(*icon))
+ if (!(*icon))
{
if (data) free(data);
return EINA_FALSE;
@@ -809,7 +877,7 @@ ecore_x_netwm_icons_get(Ecore_X_Window win, Ecore_X_Icon **icon, int *num)
/* Fetch the icons */
p = data;
- for (i = 0; i < icons; i++)
+ for (i = 0; i < icons; i++)
{
unsigned int *ps, *pd, *pe;
@@ -848,8 +916,12 @@ ecore_x_netwm_icons_get(Ecore_X_Window win, Ecore_X_Icon **icon, int *num)
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_icon_geometry_set(Ecore_X_Window win, int x, int y, int w, int h)
+EAPI void
+ecore_x_netwm_icon_geometry_set(Ecore_X_Window win,
+ int x,
+ int y,
+ int w,
+ int h)
{
unsigned int geom[4];
@@ -859,20 +931,24 @@ ecore_x_netwm_icon_geometry_set(Ecore_X_Window win, int x, int y, int w, int h)
geom[1] = y;
geom[2] = w;
geom[3] = h;
- ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_ICON_GEOMETRY,
+ ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_ICON_GEOMETRY,
geom, 4);
}
-EAPI Eina_Bool
-ecore_x_netwm_icon_geometry_get(Ecore_X_Window win, int *x, int *y, int *w, int *h)
+EAPI Eina_Bool
+ecore_x_netwm_icon_geometry_get(Ecore_X_Window win,
+ int *x,
+ int *y,
+ int *w,
+ int *h)
{
int ret = 0;
unsigned int geom[4];
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ret =
- ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_ICON_GEOMETRY,
+ ret =
+ ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_ICON_GEOMETRY,
geom, 4);
if (ret != 4) return EINA_FALSE;
if (x) *x = geom[0];
@@ -883,8 +959,12 @@ ecore_x_netwm_icon_geometry_get(Ecore_X_Window win, int *x, int *y, int *w, int
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_strut_set(Ecore_X_Window win, int l, int r, int t, int b)
+EAPI void
+ecore_x_netwm_strut_set(Ecore_X_Window win,
+ int l,
+ int r,
+ int t,
+ int b)
{
unsigned int strut[4];
@@ -897,15 +977,19 @@ ecore_x_netwm_strut_set(Ecore_X_Window win, int l, int r, int t, int b)
ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_STRUT, strut, 4);
}
-EAPI Eina_Bool
-ecore_x_netwm_strut_get(Ecore_X_Window win, int *l, int *r, int *t, int *b)
+EAPI Eina_Bool
+ecore_x_netwm_strut_get(Ecore_X_Window win,
+ int *l,
+ int *r,
+ int *t,
+ int *b)
{
unsigned int strut[4];
int ret = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ret =
+ ret =
ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_STRUT, strut, 4);
if (ret != 4) return EINA_FALSE;
@@ -917,8 +1001,20 @@ ecore_x_netwm_strut_get(Ecore_X_Window win, int *l, int *r, int *t, int *b)
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_strut_partial_set(Ecore_X_Window win, int left, int right, int top, int bottom, int left_start_y, int left_end_y, int right_start_y, int right_end_y, int top_start_x, int top_end_x, int bottom_start_x, int bottom_end_x)
+EAPI void
+ecore_x_netwm_strut_partial_set(Ecore_X_Window win,
+ int left,
+ int right,
+ int top,
+ int bottom,
+ int left_start_y,
+ int left_end_y,
+ int right_start_y,
+ int right_end_y,
+ int top_start_x,
+ int top_end_x,
+ int bottom_start_x,
+ int bottom_end_x)
{
unsigned int strut[12];
@@ -940,16 +1036,28 @@ ecore_x_netwm_strut_partial_set(Ecore_X_Window win, int left, int right, int top
strut, 12);
}
-EAPI Eina_Bool
-ecore_x_netwm_strut_partial_get(Ecore_X_Window win, int *left, int *right, int *top, int *bottom, int *left_start_y, int *left_end_y, int *right_start_y, int *right_end_y, int *top_start_x, int *top_end_x, int *bottom_start_x, int *bottom_end_x)
+EAPI Eina_Bool
+ecore_x_netwm_strut_partial_get(Ecore_X_Window win,
+ int *left,
+ int *right,
+ int *top,
+ int *bottom,
+ int *left_start_y,
+ int *left_end_y,
+ int *right_start_y,
+ int *right_end_y,
+ int *top_start_x,
+ int *top_end_x,
+ int *bottom_start_x,
+ int *bottom_end_x)
{
unsigned int strut[12];
int ret = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ret =
- ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_STRUT_PARTIAL,
+ ret =
+ ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_STRUT_PARTIAL,
strut, 12);
if (ret != 12) return EINA_FALSE;
@@ -969,23 +1077,25 @@ ecore_x_netwm_strut_partial_get(Ecore_X_Window win, int *left, int *right, int *
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_user_time_set(Ecore_X_Window win, unsigned int t)
+EAPI void
+ecore_x_netwm_user_time_set(Ecore_X_Window win,
+ unsigned int t)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
ecore_x_window_prop_card32_set(win, ECORE_X_ATOM_NET_WM_USER_TIME, &t, 1);
}
-EAPI Eina_Bool
-ecore_x_netwm_user_time_get(Ecore_X_Window win, unsigned int *t)
+EAPI Eina_Bool
+ecore_x_netwm_user_time_get(Ecore_X_Window win,
+ unsigned int *t)
{
unsigned int tmp;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_USER_TIME,
- &tmp, 1))
+ if (!ecore_x_window_prop_card32_get(win, ECORE_X_ATOM_NET_WM_USER_TIME,
+ &tmp, 1))
return EINA_FALSE;
if (t) *t = tmp;
@@ -993,60 +1103,65 @@ ecore_x_netwm_user_time_get(Ecore_X_Window win, unsigned int *t)
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_visible_name_set(Ecore_X_Window win, const char *name)
+EAPI void
+ecore_x_netwm_visible_name_set(Ecore_X_Window win,
+ const char *name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_string_set(win, ECORE_X_ATOM_NET_WM_VISIBLE_NAME,
+ ecore_x_window_prop_string_set(win, ECORE_X_ATOM_NET_WM_VISIBLE_NAME,
name);
}
-EAPI int
-ecore_x_netwm_visible_name_get(Ecore_X_Window win, char **name)
+EAPI int
+ecore_x_netwm_visible_name_get(Ecore_X_Window win,
+ char **name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (name)
- *name = ecore_x_window_prop_string_get(win,
+ if (name)
+ *name = ecore_x_window_prop_string_get(win,
ECORE_X_ATOM_NET_WM_VISIBLE_NAME);
return 1;
}
-EAPI void
-ecore_x_netwm_visible_icon_name_set(Ecore_X_Window win, const char *name)
+EAPI void
+ecore_x_netwm_visible_icon_name_set(Ecore_X_Window win,
+ const char *name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_string_set(win, ECORE_X_ATOM_NET_WM_VISIBLE_ICON_NAME,
+ ecore_x_window_prop_string_set(win, ECORE_X_ATOM_NET_WM_VISIBLE_ICON_NAME,
name);
}
-EAPI int
-ecore_x_netwm_visible_icon_name_get(Ecore_X_Window win, char **name)
+EAPI int
+ecore_x_netwm_visible_icon_name_get(Ecore_X_Window win,
+ char **name)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (name)
+ if (name)
{
- *name =
- ecore_x_window_prop_string_get(win,
+ *name =
+ ecore_x_window_prop_string_get(win,
ECORE_X_ATOM_NET_WM_VISIBLE_ICON_NAME);
}
return 1;
}
-EAPI Eina_Bool
-ecore_x_netwm_sync_counter_get(Ecore_X_Window win, Ecore_X_Sync_Counter *counter)
+EAPI Eina_Bool
+ecore_x_netwm_sync_counter_get(Ecore_X_Window win,
+ Ecore_X_Sync_Counter *counter)
{
unsigned int tmp;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!ecore_x_window_prop_card32_get(win,
- ECORE_X_ATOM_NET_WM_SYNC_REQUEST_COUNTER,
- &tmp, 1))
+ if (!ecore_x_window_prop_card32_get(win,
+ ECORE_X_ATOM_NET_WM_SYNC_REQUEST_COUNTER,
+ &tmp, 1))
return EINA_FALSE;
if (counter) *counter = tmp;
@@ -1054,8 +1169,9 @@ ecore_x_netwm_sync_counter_get(Ecore_X_Window win, Ecore_X_Sync_Counter *counter
return EINA_TRUE;
}
-EAPI Eina_Bool
-ecore_x_netwm_allowed_action_isset(Ecore_X_Window win, Ecore_X_Action action)
+EAPI Eina_Bool
+ecore_x_netwm_allowed_action_isset(Ecore_X_Window win,
+ Ecore_X_Action action)
{
int num = 0, i = 0;
Ecore_X_Atom *atoms, atom;
@@ -1063,15 +1179,15 @@ ecore_x_netwm_allowed_action_isset(Ecore_X_Window win, Ecore_X_Action action)
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- num =
- ecore_x_window_prop_atom_list_get(win, ECORE_X_ATOM_NET_WM_WINDOW_TYPE,
+ num =
+ ecore_x_window_prop_atom_list_get(win, ECORE_X_ATOM_NET_WM_WINDOW_TYPE,
&atoms);
if (num <= 0) return EINA_FALSE;
atom = _ecore_xcb_netwm_action_atom_get(action);
- for (i = 0; i < num; i++)
+ for (i = 0; i < num; i++)
{
- if (atoms[i] == atom)
+ if (atoms[i] == atom)
{
ret = EINA_TRUE;
break;
@@ -1082,8 +1198,10 @@ ecore_x_netwm_allowed_action_isset(Ecore_X_Window win, Ecore_X_Action action)
return ret;
}
-EAPI Eina_Bool
-ecore_x_netwm_allowed_action_get(Ecore_X_Window win, Ecore_X_Action **action, unsigned int *num)
+EAPI Eina_Bool
+ecore_x_netwm_allowed_action_get(Ecore_X_Window win,
+ Ecore_X_Action **action,
+ unsigned int *num)
{
Ecore_X_Atom *atoms;
int num_ret = 0;
@@ -1093,14 +1211,14 @@ ecore_x_netwm_allowed_action_get(Ecore_X_Window win, Ecore_X_Action **action, un
if (num) *num = 0;
if (action) *action = NULL;
- num_ret =
- ecore_x_window_prop_atom_list_get(win, ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS,
+ num_ret =
+ ecore_x_window_prop_atom_list_get(win, ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS,
&atoms);
if (num_ret <= 0) return EINA_FALSE;
- if (action)
+ if (action)
{
*action = malloc(num_ret * sizeof(Ecore_X_Action));
- if (*action)
+ if (*action)
{
int i = 0;
@@ -1113,17 +1231,19 @@ ecore_x_netwm_allowed_action_get(Ecore_X_Window win, Ecore_X_Action **action, un
return EINA_TRUE;
}
-EAPI void
-ecore_x_netwm_allowed_action_set(Ecore_X_Window win, Ecore_X_Action *action, unsigned int num)
+EAPI void
+ecore_x_netwm_allowed_action_set(Ecore_X_Window win,
+ Ecore_X_Action *action,
+ unsigned int num)
{
Ecore_X_Atom *set;
unsigned int i = 0;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- if (!num)
+ if (!num)
{
- ecore_x_window_prop_property_del(win,
+ ecore_x_window_prop_property_del(win,
ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS);
return;
}
@@ -1134,24 +1254,26 @@ ecore_x_netwm_allowed_action_set(Ecore_X_Window win, Ecore_X_Action *action, uns
for (i = 0; i < num; i++)
set[i] = _ecore_xcb_netwm_action_atom_get(action[i]);
- ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS,
+ ecore_x_window_prop_atom_set(win, ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS,
set, num);
free(set);
}
/* local functions */
-int
-_ecore_xcb_netwm_startup_info_begin(Ecore_X_Window win __UNUSED__, uint8_t data __UNUSED__)
+int
+_ecore_xcb_netwm_startup_info_begin(Ecore_X_Window win __UNUSED__,
+ uint8_t data __UNUSED__)
{
// TODO: TBD
- return 1;
+ return 1;
}
-int
-_ecore_xcb_netwm_startup_info(Ecore_X_Window win __UNUSED__, uint8_t data __UNUSED__)
+int
+_ecore_xcb_netwm_startup_info(Ecore_X_Window win __UNUSED__,
+ uint8_t data __UNUSED__)
{
// TODO: TBD
- return 1;
+ return 1;
}
/* static void */
@@ -1172,46 +1294,60 @@ _ecore_xcb_netwm_startup_info(Ecore_X_Window win __UNUSED__, uint8_t data __UNUS
/* free(info); */
/* } */
-static Ecore_X_Atom
-_ecore_xcb_netwm_window_type_atom_get(Ecore_X_Window_Type type)
+static Ecore_X_Atom
+_ecore_xcb_netwm_window_type_atom_get(Ecore_X_Window_Type type)
{
- switch (type)
+ switch (type)
{
case ECORE_X_WINDOW_TYPE_DESKTOP:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DESKTOP;
+
case ECORE_X_WINDOW_TYPE_DOCK:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DOCK;
+
case ECORE_X_WINDOW_TYPE_TOOLBAR:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_TOOLBAR;
+
case ECORE_X_WINDOW_TYPE_MENU:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_MENU;
+
case ECORE_X_WINDOW_TYPE_UTILITY:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_UTILITY;
+
case ECORE_X_WINDOW_TYPE_SPLASH:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_SPLASH;
+
case ECORE_X_WINDOW_TYPE_DIALOG:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DIALOG;
+
case ECORE_X_WINDOW_TYPE_NORMAL:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NORMAL;
+
case ECORE_X_WINDOW_TYPE_DROPDOWN_MENU:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DROPDOWN_MENU;
+
case ECORE_X_WINDOW_TYPE_POPUP_MENU:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_POPUP_MENU;
+
case ECORE_X_WINDOW_TYPE_TOOLTIP:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_TOOLTIP;
+
case ECORE_X_WINDOW_TYPE_NOTIFICATION:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NOTIFICATION;
+
case ECORE_X_WINDOW_TYPE_COMBO:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_COMBO;
+
case ECORE_X_WINDOW_TYPE_DND:
return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DND;
+
default:
return 0;
}
}
-static Ecore_X_Window_Type
-_ecore_xcb_netwm_window_type_type_get(Ecore_X_Atom atom)
+static Ecore_X_Window_Type
+_ecore_xcb_netwm_window_type_type_get(Ecore_X_Atom atom)
{
if (atom == ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DESKTOP)
return ECORE_X_WINDOW_TYPE_DESKTOP;
@@ -1230,116 +1366,141 @@ _ecore_xcb_netwm_window_type_type_get(Ecore_X_Atom atom)
else if (atom == ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NORMAL)
return ECORE_X_WINDOW_TYPE_NORMAL;
else if (atom == ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DROPDOWN_MENU)
- return ECORE_X_WINDOW_TYPE_DROPDOWN_MENU;
+ return ECORE_X_WINDOW_TYPE_DROPDOWN_MENU;
else if (atom == ECORE_X_ATOM_NET_WM_WINDOW_TYPE_POPUP_MENU)
- return ECORE_X_WINDOW_TYPE_POPUP_MENU;
+ return ECORE_X_WINDOW_TYPE_POPUP_MENU;
else if (atom == ECORE_X_ATOM_NET_WM_WINDOW_TYPE_TOOLTIP)
- return ECORE_X_WINDOW_TYPE_TOOLTIP;
+ return ECORE_X_WINDOW_TYPE_TOOLTIP;
else if (atom == ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NOTIFICATION)
- return ECORE_X_WINDOW_TYPE_NOTIFICATION;
+ return ECORE_X_WINDOW_TYPE_NOTIFICATION;
else if (atom == ECORE_X_ATOM_NET_WM_WINDOW_TYPE_COMBO)
- return ECORE_X_WINDOW_TYPE_COMBO;
+ return ECORE_X_WINDOW_TYPE_COMBO;
else if (atom == ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DND)
- return ECORE_X_WINDOW_TYPE_DND;
+ return ECORE_X_WINDOW_TYPE_DND;
else
return ECORE_X_WINDOW_TYPE_UNKNOWN;
}
-static Ecore_X_Atom
-_ecore_xcb_netwm_window_state_atom_get(Ecore_X_Window_State state)
+static Ecore_X_Atom
+_ecore_xcb_netwm_window_state_atom_get(Ecore_X_Window_State state)
{
- switch (state)
+ switch (state)
{
case ECORE_X_WINDOW_STATE_MODAL:
return ECORE_X_ATOM_NET_WM_STATE_MODAL;
+
case ECORE_X_WINDOW_STATE_STICKY:
return ECORE_X_ATOM_NET_WM_STATE_STICKY;
+
case ECORE_X_WINDOW_STATE_MAXIMIZED_VERT:
return ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_VERT;
+
case ECORE_X_WINDOW_STATE_MAXIMIZED_HORZ:
return ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_HORZ;
+
case ECORE_X_WINDOW_STATE_SHADED:
return ECORE_X_ATOM_NET_WM_STATE_SHADED;
+
case ECORE_X_WINDOW_STATE_SKIP_TASKBAR:
return ECORE_X_ATOM_NET_WM_STATE_SKIP_TASKBAR;
+
case ECORE_X_WINDOW_STATE_SKIP_PAGER:
return ECORE_X_ATOM_NET_WM_STATE_SKIP_PAGER;
+
case ECORE_X_WINDOW_STATE_HIDDEN:
return ECORE_X_ATOM_NET_WM_STATE_HIDDEN;
+
case ECORE_X_WINDOW_STATE_FULLSCREEN:
return ECORE_X_ATOM_NET_WM_STATE_FULLSCREEN;
+
case ECORE_X_WINDOW_STATE_ABOVE:
return ECORE_X_ATOM_NET_WM_STATE_ABOVE;
+
case ECORE_X_WINDOW_STATE_BELOW:
return ECORE_X_ATOM_NET_WM_STATE_BELOW;
+
case ECORE_X_WINDOW_STATE_DEMANDS_ATTENTION:
return ECORE_X_ATOM_NET_WM_STATE_DEMANDS_ATTENTION;
+
default:
- return 0;
+ return 0;
}
}
-Ecore_X_Window_State
-_ecore_xcb_netwm_window_state_get(Ecore_X_Atom atom)
+Ecore_X_Window_State
+_ecore_xcb_netwm_window_state_get(Ecore_X_Atom atom)
{
if (atom == ECORE_X_ATOM_NET_WM_STATE_MODAL)
- return ECORE_X_WINDOW_STATE_MODAL;
+ return ECORE_X_WINDOW_STATE_MODAL;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_STICKY)
- return ECORE_X_WINDOW_STATE_STICKY;
+ return ECORE_X_WINDOW_STATE_STICKY;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_VERT)
- return ECORE_X_WINDOW_STATE_MAXIMIZED_VERT;
+ return ECORE_X_WINDOW_STATE_MAXIMIZED_VERT;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_HORZ)
- return ECORE_X_WINDOW_STATE_MAXIMIZED_HORZ;
+ return ECORE_X_WINDOW_STATE_MAXIMIZED_HORZ;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_SHADED)
- return ECORE_X_WINDOW_STATE_SHADED;
+ return ECORE_X_WINDOW_STATE_SHADED;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_SKIP_TASKBAR)
- return ECORE_X_WINDOW_STATE_SKIP_TASKBAR;
+ return ECORE_X_WINDOW_STATE_SKIP_TASKBAR;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_SKIP_PAGER)
- return ECORE_X_WINDOW_STATE_SKIP_PAGER;
+ return ECORE_X_WINDOW_STATE_SKIP_PAGER;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_HIDDEN)
- return ECORE_X_WINDOW_STATE_HIDDEN;
+ return ECORE_X_WINDOW_STATE_HIDDEN;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_FULLSCREEN)
- return ECORE_X_WINDOW_STATE_FULLSCREEN;
+ return ECORE_X_WINDOW_STATE_FULLSCREEN;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_ABOVE)
- return ECORE_X_WINDOW_STATE_ABOVE;
+ return ECORE_X_WINDOW_STATE_ABOVE;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_BELOW)
- return ECORE_X_WINDOW_STATE_BELOW;
+ return ECORE_X_WINDOW_STATE_BELOW;
else if (atom == ECORE_X_ATOM_NET_WM_STATE_DEMANDS_ATTENTION)
- return ECORE_X_WINDOW_STATE_DEMANDS_ATTENTION;
+ return ECORE_X_WINDOW_STATE_DEMANDS_ATTENTION;
else
- return ECORE_X_WINDOW_STATE_UNKNOWN;
+ return ECORE_X_WINDOW_STATE_UNKNOWN;
}
-static Ecore_X_Atom
-_ecore_xcb_netwm_action_atom_get(Ecore_X_Action action)
+static Ecore_X_Atom
+_ecore_xcb_netwm_action_atom_get(Ecore_X_Action action)
{
switch (action)
{
case ECORE_X_ACTION_MOVE:
return ECORE_X_ATOM_NET_WM_ACTION_MOVE;
+
case ECORE_X_ACTION_RESIZE:
return ECORE_X_ATOM_NET_WM_ACTION_RESIZE;
+
case ECORE_X_ACTION_MINIMIZE:
return ECORE_X_ATOM_NET_WM_ACTION_MINIMIZE;
+
case ECORE_X_ACTION_SHADE:
return ECORE_X_ATOM_NET_WM_ACTION_SHADE;
+
case ECORE_X_ACTION_STICK:
return ECORE_X_ATOM_NET_WM_ACTION_STICK;
+
case ECORE_X_ACTION_MAXIMIZE_HORZ:
return ECORE_X_ATOM_NET_WM_ACTION_MAXIMIZE_HORZ;
+
case ECORE_X_ACTION_MAXIMIZE_VERT:
return ECORE_X_ATOM_NET_WM_ACTION_MAXIMIZE_VERT;
+
case ECORE_X_ACTION_FULLSCREEN:
return ECORE_X_ATOM_NET_WM_ACTION_FULLSCREEN;
+
case ECORE_X_ACTION_CHANGE_DESKTOP:
return ECORE_X_ATOM_NET_WM_ACTION_CHANGE_DESKTOP;
+
case ECORE_X_ACTION_CLOSE:
return ECORE_X_ATOM_NET_WM_ACTION_CLOSE;
+
case ECORE_X_ACTION_ABOVE:
return ECORE_X_ATOM_NET_WM_ACTION_ABOVE;
+
case ECORE_X_ACTION_BELOW:
return ECORE_X_ATOM_NET_WM_ACTION_BELOW;
+
default:
return 0;
}
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_pixmap.c b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_pixmap.c
index 64ebdd0292..f9bf525f7a 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_pixmap.c
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_pixmap.c
@@ -18,8 +18,11 @@
* @return New pixmap.
* @ingroup Ecore_X_Pixmap_Group
*/
-EAPI Ecore_X_Pixmap
-ecore_x_pixmap_new(Ecore_X_Window win, int w, int h, int dep)
+EAPI Ecore_X_Pixmap
+ecore_x_pixmap_new(Ecore_X_Window win,
+ int w,
+ int h,
+ int dep)
{
Ecore_X_Pixmap pmap;
@@ -45,8 +48,8 @@ ecore_x_pixmap_new(Ecore_X_Window win, int w, int h, int dep)
* @param pmap The given pixmap.
* @ingroup Ecore_X_Pixmap_Group
*/
-EAPI void
-ecore_x_pixmap_free(Ecore_X_Pixmap pmap)
+EAPI void
+ecore_x_pixmap_free(Ecore_X_Pixmap pmap)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -69,8 +72,16 @@ ecore_x_pixmap_free(Ecore_X_Pixmap pmap)
* @param dy The Y position at which to paste the area on @p dest.
* @ingroup Ecore_X_Pixmap_Group
*/
-EAPI void
-ecore_x_pixmap_paste(Ecore_X_Pixmap pmap, Ecore_X_Drawable dest, Ecore_X_GC gc, int sx, int sy, int w, int h, int dx, int dy)
+EAPI void
+ecore_x_pixmap_paste(Ecore_X_Pixmap pmap,
+ Ecore_X_Drawable dest,
+ Ecore_X_GC gc,
+ int sx,
+ int sy,
+ int w,
+ int h,
+ int dx,
+ int dy)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
CHECK_XCB_CONN;
@@ -88,8 +99,12 @@ ecore_x_pixmap_paste(Ecore_X_Pixmap pmap, Ecore_X_Drawable dest, Ecore_X_GC gc,
* @param h Pointer to an integer in which to store the height.
* @ingroup Ecore_X_Pixmap_Group
*/
-EAPI void
-ecore_x_pixmap_geometry_get(Ecore_X_Pixmap pmap, int *x, int *y, int *w, int *h)
+EAPI void
+ecore_x_pixmap_geometry_get(Ecore_X_Pixmap pmap,
+ int *x,
+ int *y,
+ int *w,
+ int *h)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
@@ -103,10 +118,11 @@ ecore_x_pixmap_geometry_get(Ecore_X_Pixmap pmap, int *x, int *y, int *w, int *h)
* @return The depth of the pixmap.
* @ingroup Ecore_X_Pixmap_Group
*/
-EAPI int
-ecore_x_pixmap_depth_get(Ecore_X_Pixmap pmap)
+EAPI int
+ecore_x_pixmap_depth_get(Ecore_X_Pixmap pmap)
{
LOGFN(__FILE__, __LINE__, __FUNCTION__);
return ecore_x_drawable_depth_get(pmap);
}
+
diff --git a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_private.h b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_private.h
index c143d9d9b2..9d8c26b383 100644
--- a/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_private.h
+++ b/legacy/ecore/src/lib/ecore_x/xcb/ecore_xcb_private.h
@@ -51,7 +51,7 @@ extern int _ecore_xcb_log_dom;
# ifdef CRIT
# undef CRIT
# endif
-# define CRIT(...) EINA_LOG_DOM_CRIT(_ecore_xcb_log_dom, __VA_ARGS__)
+# define CRIT(...) EINA_LOG_DOM_CRIT(_ecore_xcb_log_dom, __VA_ARGS__)
# ifdef LOGFNS
# include <stdio.h>
@@ -72,117 +72,122 @@ extern int _ecore_xcb_log_dom;
# define MAX(a, b) ((a < b) ? b : a)
# endif
-#define CHECK_XCB_CONN \
- { \
- if (xcb_connection_has_error(_ecore_xcb_conn)) \
- { \
- DBG("XCB Connection Has Error !!"); \
- _ecore_xcb_io_error_handle(NULL); \
- } \
- }
+#define CHECK_XCB_CONN \
+ { \
+ if (xcb_connection_has_error(_ecore_xcb_conn)) \
+ { \
+ DBG("XCB Connection Has Error !!"); \
+ _ecore_xcb_io_error_handle(NULL); \
+ } \
+ }
/* enums */
typedef enum _Ecore_Xcb_Encoding_Style Ecore_Xcb_Encoding_Style;
-enum _Ecore_Xcb_Encoding_Style
+enum _Ecore_Xcb_Encoding_Style
{
- XcbStringStyle,
- XcbCompoundTextStyle,
+ XcbStringStyle,
+ XcbCompoundTextStyle,
XcbTextStyle,
- XcbStdICCTextStyle,
+ XcbStdICCTextStyle,
XcbUTF8StringStyle
};
/* structures */
-typedef struct _Ecore_X_DND_Source Ecore_X_DND_Source;
-typedef struct _Ecore_X_DND_Target Ecore_X_DND_Target;
-typedef struct _Ecore_X_Selection_Intern Ecore_X_Selection_Intern;
+typedef struct _Ecore_X_DND_Source Ecore_X_DND_Source;
+typedef struct _Ecore_X_DND_Target Ecore_X_DND_Target;
+typedef struct _Ecore_X_Selection_Intern Ecore_X_Selection_Intern;
typedef struct _Ecore_X_Selection_Converter Ecore_X_Selection_Converter;
-typedef struct _Ecore_X_Selection_Parser Ecore_X_Selection_Parser;
-typedef struct _Ecore_Xcb_Textproperty Ecore_Xcb_Textproperty;
+typedef struct _Ecore_X_Selection_Parser Ecore_X_Selection_Parser;
+typedef struct _Ecore_Xcb_Textproperty Ecore_Xcb_Textproperty;
-struct _Ecore_X_DND_Source
+struct _Ecore_X_DND_Source
{
- int version;
+ int version;
Ecore_X_Window win, dest;
- enum
- {
- ECORE_X_DND_SOURCE_IDLE,
- ECORE_X_DND_SOURCE_DRAGGING,
- ECORE_X_DND_SOURCE_DROPPED,
- ECORE_X_DND_SOURCE_CONVERTING
- } state;
-
- struct
- {
- short x, y;
- unsigned short width, height;
- } rectangle;
-
- struct
- {
- Ecore_X_Window window;
- int x, y;
- } prev;
+ enum
+ {
+ ECORE_X_DND_SOURCE_IDLE,
+ ECORE_X_DND_SOURCE_DRAGGING,
+ ECORE_X_DND_SOURCE_DROPPED,
+ ECORE_X_DND_SOURCE_CONVERTING
+ } state;
+
+ struct
+ {
+ short x, y;
+ unsigned short width, height;
+ } rectangle;
+
+ struct
+ {
+ Ecore_X_Window window;
+ int x, y;
+ } prev;
Ecore_X_Time time;
Ecore_X_Atom action, accepted_action;
- int will_accept, suppress;
- int await_status;
+ int will_accept, suppress;
+ int await_status;
};
-struct _Ecore_X_DND_Target
+struct _Ecore_X_DND_Target
{
- int version;
+ int version;
Ecore_X_Window win, source;
- enum
- {
- ECORE_X_DND_TARGET_IDLE,
- ECORE_X_DND_TARGET_ENTERED
- } state;
+ enum
+ {
+ ECORE_X_DND_TARGET_IDLE,
+ ECORE_X_DND_TARGET_ENTERED
+ } state;
- struct
- {
- int x, y;
- } pos;
+ struct
+ {
+ int x, y;
+ } pos;
Ecore_X_Time time;
Ecore_X_Atom action, accepted_action;
- int will_accept;
+ int will_accept;
};
-struct _Ecore_X_Selection_Intern
+struct _Ecore_X_Selection_Intern
{
Ecore_X_Window win;
- Ecore_X_Atom selection;
+ Ecore_X_Atom selection;
unsigned char *data;
- int length;
- Ecore_X_Time time;
+ int length;
+ Ecore_X_Time time;
};
-struct _Ecore_X_Selection_Converter
+struct _Ecore_X_Selection_Converter
{
- Ecore_X_Atom target;
- Eina_Bool (*convert) (char *target, void *data, int size, void **data_ret,
- int *size_ret, Ecore_X_Atom *type, int *size_type);
+ Ecore_X_Atom target;
+ Eina_Bool (*convert)(char *target,
+ void *data,
+ int size,
+ void **data_ret,
+ int *size_ret,
+ Ecore_X_Atom *type,
+ int *size_type);
Ecore_X_Selection_Converter *next;
};
-struct _Ecore_X_Selection_Parser
+struct _Ecore_X_Selection_Parser
{
- char *target;
- void *(*parse) (const char *target, void *data, int size, int format);
+ char *target;
+ void *(*parse)(const char *target, void *data, int size, int format);
Ecore_X_Selection_Parser *next;
};
-struct _Ecore_Xcb_Textproperty
+struct _Ecore_Xcb_Textproperty
{
- char *value;
+ char *value;
Ecore_X_Atom encoding;
unsigned int format, nitems;
};
@@ -218,7 +223,9 @@ extern int _ecore_xcb_button_grabs_num;
extern int _ecore_xcb_key_grabs_num;
extern Ecore_X_Window *_ecore_xcb_button_grabs;
extern Ecore_X_Window *_ecore_xcb_key_grabs;
-extern Eina_Bool (*_ecore_xcb_window_grab_replay_func)(void *data, int type, void *event);
+extern Eina_Bool (*_ecore_xcb_window_grab_replay_func)(void *data,
+ int type,
+ void *event);
extern void *_ecore_xcb_window_grab_replay_data;
/* private function prototypes */
@@ -239,81 +246,148 @@ void _ecore_xcb_screensaver_finalize(void);
void _ecore_xcb_sync_init(void);
void _ecore_xcb_sync_finalize(void);
-void _ecore_xcb_sync_magic_send(int val, Ecore_X_Window win);
+void _ecore_xcb_sync_magic_send(int val,
+ Ecore_X_Window win);
-void _ecore_xcb_render_init(void);
-void _ecore_xcb_render_finalize(void);
-Eina_Bool _ecore_xcb_render_argb_get(void);
-Eina_Bool _ecore_xcb_render_anim_get(void);
-Eina_Bool _ecore_xcb_render_avail_get(void);
+void _ecore_xcb_render_init(void);
+void _ecore_xcb_render_finalize(void);
+Eina_Bool _ecore_xcb_render_argb_get(void);
+Eina_Bool _ecore_xcb_render_anim_get(void);
+Eina_Bool _ecore_xcb_render_avail_get(void);
-Eina_Bool _ecore_xcb_render_visual_supports_alpha(Ecore_X_Visual visual);
-uint32_t _ecore_xcb_render_find_visual_id(int type, Eina_Bool check_alpha);
-Ecore_X_Visual *_ecore_xcb_render_visual_get(int visual_id);
+Eina_Bool _ecore_xcb_render_visual_supports_alpha(Ecore_X_Visual visual);
+uint32_t _ecore_xcb_render_find_visual_id(int type,
+ Eina_Bool check_alpha);
+Ecore_X_Visual *_ecore_xcb_render_visual_get(int visual_id);
-void _ecore_xcb_randr_init(void);
-void _ecore_xcb_randr_finalize(void);
+void _ecore_xcb_randr_init(void);
+void _ecore_xcb_randr_finalize(void);
-void _ecore_xcb_xfixes_init(void);
-void _ecore_xcb_xfixes_finalize(void);
-Eina_Bool _ecore_xcb_xfixes_avail_get(void);
+void _ecore_xcb_xfixes_init(void);
+void _ecore_xcb_xfixes_finalize(void);
+Eina_Bool _ecore_xcb_xfixes_avail_get(void);
-void _ecore_xcb_damage_init(void);
-void _ecore_xcb_damage_finalize(void);
+void _ecore_xcb_damage_init(void);
+void _ecore_xcb_damage_finalize(void);
-void _ecore_xcb_composite_init(void);
-void _ecore_xcb_composite_finalize(void);
+void _ecore_xcb_composite_init(void);
+void _ecore_xcb_composite_finalize(void);
-void _ecore_xcb_dpms_init(void);
-void _ecore_xcb_dpms_finalize(void);
+void _ecore_xcb_dpms_init(void);
+void _ecore_xcb_dpms_finalize(void);
-void _ecore_xcb_cursor_init(void);
-void _ecore_xcb_cursor_finalize(void);
+void _ecore_xcb_cursor_init(void);
+void _ecore_xcb_cursor_finalize(void);
-void _ecore_xcb_xinerama_init(void);
-void _ecore_xcb_xinerama_finalize(void);
+void _ecore_xcb_xinerama_init(void);
+void _ecore_xcb_xinerama_finalize(void);
-void _ecore_xcb_dnd_init(void);
-void _ecore_xcb_dnd_shutdown(void);
+void _ecore_xcb_dnd_init(void);
+void _ecore_xcb_dnd_shutdown(void);
Ecore_X_DND_Source *_ecore_xcb_dnd_source_get(void);
Ecore_X_DND_Target *_ecore_xcb_dnd_target_get(void);
-void _ecore_xcb_dnd_drag(Ecore_X_Window root, int x, int y);
-
-void _ecore_xcb_selection_init(void);
-void _ecore_xcb_selection_shutdown(void);
-void *_ecore_xcb_selection_parse(const char *target, void *data, int size, int format);
-char *_ecore_xcb_selection_target_get(Ecore_X_Atom target);
+void _ecore_xcb_dnd_drag(Ecore_X_Window root,
+ int x,
+ int y);
+
+void _ecore_xcb_selection_init(void);
+void _ecore_xcb_selection_shutdown(void);
+void *_ecore_xcb_selection_parse(const char *target,
+ void *data,
+ int size,
+ int format);
+char *_ecore_xcb_selection_target_get(Ecore_X_Atom target);
Ecore_X_Selection_Intern *_ecore_xcb_selection_get(Ecore_X_Atom selection);
# ifdef HAVE_ICONV
-Eina_Bool _ecore_xcb_utf8_textlist_to_textproperty(char **list, int count, Ecore_Xcb_Encoding_Style style, Ecore_Xcb_Textproperty *ret);
+Eina_Bool _ecore_xcb_utf8_textlist_to_textproperty(char **list,
+ int count,
+ Ecore_Xcb_Encoding_Style style,
+ Ecore_Xcb_Textproperty *ret);
# endif
-Eina_Bool _ecore_xcb_mb_textlist_to_textproperty(char **list, int count, Ecore_Xcb_Encoding_Style style, Ecore_Xcb_Textproperty *ret);
-Eina_Bool _ecore_xcb_textlist_to_textproperty(const char *type, char **list, int count, Ecore_Xcb_Encoding_Style style, Ecore_Xcb_Textproperty *ret);
+Eina_Bool _ecore_xcb_mb_textlist_to_textproperty(char **list,
+ int count,
+ Ecore_Xcb_Encoding_Style style,
+ Ecore_Xcb_Textproperty *ret);
+Eina_Bool _ecore_xcb_textlist_to_textproperty(const char *type,
+ char **list,
+ int count,
+ Ecore_Xcb_Encoding_Style style,
+ Ecore_Xcb_Textproperty *ret);
# ifdef HAVE_ICONV
-Eina_Bool _ecore_xcb_utf8_textproperty_to_textlist(const Ecore_Xcb_Textproperty *text_prop, char ***list_ret, int *count_ret);
+Eina_Bool _ecore_xcb_utf8_textproperty_to_textlist(const Ecore_Xcb_Textproperty *text_prop,
+ char ***list_ret,
+ int *count_ret);
# endif
-Eina_Bool _ecore_xcb_mb_textproperty_to_textlist(const Ecore_Xcb_Textproperty *text_prop, char ***list_ret, int *count_ret);
-Eina_Bool _ecore_xcb_textproperty_to_textlist(const Ecore_Xcb_Textproperty *text_prop, const char *type, char ***list_ret, int *count_ret);
-
-void _ecore_xcb_events_init(void);
-void _ecore_xcb_events_shutdown(void);
-void _ecore_xcb_events_handle(xcb_generic_event_t *ev);
+Eina_Bool _ecore_xcb_mb_textproperty_to_textlist(const Ecore_Xcb_Textproperty *text_prop,
+ char ***list_ret,
+ int *count_ret);
+Eina_Bool _ecore_xcb_textproperty_to_textlist(const Ecore_Xcb_Textproperty *text_prop,
+ const char *type,
+ char ***list_ret,
+ int *count_ret);
+
+void _ecore_xcb_events_init(void);
+void _ecore_xcb_events_shutdown(void);
+void _ecore_xcb_events_handle(xcb_generic_event_t *ev);
Ecore_X_Time _ecore_xcb_events_last_time_get(void);
unsigned int _ecore_xcb_events_modifiers_get(unsigned int state);
-void _ecore_xcb_event_mouse_move(uint16_t timestamp, uint16_t modifiers, int16_t x, int16_t y, int16_t root_x, int16_t root_y, xcb_window_t event_win, xcb_window_t win, xcb_window_t root_win, uint8_t same_screen, int dev, double radx, double rady, double pressure, double angle, int16_t mx, int16_t my, int16_t mrx, int16_t mry);
-Ecore_Event_Mouse_Button *_ecore_xcb_event_mouse_button(int event, uint16_t timestamp, uint16_t modifiers, xcb_button_t buttons, int16_t x, int16_t y, int16_t root_x, int16_t root_y, xcb_window_t event_win, xcb_window_t win, xcb_window_t root_win, uint8_t same_screen, int dev, double radx, double rady, double pressure, double angle, int16_t mx, int16_t my, int16_t mrx, int16_t mry);
-
-void _ecore_xcb_keymap_init(void);
-void _ecore_xcb_keymap_finalize(void);
-void _ecore_xcb_keymap_shutdown(void);
-void _ecore_xcb_keymap_refresh(xcb_mapping_notify_event_t *event);
-xcb_keysym_t _ecore_xcb_keymap_keycode_to_keysym(xcb_keycode_t keycode, int col);
+void _ecore_xcb_event_mouse_move(uint16_t timestamp,
+ uint16_t modifiers,
+ int16_t x,
+ int16_t y,
+ int16_t root_x,
+ int16_t root_y,
+ xcb_window_t event_win,
+ xcb_window_t win,
+ xcb_window_t root_win,
+ uint8_t same_screen,
+ int dev,
+ double radx,
+ double rady,
+ double pressure,
+ double angle,
+ int16_t mx,
+ int16_t my,
+ int16_t mrx,
+ int16_t mry);
+Ecore_Event_Mouse_Button *_ecore_xcb_event_mouse_button(int event,
+ uint16_t timestamp,
+ uint16_t modifiers,
+ xcb_button_t buttons,
+ int16_t x,
+ int16_t y,
+ int16_t root_x,
+ int16_t root_y,
+ xcb_window_t event_win,
+ xcb_window_t win,
+ xcb_window_t root_win,
+ uint8_t same_screen,
+ int dev,
+ double radx,
+ double rady,
+ double pressure,
+ double angle,
+ int16_t mx,
+ int16_t my,
+ int16_t mrx,
+ int16_t mry);
+
+void _ecore_xcb_keymap_init(void);
+void _ecore_xcb_keymap_finalize(void);
+void _ecore_xcb_keymap_shutdown(void);
+void _ecore_xcb_keymap_refresh(xcb_mapping_notify_event_t *event);
+xcb_keysym_t _ecore_xcb_keymap_keycode_to_keysym(xcb_keycode_t keycode,
+ int col);
xcb_keycode_t *_ecore_xcb_keymap_keysym_to_keycode(xcb_keysym_t keysym);
-char *_ecore_xcb_keymap_keysym_to_string(xcb_keysym_t keysym);
-xcb_keycode_t _ecore_xcb_keymap_string_to_keycode(const char *key);
-int _ecore_xcb_keymap_lookup_string(xcb_keycode_t keycode, int state, char *buffer, int bytes, xcb_keysym_t *sym);
+char *_ecore_xcb_keymap_keysym_to_string(xcb_keysym_t keysym);
+xcb_keycode_t _ecore_xcb_keymap_string_to_keycode(const char *key);
+int _ecore_xcb_keymap_lookup_string(xcb_keycode_t keycode,
+ int state,
+ char *buffer,
+ int bytes,
+ xcb_keysym_t *sym);
void _ecore_xcb_input_init(void);
void _ecore_xcb_input_finalize(void);
@@ -324,32 +398,48 @@ void _ecore_xcb_input_handle_event(xcb_generic_event_t *event);
void _ecore_xcb_input_handle_event(xcb_generic_event_t *event __UNUSED__);
# endif
-void _ecore_xcb_dri_init(void);
-void _ecore_xcb_dri_finalize(void);
+void _ecore_xcb_dri_init(void);
+void _ecore_xcb_dri_finalize(void);
-void _ecore_xcb_xtest_init(void);
-void _ecore_xcb_xtest_finalize(void);
+void _ecore_xcb_xtest_i