//#define WIN_X 184 // Portrait mode X
//#define WIN_Y 1192 // Portrait mode Y
-#define WIN_X 464
-#define WIN_Y 632
+#define WIN_X 461
+#define WIN_Y 628
#define SR_WIN_X 0 /// Screen Reader mode window x
#define SR_WIN_Y 656 /// Screen reader mode window y
-#define WIN_W 352
-#define WIN_H 88
+#define WIN_W 358
+#define WIN_H 92
#define SR_WIN_W 1280 /// Screen Reader mode window width
-#define SR_WIN_H 64 /// Screen Reader mode window height
+#define SR_WIN_H 72 /// Screen Reader mode window height
-#define ROOT_GRID_W 352
-#define ROOT_GRID_H 80
+#define ROOT_GRID_W 358
+#define ROOT_GRID_H 92
#define SR_ROOT_GRID_W 1280
-#define SR_ROOT_GRID_H 64
+#define SR_ROOT_GRID_H 72
-#define BG_IMAGE_W 350
-#define BG_IMAGE_H 80
+#define BG_IMAGE_W 358
+#define BG_IMAGE_H 92
#define SR_BG_IMAGE_W 1280
-#define SR_BG_IMAGE_H 64
+#define SR_BG_IMAGE_H 72
#define POST_ANIM_WIN_W 120
#define POST_ANIM_WIN_H 8
#define SOFTKEY_BG_IMAGE "img/02_bg_softkey_active.png"
+#define SR_SOFTKEY_BG_IMAGE "img/softkey_screen_reader_bg.png"
typedef struct{
//Service data member
char *path = get_resource_path(SOFTKEY_BG_IMAGE);
LOG_D("Softkey bg bar image path: %s", (path ? path : "null"));
elm_image_file_set(bg_img, path, NULL);
- efl_gfx_image_scale_method_set(bg_img, EFL_GFX_IMAGE_SCALE_METHOD_FILL);
+ // we have to clip the source image because source image is size of 370X98
+ // and because of UX tool issue regarding the shadow image
+ // they can't make it same size of container
+ // source image will have lot of space at boundary..that will create problem
+ // in animationa and event area.
+ Evas_Object *evas_img = elm_image_object_get(bg_img);
+ evas_object_image_load_region_set(evas_img, 6, 6, BG_IMAGE_W, BG_IMAGE_H);
+ evas_object_resize(bg_img, BG_IMAGE_W, BG_IMAGE_H);
elm_grid_pack(parent_grid, bg_img, 0, 0, BG_IMAGE_W, BG_IMAGE_H);
+
//free resource path
free((void*)path);
+
return bg_img;
}
static Evas_Object*
create_background_rect(Evas_Object *parent_grid)
{
- /** Create Bg Rect for Screen Reader Mode
+ /** Create Bg image for Screen Reader Mode
* We create this rect at start because if create the rect at run time than,
* we need re-pack the root grid to keep the staking order correct.
* */
- Evas_Object *bg_rect = evas_object_rectangle_add(parent_grid);
- // Color value according to gui [#EEEFF1]
- evas_object_color_set(bg_rect, 238, 239, 241, 255);
- elm_grid_pack(parent_grid, bg_rect, 0, 0, SR_BG_IMAGE_W, SR_BG_IMAGE_H);
- return bg_rect;
+ Evas_Object *sr_bg_img = elm_image_add(parent_grid);
+ if(sr_bg_img == NULL)
+ {
+ LOG_E("Failed to create screen reader mode background image for softkey");
+ return NULL;
+ }
+ char *path = get_resource_path(SR_SOFTKEY_BG_IMAGE);
+ LOG_D("Softkey screen reader bg bar image path: %s", (path ? path : "null"));
+ elm_image_file_set(sr_bg_img, path, NULL);
+ // we have to clip the source image because source image is size of 1298X72
+ // and because of UX tool issue regarding the shadow image
+ // they can't make it same size of container
+ // source image will have lot of space at boundary..that will create problem
+ // in animationa and event area.
+ Evas_Object *evas_img = elm_image_object_get(sr_bg_img);
+ evas_object_image_load_region_set(evas_img, 9, 0, SR_BG_IMAGE_W, SR_BG_IMAGE_H);
+ evas_object_resize(sr_bg_img, SR_BG_IMAGE_W, SR_BG_IMAGE_H);
+ elm_grid_pack(parent_grid, sr_bg_img, 0, 0, SR_BG_IMAGE_W, SR_BG_IMAGE_H);
+
+ //free resource path
+ free((void*)path);
+
+ return sr_bg_img;
}
void softkey_window_geometry_update(Evas_Object *win, Eina_Bool post_animation)
/** TO DO need to define these value in common place */
-#define TRANSLATION_VALUE 80
+#define TRANSLATION_VALUE 84
#define TRANSLATION_DURATION 0.3
#define END_WIDTH 120
#define START_WIDTH 80
-#define CONTAINER_WIDTH 352 // this has to be same as window width.
+#define CONTAINER_WIDTH 358 // this has to be same as window width.
#define ACTIVATE_BAR_HEIGHT 8
#define ACTIVATE_BAR_START_Y 0
#define ACTIVATE_BAR_END_Y 80
int pos_y = 0;
if(softkey_container_current_visible_state_get() == SOFTKEY_STATE_VISIBLE_FULL){
width = START_WIDTH + ((END_WIDTH - START_WIDTH) * progress);
- pos_y = ACTIVATE_BAR_START_Y + ((ACTIVATE_BAR_END_Y - ACTIVATE_BAR_START_Y) * progress);
}
else {
width = END_WIDTH - ((END_WIDTH - START_WIDTH) * progress);
- pos_y = ACTIVATE_BAR_END_Y - ((ACTIVATE_BAR_END_Y - ACTIVATE_BAR_START_Y) * progress);
}
int pos_x = (CONTAINER_WIDTH/2) - (width/2);