TizenRefApp-7486 [Call UI] Implement application widget RTL mode support 94/93494/1
authorIgor Olshevskyi <i.olshevskyi@samsung.com>
Fri, 21 Oct 2016 15:20:10 +0000 (18:20 +0300)
committerIgor Olshevskyi <i.olshevskyi@samsung.com>
Mon, 24 Oct 2016 12:47:14 +0000 (15:47 +0300)
Change-Id: Ib62f977226fac842f89a3c9e65a85e5da4070bb8

17 files changed:
edje_src/edc/callui-view-caller-info.edc
edje_src/edc/callui-view-end-call.edc
edje_src/edc/callui-view-incoming-call-noti.edc
edje_src/edc/callui-view-main-layout.edc
edje_src/edc/callui-view-multi-call-list.edc
edje_src/edc/callui-view-multi-call-split.edc
edje_src/edc/callui-view-quick-pannel.edc
inc/callui-common-types.h
inc/callui-common.h
inc/callui-window.h
src/callui-common.c
src/callui-keypad.c
src/callui-view-incoming-call-noti.c
src/callui-view-multi-call-conf.c
src/callui-view-multi-call-split.c
src/callui-window.c
src/callui.c

index a328de7..c56206f 100644 (file)
@@ -75,13 +75,54 @@ group{ name: "elm/layout/callui/manage_calls";
                CU_PART_IMAGE( "btn",
                        mouse_events: 1;
                        description { state: "default" 0.0;
-                               rel1 { relative: 0.0 0.0;       to: "bg"; }
-                               rel2 { relative: 1.0 1.0;       to: "bg"; }
+                               rel1 { relative: 0.0 0.0; to: "bg"; }
+                               rel2 { relative: 1.0 1.0; to: "bg"; }
                                image.normal: "call_multi_ic_arrow.png";
                                color_class: "manage_calls_arrow";
+                               map {
+                                       on: 1;
+                                       smooth: 1;
+                                       perspective_on: 1;
+                                       rotation.x: 0;
+                                       rotation.y: 0;
+                                       rotation.z: 0;
+                               }
+                       }
+                       description { state: "ltr" 0.0;
+                               inherit: "default" 0.0;
+                       }
+                       description { state: "rtl" 0.0;
+                               inherit: "default" 0.0;
+                               map.rotation.y: 180.0;
                        }
                )
        }
+       programs {
+               program { name: "ltr";
+                       signal: "edje,state,ltr";
+                       source: "edje";
+                       action: STATE_SET "ltr" 0 0;
+                       target: "btn";
+               }
+               program { name: "rtl";
+                       signal: "edje,state,rtl";
+                       source: "edje";
+                       action: STATE_SET "rtl" 0 0;
+                       target: "btn";
+               }
+               program { name: "set_ltr";
+                       signal: "set_ltr_mode";
+                       source: "manage_calls";
+                       action: STATE_SET "ltr" 0 0;
+                       target: "btn";
+               }
+               program { name: "set_rtl";
+                       signal: "set_rtl_mode";
+                       source: "manage_calls";
+                       action: STATE_SET "rtl" 0 0;
+                       target: "btn";
+               }
+       }
 }
 
 group{
index 17cb34a..2e46efd 100644 (file)
 
 styles {
        style { name: "ec_contact_name";
-               base: "font=Tizen:style=Light font_size=56 color=#fafafaff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Light font_size=56 color=#fafafaff align=auto ellipsis=1.0";
        }
        style { name: "ec_phone_number";
-               base: "font=Tizen:style=Regular font_size=34 color=#fafafaff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=34 color=#fafafaff align=auto ellipsis=1.0";
        }
        style { name: "ec_call_status";
-               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=auto ellipsis=1.0";
        }
        style { name: "ec_reply_btn";
                base: "font=Tizen:style=Regular font_size=28 text_class=tizen color=#808080ff align=center valign=center ellipsis=1.0";
index d4ee602..c5d793f 100644 (file)
 
 styles {
        style { name: "an_contacts_name";
-               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=left valign=center ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=auto valign=center ellipsis=1.0";
        }
        style { name: "an_contacts_info";
-               base: "font=Tizen:style=Regular font_size=32 color=#fafafaff align=left valign=center ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=32 color=#fafafaff align=auto valign=center ellipsis=1.0";
        }
        style { name: "an_reject_msg_item";
-               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=left valign=center ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=auto valign=center ellipsis=1.0";
        }
        style { name: "an_button";
                base: "font=Tizen:style=Regular font_size=40 color=#ffffffff align=center valign=center ellipsis=1.0";
@@ -1081,34 +1081,43 @@ group {
                                inherit: "default" 0.0;
                        }
                )
-               CU_PART_TEXTBLOCK ( "text.status",
+               CU_PART_TEXTBLOCK( "text.status",
                        description { state: "default" 0.0;
-                               align: 0.0 0.0;
+                               align: 0.5 0.0;
                                rel1 { relative: 1.0 1.0; to_x: "contact_icon.pad.right"; to_y: "text_info.pad.top"; }
                                rel2 { relative: 0.0 1.0; to_x: "padding.right"; to_y: "text_info.pad.top"; }
                                min: 0 AN_STATUS_TXT_H;
                                fixed: 0 1;
-                               text.style:"an_contacts_info";
+                               text {
+                                       style:"an_contacts_info";
+                                       fit: 1 1;
+                               }
                        }
                )
-               CU_PART_TEXTBLOCK ( "text.contact_name",
+               CU_PART_TEXTBLOCK( "text.contact_name",
                        description { state: "default" 0.0;
-                               align: 0.0 0.0;
+                               align: 0.5 0.0;
                                rel1 { relative: 1.0 1.0; to_x: "contact_icon.pad.right"; to_y: "text.status"; }
                                rel2 { relative: 0.0 1.0; to_x: "padding.right"; to_y: "text.status"; }
                                min: 0 AN_CONTACT_NAME_TXT_H;
                                fixed: 0 1;
-                               text.style:"an_contacts_name";
+                               text {
+                                       style:"an_contacts_name";
+                                       fit: 1 1;
+                               }
                        }
                )
-               CU_PART_TEXTBLOCK ( "text.contact_number",
+               CU_PART_TEXTBLOCK( "text.contact_number",
                        description { state: "default" 0.0;
-                               align: 0.0 0.0;
+                               align: 0.5 0.0;
                                rel1 { relative: 1.0 1.0; to_x: "contact_icon.pad.right"; to_y: "text.contact_name"; }
                                rel2 { relative: 0.0 1.0; to_x: "padding.right"; to_y: "text.contact_name"; }
                                min: 0 AN_CONTACT_NUMBER_TXT_H;
                                fixed: 0 1;
-                               text.style:"an_contacts_info";
+                               text {
+                                       style:"an_contacts_info";
+                                       fit: 1 1;
+                               }
                        }
                        description { state: "show" 0.0;
                                inherit: "default" 0.0;
index ba2ad8d..c9dfc80 100644 (file)
@@ -23,6 +23,13 @@ group { name: "elm/layout/callui/app_main";
                CU_PART_SWALLOW( "elm.swallow.content",
                        description { state: "default" 0.0; }
                )
+               CU_PART_SWALLOW( "elm.swallow.active_noti",
+                       description { state: "default" 0.0;
+                               rel1{ relative: 0.0 0.0; to: "bg"; }
+                               rel2{ relative: 0.0 1.0; to: "bg"; }
+                               align: 0 0.5;
+                       }
+               )
                CU_PART_SWALLOW( "swallow.action_bar",
                        clip_to: "keypadarea.clipper";
                        description { state: "default" 0.0;
@@ -110,7 +117,7 @@ group { name: "elm/layout/callui/app_main";
 
 styles {
        style { name: "vml_call_status";
-               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=auto ellipsis=1.0";
        }
 }
 
index 6bf1933..f04ee18 100644 (file)
@@ -22,7 +22,7 @@
 
 styles {
        style { name: "multicall_list_call_duration";
-               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=auto ellipsis=1.0";
        }
 }
 
index 02d29fb..ea4d1dc 100644 (file)
 
 styles {
        style { name: "sc_contact_name";
-               base: "font=Tizen:style=Light font_size=56 color=#fafafaff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Light font_size=56 color=#fafafaff align=auto ellipsis=1.0";
        }
        style { name: "sc_phone_number";
-               base: "font=Tizen:style=Regular font_size=34 color=#fafafaff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=34 color=#fafafaff align=auto ellipsis=1.0";
        }
        style { name: "sc_call_duration";
-               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=40 color=#fafafaff align=auto ellipsis=1.0";
        }
        style { name: "sc_manage_call_btn";
                base: "font=Tizen:style=Regular font_size=27 color=#fafafaff align=center valign=center ellipsis=1.0";
        }
 }
 
-#define SPLIT_CALL_MANAGE_BTN(grp_name, bg_image, icon, bg_color_norm, bg_color_press) \
+#define SPLIT_CALL_MANAGE_BTN(grp_name, bg_image_ltr, bg_image_rtl, icon, bg_color_norm_ltr, bg_color_press_ltr, bg_color_norm_rtl, bg_color_press_rtl) \
        group { name: "elm/button/base/"grp_name; \
                images { \
-                       image: bg_image COMP; \
+                       image: bg_image_ltr COMP; \
+                       image: bg_image_rtl COMP; \
                        image: icon COMP; \
                } \
                script { \
                        PRESS_EFFECT_DEFAULT_SCRIPT_VAR \
+                       public is_rtl = 0; \
                } \
-               parts { part { name: "bg"; \
+               parts { \
+                       part { name: "bg"; \
                                type: IMAGE; \
                                scale: 1; \
                                description { \
                                        state: "default" 0.0; \
-                                       image.normal: bg_image; \
-                                       color_class: bg_color_norm; \
+                                       image.normal: bg_image_ltr; \
+                                       color_class: bg_color_norm_ltr; \
+                               } \
+                               description { state: "ltr" 0.0; \
+                                       inherit: "default" 0.0; \
+                               } \
+                               description { state: "rtl" 0.0; \
+                                       image.normal: bg_image_rtl; \
+                                       color_class: bg_color_norm_rtl; \
                                } \
                        } \
-                       part { name: "bg_press"; \
+                       part { name: "bg_press_ltr"; \
                                type: IMAGE; \
                                scale: 1; \
                                mouse_events: 1; \
                                description { state: "default" 0.0; \
                                        rel1 { relative: 0.0 0.0; to: "bg"; } \
                                        rel2 { relative: 1.0 1.0; to: "bg"; } \
-                                       image.normal: bg_image; \
+                                       image.normal: bg_image_ltr; \
                                        color_class: "transparent_black"; \
                                } \
                                description { state: "pressed" 0.0; \
                                        inherit: "default" 0.0; \
-                                       color_class: bg_color_press; \
+                                       color_class: bg_color_press_ltr; \
+                               } \
+                               description { state: "pressed_effect" 0.0; \
+                                       inherit: "pressed" 0.0; \
+                                       rel1 { relative: 0.15 0.15; to: "bg"; } \
+                                       rel2 { relative: 0.85 0.85; to: "bg"; } \
+                               } \
+                       } \
+                       part { name: "bg_press_rtl"; \
+                               type: IMAGE; \
+                               scale: 1; \
+                               mouse_events: 1; \
+                               description { state: "default" 0.0; \
+                                       rel1 { relative: 0.0 0.0; to: "bg"; } \
+                                       rel2 { relative: 1.0 1.0; to: "bg"; } \
+                                       image.normal: bg_image_rtl; \
+                                       color_class: "transparent_black"; \
+                               } \
+                               description { state: "pressed" 0.0; \
+                                       inherit: "default" 0.0; \
+                                       color_class: bg_color_press_rtl; \
                                } \
                                description { state: "pressed_effect" 0.0; \
                                        inherit: "pressed" 0.0; \
@@ -118,7 +148,147 @@ styles {
                        } \
                } \
                programs { \
-                       PRESS_EFFECT_DEFAULT_PROGRAMS \
+                       program { name: "pressed_effect"; \
+                               action: STATE_SET "pressed_effect" 0.0; \
+                               script { \
+                                       if (get_int(is_rtl) == 0) { \
+                                               set_state(PART:"bg_press_ltr", "pressed_effect", 0.0); \
+                                       } else { \
+                                               set_state(PART:"bg_press_rtl", "pressed_effect", 0.0); \
+                                       } \
+                                       run_program(PROGRAM:"pressed_effect2"); \
+                               } \
+                       } \
+                       program { name: "pressed_effect2_ltr"; \
+                               action: STATE_SET "pressed" 0.0; \
+                               target: "bg_press_ltr"; \
+                               transition: TRANSITION_GLIDE(0.15); \
+                               after: "pressed_effect3"; \
+                       } \
+                       program { name: "pressed_effect2_rtl"; \
+                               action: STATE_SET "pressed" 0.0; \
+                               target: "bg_press_rtl"; \
+                               transition: TRANSITION_GLIDE(0.15); \
+                               after: "pressed_effect3"; \
+                       } \
+                       program { name: "pressed_effect2"; \
+                               script { \
+                                       if (get_int(is_rtl) == 0) { \
+                                               run_program(PROGRAM:"pressed_effect2_ltr"); \
+                                       } else { \
+                                               run_program(PROGRAM:"pressed_effect2_rtl"); \
+                                       } \
+                               } \
+                       } \
+                       program { name: "pressed_effect3"; \
+                               script { \
+                                       set_int(animate, 0); \
+                               } \
+                       } \
+                       program { name: "delay_unpressed_effect"; \
+                               in: 0.1 0.0; \
+                               after: "unpressed_effect"; \
+                       } \
+                       program { name: "unpressed_effect_ltr"; \
+                               action: STATE_SET "default" 0.0; \
+                               target: "bg_press_ltr"; \
+                               transition: TRANSITION_GLIDE(0.45); \
+                       } \
+                       program { name: "unpressed_effect_rtl"; \
+                               action: STATE_SET "default" 0.0; \
+                               target: "bg_press_rtl"; \
+                               transition: TRANSITION_GLIDE(0.45); \
+                       } \
+                       program { name: "unpressed_effect"; \
+                               script { \
+                                       if (get_int(is_rtl) == 0) { \
+                                               run_program(PROGRAM:"unpressed_effect_ltr"); \
+                                       } else { \
+                                               run_program(PROGRAM:"unpressed_effect_rtl"); \
+                                       } \
+                               } \
+                       } \
+                       program { name: "pressed"; \
+                               signal: "mouse,down,1*"; \
+                               source: "over"; \
+                               script { \
+                                       if ((get_int(multi_down) == 0) && (get_int(mouse_down) == 0)) { \
+                                               stop_program(PROGRAM:"delay_unpressed_effect"); \
+                                               set_int(mouse_down, 1); \
+                                               set_int(animate, 1); \
+                                               emit("elm,action,press", ""); \
+                                               run_program(PROGRAM:"pressed_effect"); \
+                                       } \
+                               } \
+                       } \
+                       program { name: "unpressed"; \
+                               signal: "mouse,up,1"; \
+                               source: "over"; \
+                               script { \
+                                       if (get_int(mouse_down) == 1) { \
+                                               set_int(mouse_down, 0); \
+                                               if (get_int(animate) == 0) { \
+                                                       run_program(PROGRAM:"unpressed_effect"); \
+                                               } else { \
+                                                       if (get_int(is_rtl) == 0) { \
+                                                               set_state(PART:"bg_press_ltr", "pressed", 0.0); \
+                                                       } else { \
+                                                               set_state(PART:"bg_press_rtl", "pressed", 0.0); \
+                                                       } \
+                                                       set_int(animate, 0); \
+                                                       run_program(PROGRAM:"delay_unpressed_effect"); \
+                                               } \
+                                               emit("elm,action,unpress", ""); \
+                                       } \
+                               } \
+                       } \
+                       program { name: "touch_snd"; \
+                               signal: "mouse,clicked,1"; \
+                               source: "over"; \
+                                       script { \
+                                               if (get_int(multi_down) == 0) { \
+                                                       run_program(PROGRAM:"touch_sound"); \
+                                                       run_program(PROGRAM:"clicked_signal"); \
+                                               } \
+                                       } \
+                       } \
+                       program { name: "touch_sound"; \
+                               action: RUN_PLUGIN "touch_sound"; \
+                       } \
+                       program { name: "clicked_signal"; \
+                               in: 0.001 0.0; \
+                               action: SIGNAL_EMIT "elm,action,click" ""; \
+                       } \
+                       program { name: "multi_down"; \
+                               signal: "elm,action,multi,down"; \
+                               source: "elm"; \
+                               script { \
+                                       set_int(multi_down, 1); \
+                               } \
+                       } \
+                       program { name: "multi_up"; \
+                               signal: "elm,action,multi,up"; \
+                               source: "elm"; \
+                               script { \
+                                       set_int(multi_down, 0); \
+                               } \
+                       } \
+                       program { name: "ltr"; \
+                               signal: "edje,state,ltr"; \
+                               source: "edje"; \
+                               script { \
+                                       set_state(PART:"bg", "ltr", 0.0); \
+                                       set_int(is_rtl, 0); \
+                               } \
+                       } \
+                       program { name: "rtl"; \
+                               signal: "edje,state,rtl"; \
+                               source: "edje"; \
+                               script { \
+                                       set_state(PART:"bg", "rtl", 0.0); \
+                                       set_int(is_rtl, 1); \
+                               } \
+                       } \
                } \
        }
 
@@ -146,6 +316,10 @@ group { \
                image: "call_multi_ic_arrow.png" COMP; \
                image: "call_multi_hold_bg.png" COMP; \
        } \
+       script { \
+               public is_rtl = 0; \
+               public is_arrow_shown = 0; \
+       } \
        parts { \
                _bg_part \
                CU_PART_SPACER( "pad.top", \
@@ -290,16 +464,33 @@ group { \
                                fixed: 1 1; \
                                image.normal: "call_multi_ic_arrow.png"; \
                                align: 0.0 1.0; \
+                               map { \
+                                       on: 1; \
+                                       smooth: 1; \
+                                       perspective_on: 1; \
+                                       rotation.x: 0.0; \
+                                       rotation.y: 0.0; \
+                                       rotation.z: 0.0; \
+                               } \
+                       } \
+                       description { state: "show_ltr" 0.0; \
+                               inherit: "default" 0.0; \
+                               visible: 1; \
                        } \
-                       description { state: "show" 0.0; \
+                       description { state: "show_rtl" 0.0; \
                                inherit: "default" 0.0; \
                                visible: 1; \
+                               map.rotation.y: 180.0; \
                        } \
                        description { state: "hide" 0.0; \
                                inherit: "default" 0.0; \
                        } \
-                       description { state: "pressed" 0.0; \
-                               inherit: "show" 0.0; \
+                       description { state: "pressed_ltr" 0.0; \
+                               inherit: "show_ltr" 0.0; \
+                               color_class: "pressed"; \
+                       } \
+                       description { state: "pressed_rtl" 0.0; \
+                               inherit: "show_rtl" 0.0; \
                                color_class: "pressed"; \
                        } \
                ) \
@@ -313,29 +504,69 @@ group { \
                        action: STATE_SET "hide_arrow" 0.0; \
                        target: "pad.right"; \
                } \
-               program { name: "show_arrow"; \
-                       signal: "show_manage_calls_btn"; \
-                       action: STATE_SET "show" 0.0; \
-                       target: "arrow"; \
-                       after: "max_pad_right"; \
+               program { name: "show_manage_calls_btn_ltr"; \
+                       signal: "show_manage_calls_btn_ltr"; \
+                       script { \
+                               set_int(is_arrow_shown, 1); \
+                               set_state(PART:"arrow", "show_ltr", 0.0); \
+                               run_program(PROGRAM:"max_pad_right"); \
+                       } \
+               } \
+               program { name: "show_manage_calls_btn_rtl"; \
+                       signal: "show_manage_calls_btn_rtl"; \
+                       script { \
+                               set_int(is_arrow_shown, 1); \
+                               set_state(PART:"arrow", "show_rtl", 0.0); \
+                               run_program(PROGRAM:"max_pad_right"); \
+                       } \
                } \
                program { name: "hide_arrow"; \
                        signal: "hide_manage_calls_btn"; \
-                       action: STATE_SET "hide" 0.0; \
-                       target: "arrow"; \
-                       after: "min_pad_right"; \
+                       script { \
+                               set_int(is_arrow_shown, 0); \
+                               set_state(PART:"arrow", "hide", 0.0); \
+                               run_program(PROGRAM:"min_pad_right"); \
+                       } \
                } \
                program { name: "arrow_pressed"; \
                        signal: "mouse,down,*"; \
-                       source: "arrow"; \
-                       action: STATE_SET "pressed" 0.0; \
-                       target: "arrow"; \
+                       script { \
+                               if (get_int(is_rtl) == 0) { \
+                                       set_state(PART:"arrow", "pressed_ltr", 0.0); \
+                               } else { \
+                                       set_state(PART:"arrow", "pressed_rtl", 0.0); \
+                               } \
+                       } \
                } \
                program { name: "arrow_unpressed"; \
                        signal: "mouse,up,*"; \
-                       source: "arrow"; \
-                       action: STATE_SET "default" 0.0; \
-                       target: "arrow"; \
+                       script { \
+                               if (get_int(is_rtl) == 0) { \
+                                       set_state(PART:"arrow", "show_ltr", 0.0); \
+                               } else { \
+                                       set_state(PART:"arrow", "show_rtl", 0.0); \
+                               } \
+                       } \
+               } \
+               program { name: "ltr"; \
+                       signal: "edje,state,ltr"; \
+                       source: "edje"; \
+                       script { \
+                               if (get_int(is_arrow_shown) == 1) { \
+                                       set_state(PART:"arrow", "show_ltr", 0.0); \
+                               } \
+                               set_int(is_rtl, 0); \
+                       } \
+               } \
+               program { name: "rtl"; \
+                       signal: "edje,state,rtl"; \
+                       source: "edje"; \
+                       script { \
+                               if (get_int(is_arrow_shown) == 1) { \
+                                       set_state(PART:"arrow", "show_rtl", 0.0); \
+                               } \
+                               set_int(is_rtl, 1); \
+                       } \
                } \
        } \
 } \
@@ -406,5 +637,5 @@ group { name: "elm/layout/callui/split_callers_info";
        }
 }
 
-SPLIT_CALL_MANAGE_BTN("callui_multi_split_merge_btn", "call_multi_hold_btn_merge_bg.png", "call_multi_ic_merge.png", "multi_hold_merge_btn_norm", "multi_hold_merge_btn_press");
-SPLIT_CALL_MANAGE_BTN("callui_multi_split_swap_btn", "call_multi_hold_btn_swap_bg.png", "call_multi_ic_swap.png", "multi_hold_swap_btn_norm", "multi_hold_swap_btn_press");
+SPLIT_CALL_MANAGE_BTN("callui_multi_split_merge_btn", "call_multi_hold_btn_merge_bg.png", "call_multi_hold_btn_swap_bg.png", "call_multi_ic_merge.png", "multi_hold_merge_btn_norm", "multi_hold_merge_btn_press", "multi_hold_swap_btn_norm", "multi_hold_swap_btn_press");
+SPLIT_CALL_MANAGE_BTN("callui_multi_split_swap_btn", "call_multi_hold_btn_swap_bg.png", "call_multi_hold_btn_merge_bg.png", "call_multi_ic_swap.png", "multi_hold_swap_btn_norm", "multi_hold_swap_btn_press", "multi_hold_merge_btn_norm", "multi_hold_merge_btn_press");
index 5ec7029..6a05ecf 100644 (file)
 
 styles {
        style { name: "qp_mc_caller_name";
-               base: "font=Tizen:style=Regular font_size=40 color=#000000ff align=left ellipsis=0.0";
+               base: "font=Tizen:style=Regular font_size=40 color=#000000ff align=auto ellipsis=0.0";
        }
        style { name: "qp_mc_call_duration";
-               base: "font=Tizen:style=Regular font_size=30 color=#7f7f7fff align=left ellipsis=1.0";
+               base: "font=Tizen:style=Regular font_size=30 color=#7f7f7fff align=auto ellipsis=1.0";
        }
 }
 
index 1207b40..7c3676e 100644 (file)
@@ -37,6 +37,12 @@ typedef enum {
 
 } callui_result_e;
 
+typedef enum {
+       CALLUI_LOCK_TYPE_UNLOCK = 1,
+       CALLUI_LOCK_TYPE_SWIPE_LOCK,
+       CALLUI_LOCK_TYPE_SECURITY_LOCK
+} callui_idle_lock_type_e;
+
 typedef struct {
        int r;
        int g;
index 328aabf..964023d 100644 (file)
 #include "callui-common-types.h"
 #include "callui-common-defines.h"
 
-typedef enum {
-       CALLUI_LOCK_TYPE_UNLOCK = 1,
-       CALLUI_LOCK_TYPE_SWIPE_LOCK,
-       CALLUI_LOCK_TYPE_SECURITY_LOCK
-} callui_idle_lock_type_t;
-
 /* Set call duration function prototype */
 typedef void (*set_call_duration_time)(struct tm *cur_time, Evas_Object *obj, const char *part);
 
@@ -45,7 +39,7 @@ Eina_Bool _callui_common_is_headset_conected(void *appdata);
  *
  * @return Device lock type
  */
-callui_idle_lock_type_t _callui_common_get_idle_lock_type(void);
+callui_idle_lock_type_e _callui_common_get_idle_lock_type(void);
 
 /**
  * @brief Unlocks swipe lock
@@ -261,4 +255,12 @@ bool _callui_common_is_handsfree_mode_on(void *appdata);
  */
 bool _callui_common_is_app_foreground();
 
+/**
+ * @brief Checks whether application is in mirrored mode
+ *
+ * @return @c true when application mirrored mode is on, otherwise false
+ *
+ */
+bool _callui_common_is_mirrored_mode_on();
+
 #endif /*__CALLUI_COMMON_H__ */
index 047d667..f6aa6ef 100644 (file)
@@ -97,6 +97,15 @@ void _callui_window_set_content(callui_window_h window_h, Evas_Object *content);
 void _callui_window_set_size_type(callui_window_h window_h, callui_win_size_type_e size_type);
 
 /**
+ * @brief Validates position of the window
+ *
+ * @param[in]  window_h                Window handle
+ *
+ * @return CALLUI_RESULT_OK on success or another result otherwise
+ */
+callui_result_e _callui_window_validate_position(callui_window_h window_h);
+
+/**
  * @brief Sets rotation lock state
  *
  * @param[in]  window_h        Window handle
index e5948af..c9d68e7 100755 (executable)
@@ -119,12 +119,12 @@ Eina_Bool _callui_common_is_headset_conected(void *appdata)
  *
  * @return Device lock type
  */
-callui_idle_lock_type_t _callui_common_get_idle_lock_type(void)
+callui_idle_lock_type_e _callui_common_get_idle_lock_type(void)
 {
        int lock_state = -1;
        int lock_type = SETTING_SCREEN_LOCK_TYPE_NONE;
        int ret = 0;
-       callui_idle_lock_type_t ret_val = CALLUI_LOCK_TYPE_UNLOCK;
+       callui_idle_lock_type_e ret_val = CALLUI_LOCK_TYPE_UNLOCK;
 
        ret = system_settings_get_value_int(SYSTEM_SETTINGS_KEY_LOCK_STATE, &lock_state);
        if (ret < 0) {
@@ -184,7 +184,7 @@ static void __app_launch_reply_cb(app_control_h request, app_control_h reply, ap
 static void __try_send_app_launch_request(callui_app_data_t *ad, app_control_h app_control)
 {
        int ret;
-       callui_idle_lock_type_t type = _callui_common_get_idle_lock_type();
+       callui_idle_lock_type_e type = _callui_common_get_idle_lock_type();
 
        if (type == CALLUI_LOCK_TYPE_SWIPE_LOCK) {
                if (ad->delayed_app_control) {
@@ -1233,3 +1233,10 @@ bool _callui_common_is_app_foreground()
 
        return (state == APP_STATE_FOREGROUND);
 }
+
+bool _callui_common_is_mirrored_mode_on()
+{
+       bool is_mirrored_mode = elm_config_mirrored_get();
+       dbg("Mirrored mode [%s]", is_mirrored_mode?"ON":"OFF");
+       return is_mirrored_mode;
+}
index 4acd6b7..2f2af98 100755 (executable)
@@ -97,6 +97,8 @@ static callui_result_e __callui_keypad_init(callui_keypad_h keypad, callui_app_d
 
        keypad->btns_layout = _callui_create_layout(keypad->main_layout, CALLUI_LY_STYLE_KEYPAD_BTNS);
        CALLUI_RETURN_VALUE_IF_FAIL(keypad->btns_layout, CALLUI_RESULT_ALLOCATION_FAIL);
+       elm_object_mirrored_automatic_set(keypad->btns_layout, EINA_FALSE);
+       elm_object_mirrored_set(keypad->btns_layout, EINA_FALSE);
 
        elm_object_part_content_set(keypad->main_layout, CALLUI_PART_SWALLOW_KEYPAD, keypad->btns_layout);
 
index 9bb208d..3cdcb6c 100644 (file)
@@ -91,9 +91,7 @@ struct _callui_view_incoming_call_noti {
 
        Evas_Object *parent;
 
-       Evas_Object *box;
        Evas_Object *layout;
-
        Evas_Object *rm_scroller;
        Evas_Object *rm_scroller_anchor;
        Evas_Object *rm_scroller_stroke;
@@ -130,7 +128,7 @@ static void __disappear_transit_del_cb(void *data, Elm_Transit *transit);
 static Eina_Bool __appear_effect_activated_cb(void *data);
 static Eina_Bool __disappear_effect_activated_cb(void *data);
 static void __show_reject_msg_btn_click_cb(void *data, Evas_Object *obj, void *event_info);
-static void __box_changed_hints_cb(void *data, Evas *e, Evas_Object *obj, void *event_info);
+static void __layout_changed_hints_cb(void *data, Evas *e, Evas_Object *obj, void *event_info);
 
 static void __call_action_btn_click_cb(void *data, Evas_Object *obj, void *event_info);
 static Evas_Event_Flags __gesture_layer_flick_end_cb(void *data, void *event_info);
@@ -235,7 +233,7 @@ static callui_result_e __callui_view_incoming_call_noti_ondestroy(call_view_data
 
        DELETE_ECORE_IDLE_ENTERER(vd->transit_effect_idler);
        DELETE_ELM_TRANSIT_HARD(vd->transit);
-       DELETE_EVAS_OBJECT(vd->box);
+       DELETE_EVAS_OBJECT(vd->layout);
        DELETE_EVAS_OBJECT(vd->rm_scroller_stroke);
 
        _callui_window_set_size_type(ad->window, CALLUI_WIN_SIZE_FULLSCREEN);
@@ -253,7 +251,7 @@ static callui_result_e __callui_view_incoming_call_noti_ondestroy(call_view_data
 static void __reset_params_after_transit(callui_view_incoming_call_noti_h vd)
 {
        vd->transit = NULL;
-       evas_object_freeze_events_set(vd->box, EINA_FALSE);
+       evas_object_freeze_events_set(vd->layout, EINA_FALSE);
 }
 
 static void __appear_transit_del_cb(void *data, Elm_Transit *transit)
@@ -281,7 +279,7 @@ static Eina_Bool __appear_effect_activated_cb(void *data)
        callui_view_incoming_call_noti_h vd = data;
 
        int height = 0;
-       evas_object_geometry_get(vd->box, NULL, NULL, NULL, &height);
+       evas_object_geometry_get(vd->layout, NULL, NULL, NULL, &height);
 
        DELETE_ELM_TRANSIT_HARD(vd->transit);
        vd->transit = elm_transit_add();
@@ -291,14 +289,14 @@ static Eina_Bool __appear_effect_activated_cb(void *data)
                return ECORE_CALLBACK_CANCEL;
        }
        elm_transit_del_cb_set(vd->transit, __appear_transit_del_cb, vd);
-       elm_transit_object_add(vd->transit, vd->box);
+       elm_transit_object_add(vd->transit, vd->layout);
        elm_transit_effect_translation_add(vd->transit, 0, -height, 0, 0);
        elm_transit_duration_set(vd->transit, CALLUI_MOVE_TRANSITION_TIME_SEC);
        elm_transit_objects_final_state_keep_set(vd->transit, EINA_TRUE);
        elm_transit_go(vd->transit);
 
        vd->transit_effect_idler = NULL;
-       evas_object_freeze_events_set(vd->box, EINA_TRUE);
+       evas_object_freeze_events_set(vd->layout, EINA_TRUE);
 
        return ECORE_CALLBACK_DONE;
 }
@@ -313,7 +311,7 @@ static Eina_Bool __disappear_effect_activated_cb(void *data)
        int ypos = 0;
        int width = 0;
        int height = 0;
-       evas_object_geometry_get(vd->box, &xpos, &ypos, &width, &height);
+       evas_object_geometry_get(vd->layout, &xpos, &ypos, &width, &height);
        int transit_y = -(height + ypos);
 
        DELETE_ELM_TRANSIT_HARD(vd->transit);
@@ -324,14 +322,14 @@ static Eina_Bool __disappear_effect_activated_cb(void *data)
                return ECORE_CALLBACK_CANCEL;
        }
        elm_transit_del_cb_set(vd->transit, __disappear_transit_del_cb, vd);
-       elm_transit_object_add(vd->transit, vd->box);
+       elm_transit_object_add(vd->transit, vd->layout);
        elm_transit_effect_translation_add(vd->transit, xpos, ypos, xpos, transit_y);
        elm_transit_duration_set(vd->transit, CALLUI_MOVE_TRANSITION_TIME_SEC);
        elm_transit_objects_final_state_keep_set(vd->transit, EINA_TRUE);
        elm_transit_go(vd->transit);
 
        vd->transit_effect_idler = NULL;
-       evas_object_freeze_events_set(vd->box, EINA_TRUE);
+       evas_object_freeze_events_set(vd->layout, EINA_TRUE);
 
        return ECORE_CALLBACK_CANCEL;
 }
@@ -374,7 +372,6 @@ static void __show_reject_msg_btn_click_cb(void *data, Evas_Object *obj, void *e
                        dbg("No hide animation in progress...");
                        __rm_reset_status_flags(vd);
                        _callui_window_set_size_type(ad->window, CALLUI_WIN_SIZE_FULLSCREEN);
-                       elm_object_signal_emit(vd->layout, "hide_swipe", "active_noti_main");
                        __rm_create_content(vd);
                        __move_active_noti(vd);
                }
@@ -390,15 +387,25 @@ static void __rm_get_scroller_cur_size(callui_view_incoming_call_noti_h vd, int
        dbg("RM scroller size - w[%d] h[%d]", *w, *h);
 }
 
-static void __box_changed_hints_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+static void __layout_changed_hints_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
 {
        CALLUI_RETURN_IF_FAIL(data);
        callui_view_incoming_call_noti_h vd = data;
 
-       if (vd->appear_anim_init) {
+       Evas_Coord w = 0;
+       Evas_Coord h = 0;
+       evas_object_size_hint_min_get(vd->layout, &w, &h);
+       dbg("LY hint min size - w[%d] h[%d]", w, h);
+
+       if (w == 0 || h == 0) {
+               dbg("Ignored");
                return;
        }
 
+       if (vd->appear_anim_init) {
+               dbg("Appear animation already initiated");
+               return;
+       }
        vd->appear_anim_init = true;
        vd->transit_effect_idler = ecore_idle_enterer_before_add(__appear_effect_activated_cb, vd);
 }
@@ -407,7 +414,6 @@ static void __rm_close_cb(callui_view_incoming_call_noti_h vd)
 {
        __rm_destroy_content(vd);
 
-       elm_object_signal_emit(vd->layout, "show_swipe", "active_noti_main");
        _callui_window_set_size_type(vd->base_view.ad->window, CALLUI_WIN_SIZE_ACTIVE_NOTI);
        __move_active_noti(vd);
 }
@@ -611,7 +617,7 @@ static callui_result_e __rm_create_message_items(callui_view_incoming_call_noti_
 
 static callui_result_e __rm_create_compose_item(callui_view_incoming_call_noti_h vd, Evas_Object *box)
 {
-       Evas_Object *item_ly = _callui_create_layout(vd->box, CALLUI_LY_STYLE_REJ_MSG_ITEM_COMPOSE);
+       Evas_Object *item_ly = _callui_create_layout(vd->layout, CALLUI_LY_STYLE_REJ_MSG_ITEM_COMPOSE);
        CALLUI_RETURN_VALUE_IF_FAIL(item_ly, CALLUI_RESULT_FAIL);
 
        evas_object_size_hint_weight_set(item_ly, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
@@ -669,14 +675,14 @@ static void __rm_strock_move_cb(void *data, Evas *e, Evas_Object *obj, void *eve
 static void __rm_create_content(callui_view_incoming_call_noti_h vd)
 {
        /* Reject message list background gradient color layout */
-       vd->rm_scroller_bg = _callui_create_layout(vd->box, CALLUI_LY_STYLE_REJ_MSG_SCROLLER_BG);
+       vd->rm_scroller_bg = _callui_create_layout(vd->layout, CALLUI_LY_STYLE_REJ_MSG_SCROLLER_BG);
        evas_object_event_callback_add(vd->rm_scroller_bg, EVAS_CALLBACK_RESIZE, __rm_scroller_bg_resize_cb, vd);
        evas_object_event_callback_add(vd->rm_scroller_bg, EVAS_CALLBACK_MOVE, __rm_scroller_bg_move_cb, vd);
        CALLUI_RETURN_IF_FAIL(vd->rm_scroller_bg);
        evas_object_show(vd->rm_scroller_bg);
 
        /* Reject message scroller */
-       vd->rm_scroller = elm_scroller_add(vd->box);
+       vd->rm_scroller = elm_scroller_add(vd->layout);
        if (!vd->rm_scroller) {
                err("rm_scroller is NULL");
                return __rm_destroy_content(vd);
@@ -808,21 +814,14 @@ static callui_result_e __create_main_content(callui_view_incoming_call_noti_h vd
        elm_object_part_content_set(parent, "elm.swallow.content", vd->base_view.contents);
        evas_object_show(vd->base_view.contents);
 
-       vd->box = elm_box_add(vd->base_view.contents);
-       CALLUI_RETURN_VALUE_IF_FAIL(vd->box, CALLUI_RESULT_ALLOCATION_FAIL);
-       evas_object_event_callback_add(vd->box, EVAS_CALLBACK_CHANGED_SIZE_HINTS, __box_changed_hints_cb, vd);
-       elm_box_horizontal_set(vd->box, EINA_FALSE);
-       evas_object_show(vd->box);
-
-       vd->layout = _callui_create_layout(vd->box, CALLUI_LY_STYLE_ACTIVE_NOTI_CALL_MAIN);
+       vd->layout = elm_layout_add(parent);
        CALLUI_RETURN_VALUE_IF_FAIL(vd->layout, CALLUI_RESULT_ALLOCATION_FAIL);
+       evas_object_event_callback_add(vd->layout, EVAS_CALLBACK_CHANGED_SIZE_HINTS, __layout_changed_hints_cb, vd);
+       elm_layout_theme_set(vd->layout, "layout", "callui", CALLUI_LY_STYLE_ACTIVE_NOTI_CALL_MAIN);
        evas_object_size_hint_weight_set(vd->layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
        evas_object_size_hint_align_set(vd->layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
-
-       elm_object_signal_callback_add(vd->layout, "contact_info.clicked",
-                       "active_noti_main", __contact_info_click_cb, vd);
-
-       elm_box_pack_end(vd->box, vd->layout);
+       elm_object_signal_callback_add(vd->layout, "contact_info.clicked", "active_noti_main", __contact_info_click_cb, vd);
+       elm_object_part_content_set(parent, "elm.swallow.active_noti", vd->layout);
 
        Evas_Object *answer_btn = __create_btn(vd,
                        CALLUI_BTN_STYLE_AN_ACCEPT_CALL,
@@ -884,8 +883,6 @@ static callui_result_e __update_displayed_data(callui_view_incoming_call_noti_h
        const callui_call_data_t *call_data = _callui_stp_get_call_data(ad->state_provider, CALLUI_CALL_DATA_INCOMING);
        CALLUI_RETURN_VALUE_IF_FAIL(call_data, CALLUI_RESULT_FAIL);
 
-       elm_object_signal_emit(vd->layout, "small_main_ly", "active_noti_main");
-
        const char *call_name = call_data->call_ct_info.call_disp_name;
        const char *call_number = NULL;
        if (call_data->call_disp_num[0] != '\0') {
@@ -1075,11 +1072,14 @@ static void __move_active_noti(callui_view_incoming_call_noti_h vd)
        callui_app_data_t *ad = vd->base_view.ad;
        int rotation = _callui_window_get_rotation(ad->window);
        int new_x = 0;
-       if (vd->rm_scroller) {
-               if (rotation == 90 || rotation == 270)
+       if (vd->rm_scroller && (rotation == 90 || rotation == 270)) {
+               if (_callui_common_is_mirrored_mode_on()) {
+                       new_x = ACTIVE_NOTI_LANDSCAPE_L_PAD;
+               } else {
                        new_x = (ad->root_h - ad->root_w - ACTIVE_NOTI_LANDSCAPE_L_PAD);
+               }
        }
-       evas_object_move(vd->box, new_x, 0);
+       evas_object_move(vd->layout, new_x, 0);
 }
 
 static void __parent_resize_cb(void *data, Evas *evas, Evas_Object *obj, void *event_info)
index ffae9df..89086e9 100755 (executable)
@@ -86,6 +86,9 @@ static callui_result_e __create_main_content(callui_view_mc_conf_h vd, Evas_Obje
        CALLUI_RETURN_VALUE_IF_FAIL(manage_calls_ly, CALLUI_RESULT_ALLOCATION_FAIL);
        elm_object_part_content_set(vd->caller_info, "manage_calls_btn", manage_calls_ly);
        edje_object_signal_callback_add(_EDJ(manage_calls_ly), "mouse,clicked,1", "btn", __manage_calls_btn_clicked_cb, vd);
+       if (_callui_common_is_mirrored_mode_on()) {
+               elm_object_signal_emit(manage_calls_ly, "set_rtl_mode", "manage_calls");
+       }
 
        _callui_action_bar_show(ad->action_bar);
 
index 8c7692a..d144f8b 100755 (executable)
@@ -32,6 +32,9 @@
 #define CALLUI_BTN_STYLE_SPLIT_MERGE           "callui_multi_split_merge_btn"
 #define CALLUI_BTN_STYLE_SPLIT_SWAP                    "callui_multi_split_swap_btn"
 
+#define CALLUI_BTN_STYLE_SPLIT_MERGE           "callui_multi_split_merge_btn"
+#define CALLUI_BTN_STYLE_SPLIT_SWAP                    "callui_multi_split_swap_btn"
+
 #define CALLUI_PART_TEXT_MERGE_SWAP_BTN                "text"
 #define CALLUI_PART_TEXT_STATUS                                "text.status"
 #define CALLUI_PART_TEXT_MAIN                          "text.main"
@@ -282,7 +285,11 @@ static void __set_active_info(Evas_Object *parent, Evas_Object *content, callui_
 
        if (active) {
                if (active->conf_member_count > 1) {
-                       elm_object_signal_emit(content, "show_manage_calls_btn", "");
+                       if (_callui_common_is_mirrored_mode_on()) {
+                               elm_object_signal_emit(content, "show_manage_calls_btn_rtl", "");
+                       } else {
+                               elm_object_signal_emit(content, "show_manage_calls_btn_ltr", "");
+                       }
                        elm_object_signal_callback_add(content, "mouse,up,*", "arrow", __mng_callers_btn_click_cb, ad);
                } else {
                        elm_object_signal_emit(content, "hide_manage_calls_btn", "");
@@ -299,7 +306,7 @@ static callui_result_e __create_merge_swap_btns(Evas_Object *parent, callui_app_
        elm_object_part_content_set(parent, CALLUI_PART_SWALLOW_MERGE, merge);
 
        Evas_Object *swap = __create_merge_swap_btn(parent, CALLUI_BTN_STYLE_SPLIT_SWAP, "IDS_CALL_SK_MULTICALL_SWAP");
-       CALLUI_RETURN_VALUE_IF_FAIL(merge, CALLUI_RESULT_ALLOCATION_FAIL);
+       CALLUI_RETURN_VALUE_IF_FAIL(swap, CALLUI_RESULT_ALLOCATION_FAIL);
        evas_object_smart_callback_add(swap, "clicked", __swap_btn_click_cb, ad);
        elm_object_part_content_set(parent, CALLUI_PART_SWALLOW_SWAP, swap);
 
index 9023ef6..de6eafb 100644 (file)
@@ -113,17 +113,25 @@ static void __eo_win_move_and_resize(callui_window_h window_h, bool force_resize
        int move_x = 0;
        int move_y = 0;
 
-       if (window_h->size_type != CALLUI_WIN_SIZE_FULLSCREEN) {
+       if (window_h->size_type == CALLUI_WIN_SIZE_ACTIVE_NOTI) {
                switch (angle) {
                case 90:
-                       move_y = ACTIVE_NOTI_LANDSCAPE_L_PAD;
+                       if (_callui_common_is_mirrored_mode_on()) {
+                               move_y = ad->root_h - win_w - ACTIVE_NOTI_LANDSCAPE_L_PAD;
+                       } else {
+                               move_y = ACTIVE_NOTI_LANDSCAPE_L_PAD;
+                       }
                        break;
                case 180:
                        move_y = ad->root_h - win_h;
                        break;
                case 270:
                        move_x = ad->root_w - win_h;
-                       move_y = ad->root_h - win_w - ACTIVE_NOTI_LANDSCAPE_L_PAD;
+                       if (_callui_common_is_mirrored_mode_on()) {
+                               move_y = ACTIVE_NOTI_LANDSCAPE_L_PAD;
+                       } else {
+                               move_y = ad->root_h - win_w - ACTIVE_NOTI_LANDSCAPE_L_PAD;
+                       }
                        break;
                default:
                        break;
@@ -268,6 +276,18 @@ void _callui_window_set_size_type(callui_window_h window_h, callui_win_size_type
        __eo_win_update_size(window_h, size_type);
 }
 
+callui_result_e _callui_window_validate_position(callui_window_h window_h)
+{
+       CALLUI_RETURN_VALUE_IF_FAIL(window_h, CALLUI_RESULT_INVALID_PARAM);
+
+       int angle = elm_win_rotation_get(window_h->win);
+       if (window_h->size_type == CALLUI_WIN_SIZE_ACTIVE_NOTI && (angle == 90 || angle == 270)) {
+               dbg("Need window position validation as window is ACTIVE_NOTI and in landscape mode");
+               __eo_win_update_size(window_h, CALLUI_WIN_SIZE_ACTIVE_NOTI);
+       }
+       return CALLUI_RESULT_OK;
+}
+
 static callui_result_e __eo_win_set_rotation_locked(callui_window_h window_h, bool is_locked)
 {
        CALLUI_RETURN_VALUE_IF_FAIL(window_h->rotation_locked != is_locked,
index 0c8a5ce..5a0ece9 100755 (executable)
@@ -20,6 +20,7 @@
 #include <vconf-keys.h>
 #include <network/bluetooth.h>
 #include <system_settings.h>
+#include <utils_i18n_ulocale.h>
 
 #include "callui.h"
 #include "callui-debug.h"
@@ -81,6 +82,10 @@ static void __process_media_key_up(callui_app_data_t *ad);
 static void __init_signals_handling();
 static void __app_signal_handler(int signum, siginfo_t *info, void *context);
 
+static callui_result_e __check_sys_language_character_orientation_on_rtl(const char *lang, bool *is_rtl);
+static callui_result_e __update_app_language(callui_app_data_t *ad);
+static void __set_app_mirrored_mode(bool is_mirrored_mode);
+
 static void __set_main_power_key_grab(callui_app_data_t *ad)
 {
        callui_result_e res = CALLUI_RESULT_FAIL;
@@ -415,6 +420,8 @@ static bool __app_init(callui_app_data_t *ad)
 
        _callui_common_set_lock_state_changed_cb(ad);
 
+       __update_app_language(ad);
+
        return true;
 }
 
@@ -434,20 +441,73 @@ static bool __app_create(void *data)
        return res;
 }
 
-static void __app_lang_changed_cb(app_event_info_h event_info, void *user_data)
+static callui_result_e __check_sys_language_character_orientation_on_rtl(const char *lang, bool *is_rtl)
 {
-       char *language;
-       int r = system_settings_get_value_string(SYSTEM_SETTINGS_KEY_LOCALE_LANGUAGE, &language);
-       if (r == SYSTEM_SETTINGS_ERROR_NONE) {
-               dbg("language: %s", language);
-               elm_language_set(language);
-               free(language);
+       dbg("System local language [%s]", lang);
+
+       *is_rtl = false;
+       i18n_ulocale_layout_type_e layout = I18N_ULOCALE_LAYOUT_UNKNOWN;
+       int ret = i18n_ulocale_get_character_orientation(lang, &layout);
+       CALLUI_RETURN_VALUE_IF_FAIL(ret == I18N_ERROR_NONE, CALLUI_RESULT_FAIL);
+
+       switch (layout) {
+       case I18N_ULOCALE_LAYOUT_LTR:
+               dbg("Language is LTR");
+               break;
+       case I18N_ULOCALE_LAYOUT_RTL:
+               dbg("Language is RTL");
+               *is_rtl = true;
+               break;
+       default:
+               err("Unsupported character orientation type [%d]", layout);
+               return CALLUI_RESULT_FAIL;
        }
+       return CALLUI_RESULT_OK;
+}
+
+static callui_result_e __update_app_language(callui_app_data_t *ad)
+{
+       char *lang = NULL;
+       int ret = system_settings_get_value_string(SYSTEM_SETTINGS_KEY_LOCALE_LANGUAGE, &lang);
+       CALLUI_RETURN_VALUE_IF_FAIL(ret == SYSTEM_SETTINGS_ERROR_NONE, CALLUI_RESULT_FAIL);
+       dbg("System local language [%s]", lang);
+
+       elm_language_set(lang);
+
+       bool is_rtl = false;
+       ret = __check_sys_language_character_orientation_on_rtl(lang, &is_rtl);
+       free(lang);
+       CALLUI_RETURN_VALUE_IF_FAIL(ret == CALLUI_RESULT_OK, ret);
 
+       __set_app_mirrored_mode(is_rtl);
+
+       return CALLUI_RESULT_OK;
+}
+
+static void __set_app_mirrored_mode(bool is_mirrored_mode)
+{
+       elm_config_mirrored_set(is_mirrored_mode);
+}
+
+static void __app_lang_changed_cb(app_event_info_h event_info, void *user_data)
+{
        CALLUI_RETURN_IF_FAIL(user_data);
        callui_app_data_t *ad = user_data;
 
-       _callui_vm_update_language(ad->view_manager);
+       callui_result_e res = __update_app_language(ad);
+       if (res != CALLUI_RESULT_OK) {
+               err("Update application language failed. res[%d]", res);
+       }
+       res = _callui_window_validate_position(ad->window);
+       if (res != CALLUI_RESULT_OK)
+       {
+               err("Validate window position failed. res[%d]", res);
+       }
+       res = _callui_vm_update_language(ad->view_manager);
+       if (res != CALLUI_RESULT_OK)
+       {
+               err("Update language in view manager failed. res[%d]", res);
+       }
 }
 
 static void __app_deinit(callui_app_data_t *ad)
@@ -807,7 +867,7 @@ static void __process_home_key_up(callui_app_data_t *ad)
                }
 
                if (!_callui_dpm_is_need_enforce_change_password(ad->dpm)) {
-                       callui_idle_lock_type_t lock_type = _callui_common_get_idle_lock_type();
+                       callui_idle_lock_type_e lock_type = _callui_common_get_idle_lock_type();
                        if (lock_type == CALLUI_LOCK_TYPE_SECURITY_LOCK) {
                                _callui_common_unlock_swipe_lock();
                                _callui_window_set_above_lockscreen_state(ad->window, false);