summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsunyeop.hwnag <sunyeop.hwang@samsung.com>2012-08-24 09:42:24 (GMT)
committersunyeop.hwnag <sunyeop.hwang@samsung.com>2012-08-24 09:42:24 (GMT)
commit4cafc061a707d661b6caaa19cb4ee91f6de6d020 (patch)
treeb72e927262db1a90367cb73df58811a190197da3
parente7b4fa62d8c8860adc70625f70190f77becc8c91 (diff)
downloadpwlock-4cafc061a707d661b6caaa19cb4ee91f6de6d020.zip
pwlock-4cafc061a707d661b6caaa19cb4ee91f6de6d020.tar.gz
pwlock-4cafc061a707d661b6caaa19cb4ee91f6de6d020.tar.bz2
Change sequence ug_destroy and ug_create
Change-Id: I20f997f4947f5987e06eac53f226dd1b528755c9
-rwxr-xr-xsrc/ui.c26
1 files changed, 19 insertions, 7 deletions
diff --git a/src/ui.c b/src/ui.c
index 7b2c246..11f2c17 100755
--- a/src/ui.c
+++ b/src/ui.c
@@ -628,6 +628,12 @@ static void _destroy_previous_ugs(void *data)
ad->language_ug = NULL;
}
break;
+ case _UI_CONNECTION:
+ if (ad->date_ug) {
+ ug_destroy(ad->date_ug);
+ ad->date_ug = NULL;
+ }
+ break;
default:
if (ad->date_ug) {
ug_destroy(ad->date_ug);
@@ -646,12 +652,13 @@ static void _destroy_previous_ugs(void *data)
_DBG("%s,%d", __func__, __LINE__);
- /* when last UG or SIM changed with fisrt UG, destroy the view */
+ /* when last UG or SIM changed with fisrt UG, destroy the view
if (((ad->sim_changed == 1) && (ad->ui_type == _UI_LANG))
|| (ad->ui_type == _UI_TIME)) {
_DBG("%s,%d", __func__, __LINE__);
pwlock_destroy(ad);
}
+ */
}
static Evas_Object *_create_conformant(Evas_Object * parent)
@@ -1236,9 +1243,9 @@ static void _ug_destroy_cb(ui_gadget_h ug, void *priv)
ad->kill_ug = 0;
return;
} else {
- ad->state = _ST_CONNECTION;
+ do_state_directly(_ST_CONNECTION, ad);
+ return;
}
- do_state(ad);
}
break;
default:
@@ -1282,6 +1289,7 @@ static void _ug_destroy_cb(ui_gadget_h ug, void *priv)
}
}
} else {
+ _DBG("destroy ug in _ug_destroy_cb \n");
ug_destroy(ug);
ug = NULL;
}
@@ -1554,10 +1562,12 @@ int show_connection(struct appdata *ad) {
ad->state = _ST_TIME;
else
ad->state = _ST_FINISH;
+ do_state(ad);
return 0;
}
ad->current_ug = ad->connection_ug;
evas_object_show(ad->win);
+ _destroy_previous_ugs(ad);
return 1;
}
@@ -1633,6 +1643,7 @@ int show_lang(struct appdata *ad)
if (!ad->language_ug) {
_DBG("Get phone ug failed.");
ad->state = _ST_GREETING;
+ do_state(ad);
return 0;
}
ad->current_ug = ad->language_ug;
@@ -1666,10 +1677,10 @@ int show_nosim(struct appdata *ad)
elm_toolbar_shrink_mode_set(controlbar, ELM_TOOLBAR_SHRINK_EXPAND);
- elm_toolbar_item_append(controlbar, NULL, NULL, NULL, NULL);
- elm_toolbar_item_append(controlbar, NULL, NULL, NULL, NULL);
- elm_toolbar_item_append(controlbar, NULL, NULL, NULL, NULL);
- elm_toolbar_item_append(controlbar, NULL, NULL, NULL, NULL);
+ elm_object_item_disabled_set(elm_toolbar_item_append(controlbar, NULL, NULL, NULL, NULL), EINA_TRUE);
+ elm_object_item_disabled_set(elm_toolbar_item_append(controlbar, NULL, NULL, NULL, NULL), EINA_TRUE);
+ elm_object_item_disabled_set(elm_toolbar_item_append(controlbar, NULL, NULL, NULL, NULL), EINA_TRUE);
+ elm_object_item_disabled_set(elm_toolbar_item_append(controlbar, NULL, NULL, NULL, NULL), EINA_TRUE);
elm_toolbar_item_append(controlbar, IMAGEDIR"/A01-9_controlbar_icon_Skip.png",
pwlock_get_string(IDS_IDLE_SK_SKIP),
@@ -1727,6 +1738,7 @@ int show_time(struct appdata *ad)
ad->state = _ST_GREETING;
else
ad->state = _ST_CONNECTION;
+ do_state(ad);
return 0;
}
ad->current_ug = ad->date_ug;