conformant: refer to window position when reflecting keyboard size 30/123230/5
authorHosang Kim <hosang12.kim@samsung.com>
Wed, 5 Apr 2017 04:28:01 +0000 (13:28 +0900)
committerGerrit Code Review <gerrit@review.vlan103.tizen.org>
Wed, 5 Apr 2017 06:44:02 +0000 (23:44 -0700)
The vitural keyapd geometry is absolute coordinates value.
But conformant geometry is relative coordinates value.
When calculating overlapping size between keypad and conformant,
there is calculation error. So add window's x, y position for accurate
calculation.

@tizen_fix

Change-Id: Ia6fe558716439e39ccbc4e364fec309f80385f25

src/lib/elm_conform.c

index 3f431acb1cd028f2aa408c0629fef4fa010369a4..c8508adcbafb3c0b6a38b151980e898906242f99 100644 (file)
@@ -201,9 +201,20 @@ _conformant_part_size_hints_set(Evas_Object *obj,
 {
    Evas_Coord cx, cy, cw, ch;
    Evas_Coord part_height = 0, part_width = 0;
+   //TIZEN_ONLY(20170405): add window's x,y postion when calculating overlapping size.
+   Evas_Coord tx, ty;
+   Evas_Object *top;
+   //
 
    evas_object_geometry_get(obj, &cx, &cy, &cw, &ch);
 
+   //TIZEN_ONLY(20170405): add window's x,y postion when calculating overlapping size.
+   top = elm_widget_top_get(obj);
+   evas_object_geometry_get(top, &tx, &ty, NULL, NULL);
+   cx += tx;
+   cy += ty;
+   //
+
    /* Part overlapping with conformant */
    if ((cx < (sx + sw)) && ((cx + cw) > sx)
        && (cy < (sy + sh)) && ((cy + ch) > sy))