#include <system_settings.h>
#include <system_info.h>
#include <telephony.h>
-//#include <ode/internal-encryption.h>
+#include <ode/internal-encryption.h>
#include "lock_mgr.h"
#include "package_mgr.h"
void lock_mgr_unlock(void)
{
int ret = 0;
- //int booting_completed = 0;
+ int booting_completed = 0;
int lock_type = status_active_get()->setappl_screen_lock_type_int;
_D("lock type(%d)", lock_type);
- // ret = vconf_get_int(VCONFKEY_STARTER_SEQUENCE, &booting_completed);
- // if (ret != 0) {
- // _E("Failed to get VCONFKEY STARTER SEQUENCE");
- // return;
- // }
-
- // if (!booting_completed) {
- // ret = starter_execute_ode_process(AFTER_LOCKSCREEN);
- // if (!ret) {
- // _E("Failed to execute ode process");
- // return;
- // }
- // }
+ ret = vconf_get_int(VCONFKEY_STARTER_SEQUENCE, &booting_completed);
+ if (ret != 0) {
+ _E("Failed to get VCONFKEY STARTER SEQUENCE");
+ return;
+ }
+
+ if (!booting_completed) {
+ ret = starter_execute_ode_process(AFTER_LOCKSCREEN);
+ if (!ret) {
+ _E("Failed to execute ode process");
+ return;
+ }
+ }
lock_mgr_idle_lock_state_set(VCONFKEY_IDLE_UNLOCK);
lock_mgr_sound_play(LOCK_SOUND_UNLOCK);
#include <E_DBus.h>
#include <systemd/sd-daemon.h>
-//#include <ode/internal-encryption.h>
+#include <ode/internal-encryption.h>
#include <aul.h>
#include <vconf.h>
*/
_set_starter_sequence(0);
- // ret = starter_execute_ode_process(BEFORE_LOCKSCREEN);
- // if (!ret) {
- // _E("Failed to execute ode process");
- // }
+ ret = starter_execute_ode_process(BEFORE_LOCKSCREEN);
+ if (!ret) {
+ _E("Failed to execute ode process");
+ }
aul_listen_app_dead_signal(_check_dead_signal, NULL);
}
-// int starter_execute_ode_process(int booting_state)
-// {
- // _D("This call is before or after Lockscreen: %d", booting_state);
- // int ret = ODE_ERROR_NONE;
- // int ode_state = 0;
-
- // ret = ode_internal_encryption_get_state(&ode_state);
- // if (ret != ODE_ERROR_NONE) {
- // _E("Failed to get ODE state, ret: %d", ret);
- // return 0;
- // }
-
- // if (booting_state == BEFORE_LOCKSCREEN) {
- // if (ode_state == ODE_STATE_ENCRYPTED) {
- // lock_mgr_init();
-
- // ret = ode_internal_encryption_set_mount_event_cb(_mount_complete_cb, NULL);
- // if (ret != ODE_ERROR_NONE) {
- // _E("Failed to set mount event cb");
- // }
- // } else {
- // _launch_apps();
- // }
- // } else if (booting_state == AFTER_LOCKSCREEN) {
- // if (ode_state == ODE_STATE_ENCRYPTED) {
- // _D("ODE state is: %d, and we should mount at this time", ode_state);
-
- // ret = ode_internal_encryption_mount();
- // if (ret != ODE_ERROR_NONE) {
- // _E("Failed to mount");
- // return 0;
- // }
-
- // sd_notify(0, "READY=1");
- // home_mgr_init(NULL);
-
- // vconf_set_int(VCONFKEY_STARTER_SEQUENCE, 1);
- // } else {
- // _D("ODE state is: %d, Do nothing", ode_state);
- // }
- // }
-
- // return 1;
-// }
+int starter_execute_ode_process(int booting_state)
+{
+ _D("This call is before or after Lockscreen: %d", booting_state);
+ int ret = ODE_ERROR_NONE;
+ int ode_state = 0;
+
+ ret = ode_internal_encryption_get_state(&ode_state);
+ if (ret != ODE_ERROR_NONE) {
+ _E("Failed to get ODE state, ret: %d", ret);
+ return 0;
+ }
+
+ if (booting_state == BEFORE_LOCKSCREEN) {
+ if (ode_state == ODE_STATE_ENCRYPTED) {
+ lock_mgr_init();
+
+ ret = ode_internal_encryption_set_mount_event_cb(_mount_complete_cb, NULL);
+ if (ret != ODE_ERROR_NONE) {
+ _E("Failed to set mount event cb");
+ }
+ } else {
+ _launch_apps();
+ }
+ } else if (booting_state == AFTER_LOCKSCREEN) {
+ if (ode_state == ODE_STATE_ENCRYPTED) {
+ _D("ODE state is: %d, and we should mount at this time", ode_state);
+
+ ret = ode_internal_encryption_mount();
+ if (ret != ODE_ERROR_NONE) {
+ _E("Failed to mount");
+ return 0;
+ }
+
+ sd_notify(0, "READY=1");
+ home_mgr_init(NULL);
+
+ vconf_set_int(VCONFKEY_STARTER_SEQUENCE, 1);
+ } else {
+ _D("ODE state is: %d, Do nothing", ode_state);
+ }
+ }
+
+ return 1;
+}