Fixed keyboard layouts being incorrectly positioned issue 10/80010/2
authorJi-hoon Lee <dalton.lee@samsung.com>
Thu, 14 Jul 2016 05:50:33 +0000 (14:50 +0900)
committerJi-hoon Lee <dalton.lee@samsung.com>
Thu, 14 Jul 2016 05:54:50 +0000 (14:54 +0900)
Change-Id: I7be9a7573ce53c9468813ca7a730226d67ef1db2

data/layout/wearable/LYT_PORTRAIT_4X4_CANGJIE.xml
data/layout/wearable/LYT_PORTRAIT_4X4_CHINESE.xml
data/layout/wearable/LYT_PORTRAIT_4X4_JAPANESE.xml
data/layout/wearable/LYT_PORTRAIT_4X4_ZHUYIN.xml
src/candidate/efl/candidate-efl.cpp
src/candidate/efl/candidate-efl.h
src/candidate/efl/candidate-multiline-efl.cpp
src/candidate/efl/candidate-multiline-efl.h
src/candidate/include/candidate.h
src/ise.cpp

index 120e0a9..f521bc5 100644 (file)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<layout width="360" height="240" magnifier="true" key_width="80" key_height="60" vibe_style="DEFAULT" sound_style="DEFAULT" label_type="3X4_DEFAULT">
+<layout width="360" height="240" magnifier="true" key_width="80" key_height="50" vibe_style="DEFAULT" sound_style="DEFAULT" label_type="3X4_DEFAULT">
   <image_path>
     <button_normal>B09_panel.png</button_normal>
   </image_path>
index 00c4ef8..239e9a2 100644 (file)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<layout width="360" height="240" magnifier="true" key_width="34" key_height="50" key_spacing="0" row_spacing="0" hit_left="0" hit_right="0" hit_top="0" hit_bottom="0" label_type="QTY_DEFAULT" vibe_style="DEFAULT" sound_style="DEFAULT">
+<layout width="360" height="240" magnifier="true" key_width="34" key_height="40" key_spacing="0" row_spacing="0" hit_left="0" hit_right="0" hit_top="0" hit_bottom="0" label_type="QTY_DEFAULT" vibe_style="DEFAULT" sound_style="DEFAULT">
   <image_path>
     <button_normal>B09_panel.png</button_normal>
   </image_path>
index 1ce1301..ca8cee3 100644 (file)
@@ -11,7 +11,7 @@
     <rec button="pressed">button/B09_Qwerty_btn_press.png</rec>
     <rec button="disabled">button/B09_Qwerty_btn_01.png</rec>
   </background_image>
-  <row x="10" y="40">
+  <row x="10">
     <key use_magnifier="true" longkey_magnifier="true" long_key_value="1" multitouch_type="settle_previous" hit_left="9">
       <label>
         <rec auto_upper="true">q</rec>
index 120e0a9..f521bc5 100644 (file)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<layout width="360" height="240" magnifier="true" key_width="80" key_height="60" vibe_style="DEFAULT" sound_style="DEFAULT" label_type="3X4_DEFAULT">
+<layout width="360" height="240" magnifier="true" key_width="80" key_height="50" vibe_style="DEFAULT" sound_style="DEFAULT" label_type="3X4_DEFAULT">
   <image_path>
     <button_normal>B09_panel.png</button_normal>
   </image_path>
index f30d51c..aad042a 100644 (file)
@@ -178,6 +178,11 @@ EflCandidate::hide() {
     evas_object_hide(layout);
 }
 
+int
+EflCandidate::get_height() {
+    return candidate_config.height;
+}
+
 void
 EflCandidate::update(const vector<string> &vec_str) {
     cur_candidates = vec_str;
index 11f7d75..45e3d71 100644 (file)
@@ -33,6 +33,7 @@ class EflCandidate: public Candidate
         void show();
         void hide();
         void update(const std::vector<std::string> &candidates);
+        int get_height();
         void item_pressed(Evas_Object *item);
         void item_released(Evas_Object *item);
         void item_moved(Evas_Object *item);
index dc6d53c..b77a5a0 100644 (file)
@@ -547,3 +547,9 @@ EflMultiLineCandidate::rotate(int degree)
     evas_object_move(m_candidateCloseBtn, m_screenWidth-MORE_BUTTON_WIDTH*m_screenRatio,
                      (CANDIDATE_WINDOW_HEIGHT-MORE_BUTTON_HEIGHT)*m_screenRatio/2);
 }
+
+int
+EflMultiLineCandidate::get_height()
+{
+    return CANDIDATE_WINDOW_HEIGHT*m_screenRatio;
+}
\ No newline at end of file
index 86f5b79..35ec8d1 100644 (file)
@@ -38,6 +38,7 @@ class EflMultiLineCandidate: public Candidate
         void hide();
         void update(const std::vector<std::string> &candidates);
         void rotate(int degree);
+        int get_height();
         void more_btn_clicked();
         void more_btn_released();
         void close_btn_clicked();
index f5e5a3b..f534a6f 100644 (file)
@@ -70,6 +70,7 @@ class Candidate
         virtual void hide() = 0;
         virtual void update(const std::vector<std::string> &candidates) = 0;
         virtual void rotate(int degree) { }
+        virtual int get_height() { return 0; }
         void add_event_listener(EventListener *l);
     protected:
         void notify_listeners(const EventDesc &desc);
index 73d3abf..22f6c09 100644 (file)
@@ -486,17 +486,21 @@ void CCoreEventCallback::on_candidate_show(sclint ic, const sclchar *ic_uuid)
 
     create_softcandidate();
 
-    if (g_candidate)
-        g_candidate->show();
-
     g_softcandidate_show = true;
-    g_ui->set_custom_starting_coordinates(0, CANDIDATE_WINDOW_HEIGHT);
+    if (g_candidate) {
+        g_candidate->show();
+        if (g_ui) {
+            g_ui->set_custom_starting_coordinates(0, g_candidate->get_height());
+        }
+    }
 }
 
 void CCoreEventCallback::on_candidate_hide(sclint ic, const sclchar *ic_uuid)
 {
     add_softcandidate_hide_timer();
-    g_ui->set_custom_starting_coordinates(0, 0);
+    if (g_ui) {
+        g_ui->set_custom_starting_coordinates(0, 0);
+    }
 }
 
 void CCoreEventCallback::on_process_input_device_event(sclu32 &type, sclchar *data, size_t &len, sclu32 *ret)