Set the position of vkbd to center bottom in each angles. 50/54850/1
authorSeunghun Lee <shiin.lee@samsung.com>
Fri, 18 Dec 2015 07:13:51 +0000 (16:13 +0900)
committerSeunghun Lee <shiin.lee@samsung.com>
Fri, 18 Dec 2015 07:15:24 +0000 (16:15 +0900)
Change-Id: I1fa84fd6c941ba69865c3ca109d18046addf233f

src/e_mod_input_panel.c

index 538d79994f60558a2ee6ebb15a7c46520a81115d..fb0d3e4c62b5ab3e601b0c92925b9896630e029d 100644 (file)
@@ -125,8 +125,27 @@ _e_input_panel_position_set(E_Client *ec, int w, int h)
 
    e_zone_useful_geometry_get(ec->zone, &zx, &zy, &zw, &zh);
 
-   nx = zx + (zw - w) / 2;
-   ny = zy + zh - h;
+   /* Get the position of center bottom each angles */
+   switch (ec->e.state.rot.ang.curr)
+     {
+        case 90:
+           nx = zx + zw - w;
+           ny = zy + (zh - h) / 2;
+           break;
+        case 180:
+           nx = zx + (zw - w) / 2;
+           ny = zy;
+           break;
+        case 270:
+           nx = zx;
+           ny = zy + (zh - h) / 2;
+           break;
+        case 0:
+        default:
+           nx = zx + (zw - w) / 2;
+           ny = zy + zh - h;
+           break;
+     }
 
    e_client_util_move_without_frame(ec, nx, ny);
 }