discomfitor pushed a commit to branch enlightenment-0.19.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=fc1da30ad4ac427a526ac1526634434e3f007059

commit fc1da30ad4ac427a526ac1526634434e3f007059
Author: Mike Blumenkrantz <zm...@osg.samsung.com>
Date:   Thu Sep 24 15:46:39 2015 -0400

    add util function for determining if a client is allowed to have a frame
    
    returns false if mwm borderless is set or if csd exists
---
 src/bin/e_comp_object.c | 7 +++++++
 src/bin/e_comp_object.h | 1 +
 2 files changed, 8 insertions(+)

diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c
index 98ca8a9..9df477b 100644
--- a/src/bin/e_comp_object.c
+++ b/src/bin/e_comp_object.c
@@ -2783,6 +2783,13 @@ e_comp_object_frame_geometry_set(Evas_Object *obj, int 
l, int r, int t, int b)
    cw->ec->h += t + b;
 }
 
+E_API Eina_Bool
+e_comp_object_frame_allowed(Evas_Object *obj)
+{
+   API_ENTRY EINA_FALSE;
+   return (!cw->ec->mwm.borderless) && (cw->frame_object || 
(!cw->client_inset.calc));
+}
+
 E_API void
 e_comp_object_frame_icon_geometry_get(Evas_Object *obj, int *x, int *y, int 
*w, int *h)
 {
diff --git a/src/bin/e_comp_object.h b/src/bin/e_comp_object.h
index 93fde27..85dc741 100644
--- a/src/bin/e_comp_object.h
+++ b/src/bin/e_comp_object.h
@@ -53,6 +53,7 @@ E_API void e_comp_object_util_center(Evas_Object *obj);
 E_API void e_comp_object_util_center_on(Evas_Object *obj, Evas_Object *on);
 E_API void e_comp_object_util_center_pos_get(Evas_Object *obj, int *x, int *y);
 E_API void e_comp_object_util_fullscreen(Evas_Object *obj);
+E_API Eina_Bool e_comp_object_frame_allowed(Evas_Object *obj);
 E_API void e_comp_object_frame_geometry_get(Evas_Object *obj, int *l, int *r, 
int *t, int *b);
 E_API void e_comp_object_frame_geometry_set(Evas_Object *obj, int l, int r, 
int t, int b);
 E_API void e_comp_object_frame_icon_geometry_get(Evas_Object *obj, int *x, int 
*y, int *w, int *h);

-- 


Reply via email to