aboutsummaryrefslogtreecommitdiffstats
path: root/legacy/elementary/src/lib/elm_win.c
diff options
context:
space:
mode:
authorRafael Antognolli <rafael.antognolli@intel.com>2013-05-06 20:08:58 -0300
committerRafael Antognolli <rafael.antognolli@intel.com>2013-05-06 20:08:58 -0300
commit9768137b79100b35d82fa57bc6fc43a4dc7d32e3 (patch)
tree86b7e1d975a596877c9b9d244315ef38b8fea237 /legacy/elementary/src/lib/elm_win.c
parentelementary/elm_entry.c : Just changed lines for the sequence of alphbet. (diff)
downloadefl-9768137b79100b35d82fa57bc6fc43a4dc7d32e3.tar.gz
elm/wayland: Implement borderless_set for wayland.
Also add a checkbox to the "Window States" test of elementary_test.
Diffstat (limited to 'legacy/elementary/src/lib/elm_win.c')
-rw-r--r--legacy/elementary/src/lib/elm_win.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/legacy/elementary/src/lib/elm_win.c b/legacy/elementary/src/lib/elm_win.c
index 0ccfd935cc..dffad398cf 100644
--- a/legacy/elementary/src/lib/elm_win.c
+++ b/legacy/elementary/src/lib/elm_win.c
@@ -2313,6 +2313,7 @@ _elm_win_frame_add(Elm_Win_Smart_Data *sd,
const char *style)
{
Evas_Object *obj = sd->obj;
+ int w, h;
short layer;
// FIXME: Don't use hardcoded framespace values, get it from theme
@@ -2352,11 +2353,15 @@ _elm_win_frame_add(Elm_Win_Smart_Data *sd,
edje_object_part_text_escaped_set
(sd->frame_obj, "elm.text.title", sd->title);
}
+
+ ecore_evas_geometry_get(sd->ee, NULL, NULL, &w, &h);
+ ecore_evas_resize(sd->ee, w, h);
}
static void
_elm_win_frame_del(Elm_Win_Smart_Data *sd)
{
+ int w, h;
if (sd->frame_obj)
{
edje_object_signal_callback_del
@@ -2384,6 +2389,10 @@ _elm_win_frame_del(Elm_Win_Smart_Data *sd)
evas_object_del(sd->frame_obj);
sd->frame_obj = NULL;
}
+
+ evas_output_framespace_set(sd->evas, 0, 0, 0, 0);
+ ecore_evas_geometry_get(sd->ee, NULL, NULL, &w, &h);
+ ecore_evas_resize(sd->ee, w, h);
}
#ifdef ELM_DEBUG
@@ -3330,6 +3339,21 @@ _borderless_set(Eo *obj EINA_UNUSED, void *_pd, va_list *list)
Eina_Bool borderless = va_arg(*list, int);
Elm_Win_Smart_Data *sd = _pd;
+ if (borderless)
+ {
+ if (EE_ENGINE_COMPARE(sd->ee, ELM_WAYLAND_SHM) ||
+ EE_ENGINE_COMPARE(sd->ee, ELM_WAYLAND_EGL))
+ _elm_win_frame_del(sd);
+ }
+ else
+ {
+ if (EE_ENGINE_COMPARE(sd->ee, ELM_WAYLAND_SHM) ||
+ EE_ENGINE_COMPARE(sd->ee, ELM_WAYLAND_EGL))
+ _elm_win_frame_add(sd, "default");
+
+ evas_object_show(sd->frame_obj);
+ }
+
TRAP(sd, borderless_set, borderless);
#ifdef HAVE_ELEMENTARY_X
_elm_win_xwin_update(sd);