ctxpopup: Fixed ctxpopup geometry when parent is an elm_win. Forwardport from elementary-1.7.

This is manual cherry-pick from discomfitor's elementary-1.7 patch due to the code base difference.
This commit is contained in:
Daniel Juyung Seo 2013-03-29 21:29:24 +09:00
parent a7cca7ba3f
commit 73f58db6cc
3 changed files with 8 additions and 0 deletions

View File

@ -1187,3 +1187,6 @@
* Map supports "language,changed" smart callback.
2013-03-29 Mike Blumenkrantz
* Fix ctxpopup geometry when parent is an elm_win.

View File

@ -193,6 +193,7 @@ Fixes:
* Focus highlight should be reconfigured when theme is changed.
* Fix the elm_shutdown bug in _elm_shutdown_config.
* Fix box layout bug when items with max size force sizes below minimum.
* Fix ctxpopup geometry when parent is an elm_win.
Removals:

View File

@ -164,6 +164,8 @@ _base_geometry_calc(Evas_Object *obj,
evas_object_geometry_get
(sd->parent, &hover_area.x, &hover_area.y, &hover_area.w,
&hover_area.h);
if (!strcmp(evas_object_type_get(sd->parent), "elm_win"))
hover_area.x = hover_area.y = 0;
evas_object_geometry_get(obj, &pos.x, &pos.y, NULL, NULL);
@ -1186,6 +1188,8 @@ _hover_parent_set(Eo *obj, void *_pd, va_list *list)
//Update Background
evas_object_geometry_get(parent, &x, &y, &w, &h);
if (!strcmp(evas_object_type_get(parent), "elm_win"))
x = y = 0;
evas_object_move(sd->bg, x, y);
evas_object_resize(sd->bg, w, h);