Fix wrong parent issue when creating button in tutorial mode 67/171967/1
authorJihoon Kim <jihoon48.kim@samsung.com>
Thu, 8 Mar 2018 09:30:08 +0000 (18:30 +0900)
committerJihoon Kim <jihoon48.kim@samsung.com>
Thu, 8 Mar 2018 09:30:35 +0000 (18:30 +0900)
Change-Id: I15eeeda67f9c5506a972925296ef32f1418e59b8
Signed-off-by: Jihoon Kim <jihoon48.kim@samsung.com>
src/ise-tutorial-mode.cpp

index 007cdb7..93ec2b1 100644 (file)
@@ -163,6 +163,7 @@ static Eina_Bool tutorial_show_layout_cb(void *data)
             evas_object_image_file_set(rotate, IMG_POPUP_TUTORIAL_CCW, NULL);
         }
         evas_object_image_border_set(rotate, 0, 0, 0, 0);
+
         Evas_Load_Error err_rotate = evas_object_image_load_error_get(rotate);
         if (err_rotate != EVAS_LOAD_ERROR_NONE) {
             LOGD("Could not load image, error string is \"%s\"", evas_load_error_str(err_rotate));
@@ -173,6 +174,7 @@ static Eina_Bool tutorial_show_layout_cb(void *data)
             evas_object_layer_set(rotate, EVAS_LAYER_MAX);
             evas_object_show(rotate);
         }
+
         Evas_Object *context = edje_object_add(evas_object_evas_get(tutorial_window));
         evas_object_layer_set(context, EVAS_LAYER_MAX);
         edje_object_file_set(context, EDJ_FILE_PATH, "main");
@@ -183,7 +185,7 @@ static Eina_Bool tutorial_show_layout_cb(void *data)
             edje_object_part_text_set(context, "title", TUTORIAL_TITLE);
             edje_object_part_text_set(context, "context1", TUTORIAL_CONTEXT_1);
 
-            button = elm_button_add(evas_object_evas_get(tutorial_window));
+            button = elm_button_add(tutorial_window);
             elm_object_style_set(button, "focus");
             view_set_image(button, NULL, IMG_POPUP_BUTTON_CANCEL_NORMAL);
             evas_object_resize(button, BUTTON_WIDTH, BUTTON_HEIGHT);