fixed plugin image size problem
[framework/uifw/elementary.git] / src / bin / test_weather.c
index 873a1a7..062a9a0 100644 (file)
@@ -1,7 +1,7 @@
-#include <Elementary.h>
 #ifdef HAVE_CONFIG_H
 # include "elementary_config.h"
 #endif
+#include <Elementary.h>
 #ifndef ELM_LIB_QUICKLAUNCH
 
 #ifdef HAVE_ELEMENTARY_EWEATHER
@@ -55,7 +55,7 @@ _hover_select_cb(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event
 void
 test_weather(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
 {
-   Evas_Object *win, *bg;
+   Evas_Object *win;
 #ifdef HAVE_ELEMENTARY_EWEATHER
    Evas_Object *bx, *bx0, *bt;
    EWeather *eweather;
@@ -65,15 +65,9 @@ test_weather(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_inf
    unsigned int i;
 #endif
 
-   win = elm_win_add(NULL, "weather", ELM_WIN_BASIC);
-   elm_win_title_set(win, "Weather");
+   win = elm_win_util_standard_add("weather", "Weather");
    elm_win_autodel_set(win, EINA_TRUE);
 
-   bg = elm_bg_add(win);
-   evas_object_size_hint_weight_set(bg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
-   elm_win_resize_object_add(win, bg);
-   evas_object_show(bg);
-
 #ifdef HAVE_ELEMENTARY_EWEATHER
    bx = elm_box_add(win);
    elm_win_resize_object_add(win, bx);
@@ -91,7 +85,7 @@ test_weather(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_inf
    weather[0] = eweather_object_add(evas_object_evas_get(win));
    evas_object_size_hint_weight_set(weather[0], EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
    evas_object_size_hint_align_set(weather[0], -1.0, -1.0);
-   elm_flip_content_front_set(fl, weather[0]);
+   elm_object_part_content_set(fl, "front", weather[0]);
    evas_object_show(weather[0]);
 
    module[1] = NULL;
@@ -99,7 +93,7 @@ test_weather(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_inf
    eweather = eweather_object_eweather_get(weather[1]);
    evas_object_size_hint_weight_set(weather[1], EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
    evas_object_size_hint_align_set(weather[1], -1.0, -1.0);
-   elm_flip_content_back_set(fl, weather[1]);
+   elm_object_part_content_set(fl, "back", weather[1]);
    evas_object_show(weather[1]);
 
    evas_object_show(fl);