aboutsummaryrefslogtreecommitdiffstats
path: root/legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c
diff options
context:
space:
mode:
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>2010-07-28 05:23:42 +0000
committerMike Blumenkrantz <michael.blumenkrantz@gmail.com>2010-07-28 05:23:42 +0000
commite248c8b6fc5e9485181e3f78b3409aaf47a923e8 (patch)
tree6dd87711a4335cb79140a93c208f2552f8a35bce /legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c
parentlots of doxy fixes and stop casting to char* (diff)
downloadefl-e248c8b6fc5e9485181e3f78b3409aaf47a923e8.tar.gz
uncrustify so T_UNIX will stop nagging me! :)
SVN revision: 50583
Diffstat (limited to 'legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c')
-rw-r--r--legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c100
1 files changed, 53 insertions, 47 deletions
diff --git a/legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c b/legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c
index d580da933e..d06028e686 100644
--- a/legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c
+++ b/legacy/ecore/src/lib/ecore_x/xlib/ecore_x_mwm.c
@@ -27,62 +27,68 @@
typedef struct _mwmhints
{
- CARD32 flags;
- CARD32 functions;
- CARD32 decorations;
- INT32 inputmode;
- CARD32 status;
+ CARD32 flags;
+ CARD32 functions;
+ CARD32 decorations;
+ INT32 inputmode;
+ CARD32 status;
}
MWMHints;
EAPI int
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)
+ Ecore_X_MWM_Hint_Func *fhint,
+ Ecore_X_MWM_Hint_Decor *dhint,
+ Ecore_X_MWM_Hint_Input *ihint)
{
- unsigned char *p = NULL;
- MWMHints *mwmhints = NULL;
- int num;
- int ret;
+ unsigned char *p = NULL;
+ MWMHints *mwmhints = NULL;
+ int num;
+ int ret;
LOGFN(__FILE__, __LINE__, __FUNCTION__);
ret = 0;
if (!ecore_x_window_prop_property_get(win,
- ECORE_X_ATOM_MOTIF_WM_HINTS,
- ECORE_X_ATOM_MOTIF_WM_HINTS,
- 32, &p, &num))
+ ECORE_X_ATOM_MOTIF_WM_HINTS,
+ ECORE_X_ATOM_MOTIF_WM_HINTS,
+ 32, &p, &num))
return 0;
- mwmhints = (MWMHints *) p;
+
+ mwmhints = (MWMHints *)p;
if (mwmhints)
{
- if (num >= 4)
- {
- if (dhint)
- {
- if (mwmhints->flags & ECORE_X_MWM_HINTS_DECORATIONS)
- *dhint = mwmhints->decorations;
- else
- *dhint = ECORE_X_MWM_HINT_DECOR_ALL;
- }
- if (fhint)
- {
- if (mwmhints->flags & ECORE_X_MWM_HINTS_FUNCTIONS)
- *fhint = mwmhints->functions;
- else
- *fhint = ECORE_X_MWM_HINT_FUNC_ALL;
- }
- if (ihint)
- {
- if (mwmhints->flags & ECORE_X_MWM_HINTS_INPUT_MODE)
- *ihint = mwmhints->inputmode;
- else
- *ihint = ECORE_X_MWM_HINT_INPUT_MODELESS;
- }
- ret = 1;
- }
- free(mwmhints);
+ if (num >= 4)
+ {
+ if (dhint)
+ {
+ if (mwmhints->flags & ECORE_X_MWM_HINTS_DECORATIONS)
+ *dhint = mwmhints->decorations;
+ else
+ *dhint = ECORE_X_MWM_HINT_DECOR_ALL;
+ }
+
+ if (fhint)
+ {
+ if (mwmhints->flags & ECORE_X_MWM_HINTS_FUNCTIONS)
+ *fhint = mwmhints->functions;
+ else
+ *fhint = ECORE_X_MWM_HINT_FUNC_ALL;
+ }
+
+ if (ihint)
+ {
+ if (mwmhints->flags & ECORE_X_MWM_HINTS_INPUT_MODE)
+ *ihint = mwmhints->inputmode;
+ else
+ *ihint = ECORE_X_MWM_HINT_INPUT_MODELESS;
+ }
+
+ ret = 1;
+ }
+
+ free(mwmhints);
}
+
return ret;
}
@@ -93,11 +99,11 @@ ecore_x_mwm_borderless_set(Ecore_X_Window win, int borderless)
data[0] = 2; /* just set the decorations hint! */
data[2] = !borderless;
-
+
LOGFN(__FILE__, __LINE__, __FUNCTION__);
- ecore_x_window_prop_property_set(win,
- ECORE_X_ATOM_MOTIF_WM_HINTS,
- ECORE_X_ATOM_MOTIF_WM_HINTS,
- 32, (void *)data, 5);
+ ecore_x_window_prop_property_set(win,
+ ECORE_X_ATOM_MOTIF_WM_HINTS,
+ ECORE_X_ATOM_MOTIF_WM_HINTS,
+ 32, (void *)data, 5);
}