summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjk7744.park <jk7744.park@samsung.com>2015-10-24 06:44:18 (GMT)
committerjk7744.park <jk7744.park@samsung.com>2015-10-24 06:44:18 (GMT)
commit730191fd414d47760dbc95ad049cab29d42e3b2b (patch)
tree58827332b01aba4d5b77d58266ab8160e8c6cfe4
parent5cea387de7e517476d31b915642c232347ca7a3d (diff)
downloadstarter-accepted/tizen_2.4_mobile.zip
starter-accepted/tizen_2.4_mobile.tar.gz
starter-accepted/tizen_2.4_mobile.tar.bz2
-rw-r--r--[-rwxr-xr-x]CMakeLists.txt98
-rw-r--r--[-rwxr-xr-x]LICENSE0
-rw-r--r--[-rwxr-xr-x]NOTICE0
-rwxr-xr-xinclude/dbus-util_w.h34
-rw-r--r--include/dbus_util.h51
-rwxr-xr-xinclude/direct-access.h33
-rwxr-xr-xinclude/lock-daemon-lite.h25
-rwxr-xr-xinclude/lock-daemon.h25
-rwxr-xr-xinclude/lockd-debug.h85
-rwxr-xr-xinclude/lockd-process-mgr.h52
-rwxr-xr-xinclude/lockd-window-mgr.h52
-rwxr-xr-xinclude/menu_daemon.h48
-rw-r--r--include/mobile/home_mgr.h31
-rw-r--r--include/mobile/hw_key.h39
-rw-r--r--include/mobile/lock_mgr.h62
-rw-r--r--include/mobile/popup.h25
-rw-r--r--include/mobile/starter.h (renamed from include/starter.h)1
-rw-r--r--include/package_mgr.h22
-rw-r--r--include/pkg_event.h44
-rw-r--r--include/process_mgr.h38
-rwxr-xr-xinclude/starter-util.h34
-rwxr-xr-xinclude/starter-vconf.h23
-rwxr-xr-xinclude/starter_w.h62
-rw-r--r--include/status.h87
-rw-r--r--[-rwxr-xr-x]include/util.h29
-rw-r--r--[-rwxr-xr-x]include/wearable/clock_mgr.h (renamed from include/hw_key_w.h)9
-rw-r--r--[-rwxr-xr-x]include/wearable/home_mgr.h (renamed from include/lockd-bt.h)17
-rw-r--r--[-rwxr-xr-x]include/wearable/hourly_alert.h (renamed from include/hourly_alert.h)4
-rw-r--r--[-rwxr-xr-x]include/wearable/hw_key.h (renamed from include/hw_key.h)4
-rw-r--r--include/window_mgr.h37
-rw-r--r--include/x11.h24
-rw-r--r--[-rwxr-xr-x]lock_pwd/include/lock_pwd_complex.h (renamed from include/dbus-util.h)21
-rw-r--r--[-rwxr-xr-x]lock_pwd/include/lock_pwd_control_panel.h (renamed from include/clock-mgr.h)13
-rwxr-xr-xlock_pwd/include/lock_pwd_simple.h30
-rw-r--r--lock_pwd/include/lock_pwd_util.h38
-rwxr-xr-xlock_pwd/include/lock_pwd_verification.h56
-rwxr-xr-xlock_pwd/res/CMakeLists.txt1
-rwxr-xr-xlock_pwd/res/edje/CMakeLists.txt23
-rw-r--r--lock_pwd/res/edje/images/enter_pin_dot.pngbin0 -> 1023 bytes
-rw-r--r--lock_pwd/res/edje/images/event_close_bg.#.pngbin0 -> 3254 bytes
-rw-r--r--lock_pwd/res/edje/images/ls_back_02_nor.pngbin0 -> 3336 bytes
-rw-r--r--lock_pwd/res/edje/images/ls_back_02_press.pngbin0 -> 3333 bytes
-rw-r--r--lock_pwd/res/edje/images/ls_icon_call.pngbin0 -> 1538 bytes
-rw-r--r--lock_pwd/res/edje/images/ls_password_underline.#.pngbin0 -> 998 bytes
-rw-r--r--lock_pwd/res/edje/images/ls_pin_dot.pngbin0 -> 1200 bytes
-rwxr-xr-xlock_pwd/res/edje/lock_btn.edc395
-rwxr-xr-xlock_pwd/res/edje/lock_entry.edc486
-rwxr-xr-xlock_pwd/res/edje/lock_pwd.edc120
-rwxr-xr-xlock_pwd/res/edje/lock_pwd_complex.edc168
-rw-r--r--lock_pwd/res/edje/lock_pwd_control_panel.edc329
-rwxr-xr-xlock_pwd/res/edje/lock_pwd_simple.edc452
-rw-r--r--lock_pwd/src/lock_pwd_complex.c397
-rw-r--r--lock_pwd/src/lock_pwd_control_panel.c263
-rwxr-xr-xlock_pwd/src/lock_pwd_simple.c450
-rw-r--r--lock_pwd/src/lock_pwd_util.c485
-rwxr-xr-xlock_pwd/src/lock_pwd_verification.c207
-rw-r--r--packaging/starter-pre.service7
-rw-r--r--[-rwxr-xr-x]packaging/starter.service10
-rw-r--r--[-rwxr-xr-x]packaging/starter.spec88
-rwxr-xr-xpackaging/wait-lock.service14
-rw-r--r--[-rwxr-xr-x]po/CMakeLists.txt12
-rw-r--r--po/ar.po57
-rw-r--r--po/az.po59
-rw-r--r--po/bg.po59
-rw-r--r--po/bn.po57
-rw-r--r--po/ca.po59
-rw-r--r--po/cs.po59
-rw-r--r--po/da.po59
-rw-r--r--po/de.po59
-rw-r--r--po/el_GR.po59
-rw-r--r--po/en.po59
-rw-r--r--po/en_PH.po57
-rw-r--r--po/en_US.po59
-rw-r--r--po/es_ES.po59
-rw-r--r--po/es_US.po59
-rw-r--r--po/et.po59
-rw-r--r--po/eu.po59
-rw-r--r--po/fa.po57
-rw-r--r--po/fi.po59
-rw-r--r--po/fr.po59
-rw-r--r--po/fr_CA.po59
-rw-r--r--po/ga.po57
-rw-r--r--po/gl.po59
-rw-r--r--po/gu.po57
-rw-r--r--po/he.po57
-rw-r--r--po/hi.po57
-rw-r--r--po/hr.po59
-rw-r--r--po/hu.po59
-rw-r--r--po/hy.po59
-rw-r--r--po/is.po59
-rw-r--r--po/it_IT.po59
-rw-r--r--po/ja_JP.po57
-rw-r--r--po/ka.po59
-rw-r--r--po/kk.po59
-rw-r--r--po/kn.po57
-rw-r--r--po/ko_KR.po59
-rw-r--r--po/lt.po59
-rw-r--r--po/lv.po59
-rw-r--r--po/mk.po57
-rw-r--r--po/ml.po57
-rw-r--r--po/mn_MN.po59
-rw-r--r--po/nb.po59
-rw-r--r--po/nl.po59
-rw-r--r--po/pl.po59
-rw-r--r--po/pt_BR.po59
-rw-r--r--po/pt_PT.po59
-rw-r--r--po/ro.po59
-rw-r--r--po/ru_RU.po59
-rw-r--r--po/si.po57
-rw-r--r--po/sk.po59
-rw-r--r--po/sl.po59
-rw-r--r--po/sr.po59
-rw-r--r--po/sv.po59
-rw-r--r--po/ta.po57
-rw-r--r--po/te.po57
-rw-r--r--po/th.po57
-rw-r--r--po/tr_TR.po59
-rw-r--r--po/uk.po59
-rw-r--r--po/ur.po57
-rw-r--r--po/uz.po59
-rw-r--r--po/zh_CN.po57
-rw-r--r--po/zh_HK.po57
-rw-r--r--po/zh_TW.po57
-rw-r--r--[-rwxr-xr-x]rd3starter15
-rw-r--r--rd4starter11
-rwxr-xr-xsrc/clock-mgr.c807
-rwxr-xr-xsrc/dbus-util.c225
-rwxr-xr-xsrc/dbus-util_w.c745
-rw-r--r--src/dbus_util.c395
-rwxr-xr-xsrc/direct-access.c476
-rwxr-xr-xsrc/hw_key.c1600
-rwxr-xr-xsrc/hw_key_w.c1480
-rwxr-xr-xsrc/lock-daemon-lite.c2185
-rwxr-xr-xsrc/lock-daemon.c2125
-rwxr-xr-xsrc/lockd-bt.c227
-rwxr-xr-xsrc/lockd-debug.c98
-rwxr-xr-xsrc/lockd-process-mgr.c414
-rwxr-xr-xsrc/lockd-window-mgr.c807
-rwxr-xr-xsrc/menu_daemon.c813
-rw-r--r--src/mobile/home_mgr.c418
-rw-r--r--src/mobile/hw_key.c489
-rw-r--r--src/mobile/lock_mgr.c622
-rw-r--r--src/mobile/popup.c125
-rw-r--r--src/mobile/starter.c280
-rw-r--r--src/mobile/window_mgr.c451
-rw-r--r--src/package_mgr.c42
-rwxr-xr-xsrc/pkg_event.c310
-rw-r--r--src/process_mgr.c434
-rwxr-xr-xsrc/starter.c594
-rwxr-xr-xsrc/starter_w.c668
-rw-r--r--src/status.c567
-rw-r--r--src/wearable/clock_mgr.c161
-rw-r--r--src/wearable/home_mgr.c118
-rw-r--r--[-rwxr-xr-x]src/wearable/hourly_alert.c (renamed from src/hourly_alert.c)158
-rw-r--r--src/wearable/hw_key.c380
-rw-r--r--src/wearable/starter.c191
-rwxr-xr-xsrc/x11.c109
-rwxr-xr-xstarter.desktop.in9
-rw-r--r--starter.efl50
-rw-r--r--[-rwxr-xr-x]starter.manifest6
-rwxr-xr-xtest/get_entry.c92
-rwxr-xr-xtest/get_theme.c59
-rwxr-xr-xtest/set_theme.c65
163 files changed, 12721 insertions, 14878 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 141f44a..f89d8e1 100755..100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,22 +1,22 @@
CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
PROJECT(starter C)
-SET(VENDOR "samsung")
SET(PACKAGE ${PROJECT_NAME})
-SET(PKGNAME "com.${VENDOR}.${PACKAGE}")
+SET(PKGNAME "org.tizen.${PACKAGE}")
SET(PREFIX ${CMAKE_INSTALL_PREFIX})
SET(BINDIR "${PREFIX}/bin")
SET(DATADIR "${PREFIX}/share")
-SET(RESDIR "${PREFIX}/res")
SET(LOCALEDIR "${PREFIX}/share/locale")
+SET(LOCKPWDDIR "${PREFIX}/lock_pwd")
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
-
-IF("${STARTER_FEATURE_LITE}" STREQUAL "ENABLE")
-MESSAGE("######################################## LITE")
+IF("${TIZEN_PROFILE_NAME}" STREQUAL "MOBILE")
+INCLUDE_DIRECTORIES(
+ ${CMAKE_SOURCE_DIR}/include
+ ${CMAKE_SOURCE_DIR}/include/mobile
+ ${CMAKE_SOURCE_DIR}/lock_pwd/include
+)
INCLUDE(FindPkgConfig)
pkg_check_modules(pkgs REQUIRED
- ail
aul
capi-system-media-key
db-util
@@ -26,16 +26,12 @@ pkg_check_modules(pkgs REQUIRED
ecore-input
ecore-x
edbus
- eet
eina
elementary
evas
syspopup-caller
utilX
vconf
- x11
- xcomposite
- xext
appcore-efl
glib-2.0
ui-gadget-1
@@ -43,6 +39,8 @@ pkg_check_modules(pkgs REQUIRED
capi-appfw-application
capi-appfw-app-manager
capi-network-bluetooth
+ capi-system-system-settings
+ capi-ui-efl-util
feedback
alarm-service
pkgmgr-info
@@ -52,11 +50,17 @@ pkg_check_modules(pkgs REQUIRED
dbus-glib-1
tts
capi-message-port
+ security-server
+ efl-extension
+ callmgr_client
+)
+ELSE("${TIZEN_PROFILE_NAME}" STREQUAL "MOBILE")
+INCLUDE_DIRECTORIES(
+ ${CMAKE_SOURCE_DIR}/include
+ ${CMAKE_SOURCE_DIR}/include/wearable
)
-ELSE()
INCLUDE(FindPkgConfig)
pkg_check_modules(pkgs REQUIRED
- ail
aul
capi-system-media-key
db-util
@@ -66,16 +70,12 @@ pkg_check_modules(pkgs REQUIRED
ecore-input
ecore-x
edbus
- eet
eina
elementary
evas
syspopup-caller
utilX
vconf
- x11
- xcomposite
- xext
appcore-efl
glib-2.0
ui-gadget-1
@@ -91,8 +91,7 @@ pkg_check_modules(pkgs REQUIRED
dbus-1
dbus-glib-1
)
-ENDIF()
-
+ENDIF("${TIZEN_PROFILE_NAME}" STREQUAL "MOBILE")
FOREACH(flag ${pkgs_CFLAGS})
SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
@@ -117,38 +116,46 @@ IF("${ARCH}" STREQUAL "arm")
MESSAGE("add -DTARGET")
ENDIF("${ARCH}" STREQUAL "arm")
-ADD_DEFINITIONS("-DVENDOR=\"${VENDOR}\"")
ADD_DEFINITIONS("-DPACKAGE=\"${PACKAGE}\"")
ADD_DEFINITIONS("-DPACKAGE_NAME=\"${PKGNAME}\"")
ADD_DEFINITIONS("-DPREFIX=\"${PREFIX}\"")
ADD_DEFINITIONS("-DLOCALEDIR=\"${LOCALEDIR}\"")
ADD_DEFINITIONS("-D_GNU_SOURCE")
-IF("${STARTER_FEATURE_LITE}" STREQUAL "ENABLE")
-MESSAGE("######################################## LITE")
+IF("${TIZEN_PROFILE_NAME}" STREQUAL "MOBILE")
ADD_EXECUTABLE(${PROJECT_NAME}
- src/hw_key.c
- src/pkg_event.c
- src/menu_daemon.c
- src/starter.c
- src/x11.c
- src/lock-daemon-lite.c
- src/lockd-debug.c
- src/lockd-process-mgr.c
- src/lockd-window-mgr.c
- src/lockd-bt.c
- src/direct-access.c
- src/dbus-util.c
+ src/dbus_util.c
+ src/package_mgr.c
+ src/process_mgr.c
+ src/status.c
+
+ src/mobile/starter.c
+ src/mobile/popup.c
+ src/mobile/hw_key.c
+ src/mobile/home_mgr.c
+ src/mobile/lock_mgr.c
+ src/mobile/window_mgr.c
+
+ lock_pwd/src/lock_pwd_util.c
+ lock_pwd/src/lock_pwd_simple.c
+ lock_pwd/src/lock_pwd_complex.c
+ lock_pwd/src/lock_pwd_verification.c
+ lock_pwd/src/lock_pwd_control_panel.c
)
-ELSE()
+ELSE("${TIZEN_PROFILE_NAME}" STREQUAL "MOBILE")
ADD_EXECUTABLE(${PROJECT_NAME}
- src/starter_w.c
- src/hw_key_w.c
- src/hourly_alert.c
- src/dbus-util_w.c
- src/clock-mgr.c
+ src/dbus_util.c
+ src/package_mgr.c
+ src/process_mgr.c
+ src/status.c
+
+ src/wearable/clock_mgr.c
+ src/wearable/home_mgr.c
+ src/wearable/hourly_alert.c
+ src/wearable/hw_key.c
+ src/wearable/starter.c
)
-ENDIF()
+ENDIF("${TIZEN_PROFILE_NAME}" STREQUAL "MOBILE")
TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${pkgs_LDFLAGS})
INSTALL(TARGETS ${PROJECT_NAME} DESTINATION ${BINDIR})
INSTALL(DIRECTORY DESTINATION ${DATADIR})
@@ -161,4 +168,11 @@ INSTALL(FILES ${CMAKE_SOURCE_DIR}/rd3starter DESTINATION /etc/init.d
GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
#INSTALL to /etc/init.d
+INSTALL(FILES starter.efl DESTINATION /etc/smack/accesses.d)
+
ADD_SUBDIRECTORY(po)
+
+#FOR PASSWORD LOCKSCREEN
+IF("${TIZEN_PROFILE_NAME}" STREQUAL "MOBILE")
+ADD_SUBDIRECTORY(lock_pwd/res)
+ENDIF("${TIZEN_PROFILE_NAME}" STREQUAL "MOBILE")
diff --git a/LICENSE b/LICENSE
index a06208b..a06208b 100755..100644
--- a/LICENSE
+++ b/LICENSE
diff --git a/NOTICE b/NOTICE
index b2e5019..b2e5019 100755..100644
--- a/NOTICE
+++ b/NOTICE
diff --git a/include/dbus-util_w.h b/include/dbus-util_w.h
deleted file mode 100755
index 5a279c8..0000000
--- a/include/dbus-util_w.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __DBUS_H__
-#define __DBUS_H__
-
-#include <E_DBus.h>
-
-int request_Poweroff(void);
-int request_dbus_cpu_booster(void);
-int init_dbus_ALPM_signal(void *data);
-int init_dbus_COOL_DOWN_MODE_signal(void *data);
-int get_dbus_cool_down_mode(void *data);
-int init_dbus_NIKE_RUNNING_STATUS_signal(void *data);
-int init_dbus_ALPM_clock_state_signal(void *data);
-void starter_dbus_alpm_clock_signal_send(void *data);
-DBusConnection *starter_dbus_connection_get(void);
-
-
-#endif //__DBUS_H__
-
diff --git a/include/dbus_util.h b/include/dbus_util.h
new file mode 100644
index 0000000..c958416
--- /dev/null
+++ b/include/dbus_util.h
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __DBUS_UTIL_H__
+#define __DBUS_UTIL_H__
+
+#include <E_DBus.h>
+
+#define OOM_ADJ_VALUE_HOMESCREEN 0
+
+#ifdef TIZEN_PROFILE_MOBILE
+#define OOM_ADJ_VALUE_DEFAULT 200
+#else
+#define OOM_ADJ_VALUE_DEFAULT 0
+#endif
+
+#define DEVICED_BUS_NAME "org.tizen.system.deviced"
+#define DEVICED_OBJECT_PATH "/Org/Tizen/System/DeviceD"
+#define DEVICED_INTERFACE_NAME DEVICED_BUS_NAME
+#define DEVICED_PATH DEVICED_OBJECT_PATH"/Process"
+#define DEVICED_INTERFACE DEVICED_INTERFACE_NAME".Process"
+#define DEVICED_SET_METHOD "oomadj_set"
+
+#define DISPLAY_OBJECT_PATH DEVICED_OBJECT_PATH"/Display"
+#define DEVICED_INTERFACE_DISPLAY DEVICED_INTERFACE_NAME".display"
+#define MEMBER_LCD_ON "LCDOn"
+#define MEMBER_LCD_OFF "LCDOff"
+
+extern void dbus_util_send_home_raise_signal(void);
+extern int dbus_util_send_oomadj(int pid, int oom_adj_value);
+extern void dbus_util_send_cpu_booster_signal(void);
+extern void dbus_util_send_poweroff_signal(void);
+extern void dbus_util_send_lock_PmQos_signal(void);
+
+extern int dbus_util_receive_lcd_status(void (*changed_cb)(void *data, DBusMessage *msg), void *data);
+extern char *dbus_util_msg_arg_get_str(DBusMessage *msg);
+
+#endif //__DBUS_UTIL_H__
diff --git a/include/direct-access.h b/include/direct-access.h
deleted file mode 100755
index a4f4067..0000000
--- a/include/direct-access.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __DIRECT_ACCESS_H__
-#define __DIRECT_ACCESS_H__
-
-#include <E_DBus.h>
-
-DBusMessage *invoke_dbus_method_sync(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[]);
-
-DBusMessage *invoke_dbus_method(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[]);
-
-int launch_direct_access(int access_val);
-
-#endif //__DIRECT_ACCESS_H__
-
diff --git a/include/lock-daemon-lite.h b/include/lock-daemon-lite.h
deleted file mode 100755
index d1367a3..0000000
--- a/include/lock-daemon-lite.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __LOCK_DAEMON_LITE_H__
-#define __LOCK_DAEMON_LITE_H__
-
-int start_lock_daemon_lite(int launch_lock, int is_first_boot);
-int lockd_get_lock_type(void);
-int lockd_get_hall_status(void);
-int lockd_get_lock_state(void);
-
-#endif /* __LOCK_DAEMON_LITE_H__ */
diff --git a/include/lock-daemon.h b/include/lock-daemon.h
deleted file mode 100755
index d43f3e6..0000000
--- a/include/lock-daemon.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __LOCK_DAEMON_H__
-#define __LOCK_DAEMON_H__
-
-int start_lock_daemon(int launch_lock, int is_first_boot);
-int lockd_get_lock_type(void);
-int lockd_get_hall_status(void);
-int lockd_get_lock_state(void);
-
-#endif /* __LOCK_DAEMON_H__ */
diff --git a/include/lockd-debug.h b/include/lockd-debug.h
deleted file mode 100755
index 4c24a23..0000000
--- a/include/lockd-debug.h
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __LOCKD_DEBUG_H__
-#define __LOCKD_DEBUG_H__
-
-#include <stdio.h>
-#include <dlog.h>
-
-#ifdef LOG_TAG
-#undef LOG_TAG
-#endif
-
-#define LOG_TAG "STARTER"
-
-#define ENABLE_LOG_SYSTEM
-
-#ifdef ENABLE_LOG_SYSTEM
-#define STARTER_ERR(fmt, arg...) LOGE("["LOG_TAG"%s:%d:E] "fmt, __FILE__, __LINE__, ##arg)
-#define STARTER_DBG(fmt, arg...) LOGD("["LOG_TAG"%s:%d:D] "fmt, __FILE__, __LINE__, ##arg)
-#define STARTER_WARN(fmt, arg...) LOGW("["LOG_TAG"%s:%d:W] "fmt, __FILE__, __LINE__, ##arg)
-#define STARTER_SECURE_ERR(fmt, arg...) SECURE_LOGE("["LOG_TAG"%s:%d:E] "fmt, __FILE__, __LINE__, ##arg)
-#define STARTER_SECURE_DBG(fmt, arg...) SECURE_LOGD("["LOG_TAG"%s:%d:D] "fmt, __FILE__, __LINE__, ##arg)
-#define STARTER_SECURE_WARN(fmt, arg...) SECURE_LOGW("["LOG_TAG"%s:%d:W] "fmt, __FILE__, __LINE__, ##arg)
-#else
-#define STARTER_ERR(fmt, arg...)
-#define STARTER_DBG(fmt, arg...)
-#define STARTER_WARN(fmt, arg...)
-#define STARTER_SECURE_ERR(fmt, arg...)
-#define STARTER_SECURE_DBG(fmt, arg...)
-#define STARTER_SECURE_WARN(fmt, arg...)
-#endif
-
-#ifdef ENABLE_LOG_SYSTEM
-#define _ERR(fmt, arg...) do { STARTER_ERR(fmt, ##arg); } while (0)
-#define _DBG(fmt, arg...) do { STARTER_DBG(fmt, ##arg); } while (0)
-#define _WARN(fmt, arg...) do { STARTER_WARN(fmt, ##arg); } while (0)
-
-#define _SECURE_ERR(fmt, arg...) do { STARTER_SECURE_ERR(fmt, ##arg); } while (0)
-#define _SECURE_DBG(fmt, arg...) do { STARTER_SECURE_DBG(fmt, ##arg); } while (0)
-#define _SECURE_WARN(fmt, arg...) do { STARTER_SECURE_WARN(fmt, ##arg); } while (0)
-
-#define LOCKD_ERR(fmt, arg...) _ERR(fmt, ##arg)
-#define LOCKD_DBG(fmt, arg...) _DBG(fmt, ##arg)
-#define LOCKD_WARN(fmt, arg...) _WARN(fmt, ##arg)
-#define LOCKD_SECURE_ERR(fmt, arg...) _SECURE_ERR(fmt, ##arg)
-#define LOCKD_SECURE_DBG(fmt, arg...) _SECURE_DBG(fmt, ##arg)
-#define LOCKD_SECURE_WARN(fmt, arg...) _SECURE_WARN(fmt, ##arg)
-#else
-#define _ERR(...)
-#define _DBG(...)
-#define _WARN(...)
-#define _SECURE_ERR(...)
-#define _SECURE_DBG(...)
-#define _SECURE_WARN(...)
-
-#define LOCKD_ERR(...)
-#define LOCKD_DBG(...)
-#define LOCKD_WARN(...)
-#define LOCKD_SECURE_ERR(...)
-#define LOCKD_SECURE_DBG(...)
-#define LOCKD_SECURE_WARN(...)
-#endif
-
-#ifndef TRUE
-#define TRUE 1
-#endif
-#ifndef FALSE
-#define FALSE 0
-#endif
-
-#endif /* __LOCKD_DEBUG_H__ */
diff --git a/include/lockd-process-mgr.h b/include/lockd-process-mgr.h
deleted file mode 100755
index f7429da..0000000
--- a/include/lockd-process-mgr.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __LOCKD_PROCESS_MGR_H__
-#define __LOCKD_PROCESS_MGR_H__
-
-void lockd_process_mgr_init(void);
-
-int lockd_process_mgr_start_lock(void *data, int (*dead_cb) (int, void *),
- int lock_type);
-
-int lockd_process_mgr_restart_lock(int lock_type);
-
-int lockd_process_mgr_start_recovery_lock(void);
-
-int lockd_process_mgr_start_back_to_app_lock(void);
-
-int lockd_process_mgr_start_ready_lock(void);
-
-int lockd_process_mgr_start_phone_lock(void);
-
-int lockd_process_mgr_start_normal_lock(void *data, int (*dead_cb) (int, void *));
-
-void lockd_process_mgr_terminate_lock_app(int lock_app_pid,
- int state);
-
-void lockd_process_mgr_terminate_phone_lock(int phone_lock_pid);
-
-void lockd_process_mgr_kill_lock_app(int lock_app_pid);
-
-int lockd_process_mgr_check_lock(int pid);
-
-int lockd_process_mgr_check_call(int pid);
-
-int lockd_process_mgr_check_home(int pid);
-
-int lockd_process_mgr_set_lockscreen_priority(int pid);
-int lockd_process_mgr_set_pwlock_priority(int pid);
-#endif /* __LOCKD_PROCESS_MGR_H__ */
diff --git a/include/lockd-window-mgr.h b/include/lockd-window-mgr.h
deleted file mode 100755
index cbb1a98..0000000
--- a/include/lockd-window-mgr.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __LOCKD_WINDOW_MGR_H__
-#define __LOCKD_WINDOW_MGR_H__
-
-typedef struct _lockw_data lockw_data;
-
-int
-lockd_window_mgr_get_focus_win_pid(void);
-
-Eina_Bool
-lockd_window_set_window_property(lockw_data * data, int lock_app_pid,
- void *event);
-
-Eina_Bool
-lockd_window_set_window_effect(lockw_data * data, int lock_app_pid,
- void *event);
-
-void
-lockd_window_set_scroll_property(lockw_data * data, int lock_type);
-
-void lockd_window_set_phonelock_pid(lockw_data * data, int phone_lock_pid);
-
-void
-lockd_window_mgr_ready_lock(void *data, lockw_data * lockw,
- Eina_Bool(*create_cb) (void *, int, void *),
- Eina_Bool(*show_cb) (void *, int, void *));
-
-void lockd_window_mgr_finish_lock(lockw_data * lockw);
-
-lockw_data *lockd_window_init(void);
-
-void lockd_create_ug_window(void *data);
-
-void lockd_destroy_ug_window(void *data);
-
-void lockd_show_phonelock_alpha_ug(void *data);
-#endif /* __LOCKD_WINDOW_MGR_H__ */
diff --git a/include/menu_daemon.h b/include/menu_daemon.h
deleted file mode 100755
index 5972da5..0000000
--- a/include/menu_daemon.h
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <bundle.h>
-#include <sys/types.h>
-#include <stdbool.h>
-
-extern void menu_daemon_init(void *data);
-extern void menu_daemon_fini(void);
-
-extern int menu_daemon_open_app(const char *pkgname);
-extern int menu_daemon_launch_app(const char *pkgname, bundle *b);
-extern void menu_daemon_launch_app_tray(void);
-
-extern bool menu_daemon_is_homescreen(pid_t pid);
-extern int menu_daemon_is_safe_mode(void);
-extern int menu_daemon_get_cradle_status(void);
-extern const char *menu_daemon_get_svoice_pkg_name(void);
-
-extern int menu_daemon_check_dead_signal(int pid);
-
-extern char *menu_daemon_get_selected_pkgname(void);
-extern int menu_daemon_open_homescreen(const char *pkgname);
-
-#if 0
-extern int menu_daemon_get_pm_key_ignore(int ignore_key);
-extern void menu_daemon_set_pm_key_ignore(int ignore_key, int value);
-#endif
-
-extern int menu_daemon_get_volume_pid(void);
-
-extern int menu_daemon_launch_search(void);
-
-
-// End of a file
diff --git a/include/mobile/home_mgr.h b/include/mobile/home_mgr.h
new file mode 100644
index 0000000..6fd5061
--- /dev/null
+++ b/include/mobile/home_mgr.h
@@ -0,0 +1,31 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <bundle.h>
+#include <sys/types.h>
+#include <stdbool.h>
+
+extern int home_mgr_get_home_pid(void);
+extern int home_mgr_get_volume_pid(void);
+
+extern void home_mgr_init(void *data);
+extern void home_mgr_fini(void);
+
+void home_mgr_relaunch_homescreen(void);
+void home_mgr_relaunch_volume(void);
+extern int home_mgr_open_home(const char *pkgname);
+
+// End of a file
diff --git a/include/mobile/hw_key.h b/include/mobile/hw_key.h
new file mode 100644
index 0000000..c1e4857
--- /dev/null
+++ b/include/mobile/hw_key.h
@@ -0,0 +1,39 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __HW_KEY_H__
+#define __HW_KEY_H__
+
+#define KEY_VOLUMEUP "XF86AudioRaiseVolume"
+#define KEY_VOLUMEDOWN "XF86AudioLowerVolume"
+#define KEY_HOME "XF86Home"
+#define KEY_CONFIG "XF86Camera_Full"
+#define KEY_SEARCH "XF86Search"
+#define KEY_MEDIA "XF86AudioMedia"
+#define KEY_TASKSWITCH "XF86TaskPane"
+#define KEY_WEBPAGE "XF86WWW"
+#define KEY_MAIL "XF86Mail"
+#define KEY_VOICE "XF86Voice"
+#define KEY_APPS "XF86Apps"
+#define KEY_CONNECT "XF86Call"
+#define KEY_BACK "XF86Back"
+
+extern void hw_key_destroy_window(void);
+extern void hw_key_create_window(void);
+
+#endif
+
+// End of a file
diff --git a/include/mobile/lock_mgr.h b/include/mobile/lock_mgr.h
new file mode 100644
index 0000000..6db7a69
--- /dev/null
+++ b/include/mobile/lock_mgr.h
@@ -0,0 +1,62 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __LOCK_DAEMON_H__
+#define __LOCK_DAEMON_H__
+
+#include <Elementary.h>
+#include <E_DBus.h>
+#include <alarm.h>
+
+#include "window_mgr.h"
+
+#define _EDJ(x) elm_layout_edje_get(x)
+
+#ifdef TIZEN_BUILD_EMULATOR
+#define LOCK_MGR_DEFAULT_BG_PATH "/opt/share/settings/Wallpapers/Default.jpg"
+#else
+#define LOCK_MGR_DEFAULT_BG_PATH "/opt/share/settings/Wallpapers/Lock_default.png"
+#endif
+
+
+
+typedef enum {
+ LOCK_SOUND_LOCK,
+ LOCK_SOUND_UNLOCK,
+ LOCK_SOUND_BTN_KEY,
+ LOCK_SOUND_TAP,
+ LOCK_SOUND_MAX,
+} lock_sound_type_e;
+
+typedef enum {
+ LCD_STATE_ON,
+ LCD_STATE_OFF,
+ LCD_STATE_MAX,
+} lock_lcd_state_e;
+
+int lock_mgr_lcd_state_get(void);
+int lock_mgr_get_lock_pid(void);
+void lock_mgr_sound_play(lock_sound_type_e type);
+
+void lock_mgr_idle_lock_state_set(int lock_state);
+Eina_Bool lock_mgr_lockscreen_launch(void);
+void lock_mgr_unlock(void);
+
+
+int lock_mgr_daemon_start(void);
+void lock_mgr_daemon_end(void);
+
+#endif /* __LOCK_DAEMON_H__ */
diff --git a/include/mobile/popup.h b/include/mobile/popup.h
new file mode 100644
index 0000000..f8602ad
--- /dev/null
+++ b/include/mobile/popup.h
@@ -0,0 +1,25 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __POPUP_H__
+#define __POPUP_H__
+
+#include <Elementary.h>
+
+extern Evas_Object *popup_create(const char *title, const char *text);
+
+#endif
+// End of a file
diff --git a/include/starter.h b/include/mobile/starter.h
index 4ce9124..a9700c2 100644
--- a/include/starter.h
+++ b/include/mobile/starter.h
@@ -21,6 +21,7 @@
struct appdata {
struct timeval tv_start; /* start time */
+ int lcd_status;
};
#endif /* __STARTER_H__ */
diff --git a/include/package_mgr.h b/include/package_mgr.h
new file mode 100644
index 0000000..85b7d4c
--- /dev/null
+++ b/include/package_mgr.h
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __PACKAGE_MGR_H__
+#define __PACKAGE_MGR_H__
+
+extern bool package_mgr_exist_app(char *appid);
+
+#endif /* __PACKAGE_MGR_H__ */
diff --git a/include/pkg_event.h b/include/pkg_event.h
deleted file mode 100644
index c7ee8b6..0000000
--- a/include/pkg_event.h
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __NOTIFIER_H__
-#define __NOTIFIER_H__
-#include <stdbool.h>
-
-#if !defined(PUBLIC)
-#define PUBLIC __attribute__((visibility("default"))) /**<All other from outside modules can access this typed API */
-#endif
-
-#if !defined(PROTECTED)
-#define PROTECTED __attribute__((visibility("hidden"))) /**<All other from outside modules can not access this directly */
-#endif
-
-#if !defined(PRIVATE)
-#define PRIVATE __attribute__((visibility("internal"))) /**<Does not export APIs to the other. only can be accessed in this module */
-#endif
-
-
-struct desktop_notifier {
- int number;
- int ifd;
- Ecore_Fd_Handler *handler;
-};
-
-
-PRIVATE void pkg_event_init(void);
-PRIVATE void pkg_event_fini(void);
-
-#endif
diff --git a/include/process_mgr.h b/include/process_mgr.h
new file mode 100644
index 0000000..008dfae
--- /dev/null
+++ b/include/process_mgr.h
@@ -0,0 +1,38 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __PROCESS_MGR_H__
+#define __PROCESS_MGR_H__
+
+typedef struct _process_mgr_s *process_mgr_h;
+
+typedef void (*after_func)(int pid);
+typedef int (*change_func)(const char *, const char *, const char *, void *, void *);
+
+void process_mgr_must_launch(const char *appid, const char *key, const char *value, change_func cfn, after_func afn);
+void process_mgr_must_open(const char *appid, change_func cfn, after_func afn);
+void process_mgr_must_syspopup_launch(const char *appid, const char *key, const char *value, change_func cfn, after_func afn);
+
+extern void process_mgr_terminate_app(int lock_app_pid, int state);
+extern void process_mgr_kill_app(int lock_app_pid);
+
+extern int process_mgr_validate_app(int pid);
+extern int process_mgr_validate_call(int pid);
+
+extern int process_mgr_set_lock_priority(int pid);
+extern int process_mgr_set_pwlock_priority(int pid);
+
+#endif /* __PROCESS_MGR_H__ */
diff --git a/include/starter-util.h b/include/starter-util.h
deleted file mode 100755
index 41999f6..0000000
--- a/include/starter-util.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __STARTER_UTIL_H__
-#define __STARTER_UTIL_H__
-
-#include <stdio.h>
-#include <sys/time.h>
-
-#if 0
-#define WRITE_FILE_LOG(fmt, arg...) do { \
- FILE *fp;\
- struct timeval tv; \
- gettimeofday(&tv, NULL); \
- fp = fopen("/var/log/boottime", "a+");\
- if (NULL == fp) break;\
- fprintf(fp, "%u%09u : "fmt"\n", (int) tv.tv_sec, (int) tv.tv_usec, ##arg); \
- fclose(fp);\
-} while (0)
-#endif
-#endif /* __STARTER_UTIL_H__ */
diff --git a/include/starter-vconf.h b/include/starter-vconf.h
deleted file mode 100755
index 2d51f0c..0000000
--- a/include/starter-vconf.h
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __STARTER_VCONF_H__
-#define __STARTER_VCONF_H__
-
-#define VCONF_PRIVATE_LOCKSCREEN_PKGNAME "file/private/lockscreen/pkgname"
-#define VCONF_PRIVATE_LOCKSCREEN_DEFAULT_PKGNAME "file/private/lockscreen/default_pkgname"
-
-#endif /* __STARTER_VCONF_H__ */
diff --git a/include/starter_w.h b/include/starter_w.h
deleted file mode 100755
index 102a00b..0000000
--- a/include/starter_w.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __STARTER_W_H__
-#define __STARTER_W_H__
-
-#include <sys/time.h>
-#include <aul.h>
-#include <alarm.h>
-
-struct appdata {
- struct timeval tv_start; /* start time */
- int launcher_pid;
- alarm_id_t alarm_id; /* -1 : None, others : set alarm */
- int bt_connected;
- char *home_pkgname;
- int first_boot;
- int cool_down_mode;
- int wake_up_setting;
- int pid_ALPM_clock;
- int ambient_mode;
- int retry_cnt;
- int nike_running_status;
- int ALPM_clock_state;
- int reserved_apps_local_port_id;
- Eina_List *reserved_apps_list;
- int lcd_status;
- char *reserved_popup_app_id;
-
- int pid_clock_viewer;
-};
-
-typedef enum {
- STARTER_RESERVED_APPS_SHEALTH = 0,
- STARTER_RESERVED_APPS_NIKE = 1,
- STARTER_RESERVED_APPS_HERE = 2,
- STARTER_RESERVED_APPS_MAX = 3,
-} starter_reservd_apps_type;
-
-#define W_HOME_PKGNAME "org.tizen.w-home"
-#define W_LAUNCHER_PKGNAME "com.samsung.w-launcher-app"
-
-#define W_CLOCK_VIEWER_PKGNAME "org.tizen.w-clock-viewer"
-
-
-int w_open_app(char *pkgname);
-int w_launch_app(char *pkgname, bundle *b);
-
-#endif /* __STARTER_H__ */
diff --git a/include/status.h b/include/status.h
new file mode 100644
index 0000000..9f203f3
--- /dev/null
+++ b/include/status.h
@@ -0,0 +1,87 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __STATUS_H__
+#define __STATUS_H__
+
+#include <Eina.h>
+
+#ifndef VCONFKEY_STARTER_RESERVED_APPS_STATUS
+/* 2 digits for reserved apps & popup */
+/* 0x01 : reserved apps */
+/* 0x10 : reserved popup */
+#define VCONFKEY_STARTER_RESERVED_APPS_STATUS "memory/starter/reserved_apps_status"
+#endif
+
+#define VCONFKEY_SETAPPL_PASSWORD_ATTEMPTS_LEFT_INT VCONFKEY_SETAPPL_PREFIX"/phone_lock_attempts_left"
+
+#define STATUS_DEFAULT_LOCK_PKG_NAME "org.tizen.lockscreen"
+
+typedef enum {
+ STATUS_ACTIVE_KEY_INVALID = -1,
+ STATUS_ACTIVE_KEY_PM_STATE = 0,
+ STATUS_ACTIVE_KEY_SETAPPL_SELECTED_PACKAGE_NAME,
+ STATUS_ACTIVE_KEY_SETAPPL_SCREEN_LOCK_TYPE_INT,
+ STATUS_ACTIVE_KEY_STARTER_SEQUENCE,
+ STATUS_ACTIVE_KEY_SYSMAN_POWER_OFF_STATUS,
+ STATUS_ACTIVE_KEY_LANGSET,
+ STATUS_ACTIVE_KEY_MAX,
+} status_active_key_e;
+
+struct status_active_s {
+ Eina_List *list[STATUS_ACTIVE_KEY_MAX];
+ char *setappl_selected_package_name;
+ int setappl_screen_lock_type_int;
+ char *langset;
+ int pm_state;
+ int starter_sequence;
+ int sysman_power_off_status;
+};
+
+struct status_passive_s {
+ int wms_wakeup_by_gesture_setting;
+
+ int pm_key_ignore;
+ int pm_state;
+ int call_state;
+ int idle_lock_state;
+ int setappl_password_attempts_left_int;
+ int remote_lock_islocked;
+ int setappl_psmode;
+ int starter_reserved_apps_status;
+ int setappl_sound_lock_bool;
+ int setappl_motion_activation;
+ int setappl_use_pick_up;
+ int setappl_accessibility_lock_time_int;
+ int boot_animation_finished;
+ int setappl_ambient_mode_bool;
+
+ char *setappl_3rd_lock_pkg_name_str;
+};
+typedef struct status_passive_s *status_passive_h;
+typedef struct status_active_s *status_active_h;
+typedef int (*status_active_cb)(status_active_key_e key, void *data);
+
+extern status_active_h status_active_get(void);
+extern status_passive_h status_passive_get(void);
+
+int status_active_register_cb(status_active_key_e key, status_active_cb func, void *data);
+int status_active_unregister_cb(status_active_key_e key, status_active_cb func);
+
+extern int status_register(void);
+extern void status_unregister(void);
+
+#endif //__STATUS_H__
diff --git a/include/util.h b/include/util.h
index 5972926..bec5430 100755..100644
--- a/include/util.h
+++ b/include/util.h
@@ -19,19 +19,27 @@
#include <dlog.h>
#include <stdio.h>
#include <sys/time.h>
+#include <app.h>
-#define APP_TRAY_PKG_NAME "com.samsung.app-tray"
+#define APP_TRAY_PKG_NAME "org.tizen.app-tray"
#define MENU_SCREEN_PKG_NAME "org.tizen.menu-screen"
-#define PROVIDER_PKG_NAME "com.samsung.data-provider-master"
-#define SVOICE_PKG_NAME "com.samsung.svoice"
-#define CLUSTER_HOME_PKG_NAME "com.samsung.cluster-home"
-#define EASY_HOME_PKG_NAME "com.samsung.easy-home"
-#define EASY_APPS_PKG_NAME "com.samsung.easy-apps"
+#define PROVIDER_PKG_NAME "org.tizen.data-provider-master"
+#define CLUSTER_HOME_PKG_NAME "org.tizen.cluster-home"
+#define EASY_HOME_PKG_NAME "org.tizen.easy-home"
+#define EASY_APPS_PKG_NAME "org.tizen.easy-apps"
#define HOMESCREEN_PKG_NAME "org.tizen.homescreen"
#define TASKMGR_PKG_NAME "org.tizen.task-mgr"
-#define DEFAULT_TASKMGR_PKG_NAME "com.samsung.taskmgr"
+#define DEFAULT_TASKMGR_PKG_NAME "org.tizen.taskmgr"
#define CONF_PATH_NUMBER 1024
+#define BUF_SIZE_16 16
+#define BUF_SIZE_32 32
+#define BUF_SIZE_128 128
+#define BUF_SIZE_256 256
+#define BUF_SIZE_512 512
+#define BUF_SIZE_1024 1024
+
+
#ifdef LOG_TAG
#undef LOG_TAG
#define LOG_TAG "STARTER"
@@ -111,6 +119,13 @@
fclose(fp);\
} while (0)
+#if !defined(_)
+#define _(str) dgettext(PACKAGE, str)
+#endif
+
+#if !defined(S_)
+#define S_(str) dgettext("sys_string", str)
+#endif
#endif /* __MENU_DAEMON_UTIL_H__ */
diff --git a/include/hw_key_w.h b/include/wearable/clock_mgr.h
index 13f9062..4f3af15 100755..100644
--- a/include/hw_key_w.h
+++ b/include/wearable/clock_mgr.h
@@ -14,7 +14,10 @@
* limitations under the License.
*/
-extern void destroy_key_window(void);
-extern void create_key_window(char *home_pkgname, void *data);
+#ifndef __CLOCK_MGR_H__
+#define __CLOCK_MGR_H__
-// End of a file
+void clock_mgr_init(void);
+void clock_mgr_fini(void);
+
+#endif /* __CLOCK_MGR_H__*/
diff --git a/include/lockd-bt.h b/include/wearable/home_mgr.h
index 33a9369..d01a8ea 100755..100644
--- a/include/lockd-bt.h
+++ b/include/wearable/home_mgr.h
@@ -14,15 +14,14 @@
* limitations under the License.
*/
-#ifndef __LOCKD_BT_H__
-#define __LOCKD_BT_H__
+#ifndef __HOME_MGR_H__
+#define __HOME_MGR_H__
-int lockd_start_bt_monitor(void);
+extern void home_mgr_launch_home(void);
+extern void home_mgr_launch_home_first(void);
+extern void home_mgr_launch_home_by_power(void);
-void lockd_stop_bt_monitor(void);
+extern void home_mgr_init(void);
+extern void home_mgr_fini(void);
-void lockd_change_security_auto_lock(int is_connected);
-
-int lockd_get_auto_lock_security(void);
-
-#endif /* __LOCKD_BT_H__ */
+#endif /* __HOME_MGR_H__*/
diff --git a/include/hourly_alert.h b/include/wearable/hourly_alert.h
index 1e8ee11..a0ecf40 100755..100644
--- a/include/hourly_alert.h
+++ b/include/wearable/hourly_alert.h
@@ -18,7 +18,7 @@
#define __HOURLY_ALERT_H__
-void init_hourly_alert(void *data);
-void fini_hourly_alert(void *data);
+void hourly_alert_init(void);
+void hourly_alert_fini(void);
#endif /* __HOURLY_ALERT_H__ */
diff --git a/include/hw_key.h b/include/wearable/hw_key.h
index ec02f61..a937000 100755..100644
--- a/include/hw_key.h
+++ b/include/wearable/hw_key.h
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-extern void destroy_key_window(void);
-extern void create_key_window(void);
+extern void hw_key_destroy_window(void);
+extern void hw_key_create_window(void);
// End of a file
diff --git a/include/window_mgr.h b/include/window_mgr.h
new file mode 100644
index 0000000..1205798
--- /dev/null
+++ b/include/window_mgr.h
@@ -0,0 +1,37 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __WINDOW_MGR_H__
+#define __WINDOW_MGR_H__
+
+typedef struct _lockw_data lockw_data;
+
+int window_mgr_get_focus_window_pid(void);
+Eina_Bool window_mgr_set_prop(lockw_data * data, int lock_app_pid, void *event);
+Eina_Bool window_mgr_set_effect(lockw_data * data, int lock_app_pid, void *event);
+
+void window_mgr_set_scroll_prop(lockw_data * data, int lock_type);
+void window_mgr_register_event(void *data, lockw_data * lockw,
+ Eina_Bool (*create_cb) (void *, int, void *),
+ Eina_Bool (*show_cb) (void *, int, void *));
+void window_mgr_unregister_event(lockw_data * lockw);
+
+lockw_data *window_mgr_init(void);
+void window_mgr_fini(lockw_data *lockw);
+
+Evas_Object *window_mgr_pwd_lock_win_create(void);
+
+#endif /* __WINDOW_MGR_H__ */
diff --git a/include/x11.h b/include/x11.h
deleted file mode 100644
index ef0bbc5..0000000
--- a/include/x11.h
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef __STARTER_X11_H__
-#define __STARTER_X11_H__
-
-void prop_string_set(const char *name, const char *value);
-void prop_int_set(const char *name, unsigned int val);
-void set_window_scale(void);
-
-#endif /* __STARTER_X11_H__ */
diff --git a/include/dbus-util.h b/lock_pwd/include/lock_pwd_complex.h
index 3b20715..bb92dca 100755..100644
--- a/include/dbus-util.h
+++ b/lock_pwd/include/lock_pwd_complex.h
@@ -14,20 +14,15 @@
* limitations under the License.
*/
-#ifndef __DBUS_UTIL_H__
-#define __DBUS_UTIL_H__
+#ifndef __LOCK_PWD_COMPLEX_H__
+#define __LOCK_PWD_COMPLEX_H__
-#include <E_DBus.h>
+#include "lock_pwd_verification.h"
-#define OOM_ADJ_VALUE_HOMESCREEN 0
+Eina_Bool lock_pwd_complex_is_blocked_get(void);
+void lock_pwd_complex_event(lock_pwd_event_e event);
+Evas_Object *lock_pwd_complex_layout_create(void *data);
+void lock_pwd_complex_layout_destroy(void);
+void lock_pwd_complex_view_init(void);
-#ifdef FEATURE_LITE
-#define OOM_ADJ_VALUE_DEFAULT 200
-#else
-#define OOM_ADJ_VALUE_DEFAULT 0
#endif
-
-void starter_dbus_home_raise_signal_send(void);
-int starter_dbus_set_oomadj(int pid, int oom_adj_value);
-
-#endif //__DBUS_UTIL_H__
diff --git a/include/clock-mgr.h b/lock_pwd/include/lock_pwd_control_panel.h
index 2b32512..9c65e80 100755..100644
--- a/include/clock-mgr.h
+++ b/lock_pwd/include/lock_pwd_control_panel.h
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-#ifndef __CLOCK_MGR_H__
-#define __CLOCK_MGR_H__
+#ifndef __LOCK_PWD_CONTROL_PANEL_H__
+#define __LOCK_PWD_CONTROL_PANEL_H__
-void init_clock_mgr(void *data);
-void fini_clock_mgr(void *data);
-void clock_mgr_set_reserved_apps_status(void *data);
+void lock_pwd_control_panel_cancel_btn_enable_set(Eina_Bool enable);
-#endif
-/* __CLOCK_MGR_H__*/
+Evas_Object *lock_pwd_control_panel_create(Evas_Object *parent);
+void lock_pwd_control_panel_del(void);
+#endif
diff --git a/lock_pwd/include/lock_pwd_simple.h b/lock_pwd/include/lock_pwd_simple.h
new file mode 100755
index 0000000..b820003
--- /dev/null
+++ b/lock_pwd/include/lock_pwd_simple.h
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __LOCK_PWD_SIMPLE_H__
+#define __LOCK_PWD_SIMPLE_H__
+
+#include <Elementary.h>
+
+#include "lock_pwd_verification.h"
+
+Eina_Bool lock_pwd_simple_is_blocked_get(void);
+Evas_Object *lock_pwd_simple_layout_create(void *data);
+void lock_pwd_simple_layout_destroy(void);
+void lock_pwd_simple_event(lock_pwd_event_e event);
+void lock_pwd_simple_view_init(void);
+
+#endif
diff --git a/lock_pwd/include/lock_pwd_util.h b/lock_pwd/include/lock_pwd_util.h
new file mode 100644
index 0000000..cd53bfa
--- /dev/null
+++ b/lock_pwd/include/lock_pwd_util.h
@@ -0,0 +1,38 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __LOCK_PWD_UTIL_H__
+#define __LOCK_PWD_UTIL_H__
+
+#define LOCK_PWD_EDJE_FILE "/usr/share/starter/lock_pwd/res/edje/lock_pwd.edj"
+#define LOCK_PWD_BTN_EDJE_FILE "/usr/share/starter/lock_pwd/res/edje/lock_btn.edj"
+
+int lock_pwd_util_win_width_get(void);
+int lock_pwd_util_win_height_get(void);
+
+void lock_pwd_util_create(Eina_Bool is_show);
+void lock_pwd_util_destroy(void);
+
+void lock_pwd_util_popup_create(char *title, char *text, Evas_Smart_Cb func, double timeout);
+
+void lock_pwd_util_view_init(void);
+void lock_pwd_util_back_key_relased(void);
+Evas_Object *lock_pwd_util_win_get(void);
+Eina_Bool lock_pwd_util_win_visible_get(void);
+void lock_pwd_util_win_show(void);
+void lock_pwd_util_win_hide(void);
+
+#endif
diff --git a/lock_pwd/include/lock_pwd_verification.h b/lock_pwd/include/lock_pwd_verification.h
new file mode 100755
index 0000000..5d3b15b
--- /dev/null
+++ b/lock_pwd/include/lock_pwd_verification.h
@@ -0,0 +1,56 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __LOCK_PWD_VERIFICATION_H__
+#define __LOCK_PWD_VERIFICATION_H__
+
+#include <vconf.h>
+
+#define PASSWORD_ATTEMPTS_MAX_NUM 5
+#define MAX_SIMPLE_PASSWORD_NUM 4
+#define INFINITE_ATTEMPT 0
+#define PASSWORD_BLOCK_SECONDS 30
+#define PASSWORD_TIMESTAMP_STR_LENGTH 512
+#define VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR VCONFKEY_SETAPPL_PREFIX"/phone_lock_timestamp"
+
+typedef enum {
+ PWD_EVENT_CORRECT = 0,
+ PWD_EVENT_INCORRECT_WARNING = 1,
+ PWD_EVENT_INCORRECT,
+ PWD_EVENT_INPUT_BLOCK_WARNING,
+ PWD_EVENT_INPUT_BLOCK,
+ PWD_EVENT_EMPTY,
+ PWD_EVENT_OVER,
+} lock_pwd_event_e;
+
+typedef struct {
+ unsigned int current_attempt;
+ unsigned int block_attempt;
+ unsigned int max_attempt;
+ unsigned int expire_sec;
+ unsigned int incorrect_count;
+ void *data;
+} lock_pwd_policy;
+
+int lock_pwd_verification_current_attempt_get(void);
+int lock_pwd_verification_remain_attempt_get(void);
+
+lock_pwd_event_e lock_pwd_verification_verify(const char *password);
+void lock_pwd_verification_policy_create(void);
+
+void lock_pwd_verification_popup_create(lock_pwd_event_e event);
+
+#endif
diff --git a/lock_pwd/res/CMakeLists.txt b/lock_pwd/res/CMakeLists.txt
new file mode 100755
index 0000000..2ab7c7b
--- /dev/null
+++ b/lock_pwd/res/CMakeLists.txt
@@ -0,0 +1 @@
+ADD_SUBDIRECTORY(edje)
diff --git a/lock_pwd/res/edje/CMakeLists.txt b/lock_pwd/res/edje/CMakeLists.txt
new file mode 100755
index 0000000..23de665
--- /dev/null
+++ b/lock_pwd/res/edje/CMakeLists.txt
@@ -0,0 +1,23 @@
+ADD_CUSTOM_TARGET(lock_btn.edj
+ COMMAND edje_cc -id ${CMAKE_CURRENT_SOURCE_DIR}/images
+ ${CMAKE_CURRENT_SOURCE_DIR}/lock_btn.edc ${CMAKE_BINARY_DIR}/lock_pwd/res/edje/lock_btn.edj
+ DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/lock_btn.edc
+)
+ADD_DEPENDENCIES(${PROJECT_NAME} lock_btn.edj)
+INSTALL(FILES lock_btn.edj DESTINATION /usr/share/starter/lock_pwd/res/edje)
+
+ADD_CUSTOM_TARGET(lock_entry.edj
+ COMMAND edje_cc -id ${CMAKE_CURRENT_SOURCE_DIR}/images
+ ${CMAKE_CURRENT_SOURCE_DIR}/lock_entry.edc ${CMAKE_BINARY_DIR}/lock_pwd/res/edje/lock_entry.edj
+ DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/lock_entry.edc
+)
+ADD_DEPENDENCIES(${PROJECT_NAME} lock_entry.edj)
+INSTALL(FILES lock_entry.edj DESTINATION /usr/share/starter/lock_pwd/res/edje)
+
+ADD_CUSTOM_TARGET(lock_pwd.edj
+ COMMAND edje_cc -id ${CMAKE_CURRENT_SOURCE_DIR}/images
+ ${CMAKE_CURRENT_SOURCE_DIR}/lock_pwd.edc ${CMAKE_BINARY_DIR}/lock_pwd/res/edje/lock_pwd.edj
+ DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/lock_pwd.edc
+)
+ADD_DEPENDENCIES(${PROJECT_NAME} lock_pwd.edj)
+INSTALL(FILES lock_pwd.edj DESTINATION /usr/share/starter/lock_pwd/res/edje)
diff --git a/lock_pwd/res/edje/images/enter_pin_dot.png b/lock_pwd/res/edje/images/enter_pin_dot.png
new file mode 100644
index 0000000..467db33
--- /dev/null
+++ b/lock_pwd/res/edje/images/enter_pin_dot.png
Binary files differ
diff --git a/lock_pwd/res/edje/images/event_close_bg.#.png b/lock_pwd/res/edje/images/event_close_bg.#.png
new file mode 100644
index 0000000..047d7ca
--- /dev/null
+++ b/lock_pwd/res/edje/images/event_close_bg.#.png
Binary files differ
diff --git a/lock_pwd/res/edje/images/ls_back_02_nor.png b/lock_pwd/res/edje/images/ls_back_02_nor.png
new file mode 100644
index 0000000..7a8f607
--- /dev/null
+++ b/lock_pwd/res/edje/images/ls_back_02_nor.png
Binary files differ
diff --git a/lock_pwd/res/edje/images/ls_back_02_press.png b/lock_pwd/res/edje/images/ls_back_02_press.png
new file mode 100644
index 0000000..7426dfc
--- /dev/null
+++ b/lock_pwd/res/edje/images/ls_back_02_press.png
Binary files differ
diff --git a/lock_pwd/res/edje/images/ls_icon_call.png b/lock_pwd/res/edje/images/ls_icon_call.png
new file mode 100644
index 0000000..18bf92a
--- /dev/null
+++ b/lock_pwd/res/edje/images/ls_icon_call.png
Binary files differ
diff --git a/lock_pwd/res/edje/images/ls_password_underline.#.png b/lock_pwd/res/edje/images/ls_password_underline.#.png
new file mode 100644
index 0000000..9b6944b
--- /dev/null
+++ b/lock_pwd/res/edje/images/ls_password_underline.#.png
Binary files differ
diff --git a/lock_pwd/res/edje/images/ls_pin_dot.png b/lock_pwd/res/edje/images/ls_pin_dot.png
new file mode 100644
index 0000000..c01ca7c
--- /dev/null
+++ b/lock_pwd/res/edje/images/ls_pin_dot.png
Binary files differ
diff --git a/lock_pwd/res/edje/lock_btn.edc b/lock_pwd/res/edje/lock_btn.edc
new file mode 100755
index 0000000..20ecbbb
--- /dev/null
+++ b/lock_pwd/res/edje/lock_btn.edc
@@ -0,0 +1,395 @@
+/*
+ * Copyright (c) 2009-2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+styles {
+ style {
+ name: "unlock_text";
+ base: "font=Tizen:style=Regular color=#FFFFFFFF color_class=ATO017 font_size=10 text_class=ATO017 style=shadow shadow_color=#000000bf align: 0.5 0.0 wrap=word";
+ }
+}
+
+#define TEXT_BUTTON_CLASS "ATO007"
+
+
+collections {
+ base_scale: 2.6;
+ group {
+ name: "elm/button/base/emg_cal_btn";
+ parts {
+ part {
+ name: "elm.swallow.content";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ color: 0 0 0 0;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 1.0 1.0;
+ align: 0.0 0.0;
+ }
+ }
+ part {
+ name: "elm.text";
+ type: TEXT;
+ effect: "SHADOW";
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ fixed: 1 1;
+ color: 255 255 255 255;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 1.0 1.0;
+ text {
+ align: 0.0 0.5;
+ size: 28;
+ text_class: TEXT_BUTTON_CLASS;
+ }
+ }
+ description {
+ state: "pressed" 0.0;
+ inherit: "default" 0.0;
+ color: 255 255 255 120;
+ }
+ }
+ }
+ programs {
+ program {
+ name: "mouse,clicked";
+ signal: "mouse,clicked,1";
+ source: "elm.swallow.content";
+ action: SIGNAL_EMIT "elm,action,click" "";
+ }
+ program {
+ name: "button,pressed";
+ signal: "mouse,down,1";
+ action: STATE_SET "pressed" 0.0;
+ source: "elm.swallow.content";
+ target: "elm.text";
+ }
+ program {
+ name: "button,unpressed";
+ signal: "mouse,up,1";
+ action: STATE_SET "default" 0.0;
+ source: "elm.swallow.content";
+ target: "elm.text";
+ }
+ }
+ }
+
+ group {
+ name: "elm/button/base/tizen_account_btn";
+ parts {
+ part {
+ name: "elm.swallow.content";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ color: 0 0 0 0;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 1.0 1.0;
+ align: 0.0 0.0;
+ }
+ }
+ part {
+ name: "elm.text";
+ type: TEXTBLOCK;
+ effect: "SHADOW";
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ fixed: 1 1;
+ color: 255 255 255 255;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 1.0 1.0;
+ text {
+ style: "unlock_text";
+ }
+ }
+ description {
+ state: "pressed" 0.0;
+ inherit: "default" 0.0;
+ color: 255 255 255 120;
+ }
+ }
+ }
+ programs {
+ program {
+ name: "mouse,clicked";
+ signal: "mouse,clicked,1";
+ source: "elm.swallow.content";
+ action: SIGNAL_EMIT "elm,action,click" "";
+ }
+ program {
+ name: "button,pressed";
+ signal: "mouse,down,1";
+ action: STATE_SET "pressed" 0.0;
+ source: "elm.swallow.content";
+ target: "elm.text";
+ }
+ program {
+ name: "button,unpressed";
+ signal: "mouse,up,1";
+ action: STATE_SET "default" 0.0;
+ source: "elm.swallow.content";
+ target: "elm.text";
+ }
+ }
+ }
+
+ group {
+ name: "elm/button/base/right_button";
+ parts {
+ part {
+ name: "elm.swallow.content";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ color: 0 0 0 0;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 1.0 1.0;
+ align: 1.0 0.0;
+ }
+ }
+ part {
+ name: "effect";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ visible: 0;
+ }
+ description {
+ state: "pressed" 0.0;
+ //color_class: AO018;
+ visible: 1;
+ rel1.to: "elm.text";
+ rel1.offset: -3 0;
+ rel2.to: "elm.text";
+ rel2.offset: 3 0;
+ }
+ }
+ part {
+ name: "elm.text";
+ type: TEXT;
+ effect: "SHADOW";
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ color: 255 255 255 255;
+ visible: 1;
+ rel1.relative: 1.0 0.0;
+ rel2.relative: 1.0 1.0;
+ align: 1.0 0.5;
+ text {
+ align: 1.0 0.5;
+ size: 32;
+ //text_class: "ATO007";
+ min: 1 0;
+ ellipsis: -1;
+ }
+ }
+ }
+ }
+ programs {
+ program {
+ name: "mouse,clicked";
+ signal: "mouse,clicked,1";
+ source: "elm.swallow.content";
+ action: SIGNAL_EMIT "elm,action,click" "";
+ }
+ program {
+ name: "button,pressed";
+ signal: "mouse,down,1";
+ action: STATE_SET "pressed" 0.0;
+ source: "elm.swallow.content";
+ target: "effect";
+ }
+ program {
+ name: "button,unpressed";
+ signal: "mouse,up,1";
+ action: STATE_SET "default" 0.0;
+ source: "elm.swallow.content";
+ target: "effect";
+ }
+ }
+ }
+
+ group {
+ name: "elm/button/base/left_button";
+ parts {
+ part {
+ name: "elm.swallow.content";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ color: 0 0 0 0;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 1.0 1.0;
+ align: 0.0 0.0;
+ }
+ }
+ part {
+ name: "effect";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ visible: 0;
+ }
+ description {
+ state: "pressed" 0.0;
+ color_class: AO018;
+ visible: 1;
+ rel1.to: "elm.text";
+ rel1.offset: -3 -3;
+ rel2.to: "elm.text";
+ rel2.offset: 3 3;
+ }
+ }
+ part {
+ name: "elm.text";
+ type: TEXT;
+ effect: "SHADOW";
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ fixed: 1 1;
+ color: 255 255 255 255;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 0.0 1.0;
+ align: 0.0 0.5;
+ text {
+ align: 0.0 0.5;
+ size: 28;
+ //text_class: "ATO007";
+ min: 1 0;
+ ellipsis: -1;
+ }
+ }
+ }
+ }
+ programs {
+ program {
+ name: "mouse,clicked";
+ signal: "mouse,clicked,1";
+ source: "elm.text";
+ action: SIGNAL_EMIT "elm,action,click" "";
+ }
+ program {
+ name: "button,pressed";
+ signal: "mouse,down,1";
+ action: STATE_SET "pressed" 0.0;
+ source: "elm.text";
+ target: "effect";
+ }
+ program {
+ name: "button,unpressed";
+ signal: "mouse,up,1";
+ action: STATE_SET "default" 0.0;
+ source: "elm.text";
+ target: "effect";
+ }
+ }
+ }
+
+ group {
+ name: "elm/button/base/center_button";
+ parts {
+ part {
+ name: "elm.swallow.content";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ color: 0 0 0 0;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 1.0 1.0;
+ align: 0.0 0.0;
+ }
+ }
+ part {
+ name: "elm.text";
+ type: TEXT;
+ effect: "SHADOW";
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ fixed: 1 1;
+ color: 255 255 255 255;
+ visible: 1;
+ rel1.relative: 0.0 0.0;
+ rel2.relative: 1.0 1.0;
+ text {
+ align: 0.5 0.5;
+ size: 28;
+ //text_class: "ATO007";
+ }
+ }
+ description {
+ state: "pressed" 0.0;
+ inherit: "default" 0.0;
+ color: 255 255 255 128;
+ }
+ }
+ }
+ programs {
+ program {
+ name: "mouse,clicked";
+ signal: "mouse,clicked,1";
+ source: "elm.swallow.content";
+ action: SIGNAL_EMIT "elm,action,click" "";
+ }
+ program {
+ name: "button,pressed";
+ signal: "mouse,down,1";
+ action: STATE_SET "pressed" 0.0;
+ source: "elm.swallow.content";
+ target: "elm.text";
+ }
+ program {
+ name: "button,unpressed";
+ signal: "mouse,up,1";
+ action: STATE_SET "default" 0.0;
+ source: "elm.swallow.content";
+ target: "elm.text";
+ }
+ }
+ }
+}
diff --git a/lock_pwd/res/edje/lock_entry.edc b/lock_pwd/res/edje/lock_entry.edc
new file mode 100755
index 0000000..f4b3cca
--- /dev/null
+++ b/lock_pwd/res/edje/lock_entry.edc
@@ -0,0 +1,486 @@
+/*
+ * Copyright (c) 2009-2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+collections {
+ base_scale : 2.6;
+
+ group {
+ name: "elm/entry/base-single/default";
+ data.item: "default_font_size" "43";
+ data.item: "min_font_size" "8";
+ data.item: "max_font_size" "60";
+ styles {
+ style { name: "entry_single_textblock_style";
+ base: "font=Tizen:style=Roman font_size=43 align=center color=#FFFFFFFF wrap=none left_margin=1 right_margin=3 text_class=Tizen style=shadow shadow_color=#000000bf";
+ tag: "br" "\n";
+ tag: "ps" "ps";
+ tag: "tab" "\t";
+ tag: "em" "+ font=Tizen:style=Oblique";
+ tag: "b" "+ font=Tizen:style=Bold";
+ tag: "link" "+ color=#800 underline=on underline_color=#8008";
+ tag: "hilight" "+ font=Tizen:style=Bold";
+ tag: "preedit" "+ underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ tag: "preedit_sel" "+ backing=on backing_color="ENTRY_PREEDIT_BACKGROUND_COLOR_INC" color="ENTRY_PREEDIT_TEXT_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_TEXT_COLOR_INC;
+ tag: "preedit_sub1" "+ backing=on backing_color="ENTRY_PREEDIT_SUB1_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ tag: "preedit_sub2" "+ backing=on backing_color="ENTRY_PREEDIT_SUB2_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ tag: "preedit_sub3" "+ backing=on backing_color="ENTRY_PREEDIT_SUB3_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ tag: "preedit_sub4" "+ backing=on backing_color="ENTRY_PREEDIT_SUB4_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ }
+ style { name: "entry_single_textblock_disabled_style";
+ base: "font=Tizen:style=Roman font_size=43 color=00000080 wrap=none left_margin=1 right_margin=3 text_class=Tizen";
+ tag: "br" "\n";
+ tag: "ps" "ps";
+ tag: "tab" "\t";
+ tag: "em" "+ font=Tizen:style=Oblique";
+ tag: "b" "+ font=Tizen:style=Bold";
+ tag: "link " "+ color=#00000080 underline=on underline_color=#00000080";
+ tag: "hilight" "+ font=Tizen:style=Bold";
+ tag: "preedit" "+ underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ tag: "preedit_sel" "+ backing=on backing_color="ENTRY_PREEDIT_BACKGROUND_COLOR_INC" color="ENTRY_PREEDIT_TEXT_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_TEXT_COLOR_INC;
+ tag: "preedit_sub1" "+ backing=on backing_color="ENTRY_PREEDIT_SUB1_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ tag: "preedit_sub2" "+ backing=on backing_color="ENTRY_PREEDIT_SUB2_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ tag: "preedit_sub3" "+ backing=on backing_color="ENTRY_PREEDIT_SUB3_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ tag: "preedit_sub4" "+ backing=on backing_color="ENTRY_PREEDIT_SUB4_COLOR_INC" underline=on underline_color="ENTRY_PREEDIT_UNDERLINE_COLOR_INC;
+ }
+ }
+ data {
+ item: context_menu_orientation "horizontal";
+ }
+ parts {
+ part {
+ name: "entry.swallow.background";
+ type: SWALLOW;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ visible: 1;
+ rel1 { relative: 0 0; to: "elm.text"; }
+ rel2 { relative: 1 1; to: "elm.text"; }
+ }
+ }
+ }
+ parts {
+ part {
+ name: "elm.text";
+ type: TEXTBLOCK;
+ mouse_events: 1;
+ scale: 1;
+ entry_mode: EDITABLE;
+ select_mode: BLOCK_HANDLE;
+ multiline: 0;
+ source: "elm/entry/selection/default";
+ source2: "elm/entry/selection/block_handle";
+ source3: "elm/entry/selection/block_handle_top";
+ source4: "elm/entry/cursor/default";
+ source5: "elm/entry/anchor/default";
+ description {
+ state: "default" 0.0;
+ text {
+ style: "entry_single_textblock_style";
+ min: 1 1;
+ max: 0 1;
+ ellipsis: -1;
+ }
+ }
+ description {
+ state: "disabled" 0.0;
+ inherit: "default" 0.0;
+ text {
+ style: "entry_single_textblock_disabled_style";
+ }
+ }
+ }
+ }
+ programs {
+ program {
+ name: "focus";
+ signal: "load";
+ source: "";
+ action: FOCUS_SET;
+ target: "elm.text";
+ }
+ program {
+ name: "disable";
+ signal: "elm,state,disabled";
+ source: "elm";
+ action: STATE_SET "disabled" 0.0;
+ target: "elm.text";
+ }
+ program {
+ name: "enable";
+ signal: "elm,state,enabled";
+ source: "elm";
+ action: STATE_SET "default" 0.0;
+ target: "elm.text";
+ }
+ }
+ }
+ group {
+ name: "elm/entry/base-password/lockscreen_complex_password_style";
+ data.item: "default_font_size" "43";
+ data.item: "min_font_size" "8";
+ data.item: "max_font_size" "60";
+ data {
+ item: context_menu_orientation "horizontal";
+ }
+ parts {
+ part {
+ name: "entry.swallow.background";
+ type: SWALLOW;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ visible: 1;
+ rel1 { relative: 0 0; to: "elm.text"; }
+ rel2 { relative: 1 1; to: "elm.text"; }
+ }
+ }
+ }
+ parts {
+ part {
+ name: "elm.text";
+ type: TEXTBLOCK;
+ mouse_events: 1;
+ scale: 1;
+ entry_mode: PASSWORD;
+ select_mode: BLOCK_HANDLE;
+ multiline: 0;
+ source: "elm/entry/selection/default";
+ source2: "elm/entry/selection/block_handle";
+ source3: "elm/entry/selection/block_handle_top";
+ source4: "elm/entry/cursor/default";
+ source5: "elm/entry/anchor/default";
+ description {
+ state: "default" 0.0;
+ text {
+ style: "entry_single_textblock_style";
+ repch: "•";
+ min: 1 1;
+ max: 0 0;
+ ellipsis: -1;
+ }
+ }
+ description {
+ state: "disabled" 0.0;
+ inherit: "default" 0.0;
+ text {
+ style: "entry_single_textblock_disabled_style";
+ }
+ }
+ }
+ }
+ programs {
+ program {
+ name: "focus";
+ signal: "load";
+ source: "";
+ action: FOCUS_SET;
+ target: "elm.text";
+ }
+ program {
+ name: "disable";
+ signal: "elm,state,disabled";
+ source: "elm";
+ action: STATE_SET "disabled" 0.0;
+ target: "elm.text";
+ }
+ program {
+ name: "enable";
+ signal: "elm,state,enabled";
+ source: "elm";
+ action: STATE_SET "default" 0.0;
+ target: "elm.text";
+ }
+ }
+ }
+ group {
+ name: "elm/entry/cursor/default";
+ parts {
+ part {
+ name: "clip2";
+ type: RECT;
+ mouse_events: 0;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ rel1.to: "clip";
+ rel2.to: "clip";
+ visible: 0;
+ }
+ description {
+ state: "focused" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ }
+ part {
+ name: "clip";
+ type: RECT;
+ mouse_events: 0;
+ scale: 1;
+ clip_to: "clip2";
+ description {
+ state: "default" 0.0;
+ rel1.offset: -10 0;
+ rel2.offset: 9 9;
+ }
+ description {
+ state: "hidden" 0.0;
+ inherit: "default" 0.0;
+ visible: 0;
+ }
+ }
+ part {
+ name: "base";
+ mouse_events: 0;
+ scale: 1;
+ clip_to: "clip";
+ description {
+ state: "default" 0.0;
+ min: 2 2;
+ align: 0.5 1.0;
+ color: 0 0 0 0;
+ }
+ }
+ part {
+ name: "glow";
+ type: RECT;
+ mouse_events: 0;
+ scale: 1;
+ clip_to: "clip2";
+ description {
+ state: "default" 0.0;
+ min: 4 0;
+ fixed: 1 0;
+ align: 0.5 0.5;
+ rel1 {
+ relative: 0.0 0.0;
+ offset: 0 2;
+ }
+ rel2 {
+ relative: 0.0 1.0;
+ offset: 0 -2;
+ }
+ color: 42 137 194 255;
+ }
+ description {
+ state: "hidden" 0.0;
+ inherit: "default" 0.0;
+ color: 0 0 0 0;
+ }
+ }
+ }
+ programs {
+ program {
+ name: "show";
+ action: STATE_SET "hidden" 0.0;
+ in: 0.6 0.0;
+ target: "glow";
+ after: "show4";
+ }
+ program {
+ name: "show4";
+ action: STATE_SET "default" 0.0;
+ in: 0.6 0.0;
+ target: "glow";
+ after: "show";
+ }
+ program {
+ name: "focused";
+ signal: "elm,action,focus";
+ source: "elm";
+ action: STATE_SET "focused" 0.0;
+ target: "clip2";
+ after: "show4";
+ }
+ program {
+ name: "unfocused";
+ signal: "elm,action,unfocus";
+ source: "elm";
+ action: STATE_SET "default" 0.0;
+ target: "clip2";
+ after: "stop_glow";
+ }
+ program {
+ name: "stop_glow";
+ action: ACTION_STOP;
+ target: "show";
+ target: "show4";
+ }
+ }
+ }
+ group { name: "elm/entry/selection/default";
+ parts {
+ part {
+ name: "bg";
+ type: RECT;
+ scale: 1;
+ mouse_events: 0;
+ description {
+ state: "default" 0.0;
+ color: 138 183 223 128;
+ }
+ }
+ }
+ }
+ group {
+ name: "elm/entry/selection/block_handle";
+ data.item: "position" "BOTH";
+ parts {
+ part {
+ name: "bg";
+ type: RECT;
+ scale: 1;
+ mouse_events: 1;
+ description {
+ state: "default" 0.0;
+ visible: 1;
+ fixed: 1 1;
+ align: 0.5 0.25;
+ min: 50 80;
+ color: 0 0 0 0;
+ }
+ }
+ part {
+ name: "handle";
+ mouse_events: 1;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ visible: 0;
+ fixed: 1 1;
+ align: 0.5 0.0;
+ min: 48 66;
+ rel1 {
+ relative: 0.0 0.0;
+ offset: 0 0;
+ }
+ rel2 {
+ relative: 0.0 0.0;
+ offset: 0 0;
+ }
+ image {
+ border: 0 0 0 0;
+ }
+ image.middle: SOLID;
+ fill.smooth: 0;
+ }
+ description {
+ state: "show" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ }
+ }
+ programs {
+ program {
+ name: "focused";
+ signal: "elm,action,focus";
+ source: "elm";
+ action: STATE_SET "show" 0.0;
+ target: "handle";
+ }
+ program {
+ name: "unfocused";
+ signal: "elm,action,unfocus";
+ source: "elm";
+ action: STATE_SET "default" 0.0;
+ target: "handle";
+ }
+ }
+ }
+ group {
+ name: "elm/entry/selection/block_handle_top";
+ data.item: "position" "BOTH";
+ parts {
+ part {
+ name: "bg";
+ type: RECT;
+ scale: 1;
+ mouse_events: 1;
+ description {
+ state: "default" 0.0;
+ visible: 1;
+ fixed: 1 1;
+ align: 0.5 0.75;
+ min: 50 80;
+ color: 0 0 0 0;
+ }
+ }
+ part {
+ name: "handle";
+ mouse_events: 1;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ visible: 0;
+ fixed: 1 1;
+ align: 0.5 1.0;
+ min: 48 66;
+ rel1 {
+ relative: 0.0 0.0;
+ offset: 0 0;
+ }
+ rel2 {
+ relative: 0.0 0.0;
+ offset: 0 0;
+ }
+ image {
+ border: 0 0 0 0;
+ }
+ image.middle: SOLID;
+ fill.smooth: 0;
+ }
+ description {
+ state: "show" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ }
+ }
+ programs {
+ program {
+ name: "focused";
+ signal: "elm,action,focus";
+ source: "elm";
+ action: STATE_SET "show" 0.0;
+ target: "handle";
+ }
+ program {
+ name: "unfocused";
+ signal: "elm,action,unfocus";
+ source: "elm";
+ action: STATE_SET "default" 0.0;
+ target: "handle";
+ }
+ }
+ }
+ group {
+ name: "elm/entry/anchor/default";
+ parts {
+ part {
+ name: "bg";
+ type: RECT;
+ scale: 1;
+ mouse_events: 0;
+ description {
+ state: "default" 0.0;
+ color: 128 0 0 64;
+ }
+ }
+ }
+ }
+}
diff --git a/lock_pwd/res/edje/lock_pwd.edc b/lock_pwd/res/edje/lock_pwd.edc
new file mode 100755
index 0000000..0f974f3
--- /dev/null
+++ b/lock_pwd/res/edje/lock_pwd.edc
@@ -0,0 +1,120 @@
+/*
+ * Copyright (c) 2009-2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#define WIN_WIDTH 720
+#define WIN_HEIGHT 1280
+
+#define INDICATOR_HEIGHT 52
+
+/* simple password */
+#define HELP_TEXT_AREA_HEIGHT 398
+#define KEYPAD_AREA_HEIGHT 592
+#define CONTROL_AREA_HEIGHT 184
+
+#define NUMBER_PANEL_DOT_WIDTH 32
+#define NUMBER_PANEL_DOT_HEIGHT NUMBER_PANEL_DOT_WIDTH
+#define NUMBER_PANEL_PADDING_LEFT 144
+#define NUMBER_PANEL_PADDING_RIGHT NUMBER_PANEL_PADDING_LEFT
+#define NUMBER_PANEL_WIDTH 96
+#define NUMBER_PANEL_HEIGHT NUMBER_PANEL_WIDTH
+#define NUMBER_PANEL_PADDING 16
+
+#define NUMBER_KEYPAD_PANEL_WIDTH WIN_WIDTH
+#define NUMBER_KEYPAD_PANEL_HEIGHT WIN_HEIGHT
+#define NUMBER_KEYPAD_BUTTON_WIDTH (WIN_WIDTH/3)
+#define NUMBER_KEYPAD_BUTTON_HEIGHT (KEYPAD_AREA_HEIGHT/4)
+#define NUMBER_KEYPAD_BUTTON_PAD_Y 10
+
+#define NUMBER_KEYPAD_REL_W(x) ((x)/NUMBER_KEYPAD_PANEL_WIDTH)
+#define NUMBER_KEYPAD_REL_H(y) ((y)/NUMBER_KEYPAD_PANEL_HEIGHT)
+#define NUMBER_KEYPAD_BUTTON_REL_W(x) ((x)/NUMBER_KEYPAD_BUTTON_WIDTH)
+#define NUMBER_KEYPAD_BUTTON_REL_H(y) ((y)/NUMBER_KEYPAD_BUTTON_HEIGHT)
+
+#define NUMBER_KEYPAD_NUM_SIZE 72
+#define NUMBER_KEYPAD_NUM_TEXT_SIZE 29
+
+/* simple password - button pressed color */
+#define LOCK_TEXT_COLOR 245 245 245 255
+#define LOCK_TEXT_COLOR2 0 0 0 0
+#define LOCK_TEXT_COLOR3 0 0 0 178
+#define BUTTON_PRESSED_COLOR 179 179 179 179
+
+/* complex password */
+#define LINE_COLOR "AO021"
+#define LINE_SHADOW_COLOR "AO017"
+#define INFO_FONT_COLOR "ATO033"
+#define PASS_FONT_COLOR "ATO035"
+#define PASS_FONT_SIZE 43
+#define INFO_FONT_SIZE 30
+
+#define IME_RESIZED 1
+#define IME_DOWN 2
+
+#define RETURN_TO_CALL_HEIGHT 46
+#define RETURN_TO_CALL_ICON_SIZE 46
+
+
+collections {
+ base_scale: 2.6;
+
+#include "lock_pwd_simple.edc"
+#include "lock_pwd_complex.edc"
+#include "lock_pwd_control_panel.edc"
+
+ group {
+ name: "lock_pwd";
+ parts {
+ part {
+ name: "bg";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ rel1 { relative: 0.0 0.0; }
+ rel2 { relative: 1.0 1.0; }
+ }
+ }
+ part {
+ name: "sw.bg";
+ type: SWALLOW;
+ description {
+ state: "default" 0.0;
+ rel1 { to: "bg"; }
+ rel2 { to: "bg"; }
+ }
+ }
+ part {
+ name: "dim.bg";
+ type: RECT;
+ description {
+ state: "default" 0.0;
+ color: 20 20 20 100;
+ rel1 { to: "bg"; }
+ rel2 { to: "bg"; }
+ }
+ }
+ part {
+ name: "sw.lock_pwd";
+ type: SWALLOW;
+ description {
+ state: "default" 0.0;
+ rel1 { to: "bg"; }
+ rel2 { to: "bg"; }
+ }
+ }
+ }
+ }
+
+}
diff --git a/lock_pwd/res/edje/lock_pwd_complex.edc b/lock_pwd/res/edje/lock_pwd_complex.edc
new file mode 100755
index 0000000..f484c47
--- /dev/null
+++ b/lock_pwd/res/edje/lock_pwd_complex.edc
@@ -0,0 +1,168 @@
+/*
+ * Copyright (c) 2009-2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+styles {
+ style {
+ name: "style_complex_title";
+ base: "font=Tizen:style=Regular color=#ffffffff color_class=ATO033 font_size=40 wrap=mixed align=center style=shadow shadow_color=#000000bf text_class=ATO033";
+ tag: "br" "\n";
+ tag: "hilight" "+ color=#ffff";
+ tag: "b" "+ color=#ffff";
+ tag: "tab" "\t";
+ }
+}
+
+ group {
+ name: "lock-complex-password";
+ images {
+ image: "ls_password_underline.#.png" COMP;
+ }
+ parts {
+ part {
+ name: "bg";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ }
+ }
+ part {
+ name: "padding.top.title";
+ type: SPACER;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ min: WIN_WIDTH 153;
+ max: WIN_WIDTH 153;
+ fixed: 1 1;
+ align: 0.5 0.0;
+ }
+ }
+ part {
+ name: "title";
+ type: TEXTBLOCK;
+ scale: 1;
+ effect: "SHADOW";
+ description {
+ state: "default" 0.0;
+ rel1 { relative: 0.0 1.0; to: "padding.top.title"; }
+ rel2 { relative: 1.0 1.0; to: "padding.top.title"; }
+ align: 0.5 0.0;
+ fixed: 1 1;
+ color_class: "ATO033";
+ text {
+ style: "style_simple_title";
+ min: 0 1;
+ align: 0.5 0.5;
+ text: "Enter PIN";
+ }
+ }
+ description {
+ state: "show_title" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ description {
+ state: "hide_title" 0.0;
+ inherit: "default" 0.0;
+ visible: 0;
+ }
+ }
+ part {
+ name: "padding.top.entry";
+ type: SPACER;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.5 0.0;
+ rel1 { relative: 0.0 0.0; to: "bg"; }
+ rel2 { relative: 1.0 0.0; to: "bg"; }
+ min: WIN_WIDTH (INDICATOR_HEIGHT+232);
+ max: WIN_WIDTH (INDICATOR_HEIGHT+232);
+ fixed: 1 1;
+ }
+ }
+ part {
+ name: "entry";
+ type: SWALLOW;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ rel1 { relative: 0.0 1.0; to : "padding.top.entry"; }
+ rel2 { relative: 1.0 1.0; to : "padding.top.entry"; }
+ min: (WIN_WIDTH-32-32) 70;
+ max: (WIN_WIDTH-32-32) 70;
+ fixed: 1 1;
+ align: 0.5 0.0;
+ }
+ }
+ part {
+ name: "underline";
+ type: IMAGE;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ fixed: 1 1;
+ rel1 { relative: 0.0 1.0; to: "entry"; offset: 0 10;}
+ rel2 { relative: 1.0 1.0; to: "entry"; offset: 0 10;}
+ min: 0 4;
+ max: -1 4;
+ image.normal: "ls_password_underline.#.png";
+ }
+ }
+ /* Bottom : changed by IME height */
+ part {
+ name: "spacer.bottom";
+ type: SPACER;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ min: WIN_WIDTH CONTROL_AREA_HEIGHT;
+ max: WIN_WIDTH CONTROL_AREA_HEIGHT;
+ fixed: 1 1;
+ align: 0.5 1.0;
+ rel1 { relative: 0.0 1.0; to: "bg"; }
+ rel2 { relative: 1.0 1.0; to: "bg"; }
+ }
+ }
+ part {
+ name: "control_panel";
+ type: SWALLOW;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.5 0.0;
+ rel1 { relative: 0.0 0.0; to: "spacer.bottom"; }
+ rel2 { relative: 1.0 1.0; to: "spacer.bottom"; }
+ }
+ }
+ } //parts
+ programs {
+ program {
+ name: "show.title";
+ signal: "show_title";
+ action: STATE_SET "show_title" 0.0;
+ source: "title";
+ target: "title";
+ }
+ program {
+ name: "hide.title";
+ signal: "hide_title";
+ action: STATE_SET "hide_title" 0.0;
+ source: "title";
+ target: "title";
+ }
+ } //programs
+ } //gorup
diff --git a/lock_pwd/res/edje/lock_pwd_control_panel.edc b/lock_pwd/res/edje/lock_pwd_control_panel.edc
new file mode 100644
index 0000000..c4415a5
--- /dev/null
+++ b/lock_pwd/res/edje/lock_pwd_control_panel.edc
@@ -0,0 +1,329 @@
+/*
+ * Copyright (c) 2009-2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+ styles {
+ style {
+ name: "btn_text_style";
+ base: "font=Tizen:style=Regular color=#FFFFFF font_size=32 wrap=none align=center";
+ }
+ }
+
+ group {
+ name: "lock-control-panel";
+ images {
+ image: "event_close_bg.#.png" COMP;
+ }
+ parts {
+ part {
+ name: "bg";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ }
+ }
+ part {
+ name: "padding.top";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ rel1 { relative: 0.0 0.0; to: "bg"; }
+ rel2 { relative: 1.0 0.0; to: "bg"; }
+ }
+ }
+ part {
+ name: "padding.left";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ rel1 { relative: 0.0 0.0; to: "bg"; }
+ rel2 { relative: 38/WIN_WIDTH 1.0; to: "bg"; }
+ }
+ }
+ part {
+ name: "padding.right";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ rel1 { relative: (WIN_WIDTH-50)/WIN_WIDTH 0.0; to: "bg"; }
+ rel2 { relative: 1.0 1.0; to: "bg"; }
+ }
+ }
+ part {
+ name: "padding.bottom";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ rel1 { relative: 0.0 (CONTROL_AREA_HEIGHT-42)/CONTROL_AREA_HEIGHT; to: "bg"; }
+ rel2 { relative: 1.0 1.0; to: "bg"; }
+ }
+ }
+
+ /* Return to Call*/
+ part {
+ name: "sw.btn.return_to_call";
+ type: SWALLOW;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.0 1.0;
+ min: 1 46;
+ rel1 { relative: 1.0 0.0; to_x: "padding.left"; to_y: "padding.btn"; }
+ rel2 { relative: 0.0 0.0; to_x: "btn.cancel"; to_y: "padding.btn"; }
+ }
+ }
+
+ part {
+ name: "padding.btn";
+ type: SPACER;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.0 1.0;
+ min: WIN_WIDTH 16;
+ max: WIN_WIDTH 16;
+ rel1 { relative: 0.0 0.0; to_x: "bg"; to_y: "sw.btn.plmn"; }
+ rel2 { relative: 1.0 0.0; to_x: "bg"; to_y: "sw.btn.plmn"; }
+ }
+ }
+
+ /* PLMN-SPN */
+ part {
+ name: "sw.btn.plmn";
+ type: SWALLOW;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.0 1.0;
+ min: 1 46;
+ rel1 { relative: 1.0 0.0; to_x: "padding.left"; to_y: "padding.bottom"; }
+ rel2 { relative: 0.0 0.0; to_x: "btn.cancel"; to_y: "padding.bottom"; }
+ }
+ }
+
+ /* Cancel */
+ part {
+ name: "rect.cancel.btn";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ align: 1.0 1.0;
+ rel1 { to: "txt.cancel"; }
+ rel2 { to: "txt.cancel"; }
+ }
+ }
+ part {
+ name: "txt.cancel";
+ type: TEXTBLOCK;
+ scale: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ align: 1.0 1.0;
+ rel1 { relative: 0.0 0.0; to_x: "padding.right"; to_y: "padding.bottom"; }
+ rel2 { relative: 0.0 0.0; to_x: "padding.right"; to_y: "padding.bottom"; }
+ text {
+ style: "btn_text_style";
+ min: 1 1;
+ ellipsis: -1;
+ align: 0.5 0.5;
+ text: "CANCEL";
+ }
+ }
+ }
+ part {
+ name: "btn.cancel";
+ type: IMAGE;
+ description {
+ state: "default" 0.0;
+ align: 1.0 0.0;
+ rel1 { to: "txt.cancel"; offset: -10 0; }
+ rel2 { to: "txt.cancel"; offset: 10 0; }
+ image {
+ normal: "event_close_bg.#.png";
+ }
+ color: 100 100 100 100;
+ }
+ description {
+ state: "press" 0.0;
+ inherit: "default" 0.0;
+ color: 50 50 50 50;
+ }
+ description {
+ state: "show" 0.0;
+ inherit: "default" 0.0;
+ color: 178 178 178 178;
+ }
+ }
+ part {
+ name: "btn.cancel.block";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 0;
+ description {
+ state: "default" 0.0;
+ rel1 { to: "btn.cancel"; }
+ rel2 { to: "btn.cancel"; }
+ color: 0 0 0 0;
+ visible: 0;
+ }
+ description {
+ state: "show" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ }
+ }
+ programs {
+ program {
+ signal: "btn,cancel,enable";
+ source: "prog";
+ action: STATE_SET "default" 0.0;
+ target: "btn.cancel.block";
+ target: "btn.cancel";
+ }
+ program {
+ signal: "btn,cancel,disable";
+ source: "prog";
+ action: STATE_SET "show" 0.0;
+ target: "btn.cancel.block";
+ target: "btn.cancel";
+ }
+ program {
+ name: "btn,cancel,press";
+ signal: "mouse,down,1";
+ source: "btn.cancel";
+ action: STATE_SET "press" 0.0;
+ target: "btn.cancel";
+ }
+ program {
+ name: "btn,cancel,release";
+ signal: "mouse,up,1";
+ source: "btn.cancel";
+ action: STATE_SET "default" 0.0;
+ target: "btn.cancel";
+ }
+ program {
+ name: "btn,cancel,clicked";
+ signal: "mouse,clicked,1";
+ source: "btn.cancel";
+ action: SIGNAL_EMIT "btn,cancel,clicked" "btn.cancel";
+ }
+ }
+ }
+
+ group {
+ name: "btn-return-to-call";
+ images {
+ image: "ls_icon_call.png" COMP;
+ }
+ parts {
+ part {
+ name: "bg";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ }
+ }
+ part {
+ name: "img.call.icon";
+ type: IMAGE;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.0 0.0;
+ min: RETURN_TO_CALL_ICON_SIZE RETURN_TO_CALL_ICON_SIZE;
+ max: RETURN_TO_CALL_ICON_SIZE RETURN_TO_CALL_ICON_SIZE;
+ rel1 { relative: 0.0 0.0; to: "bg"; }
+ rel2 { relative: 0.0 0.0; to: "bg"; }
+ image {
+ normal: "ls_icon_call.png";
+ }
+ }
+ }
+ part {
+ name: "padding.icon";
+ type: SPACER;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.0 0.0;
+ min: 10 RETURN_TO_CALL_HEIGHT;
+ max: 10 RETURN_TO_CALL_HEIGHT;
+ rel1 { relative: 1.0 0.0; to_x: "img.call.icon"; to_y: "bg"; }
+ rel2 { relative: 1.0 1.0; to_x: "img.call.icon"; to_y: "bg"; }
+ }
+ }
+ part {
+ name: "txt.return_to_call";
+ type: TEXTBLOCK;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.0 0.0;
+ rel1 { relative: 1.0 0.0; to_x: "padding.icon"; to_y: "bg"; }
+ rel2 { relative: 1.0 1.0; to_x: "padding.icon"; to_y: "bg"; }
+ text {
+ style: "btn_text_style";
+ min: 1 1;
+ ellipsis: -1;
+ align: 0.0 0.5;
+ text: "Return to call";
+ }
+ }
+ }
+ part {
+ name: "btn.return_to_call";
+ type: RECT;
+ mouse_events: 1;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ align: 0.0 0.0;
+ color: 0 0 0 0;
+ rel1 { relative: 0.0 0.0; to_x: "img.call.icon"; to_y: "bg"; }
+ rel2 { relative: 1.0 1.0; to_x: "txt.return_to_call"; to_y: "bg"; }
+ }
+ description {
+ state: "press" 0.0;
+ inherit: "default" 0.0;
+ color: 50 50 50 50;
+ }
+ }
+ }
+ programs {
+ program {
+ name: "btn,return_to_call,press";
+ signal: "mouse,down,1";
+ source: "btn.return_to_call";
+ action: STATE_SET "press" 0.0;
+ target: "btn.return_to_call";
+ }
+ program {
+ name: "btn,return_to_call,release";
+ signal: "mouse,up,1";
+ source: "btn.return_to_call";
+ action: STATE_SET "default" 0.0;
+ target: "btn.return_to_call";
+ }
+ program {
+ name: "btn,return_to_call,clicked";
+ signal: "mouse,clicked,1";
+ source: "btn.return_to_call";
+ action: SIGNAL_EMIT "btn,return_to_call,clicked" "btn.return_to_call";
+ }
+ }
+ }
diff --git a/lock_pwd/res/edje/lock_pwd_simple.edc b/lock_pwd/res/edje/lock_pwd_simple.edc
new file mode 100755
index 0000000..759435b
--- /dev/null
+++ b/lock_pwd/res/edje/lock_pwd_simple.edc
@@ -0,0 +1,452 @@
+/*
+ * Copyright (c) 2009-2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#define PART_KEYPAD_BUTTON_NUMBER(keypad_button, offx, offy, button_number, button_text) \
+ part { \
+ name: keypad_button; \
+ type: RECT; \
+ mouse_events: 1; \
+ repeat_events: 1; \
+ description { \
+ state: "default" 0.0; \
+ color: 0 0 0 0; \
+ fixed: 1 1; \
+ rel1 { relative: NUMBER_KEYPAD_REL_W(offx) NUMBER_KEYPAD_REL_H(WIN_HEIGHT-CONTROL_AREA_HEIGHT-KEYPAD_AREA_HEIGHT+offy); to:"bg";} \
+ rel2 { relative: NUMBER_KEYPAD_REL_W(offx+NUMBER_KEYPAD_BUTTON_WIDTH) NUMBER_KEYPAD_REL_H(WIN_HEIGHT-CONTROL_AREA_HEIGHT-KEYPAD_AREA_HEIGHT+offy+NUMBER_KEYPAD_BUTTON_HEIGHT); to:"bg"; } \
+ } \
+ description { \
+ state: "pressed" 0.0; \
+ inherit: "default" 0.0; \
+ color: BUTTON_PRESSED_COLOR; \
+ } \
+ description { \
+ state: "hide" 0.0; \
+ visible: 0; \
+ } \
+ } \
+ part { \
+ name: keypad_button"_feedback"; \
+ type: RECT; \
+ repeat_events: 1; \
+ description { \
+ state: "default" 0.0; \
+ fixed: 1 1; \
+ color: BUTTON_PRESSED_COLOR; \
+ visible: 0; \
+ rel1.to: keypad_button; \
+ rel2.to: keypad_button; \
+ } \
+ description { \
+ state: "pressed" 0.0; \
+ inherit: "default" 0.0; \
+ visible: 1; \
+ } \
+ } \
+ part { \
+ name: keypad_button"_number"; \
+ type: TEXT; \
+ scale: 1; \
+ effect: "SHADOW"; \
+ mouse_events: 0; \
+ repeat_events: 1; \
+ description { \
+ state: "default" 0.0; \
+ fixed: 1 1; \
+ align: 0.5 0.5; \
+ color_class: PASS_KEY_NUM_COLOR; \
+ visible: 1; \
+ rel1 { relative: 0.0 (17)/NUMBER_KEYPAD_BUTTON_HEIGHT; to: keypad_button;} \
+ rel2 { relative: 1.0 (17+81)/NUMBER_KEYPAD_BUTTON_HEIGHT; to: keypad_button;} \
+ text { \
+ align: 0.5 0.5; \
+ size: NUMBER_KEYPAD_NUM_SIZE; \
+ text: button_number; \
+ font: "Tizen:style=SNum-3L"; \
+ text_class: "tizen"; \
+ } \
+ } \
+ description { \
+ state: "hide" 0.0; \
+ inherit: "default" 0.0; \
+ visible: 0; \
+ } \
+ description { \
+ state: "center" 0.0; \
+ inherit: "default" 0.0; \
+ align: 0.5 0.5; \
+ rel1 { relative: 0.0 0.0; to: keypad_button;} \
+ rel2 { relative: 1.0 1.0; to: keypad_button;} \
+ text { \
+ align: 0.5 0.5; \
+ size: NUMBER_KEYPAD_NUM_SIZE; \
+ text: button_number; \
+ font: "Tizen:style=SNum-3L"; \
+ text_class: "tizen"; \
+ } \
+ } \
+ } \
+ part { \
+ name: keypad_button"_text"; \
+ type: TEXT; \
+ scale: 1; \
+ effect: "SHADOW"; \
+ mouse_events: 0; \
+ repeat_events: 1; \
+ description { \
+ state: "default" 0.0; \
+ visible: 1; \
+ fixed: 1 1; \
+ align: 0.5 0.5; \
+ color_class: PASS_KEY_SUB_COLOR; \
+ rel1 { relative: 0.0 (17+81)/NUMBER_KEYPAD_BUTTON_HEIGHT; to: keypad_button;} \
+ rel2 { relative: 1.0 (17+81+24)/NUMBER_KEYPAD_BUTTON_HEIGHT; to: keypad_button;} \
+ text { \
+ size: NUMBER_KEYPAD_NUM_TEXT_SIZE; \
+ text: button_text; \
+ align: 0.5 0.5; \
+ font: "Tizen:style=Regular"; \
+ text_class: "tizen"; \
+ } \
+ } \
+ description { \
+ state: "hide" 0.0; \
+ inherit: "default" 0.0; \
+ visible: 0; \
+ } \
+ }
+
+#define PROG_KEYPAD_BUTTON(keypad_button) \
+ program { \
+ name: "down_"keypad_button; \
+ signal: "mouse,down,*"; \
+ source: keypad_button; \
+ script { \
+ set_state(PART:keypad_button"_feedback", "pressed", 0.0); \
+ emit("keypad_down", keypad_button); \
+ } \
+ } \
+ program { \
+ name: "multi_down_"keypad_button; \
+ signal: "multi_down_"keypad_button; \
+ source: keypad_button; \
+ script { \
+ set_state(PART:keypad_button"_feedback", "pressed", 0.0); \
+ emit("keypad_down", keypad_button); \
+ } \
+ } \
+ program { \
+ name: "ani_"keypad_button; \
+ signal: "ani"; \
+ source: keypad_button; \
+ action: STATE_SET "default" 0.0; \
+ transition: SINUSOIDAL 0.05; \
+ target: keypad_button"_feedback"; \
+ } \
+ program { \
+ name: "up_"keypad_button; \
+ signal: "mouse,up,1"; \
+ source: keypad_button; \
+ script { \
+ emit("keypad_down_up", keypad_button); \
+ emit("ani", keypad_button); \
+ } \
+ } \
+ program { \
+ name: "multi_up_"keypad_button; \
+ signal: "multi_up_"keypad_button; \
+ source: keypad_button; \
+ script { \
+ emit("keypad_down_up", keypad_button); \
+ emit("ani", keypad_button); \
+ } \
+ } \
+ program { \
+ name: "clicked_"keypad_button; \
+ signal: "mouse,clicked,1"; \
+ source: keypad_button; \
+ script { \
+ emit("keypad_down_clicked", keypad_button); \
+ } \
+ } \
+ program { \
+ name: "multi_clicked_"keypad_button; \
+ signal: "multi_clicked_"keypad_button; \
+ source: keypad_button; \
+ script { \
+ emit("keypad_down_clicked", keypad_button); \
+ } \
+ } \
+
+#define PANEL_PART(idx) \
+ part { \
+ name: "panel"idx; \
+ type: TEXT; \
+ scale: 1; \
+ effect: "SHADOW"; \
+ description { \
+ state: "default" 0.0; \
+ fixed: 1 1; \
+ rel1 { relative: NUMBER_KEYPAD_REL_W(NUMBER_PANEL_PADDING_LEFT+(idx*(NUMBER_PANEL_WIDTH+NUMBER_PANEL_PADDING))) NUMBER_KEYPAD_REL_H(INDICATOR_HEIGHT+HELP_TEXT_AREA_HEIGHT-166+35); to: "bg"; } \
+ rel2 { relative: NUMBER_KEYPAD_REL_W(NUMBER_PANEL_PADDING_LEFT+(idx*(NUMBER_PANEL_WIDTH+NUMBER_PANEL_PADDING))+NUMBER_PANEL_WIDTH) NUMBER_KEYPAD_REL_H(INDICATOR_HEIGHT+HELP_TEXT_AREA_HEIGHT-166+35+NUMBER_PANEL_HEIGHT); to: "bg"; } \
+ text { \
+ size: 90; \
+ font: "Tizen:style=SNum-3L"; \
+ text_class: "tizen"; \
+ } \
+ visible: 0; \
+ } \
+ description { \
+ state: "show" 0.0; \
+ inherit: "default" 0.0; \
+ visible: 1; \
+ } \
+ } \
+ part { \
+ name: "dot"idx; \
+ type: IMAGE; \
+ scale: 1; \
+ description { \
+ state: "default" 0.0; \
+ fixed: 1 1; \
+ min: NUMBER_PANEL_DOT_WIDTH NUMBER_PANEL_DOT_HEIGHT; \
+ max: NUMBER_PANEL_DOT_WIDTH NUMBER_PANEL_DOT_HEIGHT; \
+ rel1 { to: "panel"idx; } \
+ rel2 { to: "panel"idx; } \
+ image { \
+ normal: "ls_pin_dot.png"; \
+ } \
+ visible: 0; \
+ } \
+ description { \
+ state: "show" 0.0; \
+ inherit: "default" 0.0; \
+ visible: 1; \
+ } \
+ } \
+
+#define INPUT_PROGRAM(idx) \
+ program { \
+ name: "input_show"idx; \
+ action: STATE_SET "show" 0.0; \
+ source: "keyboard"; \
+ signal: "input_show"idx; \
+ target: "panel"idx; \
+ } \
+ program { \
+ name: "input_hide"idx; \
+ action: STATE_SET "default" 0.0; \
+ source: "keyboard"; \
+ signal: "input_hide"idx; \
+ target: "panel"idx; \
+ } \
+ program { \
+ name: "dot_show"idx; \
+ action: STATE_SET "show" 0.0; \
+ source: "keyboard"; \
+ signal: "dot_show"idx; \
+ target: "dot"idx; \
+ after: "input_hide"idx; \
+ } \
+ program { \
+ name: "dot_hide"idx; \
+ action: STATE_SET "default" 0.0; \
+ source: "keyboard"; \
+ signal: "dot_hide"idx; \
+ target: "dot"idx; \
+ after: "input_hide"idx; \
+ } \
+
+
+#define PART_DBG(part_name, R, G, B, A) \
+ part { \
+ name: part_name",dbg"; \
+ type: RECT; \
+ mouse_events: 1; \
+ repeat_events: 1; \
+ description { \
+ state: "default" 0.0; \
+ rel1 { relative: 0.0 0.0; to: part_name; } \
+ rel2 { relative: 1.0 1.0; to: part_name; } \
+ color: R G B A; \
+ } \
+ } \
+
+styles {
+ style {
+ name: "style_simple_title";
+ base: "font=Tizen:style=Regular color=#ffffffff color_class=ATO030 font_size=40 wrap=mixed align=center style=shadow shadow_color=#000000bf text_class=ATO030";
+ tag: "br" "\n";
+ tag: "hilight" "+ color=#ffff";
+ tag: "b" "+ color=#ffff";
+ tag: "tab" "\t";
+ }
+}
+
+ group {
+ name: "lock-simple-password";
+ images {
+ image: "ls_pin_dot.png" COMP;
+ image: "ls_back_02_nor.png" COMP;
+ image: "ls_back_02_press.png" COMP;
+ }
+ parts {
+ part {
+ name: "bg";
+ type: SPACER;
+ description {
+ state: "default" 0.0;
+ }
+ }
+ part {
+ name: "title";
+ type: TEXTBLOCK;
+ scale: 1;
+ effect: "SHADOW";
+ description {
+ state: "default" 0.0;
+ rel1 { relative: 0.0 (INDICATOR_HEIGHT+HELP_TEXT_AREA_HEIGHT-166-25-54)/WIN_HEIGHT; to: "bg"; }
+ rel2 { relative: 1.0 (INDICATOR_HEIGHT+HELP_TEXT_AREA_HEIGHT-166-25)/WIN_HEIGHT; to: "bg"; }
+ fixed: 1 1;
+ color_class: "ATO033";
+ text {
+ style: "style_simple_title";
+ min: 0 1;
+ align: 0.5 0.5;
+ text: "Enter PIN";
+ }
+ }
+ description {
+ state: "show_title" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ description {
+ state: "hide_title" 0.0;
+ inherit: "default" 0.0;
+ visible: 0;
+ }
+ }
+
+ PANEL_PART(0)
+ PANEL_PART(1)
+ PANEL_PART(2)
+ PANEL_PART(3)
+
+ PART_KEYPAD_BUTTON_NUMBER("1", 0, 0, "1", "");
+ PART_KEYPAD_BUTTON_NUMBER("2", NUMBER_KEYPAD_BUTTON_WIDTH, 0, "2", "ABC");
+ PART_KEYPAD_BUTTON_NUMBER("3", 2*(NUMBER_KEYPAD_BUTTON_WIDTH), 0, "3", "DEF");
+ PART_KEYPAD_BUTTON_NUMBER("4", 0, NUMBER_KEYPAD_BUTTON_HEIGHT, "4", "GHI");
+ PART_KEYPAD_BUTTON_NUMBER("5", NUMBER_KEYPAD_BUTTON_WIDTH, NUMBER_KEYPAD_BUTTON_HEIGHT, "5", "JKL");
+ PART_KEYPAD_BUTTON_NUMBER("6", 2*(NUMBER_KEYPAD_BUTTON_WIDTH), NUMBER_KEYPAD_BUTTON_HEIGHT, "6", "MNO");
+ PART_KEYPAD_BUTTON_NUMBER("7", 0, 2*(NUMBER_KEYPAD_BUTTON_HEIGHT), "7", "PQRS");
+ PART_KEYPAD_BUTTON_NUMBER("8", NUMBER_KEYPAD_BUTTON_WIDTH, 2*(NUMBER_KEYPAD_BUTTON_HEIGHT), "8", "TUV");
+ PART_KEYPAD_BUTTON_NUMBER("9", 2*(NUMBER_KEYPAD_BUTTON_WIDTH), 2*(NUMBER_KEYPAD_BUTTON_HEIGHT), "9", "WXYZ");
+ PART_KEYPAD_BUTTON_NUMBER("0", NUMBER_KEYPAD_BUTTON_WIDTH, 3*(NUMBER_KEYPAD_BUTTON_HEIGHT), "0", "");
+
+ part {
+ name: "Backspace";
+ type: IMAGE;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ rel1 { relative: NUMBER_KEYPAD_REL_W(2*(NUMBER_KEYPAD_BUTTON_WIDTH)) NUMBER_KEYPAD_REL_H(WIN_HEIGHT-CONTROL_AREA_HEIGHT-KEYPAD_AREA_HEIGHT+3*(NUMBER_KEYPAD_BUTTON_HEIGHT)); to: "bg"; }
+ rel2 { relative: NUMBER_KEYPAD_REL_W(2*(NUMBER_KEYPAD_BUTTON_WIDTH)+NUMBER_KEYPAD_BUTTON_WIDTH) NUMBER_KEYPAD_REL_H(WIN_HEIGHT-CONTROL_AREA_HEIGHT-KEYPAD_AREA_HEIGHT+3*(NUMBER_KEYPAD_BUTTON_HEIGHT)+NUMBER_KEYPAD_BUTTON_HEIGHT); to: "bg"; }
+ fixed: 1 1;
+ image.normal: "ls_back_02_nor.png";
+ align: 0.5 0.5;
+ }
+ description {
+ state: "pressed" 0.0;
+ inherit: "default" 0.0;
+ image.normal: "ls_back_02_press.png";
+ }
+ }
+ part {
+ name: "Backspace_feedback";
+ type: RECT;
+ mouse_events: 1;
+ repeat_events: 1;
+ description {
+ state: "default" 0.0;
+ rel1 { to: "Backspace"; }
+ rel2 { to: "Backspace"; }
+ visible: 0;
+ color: BUTTON_PRESSED_COLOR;
+ }
+ description {
+ state: "pressed" 0.0;
+ inherit: "default" 0.0;
+ visible: 1;
+ }
+ description {
+ state: "hide" 0.0;
+ inherit: "default" 0.0;
+ }
+ }
+ /* Bottom */
+ part {
+ name: "control_panel";
+ type: SWALLOW;
+ description {
+ state: "default" 0.0;
+ rel1 { relative: 0.0 (WIN_HEIGHT-CONTROL_AREA_HEIGHT)/WIN_HEIGHT; to: "bg"; }
+ rel2 { relative: 1.0 1.0; to: "bg"; }
+ }
+ }
+ }
+ programs {
+ program {
+ name: "init.layout";
+ signal: "load";
+ source: "";
+ script {
+ set_state(PART:"0_number", "center", 0.0);
+ }
+ }
+
+ INPUT_PROGRAM(0)
+ INPUT_PROGRAM(1)
+ INPUT_PROGRAM(2)
+ INPUT_PROGRAM(3)
+
+ PROG_KEYPAD_BUTTON("1")
+ PROG_KEYPAD_BUTTON("2")
+ PROG_KEYPAD_BUTTON("3")
+ PROG_KEYPAD_BUTTON("4")
+ PROG_KEYPAD_BUTTON("5")
+ PROG_KEYPAD_BUTTON("6")
+ PROG_KEYPAD_BUTTON("7")
+ PROG_KEYPAD_BUTTON("8")
+ PROG_KEYPAD_BUTTON("9")
+ PROG_KEYPAD_BUTTON("0")
+ PROG_KEYPAD_BUTTON("Backspace")
+ }
+ program {
+ name: "show.title";
+ signal: "show_title";
+ action: STATE_SET "show_title" 0.0;
+ source: "title";
+ target: "title";
+ }
+ program {
+ name: "hide.title";
+ signal: "hide_title";
+ action: STATE_SET "hide_title" 0.0;
+ source: "title";
+ target: "title";
+ }
+ }
+
diff --git a/lock_pwd/src/lock_pwd_complex.c b/lock_pwd/src/lock_pwd_complex.c
new file mode 100644
index 0000000..dd70267
--- /dev/null
+++ b/lock_pwd/src/lock_pwd_complex.c
@@ -0,0 +1,397 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <Elementary.h>
+#include <Ecore.h>
+
+#include "lock_mgr.h"
+#include "util.h"
+#include "lock_pwd_util.h"
+#include "lock_pwd_complex.h"
+#include "lock_pwd_control_panel.h"
+
+#define MAX_COMPLEX_PASSWORD_NUM 16
+#define LOCK_PWD_ENTRY_EDJE_FILE "/usr/share/starter/lock_pwd/res/edje/lock_entry.edj"
+
+static struct _s_lock_pwd_complex {
+ Evas_Object *pwd_complex_layout;
+ Evas_Object *pwd_complex_entry;
+
+ Eina_Bool is_blocked;
+ Ecore_Timer *timer_pin;
+ Elm_Theme *entry_theme;
+ int pin_time_remain;
+} s_lock_pwd_complex = {
+ .pwd_complex_layout = NULL,
+ .pwd_complex_entry = NULL,
+
+ .is_blocked = EINA_FALSE,
+ .timer_pin = NULL,
+ .entry_theme = NULL,
+ .pin_time_remain = PASSWORD_BLOCK_SECONDS,
+};
+
+
+
+
+Eina_Bool lock_pwd_complex_is_blocked_get(void)
+{
+ return s_lock_pwd_complex.is_blocked;
+}
+
+static void _pwd_complex_layout_title_set(const char *title)
+{
+ ret_if(!s_lock_pwd_complex.pwd_complex_layout);
+ ret_if(!title);
+
+ elm_object_part_text_set(s_lock_pwd_complex.pwd_complex_layout, "title", title);
+}
+
+
+
+void lock_pwd_complex_entry_clear(void)
+{
+ ret_if(!s_lock_pwd_complex.pwd_complex_entry);
+
+ elm_entry_entry_set(s_lock_pwd_complex.pwd_complex_entry, "");
+}
+
+
+
+static Eina_Bool _pwd_complex_entry_clear(void *data)
+{
+ lock_pwd_complex_entry_clear();
+ return ECORE_CALLBACK_CANCEL;
+}
+
+
+
+static void _pwd_complex_lock_time_init(void)
+{
+ if (vconf_set_str(VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR, "") < 0) {
+ _E("Failed to set vconfkey : %s", VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR);
+ }
+}
+
+
+
+static void _pwd_complex_lock_time_save(void)
+{
+ time_t cur_time = time(NULL);
+ char buf[64] = { 0, };
+ snprintf(buf, sizeof(buf), "%ld", cur_time);
+ if (vconf_set_str(VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR, buf) < 0) {
+ _E("Failed to set vconfkey : %s", VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR);
+ }
+}
+
+
+
+static void _pwd_complex_event_correct(lock_pwd_event_e event)
+{
+ _D("%s", __func__);
+
+ lock_pwd_util_win_hide();
+ lock_pwd_complex_entry_clear();
+ _pwd_complex_layout_title_set(_("IDS_COM_BODY_ENTER_PASSWORD"));
+
+ lock_mgr_idle_lock_state_set(VCONFKEY_IDLE_UNLOCK);
+ lock_mgr_sound_play(LOCK_SOUND_UNLOCK);
+}
+
+
+
+static void _pwd_complex_event_incorrect(lock_pwd_event_e event)
+{
+ char temp_str[BUF_SIZE_256] = { 0, };
+ char temp_left[BUF_SIZE_256] = { 0, };
+ int remain_attempt = 0;
+
+ remain_attempt = lock_pwd_verification_remain_attempt_get();
+ _D("remain_attempt(%d)", remain_attempt);
+
+ if (remain_attempt == 1) {
+ strncpy(temp_left, _("IDS_IDLE_BODY_1_ATTEMPT_LEFT"), sizeof(temp_left));
+ temp_left[sizeof(temp_left) - 1] = '\0';
+ } else {
+ snprintf(temp_left, sizeof(temp_left), _("IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"), remain_attempt);
+ }
+ snprintf(temp_str, sizeof(temp_str), "%s<br>%s", _("IDS_IDLE_BODY_INCORRECT_PASSWORD"), temp_left);
+ _pwd_complex_layout_title_set(temp_str);
+
+ ecore_timer_add(0.1, _pwd_complex_entry_clear, NULL);
+
+ lock_pwd_verification_popup_create(event);
+}
+
+
+
+static Eina_Bool _wrong_pwd_wait_timer_cb(void *data)
+{
+ char try_again_buf[BUF_SIZE_256] = { 0, };
+ char incorrect_pass_buf[BUF_SIZE_256] = { 0, };
+
+ retv_if(!s_lock_pwd_complex.pwd_complex_layout, ECORE_CALLBACK_CANCEL);
+
+ snprintf(try_again_buf, sizeof(try_again_buf), _("IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"), s_lock_pwd_complex.pin_time_remain);
+ snprintf(incorrect_pass_buf, sizeof(incorrect_pass_buf), "%s<br>%s", _("IDS_IDLE_BODY_INCORRECT_PASSWORD"), try_again_buf);
+ _pwd_complex_layout_title_set(incorrect_pass_buf);
+
+ if (s_lock_pwd_complex.pin_time_remain == PASSWORD_BLOCK_SECONDS ||
+ s_lock_pwd_complex.pin_time_remain > 0) {
+ s_lock_pwd_complex.pin_time_remain--;
+ return ECORE_CALLBACK_RENEW;
+ } else {
+ lock_pwd_complex_view_init();
+
+ int lcd_state = lock_mgr_lcd_state_get();
+ if (lcd_state == LCD_STATE_OFF) {
+ if (!lock_mgr_lockscreen_launch()) {
+ _E("Failed to launch lockscreen");
+ }
+ }
+ }
+
+ return ECORE_CALLBACK_CANCEL;
+}
+
+
+
+static void _pwd_complex_event_input_block(lock_pwd_event_e event)
+{
+ _D("%s", __func__);
+
+ int block_sec = PASSWORD_BLOCK_SECONDS;
+ char try_again_buf[BUF_SIZE_256] = { 0, };
+ char incorrect_pass_buf[BUF_SIZE_256] = { 0, };
+
+ ret_if(!s_lock_pwd_complex.pwd_complex_layout);
+
+ _pwd_complex_lock_time_save();
+
+ snprintf(try_again_buf, sizeof(try_again_buf), _("IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"), block_sec);
+ snprintf(incorrect_pass_buf, sizeof(incorrect_pass_buf), "%s<br>%s", _("IDS_IDLE_BODY_INCORRECT_PASSWORD"), try_again_buf);
+ _pwd_complex_layout_title_set(incorrect_pass_buf);
+
+ s_lock_pwd_complex.is_blocked = EINA_TRUE;
+
+ if (s_lock_pwd_complex.timer_pin) {
+ ecore_timer_del(s_lock_pwd_complex.timer_pin);
+ s_lock_pwd_complex.timer_pin = NULL;
+ }
+
+ s_lock_pwd_complex.timer_pin = ecore_timer_add(1.0, _wrong_pwd_wait_timer_cb, NULL);
+
+ ecore_timer_add(0.1, _pwd_complex_entry_clear, NULL);
+
+ lock_pwd_verification_popup_create(event);
+
+ lock_pwd_control_panel_cancel_btn_enable_set(EINA_FALSE);
+}
+
+
+
+void lock_pwd_complex_event(lock_pwd_event_e event)
+{
+ switch(event) {
+ case PWD_EVENT_CORRECT:
+ _pwd_complex_event_correct(event);
+ break;
+ case PWD_EVENT_INCORRECT_WARNING:
+ case PWD_EVENT_INCORRECT:
+ _pwd_complex_event_incorrect(event);
+ break;
+ case PWD_EVENT_INPUT_BLOCK_WARNING:
+ case PWD_EVENT_INPUT_BLOCK:
+ _pwd_complex_event_input_block(event);
+ break;
+ case PWD_EVENT_EMPTY:
+ break;
+ case PWD_EVENT_OVER:
+ break;
+ default:
+ break;
+ }
+}
+
+
+
+static void _pwd_complex_enter_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ char buf[BUF_SIZE_256] = { 0, };
+ char *markup_txt = NULL;
+
+ ret_if(!obj);
+
+ const char *password = elm_entry_entry_get(obj);
+ ret_if(!password);
+
+ markup_txt = elm_entry_utf8_to_markup(password);
+ snprintf(buf, sizeof(buf), "%s", markup_txt);
+ free(markup_txt);
+
+ lock_pwd_event_e pwd_event = lock_pwd_verification_verify(buf);
+ lock_pwd_complex_event(pwd_event);
+}
+
+
+
+static void _pwd_complex_entry_customize(Evas_Object *entry)
+{
+ static Elm_Entry_Filter_Limit_Size limit_filter_data_alpha;
+ Elm_Theme *th = elm_theme_new();
+ ret_if(!th);
+
+ elm_theme_ref_set(th, NULL);
+ elm_theme_extension_add(th, LOCK_PWD_ENTRY_EDJE_FILE);
+ elm_object_theme_set(entry, th);
+ elm_object_style_set(entry, "lockscreen_complex_password_style");
+ limit_filter_data_alpha.max_char_count = MAX_COMPLEX_PASSWORD_NUM;
+ limit_filter_data_alpha.max_byte_count = 0;
+ elm_entry_markup_filter_append(entry, elm_entry_filter_limit_size, &limit_filter_data_alpha);
+
+ s_lock_pwd_complex.entry_theme = th;
+}
+
+
+
+Evas_Object *_pwd_complex_entry_create(void *data)
+{
+ Evas_Object *parent = NULL;
+ Evas_Object *entry = NULL;
+
+ parent = (Evas_Object *)data;
+ retv_if(!parent, NULL);
+
+ entry = elm_entry_add(parent);
+ retv_if(!entry, NULL);
+
+ _pwd_complex_entry_customize(entry);
+
+ elm_entry_single_line_set(entry, EINA_TRUE);
+ elm_entry_password_set(entry, EINA_TRUE);
+ elm_entry_entry_set(entry, "");
+ elm_entry_cursor_end_set(entry);
+ elm_entry_cnp_mode_set(entry, ELM_CNP_MODE_PLAINTEXT);
+ elm_entry_input_panel_layout_set(entry, ELM_INPUT_PANEL_LAYOUT_PASSWORD);
+ elm_entry_input_panel_imdata_set(entry, "type=lockscreen", 15);
+ elm_entry_input_panel_return_key_type_set(entry, ELM_INPUT_PANEL_RETURN_KEY_TYPE_DONE);
+
+ evas_object_smart_callback_add(entry, "activated", _pwd_complex_enter_cb, NULL);
+
+ evas_object_show(entry);
+
+ return entry;
+}
+
+
+
+Evas_Object *lock_pwd_complex_layout_create(void *data)
+{
+ Evas_Object *parent = NULL;
+ Evas_Object *pwd_complex_layout = NULL;
+ Evas_Object *pwd_complex_entry = NULL;
+ Evas_Object *pwd_control_panel = NULL;
+
+ lock_pwd_verification_policy_create();
+
+ parent = (Evas_Object *)data;
+ retv_if(!parent, NULL);
+
+ pwd_complex_layout = elm_layout_add(parent);
+ goto_if(!pwd_complex_layout, ERROR);
+ s_lock_pwd_complex.pwd_complex_layout = pwd_complex_layout;
+
+ if (!elm_layout_file_set(pwd_complex_layout, LOCK_PWD_EDJE_FILE, "lock-complex-password")) {
+ _E("Failed to set edje file : %s", LOCK_PWD_EDJE_FILE);
+ goto ERROR;
+ }
+
+ evas_object_size_hint_weight_set(pwd_complex_layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(pwd_complex_layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ evas_object_show(pwd_complex_layout);
+
+ /* create entry */
+ pwd_complex_entry = _pwd_complex_entry_create(pwd_complex_layout);
+ goto_if(!pwd_complex_entry, ERROR);
+ s_lock_pwd_complex.pwd_complex_entry = pwd_complex_entry;
+
+ elm_object_part_content_set(pwd_complex_layout, "entry", pwd_complex_entry);
+
+ _pwd_complex_layout_title_set(_("IDS_COM_BODY_ENTER_PASSWORD"));
+
+ /* create control panel */
+ pwd_control_panel = lock_pwd_control_panel_create(pwd_complex_layout);
+ if (pwd_control_panel) {
+ elm_object_part_content_set(pwd_complex_layout, "control_panel", pwd_control_panel);
+ } else {
+ _E("Failed to create password control panel");
+ }
+
+ evas_object_show(pwd_complex_layout);
+
+ return pwd_complex_layout;
+
+ERROR:
+ _E("Failed to create complex password layout");
+
+ if (pwd_complex_layout) {
+ evas_object_del(pwd_complex_layout);
+ s_lock_pwd_complex.pwd_complex_layout = NULL;
+ }
+
+ return NULL;
+}
+
+
+void lock_pwd_complex_layout_destroy(void)
+{
+ if (s_lock_pwd_complex.timer_pin) {
+ ecore_timer_del(s_lock_pwd_complex.timer_pin);
+ s_lock_pwd_complex.timer_pin = NULL;
+ }
+
+ if (s_lock_pwd_complex.entry_theme) {
+ elm_theme_free(s_lock_pwd_complex.entry_theme);
+ s_lock_pwd_complex.entry_theme = NULL;
+ }
+
+ if (s_lock_pwd_complex.pwd_complex_entry) {
+ evas_object_del(s_lock_pwd_complex.pwd_complex_entry);
+ s_lock_pwd_complex.pwd_complex_entry = NULL;
+ }
+
+ if (s_lock_pwd_complex.pwd_complex_layout) {
+ evas_object_del(s_lock_pwd_complex.pwd_complex_layout);
+ s_lock_pwd_complex.pwd_complex_layout = NULL;
+ }
+}
+
+
+
+void lock_pwd_complex_view_init(void)
+{
+ _D("initialize complex password values");
+ _pwd_complex_layout_title_set(_("IDS_COM_BODY_ENTER_PASSWORD"));
+ elm_object_signal_emit(s_lock_pwd_complex.pwd_complex_layout, "show_title", "title");
+ s_lock_pwd_complex.is_blocked = EINA_FALSE;
+
+ lock_pwd_complex_entry_clear();
+
+ _pwd_complex_lock_time_init();
+
+ lock_pwd_control_panel_cancel_btn_enable_set(EINA_TRUE);
+}
diff --git a/lock_pwd/src/lock_pwd_control_panel.c b/lock_pwd/src/lock_pwd_control_panel.c
new file mode 100644
index 0000000..52a6675
--- /dev/null
+++ b/lock_pwd/src/lock_pwd_control_panel.c
@@ -0,0 +1,263 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <app_control.h>
+#include <utilX.h>
+#include <ui-gadget.h>
+#include <call-manager.h>
+
+#include "lock_mgr.h"
+#include "util.h"
+#include "lock_pwd_util.h"
+#include "lock_pwd_control_panel.h"
+
+static struct _s_lock_pwd_control_panel {
+ Evas_Object *control_panel_layout;
+ Evas_Object *btn_cancel;
+ Evas_Object *btn_return_to_call;
+ Evas_Object *btn_plmn;
+ cm_client_h cm_handle;
+} s_lock_pwd_control_panel = {
+ .control_panel_layout = NULL,
+ .btn_cancel = NULL,
+ .btn_return_to_call = NULL,
+ .btn_plmn = NULL,
+ .cm_handle = NULL,
+};
+
+
+
+
+void lock_pwd_control_panel_cancel_btn_enable_set(Eina_Bool enable)
+{
+ ret_if(!s_lock_pwd_control_panel.control_panel_layout);
+
+ if (enable) {
+ elm_object_signal_emit(s_lock_pwd_control_panel.control_panel_layout, "btn,cancel,enable", "prog");
+ } else {
+ elm_object_signal_emit(s_lock_pwd_control_panel.control_panel_layout, "btn,cancel,disable", "prog");
+ }
+}
+
+
+
+static void _btn_cancel_clicked_cb(void *data, Evas_Object *obj, const char *emission, const char *source)
+{
+ _D("Cancel button is clicked");
+
+ lock_mgr_sound_play(LOCK_SOUND_TAP);
+
+ if (!lock_mgr_lockscreen_launch()) {
+ _E("Failed to launch lockscreen");
+ }
+
+ lock_pwd_util_view_init();
+}
+
+
+
+static void _btn_return_to_call_clicked_cb(void *data, Evas_Object *obj, const char *emission, const char *source)
+{
+ _D("'Return to call' button is clicked");
+
+ ret_if(!s_lock_pwd_control_panel.cm_handle);
+
+ cm_activate_ui(s_lock_pwd_control_panel.cm_handle);
+}
+
+
+
+static Evas_Object *_create_btn_return_to_call(Evas_Object *parent)
+{
+ Evas_Object *layout = NULL;
+
+ retv_if(!parent, NULL);
+
+ layout = elm_layout_add(parent);
+ retv_if(!layout, NULL);
+
+ if (!elm_layout_file_set(layout, LOCK_PWD_EDJE_FILE, "btn-return-to-call")) {
+ _E("Failed to set edje file : %s", LOCK_PWD_EDJE_FILE);
+ goto error;
+ }
+
+ evas_object_size_hint_weight_set(layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+
+ elm_object_signal_callback_add(layout, "btn,return_to_call,clicked", "btn.return_to_call", _btn_return_to_call_clicked_cb, NULL);
+
+ evas_object_show(layout);
+
+ return layout;
+
+error:
+ if (layout) {
+ evas_object_del(layout);
+ }
+
+ return NULL;
+}
+
+
+
+static void _destroy_btn_return_to_call(void)
+{
+ if (s_lock_pwd_control_panel.btn_return_to_call) {
+ elm_object_signal_callback_del(s_lock_pwd_control_panel.btn_return_to_call, "btn,return_to_call,clicked", "btn.return_to_call", _btn_return_to_call_clicked_cb);
+ evas_object_del(s_lock_pwd_control_panel.btn_return_to_call);
+ s_lock_pwd_control_panel.btn_return_to_call = NULL;
+ }
+}
+
+
+
+#if 0
+static Evas_Object *_create_btn_plmn(Evas_Object *parent)
+{
+ Evas_Object *plmn = NULL;
+
+ return plmn;
+}
+#endif
+
+
+static void _destroy_btn_plmn(void)
+{
+ if (s_lock_pwd_control_panel.btn_plmn) {
+ evas_object_del(s_lock_pwd_control_panel.btn_plmn);
+ s_lock_pwd_control_panel.btn_plmn = NULL;
+ }
+}
+
+
+
+static void _call_status_changed_cb(cm_call_status_e call_status, const char *call_num, void *user_data)
+{
+ Evas_Object *control_panel_layout = NULL;
+ Evas_Object *btn_return_to_call = NULL;
+
+ control_panel_layout = user_data;
+ ret_if(!control_panel_layout);
+
+ btn_return_to_call = elm_object_part_content_get(control_panel_layout, "sw.btn.return_to_call");
+
+ switch (call_status) {
+ case CM_CALL_STATUS_IDLE:
+ if (btn_return_to_call) {
+ _D("remove 'Return to call' button");
+ _destroy_btn_return_to_call();
+ }
+ break;
+ case CM_CALL_STATUS_RINGING:
+ case CM_CALL_STATUS_OFFHOOK:
+ if (!btn_return_to_call) {
+ _D("create 'Return to call' button");
+ btn_return_to_call = _create_btn_return_to_call(control_panel_layout);
+ if (btn_return_to_call) {
+ elm_object_part_content_set(control_panel_layout, "sw.btn.return_to_call", btn_return_to_call);
+ s_lock_pwd_control_panel.btn_return_to_call = btn_return_to_call;
+ } else {
+ _E("Failed to add a button for Return to call");
+ }
+ }
+ break;
+ default:
+ _E("call status error : %d", call_status);
+ break;
+ }
+}
+
+
+
+Evas_Object *lock_pwd_control_panel_create(Evas_Object *parent)
+{
+ Evas_Object *control_panel_layout = NULL;
+ int ret = 0;
+
+ /* Initialize callmgr-client */
+ cm_init(&s_lock_pwd_control_panel.cm_handle);
+
+ retv_if(!parent, NULL);
+
+ control_panel_layout = elm_layout_add(parent);
+ retv_if(!control_panel_layout, NULL);
+
+ if (!elm_layout_file_set(control_panel_layout, LOCK_PWD_EDJE_FILE, "lock-control-panel")) {
+ _E("Failed to set edje file : %s", LOCK_PWD_EDJE_FILE);
+ goto ERROR;
+ }
+ s_lock_pwd_control_panel.control_panel_layout = control_panel_layout;
+
+ evas_object_size_hint_weight_set(control_panel_layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(control_panel_layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+
+#if 0
+ /* plmn button */
+ Evas_Object *btn_plmn = NULL;
+ btn_plmn = _create_btn_plmn(control_panel_layout);
+ if (btn_plmn) {
+ elm_object_part_content_set(control_panel_layout, "sw.btn.plmn", btn_plmn);
+ s_lock_pwd_control_panel.btn_plmn = btn_plmn;
+ } else {
+ _E("Failed to add a button for PLMN");
+ }
+#endif
+
+ /* cancel button */
+ elm_object_part_text_set(control_panel_layout, "txt.cancel", _("IDS_COM_BUTTON_CANCEL"));
+ elm_object_signal_callback_add(control_panel_layout, "btn,cancel,clicked", "btn.cancel", _btn_cancel_clicked_cb, NULL);
+
+ evas_object_show(control_panel_layout);
+
+ ret = cm_set_call_status_cb(s_lock_pwd_control_panel.cm_handle, _call_status_changed_cb, control_panel_layout);
+ if (ret != CM_ERROR_NONE) {
+ _E("Failed to register call status callback");
+ }
+
+ return control_panel_layout;
+
+ERROR:
+ _E("Failed to create password control panel");
+
+ if (control_panel_layout) {
+ evas_object_del(control_panel_layout);
+ s_lock_pwd_control_panel.control_panel_layout = NULL;
+ }
+
+ return NULL;
+}
+
+void lock_pwd_control_panel_del(void)
+{
+ _destroy_btn_return_to_call();
+ _destroy_btn_plmn();
+
+ if (s_lock_pwd_control_panel.btn_cancel) {
+ elm_object_signal_callback_del(s_lock_pwd_control_panel.control_panel_layout, "btn,cancel,clicked", "btn.cancel", _btn_cancel_clicked_cb);
+ evas_object_del(s_lock_pwd_control_panel.btn_cancel);
+ s_lock_pwd_control_panel.btn_cancel= NULL;
+ }
+
+ if (s_lock_pwd_control_panel.control_panel_layout) {
+ evas_object_del(s_lock_pwd_control_panel.control_panel_layout);
+ s_lock_pwd_control_panel.control_panel_layout = NULL;
+ }
+
+ /* Deinitialize callmgr-client */
+ cm_unset_call_status_cb(s_lock_pwd_control_panel.cm_handle);
+ cm_deinit(s_lock_pwd_control_panel.cm_handle);
+ s_lock_pwd_control_panel.cm_handle = NULL;
+}
diff --git a/lock_pwd/src/lock_pwd_simple.c b/lock_pwd/src/lock_pwd_simple.c
new file mode 100755
index 0000000..b737464
--- /dev/null
+++ b/lock_pwd/src/lock_pwd_simple.c
@@ -0,0 +1,450 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <Elementary.h>
+#include <Ecore_X.h>
+#include <app_control.h>
+#include <bundle.h>
+#include <aul.h>
+#include <security-server.h>
+#include <vconf.h>
+
+#include "lock_mgr.h"
+#include "util.h"
+#include "status.h"
+#include "lock_pwd_util.h"
+#include "lock_pwd_simple.h"
+#include "lock_pwd_control_panel.h"
+
+#define DOT_TIME 1.5
+#define CORRECT_TIME 0.2
+
+static struct _s_lock_pwd_simple {
+ Evas_Object *pwd_simple_layout;
+ Ecore_Timer *timer_dot;
+
+ Eina_Bool is_blocked;
+
+ char pwd_simple[MAX_SIMPLE_PASSWORD_NUM +1];
+ int pwd_simple_length;
+
+ Ecore_Timer *timer_correct;
+ Ecore_Timer *timer_pin;
+ int pin_time_remain;
+} s_lock_pwd_simple = {
+ .pwd_simple_layout = NULL,
+ .timer_dot = NULL,
+
+ .is_blocked = EINA_FALSE,
+
+ .pwd_simple = { 0, },
+ .pwd_simple_length = 0,
+
+ .timer_correct = NULL,
+ .timer_pin = NULL,
+ .pin_time_remain = PASSWORD_BLOCK_SECONDS,
+};
+
+
+
+Eina_Bool lock_pwd_simple_is_blocked_get(void)
+{
+ return s_lock_pwd_simple.is_blocked;
+}
+
+
+
+
+static void _pwd_simple_layout_title_set(const char *title)
+{
+ ret_if(!s_lock_pwd_simple.pwd_simple_layout);
+ ret_if(!title);
+ elm_object_part_text_set(s_lock_pwd_simple.pwd_simple_layout, "title", title);
+}
+
+
+
+static void _pwd_simple_backspace(int length)
+{
+ char buf[BUF_SIZE_32] = { 0, };
+ ret_if(!s_lock_pwd_simple.pwd_simple_layout);
+
+ snprintf(buf, sizeof(buf), "dot_hide%d", length);
+ elm_object_signal_emit(s_lock_pwd_simple.pwd_simple_layout, buf, "keyboard");
+ if (s_lock_pwd_simple.timer_dot) {
+ ecore_timer_del(s_lock_pwd_simple.timer_dot);
+ s_lock_pwd_simple.timer_dot = NULL;
+ }
+}
+
+
+
+static Eina_Bool _hide_dot_cb(void *data)
+{
+ char buf[BUF_SIZE_32] = { 0, };
+ retv_if(!s_lock_pwd_simple.pwd_simple_layout, ECORE_CALLBACK_CANCEL);
+
+ snprintf(buf, sizeof(buf), "dot_show%d", (int)data);
+ elm_object_signal_emit(s_lock_pwd_simple.pwd_simple_layout, buf, "keyboard");
+ s_lock_pwd_simple.timer_dot = NULL;
+
+ return ECORE_CALLBACK_CANCEL;
+}
+
+
+
+static void _pwd_simple_input(int length, const char *text)
+{
+ char part_buf[BUF_SIZE_32] = { 0, };
+ char signal_buf[BUF_SIZE_32] = { 0, };
+ ret_if(!s_lock_pwd_simple.pwd_simple_layout);
+
+ lock_mgr_sound_play(LOCK_SOUND_BTN_KEY);
+
+ snprintf(part_buf, sizeof(part_buf), "panel%d", length);
+ elm_object_part_text_set(s_lock_pwd_simple.pwd_simple_layout, part_buf, text);
+
+ snprintf(signal_buf, sizeof(signal_buf), "input_show%d", length);
+ elm_object_signal_emit(s_lock_pwd_simple.pwd_simple_layout, signal_buf, "keyboard");
+
+ if (length > 0) {
+ snprintf(signal_buf, sizeof(signal_buf), "dot_show%d", length-1);
+ elm_object_signal_emit(s_lock_pwd_simple.pwd_simple_layout, signal_buf, "keyboard");
+ }
+
+ if (s_lock_pwd_simple.timer_dot) {
+ ecore_timer_del(s_lock_pwd_simple.timer_dot);
+ s_lock_pwd_simple.timer_dot = NULL;
+ }
+
+ if (length < MAX_SIMPLE_PASSWORD_NUM-1) {
+ s_lock_pwd_simple.timer_dot = ecore_timer_add(DOT_TIME, _hide_dot_cb, (void *)length);
+ }
+}
+
+
+
+static void _pwd_simple_keypad_process(void *data, Evas_Object *obj, const char *emission, const char *source)
+{
+ _D("%s", __func__);
+
+ if (s_lock_pwd_simple.is_blocked) {
+ _E("blocked");
+ lock_mgr_sound_play(LOCK_SOUND_BTN_KEY);
+ return;
+ }
+
+ if (!strncmp("Backspace", source, strlen("Backspace"))) {
+ _E("Backspace");
+ lock_mgr_sound_play(LOCK_SOUND_BTN_KEY);
+ ret_if(s_lock_pwd_simple.pwd_simple_length <= 0);
+ _pwd_simple_backspace(--s_lock_pwd_simple.pwd_simple_length);
+ } else {
+ if (s_lock_pwd_simple.pwd_simple_length >= MAX_SIMPLE_PASSWORD_NUM) {
+ _E("Too long");
+ return;
+ } else {
+ s_lock_pwd_simple.pwd_simple[s_lock_pwd_simple.pwd_simple_length] = *source;
+ _pwd_simple_input(s_lock_pwd_simple.pwd_simple_length++, source);
+ }
+ }
+
+ if (s_lock_pwd_simple.pwd_simple_length == MAX_SIMPLE_PASSWORD_NUM) {
+ lock_pwd_event_e pwd_event = lock_pwd_verification_verify(s_lock_pwd_simple.pwd_simple);
+ lock_pwd_simple_event(pwd_event);
+ }
+}
+
+
+
+Evas_Object *lock_pwd_simple_layout_create(void *data)
+{
+ Evas_Object *parent = NULL;
+ Evas_Object *pwd_simple_layout = NULL;
+ Evas_Object *pwd_control_panel = NULL;
+
+ lock_pwd_verification_policy_create();
+
+ parent = (Evas_Object *)data;
+ retv_if(!parent, NULL);
+
+ pwd_simple_layout = elm_layout_add(parent);
+ goto_if(!pwd_simple_layout, ERROR);
+ s_lock_pwd_simple.pwd_simple_layout = pwd_simple_layout;
+
+ if (!elm_layout_file_set(pwd_simple_layout, LOCK_PWD_EDJE_FILE, "lock-simple-password")) {
+ _E("Failed to set edje file : %s", LOCK_PWD_EDJE_FILE);
+ goto ERROR;
+ }
+
+ evas_object_size_hint_weight_set(pwd_simple_layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(pwd_simple_layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ evas_object_show(pwd_simple_layout);
+
+ elm_object_signal_callback_add(pwd_simple_layout, "keypad_down_clicked", "*", _pwd_simple_keypad_process, NULL);
+ _pwd_simple_layout_title_set(_("IDS_COM_BODY_ENTER_PIN"));
+
+ /* create control panel */
+ pwd_control_panel = lock_pwd_control_panel_create(pwd_simple_layout);
+ if (!pwd_control_panel) {
+ _E("Failed to create password control panel");
+ } else {
+ elm_object_part_content_set(pwd_simple_layout, "control_panel", pwd_control_panel);
+ }
+
+ return pwd_simple_layout;
+
+ERROR:
+ _E("Failed to create simple password layout");
+
+ if (pwd_simple_layout) {
+ evas_object_del(pwd_simple_layout);
+ s_lock_pwd_simple.pwd_simple_layout = NULL;
+ }
+
+ return NULL;
+}
+
+
+
+void lock_pwd_simple_layout_destroy(void)
+{
+ if (s_lock_pwd_simple.pwd_simple_layout) {
+ evas_object_del(s_lock_pwd_simple.pwd_simple_layout);
+ s_lock_pwd_simple.pwd_simple_layout = NULL;
+ }
+
+ if (s_lock_pwd_simple.timer_dot) {
+ ecore_timer_del(s_lock_pwd_simple.timer_dot);
+ s_lock_pwd_simple.timer_dot = NULL;
+ }
+
+ if (s_lock_pwd_simple.timer_pin) {
+ ecore_timer_del(s_lock_pwd_simple.timer_pin);
+ s_lock_pwd_simple.timer_pin = NULL;
+ }
+}
+
+
+
+void lock_pwd_simple_entry_clear(void)
+{
+ int i = 0;
+ char buf[BUF_SIZE_32] = { 0, };
+
+ ret_if(!s_lock_pwd_simple.pwd_simple_layout);
+
+ if (s_lock_pwd_simple.timer_dot) {
+ ecore_timer_del(s_lock_pwd_simple.timer_dot);
+ s_lock_pwd_simple.timer_dot = NULL;
+ }
+
+ for (i = 0; i <= 3; i++) {
+ snprintf(buf, sizeof(buf), "dot_hide%d", i);
+ elm_object_signal_emit(s_lock_pwd_simple.pwd_simple_layout, buf, "keyboard");
+ }
+ s_lock_pwd_simple.pwd_simple_length = 0;
+}
+
+
+
+static Eina_Bool _pwd_simple_entry_clear(void *data)
+{
+ lock_pwd_simple_entry_clear();
+ return ECORE_CALLBACK_CANCEL;
+}
+
+
+
+static void _pwd_simple_event_incorrect(lock_pwd_event_e event)
+{
+ char temp_str[BUF_SIZE_256] = { 0, };
+ char temp_left[BUF_SIZE_256] = { 0, };
+ int remain_attempt = 0;
+
+ remain_attempt = lock_pwd_verification_remain_attempt_get();
+ _D("remain_attempt(%d)", remain_attempt);
+
+ if (remain_attempt == 1) {
+ strncpy(temp_left, _("IDS_IDLE_BODY_1_ATTEMPT_LEFT"), sizeof(temp_left));
+ temp_left[sizeof(temp_left) - 1] = '\0';
+ } else {
+ snprintf(temp_left, sizeof(temp_left), _("IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"), remain_attempt);
+ }
+ snprintf(temp_str, sizeof(temp_str), "%s<br>%s", _("IDS_COM_BODY_INCORRECT_PIN"), temp_left);
+ _pwd_simple_layout_title_set(temp_str);
+
+ ecore_timer_add(0.1, _pwd_simple_entry_clear, NULL);
+
+ lock_pwd_verification_popup_create(event);
+}
+
+
+
+static Eina_Bool _pwd_correct_timer_cb(void *data)
+{
+ lock_pwd_util_win_hide();
+ lock_pwd_simple_entry_clear();
+ _pwd_simple_layout_title_set(_("IDS_COM_BODY_ENTER_PIN"));
+
+ lock_mgr_idle_lock_state_set(VCONFKEY_IDLE_UNLOCK);
+ lock_mgr_sound_play(LOCK_SOUND_UNLOCK);
+
+ s_lock_pwd_simple.timer_correct = NULL;
+
+ return ECORE_CALLBACK_CANCEL;
+}
+
+
+
+static void _pwd_simple_event_correct(lock_pwd_event_e event)
+{
+ if (s_lock_pwd_simple.timer_correct) {
+ ecore_timer_del(s_lock_pwd_simple.timer_correct);
+ }
+
+ s_lock_pwd_simple.timer_correct = ecore_timer_add(CORRECT_TIME, _pwd_correct_timer_cb, NULL);
+ if(!s_lock_pwd_simple.timer_correct) {
+ _E("Failed to add tiemr for correct password event");
+ }
+}
+
+
+
+static void _pwd_simple_lock_time_init(void)
+{
+ if (vconf_set_str(VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR, "") < 0) {
+ _E("Failed to set vconfkey : %s", VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR);
+ }
+}
+
+
+
+static void _pwd_simple_lock_time_save(void)
+{
+ time_t cur_time = time(NULL);
+ char buf[64] = { 0, };
+ snprintf(buf, sizeof(buf), "%ld", cur_time);
+ if (vconf_set_str(VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR, buf) < 0) {
+ _E("Failed to set vconfkey : %s", VCONFKEY_SETAPPL_PASSWORD_TIMESTAMP_STR);
+ }
+}
+
+
+
+static Eina_Bool _wrong_pwd_wait_timer_cb(void *data)
+{
+ char try_again_buf[BUF_SIZE_256] = { 0, };
+ char incorrect_pass_buf[BUF_SIZE_256] = { 0, };
+
+ retv_if(!s_lock_pwd_simple.pwd_simple_layout, ECORE_CALLBACK_CANCEL);
+
+ snprintf(try_again_buf, sizeof(try_again_buf), _("IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"), s_lock_pwd_simple.pin_time_remain);
+ snprintf(incorrect_pass_buf, sizeof(incorrect_pass_buf), "%s<br>%s", _("IDS_COM_BODY_INCORRECT_PIN"), try_again_buf);
+ _pwd_simple_layout_title_set(incorrect_pass_buf);
+
+ if (s_lock_pwd_simple.pin_time_remain == PASSWORD_BLOCK_SECONDS ||
+ s_lock_pwd_simple.pin_time_remain > 0) {
+ s_lock_pwd_simple.pin_time_remain--;
+ return ECORE_CALLBACK_RENEW;
+ } else {
+ lock_pwd_simple_view_init();
+
+ int lcd_state = lock_mgr_lcd_state_get();
+ if (lcd_state == LCD_STATE_OFF) {
+ if (!lock_mgr_lockscreen_launch()) {
+ _E("Failed to launch lockscreen");
+ }
+ }
+ }
+
+ return ECORE_CALLBACK_CANCEL;
+}
+
+
+
+static void _pwd_simple_event_input_block(lock_pwd_event_e event)
+{
+ _D("%s", __func__);
+
+ int block_sec = PASSWORD_BLOCK_SECONDS;
+ char try_again_buf[200] = { 0, };
+ char incorrect_pass_buf[200] = { 0, };
+
+ ret_if(!s_lock_pwd_simple.pwd_simple_layout);
+
+ _pwd_simple_lock_time_save();
+
+ snprintf(try_again_buf, sizeof(try_again_buf), _("IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"), block_sec);
+ snprintf(incorrect_pass_buf, sizeof(incorrect_pass_buf), "%s<br>%s", _("IDS_COM_BODY_INCORRECT_PIN"), try_again_buf);
+ _pwd_simple_layout_title_set(incorrect_pass_buf);
+
+ s_lock_pwd_simple.is_blocked = EINA_TRUE;
+
+ if (s_lock_pwd_simple.timer_pin) {
+ ecore_timer_del(s_lock_pwd_simple.timer_pin);
+ s_lock_pwd_simple.timer_pin = NULL;
+ }
+
+ s_lock_pwd_simple.timer_pin = ecore_timer_add(1.0, _wrong_pwd_wait_timer_cb, NULL);
+
+ ecore_timer_add(0.1, _pwd_simple_entry_clear, NULL);
+
+ lock_pwd_verification_popup_create(event);
+
+ lock_pwd_control_panel_cancel_btn_enable_set(EINA_FALSE);
+}
+
+
+
+void lock_pwd_simple_event(lock_pwd_event_e event)
+{
+ switch(event) {
+ case PWD_EVENT_CORRECT:
+ _pwd_simple_event_correct(event);
+ break;
+ case PWD_EVENT_INCORRECT_WARNING:
+ case PWD_EVENT_INCORRECT:
+ _pwd_simple_event_incorrect(event);
+ break;
+ case PWD_EVENT_INPUT_BLOCK_WARNING:
+ case PWD_EVENT_INPUT_BLOCK:
+ _pwd_simple_event_input_block(event);
+ break;
+ case PWD_EVENT_EMPTY:
+ break;
+ case PWD_EVENT_OVER:
+ break;
+ default:
+ break;
+ }
+}
+
+void lock_pwd_simple_view_init(void)
+{
+ _D("initialize simpel password values");
+ s_lock_pwd_simple.pin_time_remain = PASSWORD_BLOCK_SECONDS;
+
+ _pwd_simple_layout_title_set(_("IDS_COM_BODY_ENTER_PIN"));
+ elm_object_signal_emit(s_lock_pwd_simple.pwd_simple_layout, "show_title", "title");
+ s_lock_pwd_simple.is_blocked = EINA_FALSE;
+
+ lock_pwd_simple_entry_clear();
+
+ _pwd_simple_lock_time_init();
+
+ lock_pwd_control_panel_cancel_btn_enable_set(EINA_TRUE);
+}
diff --git a/lock_pwd/src/lock_pwd_util.c b/lock_pwd/src/lock_pwd_util.c
new file mode 100644
index 0000000..0a2b872
--- /dev/null
+++ b/lock_pwd/src/lock_pwd_util.c
@@ -0,0 +1,485 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <system_settings.h>
+#include <efl_extension.h>
+
+#include "lock_mgr.h"
+#include "util.h"
+#include "status.h"
+#include "status.h"
+#include "lock_pwd_util.h"
+#include "lock_pwd_simple.h"
+#include "lock_pwd_complex.h"
+
+static struct _s_lock_pwd_util {
+ Evas_Object *lock_pwd_win;
+ Evas_Object *conformant;
+ Evas_Object *layout;
+ Evas_Object *bg;
+
+ int win_w;
+ int win_h;
+} s_lock_pwd_util = {
+ .lock_pwd_win = NULL,
+ .conformant = NULL,
+ .layout = NULL,
+ .bg = NULL,
+
+ .win_w = 0,
+ .win_h = 0,
+};
+
+
+
+int lock_pwd_util_win_width_get(void)
+{
+ return s_lock_pwd_util.win_w;
+}
+
+
+
+int lock_pwd_util_win_height_get(void)
+{
+ return s_lock_pwd_util.win_h;
+}
+
+
+
+Evas_Object *lock_pwd_util_win_get(void)
+{
+ return s_lock_pwd_util.lock_pwd_win;
+}
+
+
+
+Eina_Bool lock_pwd_util_win_visible_get(void)
+{
+ retv_if(!s_lock_pwd_util.lock_pwd_win, EINA_FALSE);
+ return evas_object_visible_get(s_lock_pwd_util.lock_pwd_win);
+}
+
+
+
+static Evas_Object *_pwd_conformant_add(Evas_Object *parent)
+{
+ Evas_Object *conformant = NULL;
+
+ retv_if(!parent, NULL);
+
+ conformant = elm_conformant_add(parent);
+ retv_if(!conformant, NULL);
+
+ evas_object_size_hint_weight_set(conformant, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ elm_win_resize_object_add(parent, conformant);
+
+ elm_object_signal_emit(conformant, "elm,state,indicator,overlap", "elm");
+
+ evas_object_show(conformant);
+
+ return conformant;
+}
+
+
+void lock_pwd_util_bg_image_set(Evas_Object *bg, char *file)
+{
+ const char *old_filename = NULL;
+ char *lock_bg = NULL;
+ int ret = 0;
+
+ ret_if(!bg);
+
+ elm_image_file_get(bg, &old_filename, NULL);
+ if (!old_filename) {
+ old_filename = LOCK_MGR_DEFAULT_BG_PATH;
+ }
+ _D("old file name : %s", old_filename);
+
+ if (file) {
+ if (!elm_image_file_set(bg, file, NULL)) {
+ _E("Failed to set image file : %s", file);
+ goto ERROR;
+ }
+ } else {
+ ret = system_settings_get_value_string(SYSTEM_SETTINGS_KEY_WALLPAPER_LOCK_SCREEN, &lock_bg);
+ if (SYSTEM_SETTINGS_ERROR_NONE != ret) {
+ _E("Failed to get system setting value : %d", SYSTEM_SETTINGS_KEY_WALLPAPER_LOCK_SCREEN);
+ goto ERROR;
+ }
+ goto_if(!lock_bg, ERROR);
+
+ _D("lock_bg : %s", lock_bg);
+
+ if (!elm_image_file_set(bg, lock_bg, NULL)) {
+ _E("Failed to set image file : %s", lock_bg);
+ goto ERROR;
+ }
+
+ free(lock_bg);
+ }
+
+ return;
+
+ERROR:
+
+ if (!elm_bg_file_set(bg, old_filename, NULL)) {
+ _E("Failed to set old BG file : %s / Retry to set default BG.", old_filename);
+ if (!elm_bg_file_set(bg, LOCK_MGR_DEFAULT_BG_PATH, NULL)) {
+ _E("Failed to set default BG : %s", LOCK_MGR_DEFAULT_BG_PATH);
+ return;
+ }
+ }
+
+ return;
+}
+
+
+
+static void _wallpaper_lock_screen_changed_cb(system_settings_key_e key, void *data)
+{
+ Evas_Object *bg = (Evas_Object *)data;
+ ret_if(!bg);
+
+ lock_pwd_util_bg_image_set(bg, NULL);
+}
+
+
+
+static Evas_Object *_pwd_bg_add(void *data)
+{
+ Evas_Object *bg = NULL;
+ Evas_Object *parent = NULL;
+ int ret = 0;
+
+ parent = (Evas_Object *)data;
+ retv_if(!parent, NULL);
+
+ bg = elm_image_add(parent);
+ retv_if(!bg, NULL);
+
+ elm_image_aspect_fixed_set(bg, EINA_TRUE);
+ elm_image_fill_outside_set(bg, EINA_TRUE);
+ elm_image_preload_disabled_set(bg, EINA_TRUE);
+
+ lock_pwd_util_bg_image_set(bg, NULL);
+ evas_object_show(bg);
+
+ ret = system_settings_set_changed_cb(SYSTEM_SETTINGS_KEY_WALLPAPER_LOCK_SCREEN, _wallpaper_lock_screen_changed_cb, bg);
+ if (SYSTEM_SETTINGS_ERROR_NONE != ret) {
+ _E("Failed to register settings changed cb : %d", SYSTEM_SETTINGS_KEY_WALLPAPER_LOCK_SCREEN);
+ }
+
+ return bg;
+}
+
+
+
+static Evas_Object *_pwd_layout_create(Evas_Object *parent)
+{
+ Evas_Object *layout = NULL;
+
+ retv_if(!parent, NULL);
+
+ layout = elm_layout_add(parent);
+ retv_if(!layout, NULL);
+
+ if (!elm_layout_file_set(layout, LOCK_PWD_EDJE_FILE, "lock_pwd")) {
+ _E("Failed to set edje file : %s", LOCK_PWD_EDJE_FILE);
+ goto ERROR;
+ }
+
+ evas_object_size_hint_weight_set(layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+
+ evas_object_show(layout);
+
+ return layout;
+
+ERROR:
+ _E("Failed to create password layout");
+
+ if (layout) {
+ evas_object_del(layout);
+ layout = NULL;
+ }
+
+ return NULL;
+}
+
+
+
+void lock_pwd_util_back_key_relased(void)
+{
+ _D("%s", __func__);
+
+ ret_if(lock_pwd_simple_is_blocked_get());
+
+ lock_mgr_sound_play(LOCK_SOUND_TAP);
+
+ if (!lock_mgr_lockscreen_launch()) {
+ _E("Failed to launch lockscreen");
+ }
+
+ lock_pwd_util_view_init();
+}
+
+
+
+static void __win_resize_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+ Evas_Coord x = 0;
+ Evas_Coord y = 0;
+ Evas_Coord w = 0;
+ Evas_Coord h = 0;
+
+ ret_if(!obj);
+
+ evas_object_geometry_get(obj, &x, &y, &w, &h);
+ _D("win resize : %d, %d(%d*%d)", x, y, w, h);
+}
+
+
+
+static void __conformant_resize_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+ Evas_Coord x = 0;
+ Evas_Coord y = 0;
+ Evas_Coord w = 0;
+ Evas_Coord h = 0;
+
+ ret_if(!obj);
+
+ evas_object_geometry_get(obj, &x, &y, &w, &h);
+ _D("conformant resize : %d, %d(%d*%d)", x, y, w, h);
+}
+
+
+
+static void __layout_resize_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+ Evas_Coord x = 0;
+ Evas_Coord y = 0;
+ Evas_Coord w = 0;
+ Evas_Coord h = 0;
+
+ ret_if(!obj);
+
+ evas_object_geometry_get(obj, &x, &y, &w, &h);
+ _D("layout resize : %d, %d(%d*%d)", x, y, w, h);
+}
+
+
+
+void lock_pwd_util_create(Eina_Bool is_show)
+{
+ Evas_Object *win = NULL;
+ Evas_Object *conformant = NULL;
+ Evas_Object *bg = NULL;
+ Evas_Object *layout = NULL;
+ Evas_Object *pwd_layout = NULL;
+ int lock_type = 0;
+ int x = 0, y = 0, w = 0, h = 0;
+
+ if (!s_lock_pwd_util.lock_pwd_win) {
+ win = window_mgr_pwd_lock_win_create();
+ ret_if(!win);
+ s_lock_pwd_util.lock_pwd_win = win;
+
+ elm_win_screen_size_get(win, &x, &y, &w, &h);
+ _D("win size : %dx%d(%d, %d)", w, h, x, y);
+ s_lock_pwd_util.win_w = w;
+ s_lock_pwd_util.win_h = h;
+ }
+
+ conformant = _pwd_conformant_add(win);
+ goto_if(!conformant, ERROR);
+ s_lock_pwd_util.conformant = conformant;
+
+ layout = _pwd_layout_create(conformant);
+ goto_if(!layout, ERROR);
+ s_lock_pwd_util.layout = layout;
+
+ evas_object_event_callback_add(s_lock_pwd_util.lock_pwd_win, EVAS_CALLBACK_RESIZE, __win_resize_cb, NULL);
+ evas_object_event_callback_add(conformant, EVAS_CALLBACK_RESIZE, __conformant_resize_cb, NULL);
+ evas_object_event_callback_add(conformant, EVAS_CALLBACK_RESIZE, __layout_resize_cb, NULL);
+
+ elm_object_content_set(conformant, layout);
+
+ bg = _pwd_bg_add(win);
+ goto_if(!bg, ERROR);
+ s_lock_pwd_util.bg = bg;
+
+ elm_object_part_content_set(layout, "sw.bg", bg);
+
+ lock_type = status_active_get()->setappl_screen_lock_type_int;
+ _D("lock type : %d", lock_type);
+
+ switch(lock_type) {
+ case SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD:
+ pwd_layout = lock_pwd_simple_layout_create(layout);
+ break;
+ case SETTING_SCREEN_LOCK_TYPE_PASSWORD:
+ pwd_layout = lock_pwd_complex_layout_create(layout);
+ break;
+ default:
+ _E("lock type is not password : %d", lock_type);
+ goto ERROR;
+ }
+ goto_if(!pwd_layout, ERROR);
+
+ elm_object_part_content_set(layout, "sw.lock_pwd", pwd_layout);
+
+ if (is_show) {
+ evas_object_show(win);
+ }
+
+ return;
+
+ERROR:
+ _E("Failed to launch password lockscreen");
+
+ lock_pwd_util_destroy();
+
+ return;
+}
+
+
+
+void lock_pwd_util_destroy(void)
+{
+ int lock_type = status_active_get()->setappl_screen_lock_type_int;
+ _D("lock type : %d", lock_type);
+
+ if (lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD) {
+ lock_pwd_simple_layout_destroy();
+ } else if (lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD) {
+ lock_pwd_complex_layout_destroy();
+ }
+
+ if (s_lock_pwd_util.layout) {
+ evas_object_del(s_lock_pwd_util.layout);
+ s_lock_pwd_util.layout = NULL;
+ }
+
+ if (s_lock_pwd_util.conformant) {
+ evas_object_del(s_lock_pwd_util.conformant);
+ s_lock_pwd_util.conformant = NULL;
+ }
+
+ if (s_lock_pwd_util.bg) {
+ system_settings_unset_changed_cb(SYSTEM_SETTINGS_KEY_WALLPAPER_LOCK_SCREEN);
+ evas_object_del(s_lock_pwd_util.bg);
+ s_lock_pwd_util.bg = NULL;
+ }
+
+ if (s_lock_pwd_util.lock_pwd_win) {
+ evas_object_del(s_lock_pwd_util.lock_pwd_win);
+ s_lock_pwd_util.lock_pwd_win = NULL;
+ }
+}
+
+
+
+
+static void _pwd_popup_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ ret_if(!data);
+
+ evas_object_del((Evas_Object *)data);
+}
+
+
+
+void lock_pwd_util_popup_create(char *title, char *text, Evas_Smart_Cb func, double timeout)
+{
+ Evas_Object *popup = NULL;
+ Evas_Object *btn = NULL;
+
+ ret_if(!s_lock_pwd_util.lock_pwd_win);
+
+ popup = elm_popup_add(s_lock_pwd_util.lock_pwd_win);
+ ret_if(!popup);
+
+ elm_popup_orient_set(popup, ELM_POPUP_ORIENT_BOTTOM);
+ evas_object_size_hint_weight_set(popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+
+ if (title) {
+ elm_object_part_text_set(popup, "title,text", title);
+ }
+
+ if (text) {
+ elm_object_text_set(popup, text);
+ }
+
+ btn = elm_button_add(popup);
+ if (!btn) {
+ _E("Failed to create lock popup button");
+ evas_object_del(popup);
+ return;
+ }
+
+ elm_object_style_set(btn, "popup");
+ elm_object_text_set(btn, _("IDS_COM_BUTTON_OK_ABB"));
+ elm_object_part_content_set(popup, "button1", btn);
+
+ if (timeout > 0.0) {
+ elm_popup_timeout_set(popup, timeout);
+ }
+
+ if (func) {
+ evas_object_smart_callback_add(btn, "clicked", func, popup);
+ eext_object_event_callback_add(popup, EEXT_CALLBACK_BACK, func, popup);
+ } else {
+ evas_object_smart_callback_add(btn, "clicked", _pwd_popup_cb, popup);
+ eext_object_event_callback_add(popup, EEXT_CALLBACK_BACK, _pwd_popup_cb, popup);
+ }
+
+ evas_object_show(popup);
+
+ return;
+}
+
+
+
+void lock_pwd_util_view_init(void)
+{
+ _D("initialize password lock values");
+ int lock_type = 0;
+
+ /* clear pwd lockscreen */
+ lock_type = status_active_get()->setappl_screen_lock_type_int;
+ if (lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD) {
+ lock_pwd_simple_view_init();
+ } else if (lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD) {
+ lock_pwd_complex_view_init();
+ }
+}
+
+
+
+void lock_pwd_util_win_show(void)
+{
+ ret_if(!s_lock_pwd_util.lock_pwd_win);
+ evas_object_show(s_lock_pwd_util.lock_pwd_win);
+}
+
+
+
+void lock_pwd_util_win_hide(void)
+{
+ ret_if(!s_lock_pwd_util.lock_pwd_win);
+ evas_object_hide(s_lock_pwd_util.lock_pwd_win);
+}
diff --git a/lock_pwd/src/lock_pwd_verification.c b/lock_pwd/src/lock_pwd_verification.c
new file mode 100755
index 0000000..df64b1c
--- /dev/null
+++ b/lock_pwd/src/lock_pwd_verification.c
@@ -0,0 +1,207 @@
+/*
+ * Copyright (c) 2009-2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <Elementary.h>
+#include <security-server.h>
+#include <vconf.h>
+#include <vconf-keys.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+
+#include "util.h"
+#include "status.h"
+#include "lock_mgr.h"
+#include "lock_pwd_util.h"
+#include "lock_pwd_verification.h"
+#include "lock_pwd_simple.h"
+
+#define PASSWORD_LENGTH_MIN 4
+#define PASSWORD_LENGTH_MAX 16
+
+typedef enum {
+ NORMAL_PWD = 0,
+ EMPTY_PWD = 1,
+ OVERLENGTH_PWD = 2,
+} lock_pwd_type;
+
+static struct _s_lock_pwd_verification {
+ unsigned int current_attempt;
+ unsigned int remain_attempt;
+ unsigned int max_attempt;
+ unsigned int expire_sec;
+ unsigned int incorrect_count;
+} s_lock_pwd_verification = {
+ .current_attempt = 0,
+ .remain_attempt = 0,
+ .max_attempt = 0,
+ .expire_sec = 0,
+ .incorrect_count = 0,
+};
+
+
+
+int lock_pwd_verification_current_attempt_get(void)
+{
+ return s_lock_pwd_verification.current_attempt;
+}
+
+
+int lock_pwd_verification_remain_attempt_get(void)
+{
+ return s_lock_pwd_verification.remain_attempt;
+}
+
+
+static Eina_Bool _pwd_verification_check_pwd(const char *str)
+{
+ int ret = SECURITY_SERVER_API_ERROR_PASSWORD_MISMATCH;
+ unsigned int current_attempt = 0;
+ unsigned int max_attempt = 0;
+ unsigned int expire_sec = 0;
+
+ ret = security_server_chk_pwd(str, &current_attempt, &max_attempt, &expire_sec);
+ _D("ret(%d), current_attempt(%d), max_attempt(%d), valid_sec(%d)", ret, current_attempt, max_attempt, expire_sec);
+
+ s_lock_pwd_verification.current_attempt = current_attempt;
+ s_lock_pwd_verification.max_attempt = max_attempt;
+ s_lock_pwd_verification.expire_sec = expire_sec;
+
+ switch(ret) {
+ case SECURITY_SERVER_API_SUCCESS:
+ case SECURITY_SERVER_API_ERROR_PASSWORD_EXPIRED:
+ _E("Correct password");
+ return EINA_TRUE;
+ case SECURITY_SERVER_API_ERROR_PASSWORD_RETRY_TIMER:
+ _E("Timer set! : not saved");
+ break;
+ default:
+ _E("Incorrect password");
+ break;
+ }
+
+ return EINA_FALSE;
+}
+
+
+static lock_pwd_type _pwd_verification_check_length(const char *str, int min, int max)
+{
+ int len = 0;
+
+ retv_if(!str, EMPTY_PWD);
+
+ len = strlen(str);
+ retv_if(len == 0, EMPTY_PWD);
+
+ retv_if(len < min || len > max, OVERLENGTH_PWD);
+
+ return NORMAL_PWD;
+}
+
+static void _pwd_values_init(void)
+{
+ s_lock_pwd_verification.current_attempt = 0;
+ s_lock_pwd_verification.remain_attempt = PASSWORD_ATTEMPTS_MAX_NUM;
+ s_lock_pwd_verification.max_attempt = PASSWORD_ATTEMPTS_MAX_NUM;
+ s_lock_pwd_verification.incorrect_count = 0;
+}
+
+lock_pwd_event_e lock_pwd_verification_verify(const char *password)
+{
+ lock_pwd_type pwd_type = NORMAL_PWD;
+
+ retv_if(!password, PWD_EVENT_EMPTY);
+
+ pwd_type = _pwd_verification_check_length(password, PASSWORD_LENGTH_MIN, PASSWORD_LENGTH_MAX);
+ switch(pwd_type) {
+ case NORMAL_PWD:
+ if (_pwd_verification_check_pwd(password)) {
+ _D("Correct Password");
+ _pwd_values_init();
+ return PWD_EVENT_CORRECT;
+ } else {
+ s_lock_pwd_verification.incorrect_count++;
+ s_lock_pwd_verification.remain_attempt--;
+ _D("incorrect_count(%d), remain_attempt(%d)", s_lock_pwd_verification.incorrect_count, s_lock_pwd_verification.remain_attempt);
+
+ if (s_lock_pwd_verification.remain_attempt == 0) {
+ _pwd_values_init();
+ return PWD_EVENT_INPUT_BLOCK;
+ } else {
+ return PWD_EVENT_INCORRECT;
+ }
+ }
+ break;
+ case EMPTY_PWD:
+ return PWD_EVENT_EMPTY;
+ break;
+ case OVERLENGTH_PWD:
+ return PWD_EVENT_OVER;
+ break;
+ }
+
+ return PWD_EVENT_INCORRECT;
+}
+
+void lock_pwd_verification_policy_create(void)
+{
+ int ret = 0;
+ unsigned int current_attempt = 0;
+ unsigned int max_attempt = 0;
+ unsigned int expire_sec = 0;
+
+ ret = security_server_is_pwd_valid(&current_attempt, &max_attempt, &expire_sec);
+ _D("policy status(%d), current_attempt(%d), max_attempt(%d)", ret, current_attempt, max_attempt);
+
+ if (ret == SECURITY_SERVER_API_ERROR_NO_PASSWORD ||
+ ret == SECURITY_SERVER_API_ERROR_PASSWORD_EXIST) {
+ s_lock_pwd_verification.current_attempt = current_attempt;
+ s_lock_pwd_verification.max_attempt = max_attempt;
+ s_lock_pwd_verification.expire_sec = expire_sec;
+ }
+
+ s_lock_pwd_verification.remain_attempt = PASSWORD_ATTEMPTS_MAX_NUM;
+ s_lock_pwd_verification.incorrect_count = 0;
+
+ return;
+}
+
+void lock_pwd_verification_popup_create(lock_pwd_event_e event)
+{
+ char popup_text[BUF_SIZE_512] = { 0, };
+ int remain_attempt = 0;
+ int current_attempt = 0;
+
+ current_attempt = lock_pwd_verification_current_attempt_get();
+ remain_attempt = lock_pwd_verification_remain_attempt_get();
+ _D("current_attemp(%d), remain_attempt(%d)", current_attempt, remain_attempt);
+
+ switch(event) {
+ case PWD_EVENT_INCORRECT_WARNING:
+ snprintf(popup_text, sizeof(popup_text), _("IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"), current_attempt, remain_attempt);
+ lock_pwd_util_popup_create(NULL, popup_text, NULL, 0.0);
+ break;
+ case PWD_EVENT_INPUT_BLOCK:
+ snprintf(popup_text, sizeof(popup_text), _("IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"), PASSWORD_ATTEMPTS_MAX_NUM, PASSWORD_BLOCK_SECONDS);
+ lock_pwd_util_popup_create(_("IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"), popup_text, NULL, 15.0);
+ break;
+ case PWD_EVENT_INPUT_BLOCK_WARNING:
+ snprintf(popup_text, sizeof(popup_text), _("IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"), current_attempt, remain_attempt);
+ lock_pwd_util_popup_create(NULL, popup_text, NULL, 0.0);
+ break;
+ default:
+ break;
+ }
+}
diff --git a/packaging/starter-pre.service b/packaging/starter-pre.service
new file mode 100644
index 0000000..bbbf95b
--- /dev/null
+++ b/packaging/starter-pre.service
@@ -0,0 +1,7 @@
+[Unit]
+Description=Pre actions for "starter"
+
+[Service]
+Type=oneshot
+ExecStart=/etc/init.d/rd3starter
+SmackProcessLabel=starter
diff --git a/packaging/starter.service b/packaging/starter.service
index 78fe1b9..08e4873 100755..100644
--- a/packaging/starter.service
+++ b/packaging/starter.service
@@ -1,14 +1,16 @@
[Unit]
Description=Start the "starter" program
-After=wm_ready.service ac.service system-server.service launchpad-preload.service
-
+Requires=starter-pre.service
+After=starter-pre.service wm_ready.service ac.service deviced.service launchpad-preload.service
[Service]
-Type=forking
-ExecStart=/etc/init.d/rd3starter
+ExecStart=/usr/bin/starter
Restart=always
RestartSec=0
KillSignal=SIGKILL
+User=system
+Group=system
+SmackProcessLabel=starter
[Install]
WantedBy=tizen-system.target
diff --git a/packaging/starter.spec b/packaging/starter.spec
index 2510b38..5a466c4 100755..100644
--- a/packaging/starter.spec
+++ b/packaging/starter.spec
@@ -7,20 +7,29 @@ Group: TO_BE/FILLED_IN
License: Apache-2.0
Source0: starter-%{version}.tar.gz
Source1: starter.service
-Source2: wait-lock.service
+Source2: starter-pre.service
+
+%if "%{?tizen_profile_name}"=="tv"
+ExcludeArch: %{arm} %ix86 x86_64
+%endif
+
BuildRequires: cmake
-BuildRequires: pkgconfig(ail)
BuildRequires: pkgconfig(appcore-efl)
BuildRequires: pkgconfig(aul)
BuildRequires: pkgconfig(capi-appfw-application)
BuildRequires: pkgconfig(capi-appfw-app-manager)
BuildRequires: pkgconfig(capi-system-media-key)
BuildRequires: pkgconfig(capi-network-bluetooth)
+BuildRequires: pkgconfig(capi-system-system-settings)
+BuildRequires: pkgconfig(capi-ui-efl-util)
%if "%{?tizen_profile_name}" == "mobile"
BuildRequires: tts
BuildRequires: tts-devel
BuildRequires: pkgconfig(capi-message-port)
+BuildRequires: pkgconfig(security-server)
+BuildRequires: pkgconfig(efl-extension)
+BuildRequires: pkgconfig(callmgr_client)
%endif
BuildRequires: pkgconfig(feedback)
@@ -29,19 +38,14 @@ BuildRequires: pkgconfig(dlog)
BuildRequires: pkgconfig(ecore)
BuildRequires: pkgconfig(edje)
BuildRequires: pkgconfig(edbus)
-BuildRequires: pkgconfig(eet)
BuildRequires: pkgconfig(eina)
BuildRequires: pkgconfig(elementary)
BuildRequires: pkgconfig(evas)
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(syspopup-caller)
-BuildRequires: pkgconfig(tapi)
BuildRequires: pkgconfig(ui-gadget-1)
BuildRequires: pkgconfig(utilX)
BuildRequires: pkgconfig(vconf)
-BuildRequires: pkgconfig(x11)
-BuildRequires: pkgconfig(xcomposite)
-BuildRequires: pkgconfig(xext)
BuildRequires: pkgconfig(alarm-service)
BuildRequires: pkgconfig(pkgmgr-info)
BuildRequires: pkgconfig(deviced)
@@ -72,12 +76,25 @@ export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
%if "%{?tizen_profile_name}" == "mobile"
echo "tizen_profile_name is 'mobile'"
-%define STARTER_FEATURE_LITE "ENABLE"
-export CFLAGS="$CFLAGS -DFEATURE_LITE"
-export CXXFLAGS="$CXXFLAGS -DFEATURE_LITE"
+%define TIZEN_PROFILE_NAME "MOBILE"
+export CFLAGS="$CFLAGS -DTIZEN_PROFILE_MOBILE"
+export CXXFLAGS="$CXXFLAGS -DTIZEN_PROFILE_MOBILE"
+%else if "%{?tizen_profile_name}" == "wearable"
+echo "tizen_profile_name is 'wearable'"
+%define TIZEN_PROFILE_NAME "WEARABLE"
+export CFLAGS="$CFLAGS -DTIZEN_PROFILE_WEARABLE"
+export CXXFLAGS="$CXXFLAGS -DTIZEN_PROFILE_WEARABLE"
+%endif
+
+%ifarch %{arm}
+export CFLAGS="$CFLAGS -DTIZEN_BUILD_TARGET"
+export CXXFLAGS="$CXXFLAGS -DTIZEN_BUILD_TARGET"
+%else
+export CFLAGS="$CFLAGS -DTIZEN_BUILD_EMULATOR"
+export CXXFLAGS="$CXXFLAGS -DTIZEN_BUILD_EMULATOR"
%endif
-cmake . -DSTARTER_FEATURE_LITE=%{STARTER_FEATURE_LITE} -DCMAKE_INSTALL_PREFIX=%{_prefix}
+cmake . -DTIZEN_PROFILE_NAME=%{TIZEN_PROFILE_NAME} -DCMAKE_INSTALL_PREFIX=%{_prefix}
make
make -j1
@@ -87,14 +104,17 @@ rm -rf %{buildroot}
mkdir -p %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants
install -m 0644 %SOURCE1 %{buildroot}%{_libdir}/systemd/system/starter.service
+install -m 0644 %SOURCE2 %{buildroot}%{_libdir}/systemd/system/starter-pre.service
ln -s ../starter.service %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants/starter.service
mkdir -p %{buildroot}%{_libdir}/systemd/system/tizen-system.target.wants
-install -m 0644 %SOURCE2 %{buildroot}%{_libdir}/systemd/system/wait-lock.service
-ln -s ../wait-lock.service %{buildroot}%{_libdir}/systemd/system/tizen-system.target.wants/
mkdir -p %{buildroot}/usr/share/license
cp -f LICENSE %{buildroot}/usr/share/license/%{name}
mkdir -p %{buildroot}/opt/data/home-daemon
+mkdir -p %{buildroot}%{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
+ln -s %{_libdir}/systemd/system/starter.service %{buildroot}%{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
+ln -s %{_libdir}/systemd/system/starter-pre.service %{buildroot}%{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
+
%post
change_file_executable()
{
@@ -104,38 +124,7 @@ change_file_executable()
fi
}
-GOPTION="-u 5000 -f"
-SOPTION="-s system::vconf_inhouse"
-POPTION="-s starter_private::vconf"
-LOPTION="-s system::vconf_setting"
-
-vconftool set -t string file/private/lockscreen/pkgname "org.tizen.lockscreen" $GOPTION $POPTION
-vconftool set -t string file/private/lockscreen/default_pkgname "org.tizen.lockscreen" $GOPTION $POPTION
-
-vconftool set -t int memory/idle_lock/state "0" -i $GOPTION $LOPTION
-vconftool set -t bool memory/lockscreen/phone_lock_verification 0 -i $GOPTION $SOPTION
-
-vconftool set -t int memory/idle-screen/safemode "0" -i $GOPTION $SOPTION
-
-vconftool set -t int "memory/starter/sequence" 0 -i $GOPTION $SOPTION
-vconftool set -t int "memory/starter/use_volume_key" 0 -i $GOPTION $SOPTION
-vconftool set -t int db/starter/missed_call "0" -i -u 5000 -f $SOPTION
-vconftool set -t int db/starter/unread_message "0" -i -u 5000 -f $SOPTION
-
-vconftool set -t string db/svoice/package_name "com.samsung.svoice" -i -u 5000 -f -s svoice::vconf
-
-vconftool set -t string memory/idle-screen/focused_package "" -i $GOPTION $POPTION
-vconftool set -t int memory/idle-screen/is_idle_screen_launched 0 -i $GOPTION $POPTION
-
-vconftool set -t bool memory/lockscreen/sview_state 0 -i $GOPTION $SOPTION
-
-vconftool set -t int memory/lockscreen/security_auto_lock 1 -i $GOPTION $SOPTION
-
-vconftool set -t int file/private/lockscreen/bt_out -70 $GOPTION $POPTION
-vconftool set -t int file/private/lockscreen/bt_in -60 $GOPTION $POPTION
-
mkdir -p %{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
-ln -s %{_libdir}/systemd/system/wait-lock.service %{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
#ln -sf /etc/init.d/rd4starter /etc/rc.d/rc4.d/S81starter
#ln -sf /etc/init.d/rd4starter /etc/rc.d/rc3.d/S81starter
@@ -150,8 +139,15 @@ sync
%{_bindir}/starter
%{_libdir}/systemd/system/starter.service
%{_libdir}/systemd/system/multi-user.target.wants/starter.service
-%{_libdir}/systemd/system/wait-lock.service
-%{_libdir}/systemd/system/tizen-system.target.wants/wait-lock.service
+%{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/starter.service
+%{_libdir}/systemd/system/starter-pre.service
+%{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/starter-pre.service
/usr/share/license/%{name}
/opt/data/home-daemon
/usr/share/locale/*/LC_MESSAGES/*
+/etc/smack/accesses.d/starter.efl
+
+#FOR PASSWORD LOCKSCREEN
+%if "%{?tizen_profile_name}" == "mobile"
+/usr/share/starter/lock_pwd/res/edje/*
+%endif
diff --git a/packaging/wait-lock.service b/packaging/wait-lock.service
deleted file mode 100755
index 1147161..0000000
--- a/packaging/wait-lock.service
+++ /dev/null
@@ -1,14 +0,0 @@
-[Unit]
-Description=wait lockscreen
-After=tizen-boot.target boot-animation.service
-Requires=tizen-boot.target
-Before=tizen-system.target
-ConditionPathExists=|/tmp/.passwordlock
-
-[Service]
-Type=oneshot
-ExecStart=/bin/sh -c 'while [ -e /tmp/.passwordlock ]; do sleep 0.5 ; done'
-TimeoutSec=7s
-
-[Install]
-WantedBy=tizen-system.target
diff --git a/po/CMakeLists.txt b/po/CMakeLists.txt
index 51ec894..df8983d 100755..100644
--- a/po/CMakeLists.txt
+++ b/po/CMakeLists.txt
@@ -1,6 +1,16 @@
# for i18n
-SET(POFILES az.po bg.po ca.po cs.po da.po de.po el_GR.po en.po en_US.po es_ES.po et.po eu.po fi.po fr_CA.po fr.po gl.po hr.po hu.po hy.po is.po it_IT.po ka.po kk.po ko_KR.po lt.po lv.po mn_MN.po nb.po nl.po pl.po pt_BR.po pt_PT.po ro.po ru_RU.po sk.po sl.po sr.po sv.po tr_TR.po uk.po uz.po)
+SET(POFILES
+ ar.po az.po bg.po bn.po ca.po cs.po da.po de.po
+ el_GR.po en.po en_PH.po en_US.po es_ES.po es_US.po
+ et.po eu.po fa.po fi.po fr.po fr_CA.po ga.po gl.po
+ gu.po he.po hi.po hr.po hu.po hy.po is.po it_IT.po
+ ja_JP.po ka.po kk.po kn.po ko_KR.po lt.po lv.po mk.po
+ ml.po mn_MN.po nb.po nl.po pl.po pt_BR.po pt_PT.po
+ ro.po ru_RU.po si.po sk.po sl.po sr.po sv.po ta.po
+ te.po th.po tr_TR.po uk.po ur.po uz.po zh_CN.po
+ zh_HK.po zh_TW.po
+ )
SET(MSGFMT "/usr/bin/msgfmt")
diff --git a/po/ar.po b/po/ar.po
new file mode 100644
index 0000000..ecd8035
--- /dev/null
+++ b/po/ar.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "تتبقى محاولة واحدة."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "محاولات متبقية %d"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "كلمة مرور غير صحيحة."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "يتعذر بدء %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "موافق"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "خطأ PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "أدخل PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "أدخل كلمة المرور."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "لقد حاولت إلغاء قفل الجهاز %1$d من المرات بطريقة غير صحيحة. تبقّت لك %2$d من المحاولات قبل إعادة تعيين الجهاز إلى ضبط المصنع الافتراضي ومسح جميع البيانات."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "أعد المحاولة خلال %d ثوان."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "إدخال رقم PIN لعرض الرسالة"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "إدخال رقم PIN لعرض سجل المكالمات"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "لقد حاولت إلغاء قفل الجهاز %d مرات بطريقة غير صحيحة. سوف تتم الآن إعادة تعيين الجهاز إلى إعدادات المصنع الافتراضية وسيتم مسح جميع البيانات."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "يلزم إدخال %1$d إلى %2$d أرقام أو حروف."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "مكالمة طوارئ"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "تحذير"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "إلغاء"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "لقد أجريت %1$d من المحاولات غير الناجحة لإلغاء قفل جهازك. حاول مرة أخرى خلال %2$d من الثواني."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "يتعذر إلغاء قفل الشاشة"
+
diff --git a/po/az.po b/po/az.po
index f9ef67f..8cc6b55 100644
--- a/po/az.po
+++ b/po/az.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Ekran oxuyucusu aktivdir."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 cəhd qalmışdır."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Ekran oxuyucusu qeyri-aktivdir."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d cəhd qalıb."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Yanlış şifrə."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s-ə başlamaq mümkün deyildir."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Yanlış PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN daxil et."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Kodu daxil et."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Siz %1$d dəfə cihazın kilidini səhv açmağa cəhd etmisiniz. Sizin cihazın defolt parametrlərinə bərpa edilməsi və bütün məlumatların silinməsi üçün %2$d cəhdiniz qalır."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d saniyə yenidən cəhd et."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Mesaja baxmaq üçün PIN daxil et"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Zəng jurnalına baxmaq üçün PIN daxil et"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Siz %d dəfə cihazın kilidini səhv açmağa cəhd etmisiniz. Bu, zavod parametrlərinə bərpa edəcək və bütün məlumatlar silinəcək"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d - %2$d rəqəm və ya hərf tələb olunur."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Təcili zəng"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Xəbərdarlıq"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Ləğv et"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Siz cihazı kiliddən açmaq üçün %1$d dəfə uğursuz cəhd etmisiniz. %2$d saniyə ərzində yenidən cəhd edin."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Ekr kilid açmaq müm olm"
diff --git a/po/bg.po b/po/bg.po
index 2128e0a..3ef4412 100644
--- a/po/bg.po
+++ b/po/bg.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Екранният четец е активиран."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 оставащ опит."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Екранният четец е деактивиран."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Остават %d опита."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Грешна парола."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Не може да се стартира %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Неправилен PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Въведете PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Въвеждане на парола"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Опитахте да отключите устройството неуспешно %1$d пъти. Остават ви още %2$d опита, преди устройството да се рестартира до фабричните настройки по подразбиране и всички данни да бъдат изтрити."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Опитайте пак след %d сек."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Въведете PIN за преглед на съобщението"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Въведете PIN за преглед на дневника на повикванията"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Опитахте да отключите устройството неуспешно %d пъти. Сега то ще се рестартира до фабричните настройки по подразбиране и всички данни ще бъдат изтрити."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Задължителни са %1$d до %2$d цифри или букви."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Спешно повикване"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Предупреждение"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Отказ"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Направили сте %1$d неуспешни опита да отключите устройството си. Опитайте отново след %2$d секунди."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Екранът не може да се отключи"
diff --git a/po/bn.po b/po/bn.po
new file mode 100644
index 0000000..f9db98f
--- /dev/null
+++ b/po/bn.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1টি চেষ্টা বাকী।"
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%dটি প্রয়াস বাকি।"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "ভুল পাসওয়ার্ড।"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s লঞ্চ করা যায়নি।"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ওকে"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "ভুল PIN।"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN লিখুন।"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "পাসওয়ার্ড লিখুন।"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "আপনি ডিভাইসটি %1$d বার ভুলভাবে আনলক করার প্রয়াস করেছেন। ডিভাইসটি ফ্যাক্টরি ডিফল্টে পুনরায় সেট করার এবং সমস্ত তথ্য মুছে যাওয়ার আগে আপনার আর %2$dটি প্রয়াস অবশিষ্ট রয়েছে।"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d সেকেন্ড পরে আবার চেষ্টা করুন।"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "বার্তা দেখতে PIN লিখুন"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "কল লগ দেখতে PIN লিখুন"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "আপনি ডিভাইসটি ত্রুটিপূর্ণ উপায়ে %d বার আনলক করার প্রয়াস করেছেন। এটি এখন ফ্যাক্টরি ডিফল্টে পুনরায় সেট হবে এবং সমস্ত তথ্য মুছে যাবে"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d থেকে %2$dটি সংখ্যা বা অক্ষর প্রয়োজনীয়।"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "আপৎকালীন কল"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "সাবধানতা"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "বাতিল"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "আপনার ডিভাইসটি আনলক করতে আপনি %1$dটি অসফল প্রয়াস করেছেন। %2$d সেকেন্ডে পুনরায় চেষ্টা করুন।"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "স্ক্রিন আনলক করতে অক্ষম"
+
diff --git a/po/ca.po b/po/ca.po
index e41dbf4..3b54fa0 100644
--- a/po/ca.po
+++ b/po/ca.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Lector de pantalla habilitat."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Queda 1 intent"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Lector de pantalla deshabilitat."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Queden %d intents"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Contrasenya incorrecta"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "No es pot iniciar %s"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "Acceptar"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN incorrecte"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Introdueixi PIN"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Introduir contrasenya"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Ha intentat desbloquejar el dispositiu de forma incorrecta %1$d cops. Li queden %2$d intents abans que el dispositiu es restableixi als valors predeterminats de fàbrica i s'esborrin totes les dades."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Torni a intentar en %d s"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Introdueixi el PIN per veure el missatge"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Introdueixi el PIN per veure el registre de trucades"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Ha intentat desbloquejar el dispositiu de forma incorrecta %d cops. Ara es restablirà als valors predeterminats de fàbrica i s'esborraran totes les dades."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Calen de %1$d a %2$d dígits o lletres"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Trucada d'emergència"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Advertiment"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancel"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Ha intentat desbloquejar el dispositiu de manera incorrecta %1$d cops. Torni-ho a intentar en %2$d segons."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "No es pot desbloq. la pantalla"
diff --git a/po/cs.po b/po/cs.po
index f2a093b..7253b83 100644
--- a/po/cs.po
+++ b/po/cs.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Čtečka displeje byla zapnuta."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Zbývá 1 pokus."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Čtečka displeje byla vypnuta."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Počet zbývajících pokusů: %d."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Nesprávné heslo."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Nelze spustit %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Chybný PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Zadat PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Zadejte heslo."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "%1$dkrát jste se chybně pokusili odemknout zařízení. Po %2$d dalších neúspěšných pokusech se obnoví výchozí nastavení zařízení a všechna data budou vymazána."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Opakujte akci za %d s."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Zadejte PIN kód pro zobrazení zprávy"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Zadejte PIN kód pro zobrazení protokolu hovorů"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "%dkrát jste se chybně pokusili odemknout zařízení. Nyní se obnoví výchozí nastavení a všechna data budou vymazána."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Musí obsahovat %1$d až %2$d číslic nebo písmen."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Tísňové volání"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Upozornění"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Storno"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "%1$dkrát jste se neúspěšně pokusili odemknout zařízení. Opakujte akci za %2$d sekund."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Displej nelze odemknout"
diff --git a/po/da.po b/po/da.po
index 04b2a51..e5fae14 100644
--- a/po/da.po
+++ b/po/da.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Skærmlæser aktiveret."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 forsøg tilbage."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Skærmlæser deaktiveret."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d forsøg tilbage."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Forkert adgangskode."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Kunne ikke starte %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Forkert PIN-kode."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Angiv PIN-kode."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Angiv adgangskode."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Du har brugt %1$d forkerte forsøg på at oplåse enheden. Du har %2$d forsøg tilbage, før enheden nulstilles til fabriksstandarderne, og alle data slettes."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Prøv igen om %d sekunder."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Angiv PIN-kode for at se besked"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Angiv PIN-kode for at se opkaldslog"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Du har forgæves forsøgt at låse enheden op %d gange. Den nulstilles nu til fabriksstandarderne, og alle data slettes."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d til %2$d cifre eller bogstaver krævet."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Nødopkald"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Advarsel"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Annullér"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Du har foretaget %1$d mislykkede forsøg på at låse din enhed op. Prøv igen om %2$d sekunder."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Kan ikke låse skærmen op"
diff --git a/po/de.po b/po/de.po
index 516f1da..e2368bd 100644
--- a/po/de.po
+++ b/po/de.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Bildschirmleseprogramm aktiviert."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Noch 1 Versuch"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Bildschirmleseprogramm deaktiviert."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d Versuche übrig"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Falsches Passwort"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s kann nicht gestartet werden"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Falsche PIN"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN eingeben"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Passwort eingeben"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Sie haben %1$d Mal fehlerhaft versucht, das Gerät zu entsperren. Sie haben noch %2$d Versuche. Danach wird das Gerät auf die Werkseinstellungen zurückgesetzt, und alle Daten werden gelöscht."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "In %d s erneut versuchen."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Geben Sie die PIN ein, um die Nachricht anzuzeigen."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Geben Sie die PIN ein, um das Anrufprotokoll anzuzeigen."
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Sie haben %d Mal vergeblich versucht, das Gerät zu entsperren. Das Gerät wird jetzt auf die Werkseinstellungen zurückgesetzt und alle Daten gelöscht."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Es sind %1$d bis %2$d Ziffern oder Buchstaben erforderlich."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Notruf"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Warnung"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Abbruch"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Sie haben %1$d Mal vergeblich versucht, das Gerät zu entsperren. Versuchen Sie es in %2$d Sekunden erneut."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Entsperren nicht moglich"
diff --git a/po/el_GR.po b/po/el_GR.po
index 00f22d6..d2e79b3 100644
--- a/po/el_GR.po
+++ b/po/el_GR.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Η εφαρμογή ανάγνωσης οθόνης ενεργοποιήθηκε."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Απομένει 1 προσπάθεια."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Η εφαρμογή ανάγνωσης οθόνης απενεργοποιήθηκε."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d προσπάθειες απομένουν."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Λάθος κωδικός."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Αδύνατη η εκκίνηση του %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Λανθασμένο PIN κλειδώματος"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Εισαγωγή PIN κλειδώματος."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Εισαγωγή κωδικού."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Έχετε επιχειρήσει να ξεκλειδώσετε τη συσκευή %1$d φορές εσφαλμένα. Έχουν απομείνει %2$d προσπάθειες μέχρι την επαναφορά των εργοστασιακών ρυθμίσεων και τη διαγραφή όλων των δεδομένων της συσκευής"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Δοκιμ. ξανά σε %d δευτ."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Καταχώριση PIN για προβολή του μηνύματος"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Καταχώριση PIN για προβολή του αρχείου κλήσεων"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Έχετε επιχειρήσει να ξεκλειδώσετε τη συσκευή %d φορές εσφαλμένα. Θα γίνει επαναφορά των εργοστασιακών ρυθμίσεων όλα τα δεδομένα θα διαγραφούν."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Απαιτούνται από %1$d έως %2$d ψηφία ή γράμματα."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Κλήση έκτακτης ανάγκης"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Προειδοποίηση"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Ακύρωση"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Προσπαθήσατε %1$d φορές να ξεκλειδώσετε τη συσκευή σας χωρίς επιτυχία. Δοκιμάστε ξανά σε %2$d δευτερόλεπτα."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Ξεκλείδωμα οθόνης μη δυνατό"
diff --git a/po/en.po b/po/en.po
index 41ba44d..29903c5 100644
--- a/po/en.po
+++ b/po/en.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Screen reader enabled."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 attempt left."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Screen reader disabled."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d attempts left."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Incorrect password."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Unable to launch %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Incorrect PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Enter PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Enter password."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "You have attempted to unlock the device incorrectly %1$d times. You have %2$d attempts left before the device is reset to factory defaults and all data is erased."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Try again in %d seconds."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Enter PIN to view message"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Enter PIN to view call log"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "You have attempted to unlock the device incorrectly %d times. It will now be reset to factory defaults and all data will be erased."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d to %2$d digits or letters required."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Emergency call"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Warning"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancel"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "You have made %1$d unsuccessful attempts to unlock your device. Try again in %2$d seconds."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Unable to unlock screen"
diff --git a/po/en_PH.po b/po/en_PH.po
new file mode 100644
index 0000000..6ff6f94
--- /dev/null
+++ b/po/en_PH.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 attempt left."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d attempts left."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Incorrect password."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Unable to launch %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Incorrect PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Enter PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Enter password"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "You have attempted to unlock the device incorrectly %1$d times. You have %2$d attempts left before the device is reset to factory defaults and all data is erased."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Try again in %d seconds."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Enter PIN to view message"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Enter PIN to view call log"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "You have attempted to unlock the device incorrectly %d times. It will now be reset to factory defaults and all data will be erased."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d to %2$d digits or letters required."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Emergency call"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Warning"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancel"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "You have made %1$d unsuccessful attempts to unlock your device. Try again in %2$d seconds."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Unable to unlock screen"
+
diff --git a/po/en_US.po b/po/en_US.po
index 2a2607e..7ec17e0 100644
--- a/po/en_US.po
+++ b/po/en_US.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Screen reader turned on."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 attempt left."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Screen reader turned off."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d attempts left."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Incorrect password."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Unable to launch %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Incorrect PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Enter PIN"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Enter password"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "You have attempted to unlock the device incorrectly %1$d times. You have %2$d attempts left before the device is reset to factory defaults and all data is erased."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Try again in %d seconds."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Enter PIN to view message"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Enter PIN to view call log"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "You have attempted to unlock the device incorrectly %d times. It will now be reset to factory defaults and all data will be erased."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d to %2$d digits or letters required."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Emergency call"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Warning"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancel"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "You have made %1$d unsuccessful attempts to unlock your device. Try again in %2$d seconds."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Unable to unlock screen"
diff --git a/po/es_ES.po b/po/es_ES.po
index 7dd881f..f7e2f19 100644
--- a/po/es_ES.po
+++ b/po/es_ES.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Lector de pantalla activado."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Último intento"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Lector de pantalla desactivado."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Quedan %d intentos."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Contraseña incorrecta"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "No se puede iniciar %s"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN incorrecto"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Introducir PIN"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Introducir contraseña"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Ha intentado desbloquear el dispositivo de forma incorrecta %1$d veces. Le quedan %2$d intentos antes de que el dispositivo se restablezca a los valores predeterminados de fábrica y se eliminen todos los datos."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Int. de nuevo en %d seg"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Introduzca el PIN para ver el mensaje"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Introduzca el PIN para ver el registro de llamadas"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Ha intentado desbloquear el dispositivo de forma incorrecta %d veces. Ahora se restablecerá a los valores predeterminados de fábrica y se eliminarán todos los datos."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Se requieren de %1$d a %2$d dígitos o letras"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Llamada de emergencia"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Aviso"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancelar"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Ha intentado desbloquear su dispositivo %1$d veces sin éxito. Vuelva a intentarlo dentro de %2$d segundos."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "No se puede desbloq pantalla"
diff --git a/po/es_US.po b/po/es_US.po
index 7dd881f..2d14448 100644
--- a/po/es_US.po
+++ b/po/es_US.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Lector de pantalla activado."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Último intento."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Lector de pantalla desactivado."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Quedan %d intentos."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Contraseña incorrecta."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "No es posible iniciar %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "Aceptar"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN incorrecto."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Introducir PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Introducir contraseña."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Intentó desbloquear el dispositivo incorrectamente %1$d veces. Le quedan %2$d intentos antes de que el dispositivo se restablezca a sus valores predeterminados de fábrica y se eliminen todos los datos."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Intentar de nuevo en %d segundos"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Introducir PIN para ver mensaje"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Introducir PIN para ver registro de llamadas"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Intentó desbloquear el dispositivo incorrectamente %d veces. Ahora se restablecerá a sus valores predeterminados de fábrica y se eliminarán todos los datos."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Se requieren de %1$d a %2$d dígitos o letras."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Llamada de emergencia"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Aviso"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancelar"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Ha intentado desbloquear su dispositivo %1$d veces sin éxito. Vuelva a intentarlo dentro de %2$d segundos."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "No es posible desbloquear"
diff --git a/po/et.po b/po/et.po
index 7319504..a549be3 100644
--- a/po/et.po
+++ b/po/et.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Ekraanilugeja on aktiveeritud."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 katse on jäänud."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Ekraanilugeja on desaktiveeritud."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d katset jäänud."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Vale parool."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Üksust %s ei saa käivitada."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Vale PIN-kood."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Sisestage PIN-kood."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Sisestage parool."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Te olete proovinud seadet valesti lukust avada %1$d korda. %2$d katset on jäänud enne, kui seade lähtestatakse tehase vaikeseadetele ja kõik andmed kustutatakse."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Proovige %d sek parast."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Sisestage sõnumi kuvamiseks PIN-kood"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Sisestage kõnelogi kuvamiseks PIN-kood"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Te olete proovinud seadet valesti lukust avada %d korda. Nüüd lähtestatakse see tehase vaikeseadetele ning kõik andmed kustutatakse."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Nõutud on %1$d kuni %2$d numbrit või tähte."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Hädaabikõne"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Hoiatus"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Tühista"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Olete teinud seadme avamisel %1$d ebaõnnestunud katset. Proovige %2$d sekundi pärast uuesti."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Ekraani ei saa avada"
diff --git a/po/eu.po b/po/eu.po
index c8955fa..d52315f 100644
--- a/po/eu.po
+++ b/po/eu.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Pantaila irakurgailua gaituta."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Ahalegin 1 gelditzen zaizu"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Pantaila irakurgailua ezgaituta."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d saiakera geratzen dira"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Pasahitz okerra"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Ezin da %s abiatu"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "Ados"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN okerra"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PINa idatzi"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Pasahitza idatzi"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Gailua modu desegokian desblokeatzen saiatu zara %1$d aldiz. %2$d saio geratzen zaizkizu gailuan fabrikako hobespenak berrezarri eta datu guztiak ezabatu aurretik."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Saiatu berriz %d segundoren ondoren"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Idatzi PINa mezua ikusteko"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Idatzi PINa dei erregistroa ikusteko"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Gailua modu desegokian desblokeatzen saiatu zara %d aldiz. Orain, fabrikako hobespenak berrezarri eta datu guztiak ezabatuko dira."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d eta %2$d digitu edo letra artean behar dira"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Emergentzia deia"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Oharra"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Ezeztatu"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Gailua desblokeatzeko %1$d saio oker egin dituzu. Saiatu berriz %2$d segundo barru."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Ezin izan da pantaila desblokeatu"
diff --git a/po/fa.po b/po/fa.po
new file mode 100644
index 0000000..4f9fcbe
--- /dev/null
+++ b/po/fa.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 تلاش باقی مانده است."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d فرصت داريد."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "رمز اشتباه است."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "راه‌اندازی %s ممکن نیست."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "تأیید"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "پين اشتباه است."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "پین را وارد کنيد."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "رمز را وارد کنيد."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "%1$d مرتبه سعی کردید قفل دستگاه را اشتباه باز کنید. ‎%2$d تلاش دیگر باقی مانده است تا دستگاه به پیش‌فرض کارخانه بازنشانی شده و همه داده‌ها پاک شوند."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "پس از %d ثانیه دوباره امتحان کنید."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "برای مشاهده پیام پین را وارد کنید"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "برای مشاهده گزارش تماس پین را وارد کنید"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "%d مرتبه سعی کرده اید بطور نادرست قفل دستگاه را باز کنید. اکنون دستگاه به پیش فرض کارخانه بازنشانی شده و همه داده ها پاک خواهند شد."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d تا %2$d رقم یا حرف الزامی است."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "تماس اضطراری"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "هشدار"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "لغو"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "شما ‎%1$d تلاش ناموفق برای باز کردن قفل دستگاهتان داشته‌اید. ‎%2$d ثانیه دیگر دوباره امتحان کنید."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "باز کردن قفل صفحه ممکن نیست"
+
diff --git a/po/fi.po b/po/fi.po
index 7a43509..efd48b4 100644
--- a/po/fi.po
+++ b/po/fi.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Näytönlukija on käytössä."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 yritys jäljellä"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Näytönlukija on poistettu käytöstä."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d yritystä jäljellä"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Virheellinen salasana"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Sovellusta %s ei voi käynnistää."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Virheellinen PIN-koodi."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Anna PIN-koodi."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Kirjoita salasana."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Olet yrittänyt poistaa laitteen lukituksen virheellisesti %1$d kertaa. Sinulla on %2$d yrityskertaa jäljellä, ennen kuin laitteen tehdasasetukset palautetaan ja kaikki tiedot poistetaan."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Yritä %d s kul. uudelleen."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Anna PIN-koodi viestin tarkastelua varten"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Anna PIN-koodi puhelulokin tarkastelua varten"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Olet yrittänyt poistaa laitteen lukituksen virheellisesti %d kertaa. Laitteen tehdasasetukset palautetaan ja kaikki tiedot poistetaan."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Oltava %1$d–%2$d numeroa tai kirjainta."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Hätäpuhelu"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Varoitus"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Peruuta"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Laitteen lukituksen poistaminen epäonnistui %1$d kertaa. Yritä %2$d sekunnin kuluttua uudelleen."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Näytön lukit. ei voi poistaa"
diff --git a/po/fr.po b/po/fr.po
index 7efde4d..29eb6b7 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Lecteur d'écran activé."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 essai restant"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Lecteur d'écran désactivé."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d essais restants"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Mot de passe incorrect"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Impossible de lancer %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Code PIN incorrect"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Saisir le code PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Saisir le mot de passe."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Vous avez essayé de déverrouiller l'appareil de façon incorrecte à %1$d reprises. Il reste %2$d tentatives avant le rétablissement des paramètres d'origine et la suppression de toutes les données."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Réessayez dans %d secondes."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Saisir le code PIN pour afficher le message"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Saisir le code PIN pour afficher le journal d'appels"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Vous avez essayé de déverrouiller l'appareil de façon incorrecte à %d reprises. Les paramètres d'origine vont maintenant être rétablis et toutes les données effacées."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d à %2$d chiffres ou lettres requis"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Appel d'urgence"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Avertissement"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Annuler"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Le déverrouillage de votre appareil a échoué à %1$d reprises. Réessayez dans %2$d secondes."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Impossible déverrouiller écran"
diff --git a/po/fr_CA.po b/po/fr_CA.po
index 7efde4d..45e6b58 100644
--- a/po/fr_CA.po
+++ b/po/fr_CA.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Lecteur d'écran activé."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 essai restant."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Lecteur d'écran désactivé."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d essais restants."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Mot de passe incorrect."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Impossible de lancer %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "NIP incorrect"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Saisir le NIP."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Saisir le mot de passe."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Vous avez essayé de déverrouiller l'appareil de façon incorrecte à %1$d reprises. Il reste %2$d tentatives avant le rétablissement des paramètres d'origine et la suppression de toutes les données."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Réessayez ds %d secondes."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Saisir le code NIP pour afficher le message"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Saisir le code NIP pour afficher le journal d'appels"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Vous avez essayé de déverrouiller l'appareil de façon incorrecte à %d reprises. Les paramètres d'origine vont maintenant être rétablis et toutes les données effacées."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d à %2$d chiffres ou lettres requis."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Appel d'urgence"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Avertissement"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Annuler"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Le déverrouillage de votre appareil a échoué à %1$d reprises. Réessayez dans %2$d secondes."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Impossible déverrouiller écran"
diff --git a/po/ga.po b/po/ga.po
new file mode 100644
index 0000000..a2daa3d
--- /dev/null
+++ b/po/ga.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 iarracht fágtha."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d iarracht fágtha."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Pasfhocal mícheart."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Ní féidir %s a lainseáil."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN mícheart."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Iontráil PIN"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Iontráil pasfhocal"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Rinne tú iarracht mhícheart an gléas a dhíghlasáil %1$d uair. Tá %2$d iarracht fágtha sula bhfillfear an gléas ar réamhshocruithe monarchan agus sula scriosfar gach sonra."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Triail arís i gceann %d soicind"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Iontráil PIN le hamharc ar an teachtaireacht"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Iontráil PIN le hamharc ar an loga glaonna"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Rinne tú iarracht mhícheart an gléas a dhíghlasáil %d uair. Socrófar anois chuig na réamhshocruithe monarchan é agus scriosfar na sonraí go léir."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d suas le %2$d digit nó litir de dhíth."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Glao éigeandála"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Rabhadh"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cealaigh"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Rinne tú %1$d iarracht nár éirigh leo le do ghléas a dhíghlasáil. Triail arís i gceann %2$d soicind."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Díghlasáil scáil. dodhéanta."
+
diff --git a/po/gl.po b/po/gl.po
index 7dd881f..e3ce975 100644
--- a/po/gl.po
+++ b/po/gl.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Lector de pantalla activado."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Queda 1 intento"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Lector de pantalla desactivado."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Quedan %d intentos"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Contrasinal non válido"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Non se pode iniciar %s"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "Aceptar"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN incorrecto"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Introducir PIN"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Introduza o contrasinal"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Tentaches desbloquear o dispositivo incorrectamente %1$d veces. Quédanche %2$d intentos antes de que se restablezan os axustes predeterminados de fábrica e se eliminen todos os datos do dispositivo."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Ténteo de novo en %d seg."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Introduce o PIN para ver a mensaxe"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Introduce o PIN para ver o rexistro de chamadas"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Tentaches desbloquear o dispositivo incorrectamente %d veces. Agora restableceranse os axustes predeterminados de fábrica e borraranse todos os datos."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Precísanse entre %1$d e %2$d díxitos ou letras"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Chamada de urxencia"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Aviso"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancelar"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Realizaches %1$d intentos sen éxito de desbloquear o dispositivo. Téntao de novo dentro de %2$d segundos."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Imposible desbloquear pantalla"
diff --git a/po/gu.po b/po/gu.po
new file mode 100644
index 0000000..7b5bec3
--- /dev/null
+++ b/po/gu.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 પ્રયત્ન બાકી."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d પ્રયત્ન બાકી."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "ખોટો પાસવર્ડ."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s ને લોંચ કરવામાં અક્ષમ."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ઓકે"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "ખોટો PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN દાખલ કરો."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "પાસવર્ડ દાખલ કરો."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "%1$d વખત અયોગ્ય રીતે ઉપકરણ અનલોક કરવા માટે તમે પ્રયાસ કરેલ છે. ઉપકરણ ફૅકટરી ડિફોલ્ટ્સમાં રીસૅટ થાય તે પહેલાં તમારો %2$d પ્રયાસ બાકી છે અને તમામ ડેટા ભૂંસાઇ જશે."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d સેકંડ્સ પછી ફરી પ્રયત્ન કરો."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "સંદેશ જોવા માટે PIN દાખલ કરો"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "કૉલ લોગ જોવા માટે PIN દાખલ કરો"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "તમે ઉપકરણને %d વાર ખોટી રીતે અનલોક કરવાનો પ્રયાસ કર્યો છે. હવે તેને ફેકટરી મૂળભૂત પર ફરીથી ગોઠવવામાં આવશે અને બધો ડેટા ભૂંસી નાખવામાં આવશે"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d થી %2$d અંકો અથવા પત્રો આવશ્યક છે."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "તાત્કાલિક કૉલ"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "ચેતવણી"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "રદ કરો"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "તમારા ઉપકરણને અનલોક કરવા માટે તમે %1$d અસફળ પ્રયાસ કર્યા છે. %2$d સેકંડ્સમાં ફરી પ્રયાસ કરો."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "સ્ક્રીનને અનલોક કરવામાં અસમર્થ"
+
diff --git a/po/he.po b/po/he.po
new file mode 100644
index 0000000..ace2950
--- /dev/null
+++ b/po/he.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "נותר 1 ניסיון."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "נותרו %d ניסיונות."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "סיסמה שגויה."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "לא ניתן להפעיל את %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "אישור"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "קוד PIN שגוי."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "הזן PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "הזן סיסמה."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "ביצעת %1$d ניסיונות שגויים לבטל את נעילת המכשיר. לרשותך עוד %2$d ניסיונות לפני איפוס המכשיר לערכי ברירת המחדל של היצרן ומחיקת כל הנתונים."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "נסה שוב בעוד %d שניות."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "הזן קוד PIN כדי להציג הודעה"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "הזן קוד PIN כדי להציג יומן שיחות"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "ניסית לבטל את נעילת המכשיר באופן שגוי %d פעמים. הוא יאופס כעת לברירות המחדל של היצרן וכל הנתונים יימחקו."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "יש צורך ב-%1$d עד %2$d ספרות או אותיות."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "שיחת חירום"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "אזהרה"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "ביטול"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "ביצעת %1$d ניסיונות כושלים לביטול נעילת המכשיר שלך. נסה שוב בעוד %2$d שניות."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "לא ניתן לבטל נעילת מסך"
+
diff --git a/po/hi.po b/po/hi.po
new file mode 100644
index 0000000..64fa4e0
--- /dev/null
+++ b/po/hi.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 प्रयास शेष।"
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d प्रयास शेष।"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "गलत पासवर्ड।"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s प्रारंभ करने में अक्षम।"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ओके"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "गलत PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN प्रविष्ट करें।"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "पासवर्ड प्रविष्ट करें"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "आपने %1$d बार गलत ढंग से डिवाइस अनलॉक करने का प्रयास किया है। आपके पास डिवाइस फ़ैक्टरी डिफ़ॉल्ट पर रीसेट होने और सभी डाटा मिटने से पहले %2$d प्रयास शेष है।"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d सेकंड में फिर से प्रयास करें।"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "सन्देश देखने के लिए PIN प्रविष्‍ट करें"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "कॉल लॉग देखने के लिए PIN प्रविष्ट करें"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "आपने %d बार ग़लत ढ़ंग से डिवाइस अनलॉक करने का प्रयास किया है। यह अब फ़ैक्टरी डिफ़ॉल्ट में रीसेट किया जाएगा और सभी डाटा मिट जाएगा"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d से %2$d तक अंक या वर्ण आवश्यक।"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "आपातकालीन कॉल"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "चेतावनी"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "रद्द"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "आपने अपना डिवाइस अनलॉक करने के लिए %1$d असफल प्रयास किए हैं। %2$d सेकंड्स में फिर से प्रयास करें।"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "स्क्रीन अनलॉक करने में अक्षम"
+
diff --git a/po/hr.po b/po/hr.po
index b4081ad..c39f364 100644
--- a/po/hr.po
+++ b/po/hr.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Isključen čitač zaslona."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Još 1 pokušaj."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Uključen čitač zaslona."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d pokušaja preostalo."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Neispravna lozinka."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Nemoguće pokrenuti %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "U redu"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Neispravan PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Unesite PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Unesite lozinku."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Pokušali ste neispravno otključati uređaj %1$d puta. Imate još %2$d pokušaja prije nego što se uređaj vrati na tvornički zadane postavke te se svi podaci izbrišu."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Ponovite nakon %d sek."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Unesite PIN za prikaz poruke"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Unesite PIN za prikaz popisa poziva"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Pokušali ste neispravno otključati uređaj %d puta. Vratit će se na tvornički zadane postavke i svi će podaci biti izbrisani."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Potrebno je %1$d do %2$d znamenki ili slova."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "SOS poziv"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Upozorenje"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Prekid"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Neuspješno ste pokušali otključati uređaj %1$d puta. Pokušajte ponovno za %2$d sekundi."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Nije moguće otključati zaslon"
diff --git a/po/hu.po b/po/hu.po
index c6dad99..6e0dfcf 100644
--- a/po/hu.po
+++ b/po/hu.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Képernyőolvasó engedélyezve."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Még 1 próbálkozásra van."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Képernyőolvasó letiltva."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d kísérlet maradt."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Téves jelszó"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "A(z) %s nem indítható el."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Hibás PIN-kód"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Írja be a PIN-kódot!"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Írja be a jelszót."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "%1$d alkalommal helytelenül kísérelte meg az eszköz feloldását. További %2$d sikertelen kísérlet esetén visszaállnak az eszköz gyári alapértelmezései, és minden adat törlődik róla."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Prób. újra %d mp múlva."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Adja meg a PIN-t az üzenet megjelenítéséhez"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Adja meg a PIN-t a hívásnapló megjelenítéséhez"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "%d alkalommal helytelenül kísérelte meg az eszköz feloldását. Most visszaállnak az eszköz gyári alapértelmezései, és minden adat törlődik róla."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d–%2$d számjegy vagy betű szükséges."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Segélyhívás"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Figyelmeztetés"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Mégse"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "%1$d alkalommal sikertelenül próbálta feloldani az eszközt. Próbálja újra %2$d másodperc múlva."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Nem oldható fel a képernyő"
diff --git a/po/hy.po b/po/hy.po
index df2b103..36b2425 100644
--- a/po/hy.po
+++ b/po/hy.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Էկրանի ընթերցողը՝ միաց:"
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 փորձ է մնացել:"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Էկրանի ընթերցողը՝ անջատ:"
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Մնացել է %d փորձ:"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Սխալ գաղտնաբառ:"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Հնարավոր չէ գործարկել %s-ը:"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Սխալ PIN:"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Մուտքագրեք PIN-ը:"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Մուտքագրեք գաղտնաբառը:"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Դուք սարքի արգելաբացման սխալ փորձ եք արել %1$d անգամ: Ձեզ %2$d փորձ է մնացել, նախքան սարքը կհետադարձվի գործարանային կանխադրվածքի, և բոլոր տվյալները կջնջվեն:"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Նորից փորձեք %d վրկ.-ից:"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Մուտքագրեք PIN՝ հաղորդագրությունը դիտելու համար"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Մուտքագրեք PIN՝ կանչերի մատյանը դիտելու համար"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Դուք սարքի արգելաբացման սխալ փորձ եք արել %d անգամ: Այն հիմա կհետադարձվի գործարանային կանխադրվածքի, և բոլոր տվյալները կջնջվեն"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Պահանջվում է %1$d-ից %2$d թվանշան կամ տառ:"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Հրատապ զանգ"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Զգուշացում"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Չեղարկել"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Դուք կատարել եք Ձեր սարքն արգելաբացելու %1$d անհաջող փորձ: Նորից փորձեք %2$d վայրկյանից:"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Անհնար է արգելաբացել էկրանը"
diff --git a/po/is.po b/po/is.po
index 3618b8c..33efc14 100644
--- a/po/is.po
+++ b/po/is.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Kveikt á skjálesara."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 tilraun eftir."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Slökkt á skjálesara."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d tilraunir eftir."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Rangt aðgangsorð."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Mistókst að opna %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "Í lagi"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Rangt PIN-númer."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Sláðu inn PIN-númeri."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Rita aðgangsorð."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Þú hefur reynt að opna tækið á rangan hátt %1$d sinnum. Þú átt %2$d tilraunir eftir áður en tækið verður núllstillt og öllum gögnum þess eytt."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Reyndu aftur eftir %d sek."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Sláðu inn PIN-númer til að skoða skilaboð"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Sláðu inn PIN-númer til að skoða símtalaskrá"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Þú hefur reynt að opna tækið á rangan hátt %d sinnum. Það verður nú endurstillt á grunnstillingar framleiðanda og öllum gögnum verður eytt."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Slá þarf inn %1$d til %2$d stafi."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Neyðarhringing"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Viðvörun"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Hætta v."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Þú hefur gert %1$d misheppnaðar tilraunir til að opna tækið. Reyndu aftur eftir %2$d sekúndur."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Ekki er hægt að opna skjá"
diff --git a/po/it_IT.po b/po/it_IT.po
index 46b8a59..34dd7ac 100644
--- a/po/it_IT.po
+++ b/po/it_IT.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Lettura dello schermo attivata."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 tentativo rimasto."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Lettura dello schermo disattivata."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d tentativi rimasti."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Password errata."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Impossibile avviare %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN errato."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Inserisci PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Inserisci password."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Avete tentato per %1$d volte di sbloccare il dispositivo in modo errato. Sono rimasti %2$d tentativi prima che il dispositivo venga ripristinato ai valori predefiniti di fabbrica e che tutti i dati vengano eliminati."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Riprovate tra %d secondi."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Inserite il PIN per visualizzare il messaggio"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Inserite il PIN per visualizzare il registro chiamate"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "%d tentativi errati di sblocco del dispositivo. Il dispositivo verrà ripristinato ai valori predefiniti di fabbrica e i dati verranno eliminati."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Sono necessarie da %1$d a %2$d cifre o lettere."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Chiamata di emergenza"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Avviso"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Annulla"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Avete effettuato %1$d tentativi errati per sbloccare il dispositivo. Riprovate tra %2$d secondi."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Impossibile sbloccare schermo"
diff --git a/po/ja_JP.po b/po/ja_JP.po
new file mode 100644
index 0000000..986e784
--- /dev/null
+++ b/po/ja_JP.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "残りの試行回数は1回です。"
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "残り入力回数:%d回"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "パスワードが正しくありません。"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%sを起動できません。"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PINが正しくありません。"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PINを入力してください。"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "パスワードを入力"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "正しくないロック解除を%1$d回実行しました。あと%2$d回失敗すると、端末が工場出荷時の状態にリセットされ、全てのデータが削除されます。"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d秒後にやり直してください。"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "メッセージを表示するにはPINを入力します"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "通話履歴を表示するにはPINを入力します"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "正しくないロック解除を%d回実行しました。端末が工場出荷時の状態にリセットされ、全てのデータが削除されます。"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d~%2$d文字の英数字で入力してください。"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "緊急通報"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "警告"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "キャンセル"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "端末のロック解除に%1$d回失敗しました。%2$d秒後に再度実行してください。"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "画面のロック解除不可"
+
diff --git a/po/ka.po b/po/ka.po
index 3ff5ebf..470e48b 100644
--- a/po/ka.po
+++ b/po/ka.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "ეკრანის წამკითხველი ჩართულია."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "დარჩა 1 ცდა."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "ეკრანის წამკითხველი გამორთულია."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d ცდა დარჩა."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "პაროლი არასწორია."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "ვერ გაიხსნება %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "არასწორი PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "შეიყვანეთ PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "პაროლის შეყვანა."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "თქვენ აპარატის განბლოკვის %1$d არასწორი მცდელობა გქონდათ. თქვენ დაგრჩათ %2$d მცდელობა, სანამ დაბრუნდება აპარატის საწყისი ქარხნული პარამეტრები და წაიშლება ყველა მონაცემი."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "კიდევ ცადეთ %d წამში."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "შეიყვანეთ PIN, რომ ნახოთ შეტყობინება"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "შეიყვანეთ PIN, რომ ნახოთ ზარების ჟურნალი"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "თქვენ აპარატის განბლოკვის %d არასწორი მცდელობა გქონდათ. ახლა დაბრუნდება საწყისი ქარხნული პარამეტრები და წაიშლება ყველა მონაცემი"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "უნდა იყოს %1$d-%2$d ციფრი ან ასო."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "საგანგებო ზარი"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "გაფრთხილება"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "გაუქმება"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "თქვენ გქონდათ აპარატის განბლოკვის %1$d წარუმატებელი მცდელობა. ისევ სცადეთ %2$d წამში."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "ეკრანის განბლოკვა შეუძლებელია"
diff --git a/po/kk.po b/po/kk.po
index f307ec9..0145442 100644
--- a/po/kk.po
+++ b/po/kk.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Экран оқу құралы қосылды."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 әрекет қалды."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Экран оқу құралы өшірілді."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d әрекеттену аяқталды."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Қате кілтсөз."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s іске қосу мүмкін емес."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Қате PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN енгізу."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Кілтсөз енгізіңіз."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Құрылғының құлпын ашуда %1$d рет қателестіңіз. Құрылғының зауыттық параметрлері қалпына келтіріліп, барлық деректердің өшірілуінен бұрын %2$d талпынысыңыз қалды."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d сек кейін қайталаңыз."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Хабарды көру үшін, PIN кодын енгізу"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Қоңыраулар журналын көру үшін, PIN кодын енгізу"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "%d рет дұрыс емес құрылғының құлпын ашу әрекетін жасадыңыз. Зауыттық әдепкі параметрлер қалпына келтіріліп, бүкіл деректер өшіріледі"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d-%2$d сан немесе әріп талап етіледі."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Шұғыл қоңырау шалу"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Ескерту"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Тоқтату"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Құрылғы құлпын ашу үшін, %1$d рет сәтсіз әрекет жасалды. Әрекетті %2$d секундтан кейін қайталаңыз."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Экран құлпын ашу мүмкін емес"
diff --git a/po/kn.po b/po/kn.po
new file mode 100644
index 0000000..050163f
--- /dev/null
+++ b/po/kn.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 ಪ್ರಯತ್ನ ಉಳಿದಿದೆ."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d ಪ್ರಯತ್ನಗಳು ಉಳಿದಿವೆ."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "ತಪ್ಪಾದ ಪಾಸ್‌ವರ್ಡ್."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s ಪ್ರಾರಂಭಿಸಲಾಗಲಿಲ್ಲ."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ಓಕೆ"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN ತಪ್ಪಾಗಿದೆ."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN ನಮೂದಿಸಿ."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "ಪಾಸ್‌ವರ್ಡ್ ನಮೂದಿಸಿ."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "ನೀವು ಸಾಧನವನ್ನು ತಪ್ಪಾಗಿ %1$d ಸಲ ಅನ್‌ಲಾಕ್ ಮಾಡಲು ಯತ್ನಿಸಿದ್ದೀರಿ. ಸಾಧನವನ್ನು ಫ್ಯಾಕ್ಟರಿ ಡೀಫಾಲ್ಟ್‌ಗಳಿಗೆ ಮರುನಿಗದಿಗೊಳಿಸುವುದು ಮತ್ತು ಎಲ್ಲ ಡೇಟಾವು ಅಳಿಸಿಹೋಗುವ ಮೊದಲು ನಿಮಗೆ %2$d ಪ್ರಯತ್ನಗಳು ಉಳಿದಿವೆ."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d ಸೆಕೆಂಡುಗಳಲ್ಲಿ ಮತ್ತೊಮ್ಮೆ ಪ್ರಯತ್ನಿಸಿ."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "ಸಂದೇಶವನ್ನು ವೀಕ್ಷಿಸಲು PIN ನಮೂದಿಸಿ"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "ಕರೆ ಲಾಗ್ ವೀಕ್ಷಿಸಲು PIN ನಮೂದಿಸಿ"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "ನೀವು %d ಸಲ ಸಾಧನವನ್ನು ತಪ್ಪಾಗಿ ಅನ್‌ಲಾಕ್ ಮಾಡುವುದಕ್ಕೆ ಪ್ರಯತ್ನಿಸಿರುತ್ತೀರಿ. ಇದನ್ನು ಈಗ ಫ್ಯಾಕ್ಟರಿ ಡೀಫಾಲ್ಟ್‌ಗಳಿಗೆ ಮರುನಿಗದಿಗೊಳಿಸಲಾಗುವುದು ಮತ್ತು ಎಲ್ಲ ಡೇಟಾವನ್ನು ಅಳಿಸಲಾಗುವುದು"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d ರಿಂದ %2$d ಅಂಕಿಗಳು ಅಥವಾ ಅಕ್ಷರಗಳು ಅಗತ್ಯವಿರುತ್ತವೆ."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "ತುರ್ತು ಕರೆ"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "ಎಚ್ಚರಿಕೆ"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "ರದ್ದು"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "ನಿಮ್ಮ ಸಾಧನವನ್ನು ಅನ್‌ಲಾಕ್ ಮಾಡಲು ನೀವು %1$d ಯಶಸ್ವಿಯಾಗದ ಪ್ರಯತ್ನಗಳನ್ನು ಮಾಡಿದ್ದೀರಿ. %2$d ಸೆಕೆಂಡುಗಳಲ್ಲಿ ಮತ್ತೆ ಪ್ರಯತ್ನಿಸಿ."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "ಸ್ಕ್ರೀನ್ ಅನ್‌ಲಾಕ್ ಮಾಡಲು ಸಾಧ್ಯವಾಗಲಿಲ್ಲ"
+
diff --git a/po/ko_KR.po b/po/ko_KR.po
index 42cb3ff..c1c0d17 100644
--- a/po/ko_KR.po
+++ b/po/ko_KR.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "스크린 리더를 실행하였습니다."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "입력 기회가 1회 남았습니다."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "스크린 리더를 해제하였습니다."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "입력 기회가 %d회 남았습니다."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "잘못된 비밀번호를 입력하였습니다."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s을(를) 실행할 수 없습니다."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "확인"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "잘못된 PIN을 입력하였습니다."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN을 입력하세요."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "비밀번호를 입력하세요."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "잠금해제 비밀번호를 %1$d회 잘못 입력하였습니다. 디바이스 설정 및 데이터가 기본 설정으로 초기화되기까지 비밀번호를 %2$d회 입력할 수 있습니다."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d초 후에 다시 시도하세요."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "메시지를 보려면 PIN을 입력하세요"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "통화기록을 보려면 PIN을 입력하세요"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "잠금해제 비밀번호를 %d회 잘못 입력하였습니다. 디바이스 설정을 기본 설정으로 초기화하고 모든 데이터를 삭제합니다."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d-%2$d자의 숫자 또는 문자를 입력하세요."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "긴급전화"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "경고"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "취소"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "잠금해제를 %1$d회 잘못 입력하였습니다. %2$d초 후에 다시 시도하세요."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "화면 잠금을 해제할 수 없음"
diff --git a/po/lt.po b/po/lt.po
index 9b58a9a..f4fd72d 100644
--- a/po/lt.po
+++ b/po/lt.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Ekrano skaitytuvas įjungtas."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Liko 1 bandymas."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Ekrano skaitytuvas išjungtas."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d likę bandymai."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Neteisingas slaptažodis."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Negalima paleisti %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "Gerai"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Netinkamas PIN kodas."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Įvesti PIN kodą."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Įvesti slaptažodį."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Neteisingai bandėte atrakinti įrenginį %1$d kartus (-ų). Prieš grąžinant įrenginio gamyklinius numatytuosius nustatymus ir ištrinant visus duomenis, turėsite %2$d bandymus (-ų)."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Bandykite dar po %d sek."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Įveskite PIN žinutės peržiūrai"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Įveskite PIN skambučių žurnalo peržiūrai"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Neteisingai bandėte atrakinti įrenginį %d kartus (-ų). Dabar bus iš naujo nustatyti gamykliniai numatytieji nustatymai ir ištrinti visi duomenys."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Reikia nurodyti %1$d–%2$d skaitmenis (-ų) ar raides (-ių)."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Pagalbos skambučiai"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Perspėjimas"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Atšaukti"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Jūs %1$d k. nesėkmingai bandėte atrakinti įrenginį. Bandykite dar kartą po %2$d sek."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Neįmanoma atrakinti ekrano"
diff --git a/po/lv.po b/po/lv.po
index d3215f7..82311ee 100644
--- a/po/lv.po
+++ b/po/lv.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Ekrāna lasītājs ir aktivizēts."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Atlicis 1 mēģinājums."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Ekrāna lasītājs ir deaktivizēts."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Atlikuši %d mēģinājumi."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Nepareiza parole."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Nevar palaist %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "Labi"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Nepareizs PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Ievadiet PIN kodu."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Ievadiet paroli."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Jūs %1$d reizes nepareizi mēģinājāt atbloķēt ierīci. Jums ir atlikuši %2$d mēģinājumi, pirms ierīcē tiks atjaunoti rūpnīcas noklusējuma iestatījumi un visi dati tiks izdzēsti."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Mēģiniet vēlr.pēc %d sek."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Ievadiet PIN kodu, lai skatītu ziņu"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Ievadiet PIN kodu, lai skatītu zvanu žurnālu"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Jūs %d reizes neveiksmīgi mēģinājāt atbloķēt ierīci. Tagad tajā tiks atjaunoti rūpnīcas iestatījumi un visi dati tiks izdzēsti."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Nepieciešams ievadīt no %1$d līdz %2$d cipariem vai burtiem."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Ārkārtas zvans"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Brīdinājums"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Atcelt"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Jūs esat veicis %1$d neveiksmīgus ierīces atbloķēšanas mēģinājumus. Mēģiniet vēlreiz pēc %2$d sekundēm."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Nevar atbloķēt ekrānu"
diff --git a/po/mk.po b/po/mk.po
new file mode 100644
index 0000000..c245f51
--- /dev/null
+++ b/po/mk.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Уште 1 обид."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Има уште %d обиди."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Погрешна лозинка."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Не може да се активира %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Погрешен PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Внесете PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Внесете лозинка."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Се обидовте да отклучите уредот неправилно %1$d пати. Имате уште %2$d обиди пред уредот да се ресетира на фабричките поставки и сите податоци да се избришат."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Повт. обид за %d секунди."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Внесете PIN за да ја видите пораката"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Внесете PIN за да го видите дневникот на повици"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Се обидовте да го отклучите уредот неправилно %d пати. Сега ќе се ресетира на фабричките поставки и сите податоци да се избришат."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d до %2$d бројки или букви се потребни."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "SOS повик"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Предупредување"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Откажи"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Имавте %1$d неуспешни обиди да го отклучите уредот. Обидете се повторно за %2$d секунди."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Не може да се отклучи екранот"
+
diff --git a/po/ml.po b/po/ml.po
new file mode 100644
index 0000000..70bcbad
--- /dev/null
+++ b/po/ml.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 ശ്രമം ശേഷിക്കുന്നു."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d ശ്രമങ്ങള്‍ ശേഷിക്കുന്നു."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "തെറ്റായ പാസ്‌വേഡ്."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s സമാരംഭിക്കാന്‍ ആവുന്നില്ല."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ശരി"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "തെറ്റായ PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN നല്‍കുക."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "പാസ്‌വേഡ് നല്‍കുക."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "ഉപകരണം തുറക്കാൻ നിങ്ങൾ തെറ്റായി %1$d തവണ ശ്രമിച്ചു. ഉപകരണം ഫാക്ടറി ഡീഫോൾട്ടിലേക്ക് പുനഃസജ്ജമാക്കപ്പെടുകയും ഡാറ്റയെല്ലാം മായ്ക്കപ്പെടുകയും ചെയ്യുന്നതിന് മുമ്പായി നിങ്ങൾക്ക് %2$d ശ്രമങ്ങൾ ശേഷിക്കുന്നു."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d സെക്കന്‍റിനുശേഷം വീണ്ടും ശ്രമിക്കുക."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "സന്ദേശം കാണാൻ PIN നൽകുക"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "കോൾ ലോഗ് കാണാൻ PIN നൽകുക"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "നിങ്ങള്‍ %1$d തവണ തെറ്റായി ഉപകരണം അണ്‍ലോക്കുചെയ്യാന്‍ ശ്രമിച്ചു. ഇത് ഇപ്പോള്‍ ഫാക്ടറി സ്ഥിരസ്ഥിതികളിലേയ്ക്ക് പുനഃക്രമീകരിക്കുകയും എല്ലാ ഡാറ്റയും മായ്ക്കുകയും ചെയ്യും"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d മുതല്‍ %2$d വരെ അക്കങ്ങളോ അക്ഷരങ്ങളോ ആവശ്യമാണ്."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "എമര്‍ജന്‍സി കോള്‍"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "മുന്നറിയിപ്പ്"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "റദ്ദാക്കുക"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "ഉപകരണത്തിന്‍റെ ലോക്കുമാറ്റുന്നതിന് %1$d പരാജയപ്പെട്ട ശ്രമങ്ങൾ നിങ്ങൾ നടത്തി. %2$d സെക്കൻഡിൽ വീണ്ടും ശ്രമിക്കുക."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "സ്ക്രീൻ ലോക്കുനീക്കാൻ ആകില്ല"
+
diff --git a/po/mn_MN.po b/po/mn_MN.po
index 52ca19a..20e8b5a 100644
--- a/po/mn_MN.po
+++ b/po/mn_MN.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Дэлгэцийн уншигчийг идэвхжүүлсэн."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 оролдлого үлдсэн."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Дэлгэцийн уншигчийг идэвхгүй болгосон."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d оролдлого үлдсэн."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Буруу нууц үг"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Unable to launch %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Буруу PIN код"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN код оруулах"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Нууц үг оруулах"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Та төхөөрөмжийг нээх гэж %1$d удаа буруу оролдсон. Төхөөрөмж үйлдвэрийн өгөгдмөл тохиргоо руугаа буцан орж, бүх өгөгдөл арилах хүртэл %2$d удаа оролдох боломж үлдсэн."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d сек дараа дахин оролд"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "PIN оруулж зурвас үз"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "PIN оруулж дуудлагын бүртгэл үз"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Та төхөөрөмжийг нээх гэж %d удаа буруу оролдсон. Энэ одоо үйлдвэрийн өгөгдмөл тохиргоо руугаа буцаж орох бөгөөд бүх өгөгдөл арилна"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d to %2$d digits or letters required."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Яаралтай тусламжийн дуудлага"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Анхааруулга"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Цуцлах"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Та төхөөрөмжөө нээх гэж %1$d удаа амжилтгүй оролдсон. %2$d секундын дараа дахин оролд."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Дэлгэц нээх боломжгүй"
diff --git a/po/nb.po b/po/nb.po
index a942a8c..59f5305 100644
--- a/po/nb.po
+++ b/po/nb.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Skjermleser aktivert."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 forsøk gjenstår."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Skjermleser deaktivert."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d forsøk igjen."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Feil passord."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Kan ikke starte %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Ugyldig PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Angi PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Angi passord."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Du har prøvd å låse opp enheten på feil måte %1$d ganger. Du har %2$d forsøk igjen før enheten tilbakestilles til fabrikkstandarder og alle data slettes."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Prøv på nytt om %d sek."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Angi PIN-kode for å vise melding"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Angi PIN-kode for å vise samtalelogg"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Du har prøvd å låse opp enheten på feil måte %d ganger. Den vil nå bli tilbakestilt til fabrikkstandardene og alle data vil bli slettet."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d til %2$d sifre eller bokstaver nødvendige."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Nødanrop"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Advarsel"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Avbryt"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Du har gjort %1$d feil forsøk på å låse opp enheten. Prøv på nytt om %2$d sekunder."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Kan ikke låse opp skjermen"
diff --git a/po/nl.po b/po/nl.po
index 8d1f208..cf57503 100644
--- a/po/nl.po
+++ b/po/nl.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Schermlezer ingeschakeld."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 poging over."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Schermlezer uitgeschakeld."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d pogingen over."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Onjuist wachtwoord."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Kan %s niet starten."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Onjuiste PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN invoeren"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Wachtwoord invoeren"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "U hebt %1$d keer een onjuiste poging gedaan om het apparaat te ontgrendelen. U hebt nog %2$d pogingen over voordat het apparaat wordt teruggezet op de fabrieksinstellingen en alle gegevens worden gewist."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Probeer opn. over %d sec."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Pincode invoeren voor weergave bericht"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Pincode invoeren voor weergave oproepenlijst"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "U hebt %d keer een onjuiste poging gedaan om het apparaat te ontgrendelen. Het wordt nu teruggezet op de fabrieksinstellingen en alle gegevens worden gewist."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d tot %2$d cijfers of letters vereist."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Noodoproep"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Waarschuwing"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Annuleer"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "U hebt %1$d mislukte pogingen gedaan om uw apparaat te ontgrendelen. Probeer het opnieuw over %2$d seconden."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Kan scherm niet ontgrendelen"
diff --git a/po/pl.po b/po/pl.po
index 68bd811..7a263fe 100644
--- a/po/pl.po
+++ b/po/pl.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Czytnik ekranu włączony."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Pozostała 1 próba."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Czytnik ekranu wyłączony."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Pozostało prób: %d."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Błędne hasło."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Nie można uruchomić %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Nieprawidłowy PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Wpisz PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Wpisz hasło."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Nieprawidłowych prób odblokowania urządzenia: %1$d. Pozostałych prób przed wyzerowaniem urządzenia do domyślnych ustawień fabrycznych i usunięciem wszystkich danych: %2$d."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Ponów próbę za %d sek."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Podaj kod PIN, aby wyświetlić wiadomość"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Podaj kod PIN, aby wyświetlić spis połączeń"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Podjęto nieprawidłową próbę odblokowania urządzenia %d razy. W urządzeniu zostaną przywrócone domyślne ustawienia fabryczne oraz zostaną z niego usunięte wszystkie dane."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Wymaganych jest co najmniej cyfr lub liter: %1$d do %2$d."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Połączenie alarmowe"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Ostrzeżenie"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Anuluj"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Liczba nieudanych prób odblokowania urządzenia: %1$d. Spróbuj ponownie za %2$d s."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Nie można odblokować ekranu"
diff --git a/po/pt_BR.po b/po/pt_BR.po
index fd10756..2a72b18 100644
--- a/po/pt_BR.po
+++ b/po/pt_BR.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Leitor de tela ativado."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Resta 1 tentativa."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Leitor de tela desativado."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Restam %d tentativas."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Senha incorreta."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Impossível iniciar %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN incorreto."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Insira o PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Insira senha."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Você tentou desbloquear o dispositivo incorretamente %1$d vezes. Você tem %2$d tentativas restantes antes do dispositivo ser redefinido para os padrões de fábrica e todos os dados serem apagados."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Tente nov. dentro %d seg."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Insira o PIN para visualizar a mensagem"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Insira o PIN para visualizar o registro de chamadas"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Você tentou desbloquear o dispositivo incorretamente %d vezes. Ele será redefinido agora para os padrões de fábrica e todos os dados serão apagados."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "São necessários de %1$d a %2$d dígitos ou letras."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Chamada de emergência"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Aviso"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancelar"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Você fez %1$d tentativas sem sucesso para desbloquear seu dispositivo. Tente novamente em %2$d segundos."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Impossível desbloquear a tela"
diff --git a/po/pt_PT.po b/po/pt_PT.po
index 6e8c871..e409d63 100644
--- a/po/pt_PT.po
+++ b/po/pt_PT.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Leitor de ecrã activado."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Resta 1 tentativa."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Leitor de ecrã desactivado."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d tentativas restantes."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Palavra-passe incorrecta."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Impossível iniciar %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN incorrecto."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Introduzir PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Introduzir palavra-passe."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Tentou desbloquear o dispositivo incorrectamente %1$d vezes. Tem %2$d tentativas até serem repostos no dispositivo os valores de fábrica e todos os dados serem apagados."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Tente nov. dentro %d seg."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Introduza PIN para ver mensagem"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Introduza PIN para ver registo de chamadas"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Tentou desbloquear o dispositivo incorrectamente %d vezes. Este vai ser reposto para as predefinições de fábrica e todos os dados serão apagados."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "São necessários %1$d a %2$d dígitos ou letras."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Chamada de emergência"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Aviso"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancelar"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Fez %1$d tentativas mal sucedidas de desbloquear o seu dispositivo. Tente de novo daqui a %2$d segundos."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Impossível desbloquear ecrã"
diff --git a/po/ro.po b/po/ro.po
index a499c01..01abe1c 100644
--- a/po/ro.po
+++ b/po/ro.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Cititor de ecran activat."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 încercare rămasă"
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Cititor de ecran dezactivat."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d încercări rămase"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Parolă incorectă"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Imposibil de lansat %s"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN incorect"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Introduceţi PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Introduceţi parola."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Aţi încercat să deblocaţi incorect dispozitivul de %1$d ori. Mai aveţi %2$d încercări înainte ca dispozitivul să fie resetat la valorile implicite din fabrică şi înainte ca toate datele să fie şterse."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Reîncercaţi peste %d sec."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Introduceţi codul PIN pentru a vizualiza mesajul"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Introduceţi codul PIN pentru a vizualiza jurnalul de apeluri"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Aţi încercat să deblocaţi incorect dispozitivul de %d ori. Acesta va fi resetat acum la valorile implicite din fabrică şi toate datele vor fi şterse."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Sunt necesare între %1$d şi %2$d cifre sau litere."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Apel de urgenţă"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Avertisment"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Anulare"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Aţi avut %1$d încercări nereuşite de a debloca dispozitivul. Reîncercaţi peste %2$d secunde."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Ecranul nu se poate debloca"
diff --git a/po/ru_RU.po b/po/ru_RU.po
index 9048cf9..8bf77d8 100644
--- a/po/ru_RU.po
+++ b/po/ru_RU.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Чтение с экрана включено."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Осталась 1 попытка."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Чтение с экрана отключено."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Осталось попыток: %d."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Неправильный пароль"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Невозможно запустить %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ОК"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Неверный PIN"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Введите PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Введите пароль."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Число неудачных попыток разблокировки устройства: %1$d. Осталось попыток: %2$d, после чего настройки будут сброшены до заводских значений, а все данные — удалены."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Повторите через %d сек."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Введите PIN-код, чтобы просмотреть сообщение"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Введите PIN-код, чтобы просмотреть журнал вызовов"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Число неудачных попыток разблокировки устройства: %d. Настройки будут сброшены до заводских значений, а все данные — удалены"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Требуется от %1$d до %2$d цифр или букв."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Экстренный вызов"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Предупреждение"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Отмена"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Число неудачных попыток разблокировки устройства: %1$d. Повторите попытку через %2$d сек."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Невозможно разблокир-ть экран"
diff --git a/po/si.po b/po/si.po
new file mode 100644
index 0000000..f6ea642
--- /dev/null
+++ b/po/si.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 උත්සාහයක් ඉතිරිව ඇත."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "උත්සාහයන් %d ක් ඉතිරිවී ඇත."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "වැරදි මුරපදය."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s ආරම්භ කළ නොහැක."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "හරි"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "වැරදි PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN අංකය ඇතුල් කරන්න."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "මුරපදය ඇතුල් කරන්න."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "ඔබ %1$d වතාවක් වැරදි ලෙස උපාංගය අගුලු හැරීමට උත්සාහ දරා ඇත. උපාංගය කම්හල් පෙරනිමිය වෙත යළි සැකසී සියලු දත්ත මැකීමට පෙර ඔබට උත්සාහයන් %2$dක් ඉතිරිව පවතී."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "නැවත තත්පර %d කින් උත්සාහ කරන්න."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "පණිවිඩය බැලීමට PIN ඇතුළත් කරන්න"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "ඇමතුම් ලොගය බැලීමට PIN ඇතුළත් කරන්න"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "ඔබ %d වතාවක් වැරදි ලෙස උපාංගය අගුළු හැරීමට යත්න දරා තිබේ. එය දැන් නිපැයුම් අදියරේ තිබූ පෙරනිමි තත්ත්වයට යළි සැකසෙනු ඇති අතර සියලු දත්ත මැකෙනු ඇත"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d සිට %2$d දක්වා අංක හෝ අක්ෂර ගණනක් අවශ්‍ය වේ."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "හදිසි ඇමතුම්"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "අනතුරු ඇඟවීම"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "අවල. කර."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "ඔබ ඔබේ උපාංග අගුලු හැරීමට අසාර්ථක උත්සාහයන් %1$dක් ගෙන තිබේ. තත්පර %2$dකින් නැවත උත්සාහ කරන්න."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "තිරය අගුලු හැරිය නොහැක"
+
diff --git a/po/sk.po b/po/sk.po
index 870138a..a7c4730 100644
--- a/po/sk.po
+++ b/po/sk.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Čítačka obrazovky je zapnutá."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Zostáva 1 pokus."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Čítačka obrazovky je vypnutá."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "Počet zostávajúcich pokusov: %d."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Nesprávne heslo."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Nedá sa spustiť %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Nesprávny PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Zadať PIN"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Zadajte heslo."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "%1$d-krát ste sa pokúsili nesprávne odomknúť zariadenie. Zostávajú vám ešte %2$d pokusy a potom sa pre zariadenie obnovia predvolené nastavenia od výrobcu a vymažú sa všetky údaje."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Skúste znova o %d sekúnd."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Zadajte kód PIN na zobrazenie správy"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Zadajte kód PIN na zobrazenie denníka hovorov"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "%d-krát ste sa pokúsili nesprávne odomknúť zariadenie. Teraz sa preň obnovia predvolené nastavenia od výrobcu a vymažú sa všetky údaje."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Vyžaduje sa %1$d až %2$d číslic alebo písmen."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Tiesňový hovor"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Varovanie"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Zrušiť"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Dokončili ste vykonanie %1$d neúspešných pokusov o odomknutie zariadenia. Skúste to znova po uplynutí %2$d sekúnd."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Obrazovka sa nedá odomknúť"
diff --git a/po/sl.po b/po/sl.po
index bea56e7..4b88c19 100644
--- a/po/sl.po
+++ b/po/sl.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Bralnik zaslona je omogočen."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Preostal je še 1 poskus."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Bralnik zaslona je onemogočen."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d preostalih poizkusov."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Napačno geslo."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Ni mogoče zagnati %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "V redu"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Napačna koda PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Vnesite PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Vnesite geslo."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Napravo ste %1$d-krat poskusili odkleniti nepravilno. Imate še %2$d poskusov, preden bo naprava ponastavljena na privzete tovarniške nastavitve in bodo izbrisani vsi podatki."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Poskusite znova čez %d s."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Za prikaz sporočila vnesite kodo PIN"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Za prikaz dnevnika klicev vnesite kodo PIN"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Napravo ste %d-krat poskusili odkleniti nepravilno. Zdaj bo ponastavljena na privzete tovarniške nastavitve in vsi podatki bodo izbrisani."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Zahtevanih je od %1$d do %2$d znakov ali črk."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Klic v sili"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Opozorilo"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Prekliči"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "%1$d-krat ste neuspešno poskusili odkleniti napravo. Poskusite znova čez %2$d s."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Zaslona ni mogoče odkleniti"
diff --git a/po/sr.po b/po/sr.po
index 68c4406..03a9563 100644
--- a/po/sr.po
+++ b/po/sr.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Čitač ekrana je omogućen."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 pokušaj preostao."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Čitač ekrana je onemogućen."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d pokušaja ostalo."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Pogrešna šifra"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Nemoguće pokrenuti %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Neispravan PIN kod."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Unesi PIN kod."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Unesi šifru."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "%1$d puta si pogrešio/la u pokušaju da otključaš uređaj. Preostalo ti je %2$d pokušaja pre vraćanja uređaja na podrazumevana fabrička podešavanja i brisanja svih podataka."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Probaj opet za %d sekundi."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Unesi PIN kod da bi prikazao/la poruku"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Unesi PIN kod da bi prikazao/la dnevnik poziva"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "%d puta si pogrešio/la u pokušaju da otključaš uređaj. Uređaj će se sada vratiti na podrazumevana fabrička podešavanja i svi podaci će biti izbrisani."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Obavezno je između %1$d i %2$d cifara ili slova."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Pozivi u hitnim slučajevima"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Upozorenje"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Otkaži"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "%1$d neuspešnih pokušaja otključavanja uređaja. Pokušaj ponovo za %2$d sekundi."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Nije moguće otključati ekran"
diff --git a/po/sv.po b/po/sv.po
index 9c12889..48bcad7 100644
--- a/po/sv.po
+++ b/po/sv.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Skärmläsare aktiverad."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 försök kvar."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Skärmläsare inaktiverad."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d försök kvar."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Fel lösenord."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Kan inte starta %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Fel PIN-kod."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Ange PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Ange lösenord."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Du har försökt låsa upp enheten på fel sätt %1$d gånger. Du har %2$d försök kvar innan enheten återställs till fabriksinställningar och alla data raderas."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Försök igen om %d sek."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Ange PIN-koden för att visa meddelandet"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Ange PIN-koden för att visa samtalsloggen"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Du har försökt att låsa upp enheten felaktigt %d gånger. Enheten kommer nu att återställas till fabriksinställningarna och alla data kommer att raderas."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d till %2$d siffror eller bokstäver krävs."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Nödsamtal"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Varning"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Avbryt"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Du har gjort %1$d misslyckade försök att låsa upp enheten. Försök igen om %2$d sekunder."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Kan inte låsa upp skärmen"
diff --git a/po/ta.po b/po/ta.po
new file mode 100644
index 0000000..b4ed5da
--- /dev/null
+++ b/po/ta.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 முயற்சி மீதம்."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "மேலும் %d முயற்சிகள் உள்ளன."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "கடவுச்சொல் தவறு."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s ஐ தொடங்க முடியவில்லை."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "சரி"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "தவறான PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN பதி."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "கடவுச்சொல் பதிக."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "நீங்கள் சாதனத்தை பூட்டுநீக்குவதற்கு %1$d முறை தவறாக முயற்சித்துள்ளீர்கள். சாதனம் தயாரிப்பக டீஃபாலட் நிலைகளுக்கு ரீசெட் செய்யப்பட்டு அனைத்து தரவுகளும் அழிக்கப்படுவதற்கு முன் உங்களுக்கு %2$d முயற்சிகள் மீதமுள்ளன."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d விநாடி. கழித்து மீ. முயலுக."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "தகவலைக் காண, PIN உள்ளிடவும்"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "அழைப்புப் பதிவைக் காண, PIN உள்ளிடவும்"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "சாதனத்தை பூட்டுநீக்க %d முறை தவறாக முயற்சித்துள்ளீர்கள். இது இப்போது தயாரிப்பு நிலைக்கு ரீசெட் செய்யப்பட்டு அனைத்து தரவுகளும் அழிக்கப்படும்"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d முதல் %2$d வரையான இலக்கங்கள் அல்லது எழுத்துக்கள் தேவை."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "அவசர அழைப்பு"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "எச்சரிக்கை"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "ரத்து"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "உங்கள் சாதனத்தைத் திறப்பதற்கு, %1$d வெற்றிபெறாத முயற்சிகளை நீங்கள் செய்துள்ளீர்கள். %2$d வினாடிகளில் மீண்டும் முயற்சிக்கவும்."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "திரையைத் திறக்க முடியவில்லை"
+
diff --git a/po/te.po b/po/te.po
new file mode 100644
index 0000000..fb6bc44
--- /dev/null
+++ b/po/te.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 ప్రయత్నం మిగిలి ఉంది."
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d ప్రయత్నాలు మిగిలాయి."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "తప్పు పాస్వర్డ్."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%sను ఆవిష్కరించడం సాధ్యం కాదు."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "సరే"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "తప్పు PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN నమోదు చేయండి."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "పాస్వర్డును నమోదు చేయండి."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "మీరు పరికరాన్ని తప్పుగా %1$dసార్లు అన్‌లాక్ చేసేందుకు ప్రయత్నించారు. పరికరం ఫ్యాక్టరీ డిఫాల్ట్‌లకు తిరిగి అమర్చబడేందుకు మరియు మొత్తం డేటా తుడిచిపెట్టబడేందుకు మీకు %2$d ప్రయత్నాలు మిగిలివున్నాయి."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d సెకన్లలో మళ్ళీ ప్రయత్నించండి."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "సందేశాన్ని వీక్షించడానికి PINను నమోదు చేయండి"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "కాల్ లాగ్‌ను వీక్షించడానికి PINను నమోదు చేయండి"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "మీరు పరికరాన్ని %d సార్లు తప్పుగా అన్‌లాక్ చేయడానికి ప్రయత్నించారు. ఇది ఫ్యాక్టరీ డిఫాల్ట్‌లకు రీసెట్ చేయబడుతుంది మరియు మొత్తం డేటా తుడిచివేయబడుతుంది"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d నుండి %2$d అంకెలు లేదా అక్షరాలు అవసరం."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "అత్యవసర కాల్"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "హెచ్చరిక"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "రద్దు"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "మీరు మీ పరికరాన్ని అన్‌లాక్ చేయడానికి %1$d విఫల ప్రయత్నాలు చేశారు. %2$d సెకన్లల్లో మళ్లీ ప్రయత్నించండి."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "స్క్రీన్ అన్‌లాక్ చేయలేరు"
+
diff --git a/po/th.po b/po/th.po
new file mode 100644
index 0000000..633afcf
--- /dev/null
+++ b/po/th.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "เหลือ​อีก 1 ​ครั้ง"
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "เหลือ %d ​ครั้ง"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "รหัสผ่าน\nไม่ถูกต้อง"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "ไม่​ได้​รับรอง %s"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ตกลง"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN ​ผิด"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "ใส่ PIN"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "ใส่รหัสผ่าน"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "คุณได้พยายามปลดล็อค อุปกรณ์ผิดพลาด %1$d ครั้งแล้ว คุณเหลืออีก %2$d ครั้ง ก่อนอุปกรณ์จะรีเซ็ท เป็นค่าพื้นฐานจากโรงงาน และข้อมูลทุกอย่างจะถูกลบ"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "ลอง​อีก​ครั้ง​ใน %d ​วินาที"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "ใส่ PIN เพื่อดูข้อความ"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "ใส่ PIN เพื่อดูบันทึกการโทร"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "คุณได้พยายามปลดล็อคอุปกรณ์ผิดพลาด %d ครั้งแล้ว อุปกรณ์จะถูกรีเซ็ทเป็นค่าพื้นฐานจากโรงงาน และข้อมูลทั้งหมดจะถูกลบ"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "ต้องมี %1$d ถึง %2$d ตัวเลขหรือตัวอักษร"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "โทร​ฉุก​เฉิน"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "เตือน"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "ยกเลิก"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "คุณพยายามปลดล็อคอุปกรณ์ %1$d ครั้ง แต่ไม่สำเร็จ ลองอีกครั้งใน %2$d วินาที"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "ไม่สามารถปลดล็อคหน้าจอ"
+
diff --git a/po/tr_TR.po b/po/tr_TR.po
index 10a566a..cbeeb07 100644
--- a/po/tr_TR.po
+++ b/po/tr_TR.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Ekran okuyucusu etkinleştirildi."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 deneme hakkı kaldı."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Ekran okuyucusu devre dışı bırakıldı."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d deneme kaldı."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Şifre yanlış."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s öğesi başlatılamıyor."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "Tamam"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN yanlış."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN'i girin."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Şifreyi girin."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Cihazın kilidini açmak için şifreyi %1$d kez yanlış girdiniz. Cihaz varsayılan fabrika ayarlarına sıfırlanmadan ve tüm veriler silinmeden önce %2$d deneme hakkınız kaldı."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d saniye içinde de tekrar deneyin."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Mesajı görüntülemek için PIN'i girin"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Arama kaydını görüntülemek için PIN'i girin"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Cihazın kilidini %d defa yanlış açma girişiminde bulundunuz. Cihaz şimdi fabrika ayarlarına sıfırlanacak ve tüm veriler silinecektir."
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d - %2$d hane veya harf gerekli."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Acil arama"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Uyarı"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "İptal"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Cihazınızın kilidini açmak için %1$d başarısız denemede bulundunuz. %2$d saniye içinde tekrar deneyin."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Ekran kilidi açılamıyor"
diff --git a/po/uk.po b/po/uk.po
index db1dd24..9dde615 100644
--- a/po/uk.po
+++ b/po/uk.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Програму читання з екрана увімкнено."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "Залишилась 1 спроба."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Програму читання з екрана вимкнено."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d спроби залишилось."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Хибний пароль."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "Неможливо запустити %s."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ОК"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Хибний PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "Введіть PIN."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Введіть пароль."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Кількість невдалих спроб розблокування пристрою: %1$d. Залишилася %2$d спроб, перш ніж установки пристрою буде скинуто до стандартних заводських значень, а всі дані видалено."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "Повт.спробу через %d сек."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Введіть PIN-код, щоб переглянути повідомлення"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Введіть PIN-код, щоб переглянути журнал викликів"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Кількість невдалих спроб розблокування пристрою: %d. Установки буде скинуто до заводських та усі дані буде стерто"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "Потрібно ввести від %1$d до %2$d цифр або літер."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Екстрений виклик"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Попередження"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Скасувати"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Здійснено %1$d невдалих спроб розблокування пристрою. Спробуйте ще раз через %2$d сек."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Неможливо розблокувати екран"
diff --git a/po/ur.po b/po/ur.po
new file mode 100644
index 0000000..82de3ce
--- /dev/null
+++ b/po/ur.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 کوشش باقی رہگئی۔"
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d کوششیں باقی۔"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "غلط پاسورڈ۔"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%s چلانے سے قاصر۔"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "ٹھیک ہے"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "غلط پن کوڈ۔"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "پن نمبر درج کریں"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "پاس ورڈ درج کریں"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "آپ نے آلے کو %1$d بار غلط طریقے سے کھولنےکی کوشش کی۔ آلے کے فیکٹری ڈیفالٹ پر دوبارہ ترتیب دینے اور سبھی ڈیٹا کو مٹادیے جانے سے قبل آپ کے پاس صرف %2$dکوششیں بچی ہیں۔"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d سیکنڈ میں دوبارہ کوشش کریں"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "پیغام دیکھنے کے لیے پن داخل کریں"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "کال لاگ دیکھنے کے لیے پن داخل کریں"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "آپ نے اس آلہ کو %d مرتبہ غلط طریقے سے ان لاک کرنے کی کوشش کی ہے۔ آلہ کو اب فیکٹری طے شدہ پر پھر سیٹ کردیا جائے گا اور تمام ڈیٹا مٹا دیا جائے گا۔"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d سے %2$d ہندسے یا حروف درکار۔"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "ایمرجنسی کال"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "خطرہ"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "منسوخ"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "اپنا آلہ غیر مقفل کرنے کی آپ نے %1$d ناکام کوششیں کی ہیں۔ %2$d سیکنڈز میں دوبارہ کوشش کریں۔"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "اسکرین کو غیر مقفل کرنے سے قاصر"
+
diff --git a/po/uz.po b/po/uz.po
index 37a0168..424e3f0 100644
--- a/po/uz.po
+++ b/po/uz.po
@@ -1,6 +1,57 @@
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"
-msgstr "Ekranni o‘qish vositasi yoqildi."
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "1 attempt left."
-msgid "IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"
-msgstr "Ekranni o‘qish vositasi o‘chirildi."
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "%d urinish qoldi."
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "Noto‘g‘ri parol."
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "%sni ishga tushirib bo‘lmaydi."
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "OK"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "Noto‘g‘ri PIN."
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "PIN-kod kiriting."
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "Parol kiriting."
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "Siz %1$d marta qurilmani blokdan chiqarishga noto‘g‘ri urindingiz. Yana %2$dta noto‘g‘ri urinishdan so‘ng qurilma ishlab chiqaruvchi parametrlariga qaytariladi va barcha ma’lumotlar o‘chirib tashlanadi."
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d soniyada qayta urining."
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "Xabarni ko‘rib chiqish uchun PIN-kodni kiriting"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "Qo‘ng‘iroqlar jurnalini ko‘rish uchun PIN-kodni kiriting"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "Siz %d marta qurilmani blokdan chiqarishga noto‘g‘ri urindingiz. U hozir ishlab chiqaruvchi parametrlariga qaytariladi va barcha ma’lumotlar o‘chirib tashlanadi"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "%1$d-%2$d raqam yoki harflar talab qilinadi."
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "Favqulodda qo‘ng‘iroqlar"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "Ogohlantirish"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Bekor qilish"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "Qurilmangizni blokdan chiqarish uchun %1$dta noto‘g‘ri urinishni amalga oshirdingiz. %2$d soniyada qayta urinib ko‘ring."
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "Ekr. blkdan chiqar. bo‘lmaydi"
diff --git a/po/zh_CN.po b/po/zh_CN.po
new file mode 100644
index 0000000..294f851
--- /dev/null
+++ b/po/zh_CN.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "还能尝试 1 次。"
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "还有 %d 次机会。"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "密码错误"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "无法启动 %s。"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "确定"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "错误的 PIN 码"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "输入PIN码"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "输入密码"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "您解锁设备的尝试已不正确 %1$d 次。设备重置为出厂默认设置并清除所有数据前还可尝试 %2$d 次。"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "请在%d秒后重试。"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "输入 PIN 码以查看信息"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "输入 PIN 码以查看通话记录"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "您已尝试解锁设备不正确 %d 次。其现在将重置为出厂默认且所有数据将被擦除。"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "需要 %1$d 至 %2$d 个数字或字母。"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "紧急呼叫"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "警告"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "取消"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "您已进行了 %1$d 次不成功的解锁设备尝试。在 %2$d 秒后重试。"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "无法解锁屏幕"
+
diff --git a/po/zh_HK.po b/po/zh_HK.po
new file mode 100644
index 0000000..9c5fdfd
--- /dev/null
+++ b/po/zh_HK.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "剩餘1次機會。"
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "剩餘 %d 次機會。"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "密碼不正確"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "無法啟動 %s。"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "確定"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN 碼不正確。"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "輸入 PIN 碼"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "輸入密碼。"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "您已嘗試錯誤解鎖裝置 %1$d 次。僅剩 %2$d 次機會嘗試,否則裝置將重設至原廠預設值且所有數據將被刪除。"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "請在 %d 秒後重試。"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "輸入 PIN 碼以檢視訊息"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "輸入 PIN 碼以檢視通話記錄"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "您已嘗試錯誤解鎖 %d 次。裝置將重設回原廠預設值且所有數據將被清除。"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "需輸入 %1$d 至 %2$d 位數或字母。"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "緊急通話"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "警告"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "取消"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "您已嘗試 %1$d 次錯誤的裝置解鎖。請在 %2$d 秒後重試。"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "無法解鎖螢幕"
+
diff --git a/po/zh_TW.po b/po/zh_TW.po
new file mode 100644
index 0000000..1d5e946
--- /dev/null
+++ b/po/zh_TW.po
@@ -0,0 +1,57 @@
+msgid "IDS_IDLE_BODY_1_ATTEMPT_LEFT"
+msgstr "剩下一次機會。"
+
+msgid "IDS_IDLE_BODY_PD_ATTEMPTS_LEFT"
+msgstr "剩餘 %d 次嘗試機會。"
+
+msgid "IDS_IDLE_BODY_INCORRECT_PASSWORD"
+msgstr "密碼不正確"
+
+msgid "IDS_IDLE_POP_UNABLE_TO_LAUNCH_PS"
+msgstr "無法啟動 %s。"
+
+msgid "IDS_COM_BUTTON_OK_ABB"
+msgstr "確定"
+
+msgid "IDS_COM_BODY_INCORRECT_PIN"
+msgstr "PIN 不正確。"
+
+msgid "IDS_COM_BODY_ENTER_PIN"
+msgstr "輸入PIN"
+
+msgid "IDS_COM_BODY_ENTER_PASSWORD"
+msgstr "輸入密碼。"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_P1SD_TIMES_YOU_HAVE_P2SD_ATTEMPTS_LEFT_BEFORE_THE_DEVICE_IS_RESET_TO_FACTORY_MSG"
+msgstr "您已嘗試錯誤解鎖裝置 %1$d 次。僅剩 %2$d 次機會嘗試,否則裝置將重設至原廠預設值且所有資料將被刪除。"
+
+msgid "IDS_LCKSCN_POP_TRY_AGAIN_IN_PD_SECONDS"
+msgstr "%d 秒後再試一次。"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_MESSAGE_ABB"
+msgstr "輸入 PIN 碼以檢視訊息"
+
+msgid "IDS_LCKSCN_NPBODY_ENTER_PIN_TO_VIEW_CALL_LOG_ABB"
+msgstr "輸入 PIN 碼以檢視通話記錄"
+
+msgid "IDS_LCKSCN_BODY_YOU_HAVE_ATTEMPTED_TO_UNLOCK_THE_DEVICE_INCORRECTLY_PD_TIMES_IT_WILL_NOW_BE_RESET_TO_FACTORY_DEFAULTS_AND_ALL_DATA_WILL_BE_ERASED"
+msgstr "您已嘗試錯誤解鎖裝置 %d 次。裝置將設回原廠預設值且所有資料將被清除。"
+
+msgid "IDS_LCKSCN_BODY_P1SD_TO_P2SD_DIGITS_OR_LETTERS_REQUIRED"
+msgstr "需輸入 %1$d 至 %2$d 位數或字母。"
+
+msgid "IDS_LCKSCN_BODY_EMERGENCY_CALL"
+msgstr "緊急電話"
+
+msgid "IDS_COM_POP_WARNING"
+msgstr "警告"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "取消"
+
+msgid "IDS_LCKSCN_POP_YOU_HAVE_MADE_P1SD_UNSUCCESSFUL_ATTEMPTS_TO_UNLOCK_YOUR_DEVICE_TRY_AGAIN_IN_P2SD_SECONDS"
+msgstr "您已嘗試 %1$d 次錯誤的裝置解鎖。請在 %2$d 秒後重試。"
+
+msgid "IDS_LCKSCN_HEADER_UNABLE_TO_UNLOCK_SCREEN_ABB"
+msgstr "無法解除螢幕鎖定"
+
diff --git a/rd3starter b/rd3starter
index aced30e..e12e50a 100755..100644
--- a/rd3starter
+++ b/rd3starter
@@ -11,17 +11,4 @@ do
/bin/sleep 0.1
done
-vconf_set_safemode()
-{
- if [ -f /opt/etc/.safeboot ]
- then
- /usr/bin/vconftool set -t int memory/idle-screen/safemode "1" -f
- else
- /usr/bin/vconftool set -t int memory/idle-screen/safemode "0" -f
- fi
-}
-vconf_set_safemode
-
-echo -e "<2>[${_G}menu-daemon start${C_}]" > /dev/kmsg
-/usr/bin/starter &
-
+exit 0
diff --git a/rd4starter b/rd4starter
index 409c90c..58f910f 100644
--- a/rd4starter
+++ b/rd4starter
@@ -1,14 +1,3 @@
#!/bin/sh
-vconf_set_safemode()
-{
- if [ -f /opt/etc/.safeboot ]
- then
- /usr/bin/vconftool set -t int memory/idle-screen/safemode "1" -i -f
- else
- /usr/bin/vconftool set -t int memory/idle-screen/safemode "0" -i -f
- fi
-}
-vconf_set_safemode
-
echo -e "<2>[${_G}menu-daemon start${C_}]" > /dev/kmsg
/usr/bin/starter &
diff --git a/src/clock-mgr.c b/src/clock-mgr.c
deleted file mode 100755
index 01d147d..0000000
--- a/src/clock-mgr.c
+++ /dev/null
@@ -1,807 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <ail.h>
-#include <bundle.h>
-#include <Elementary.h>
-#include <Ecore_X.h>
-#include <Ecore_Input.h>
-#include <utilX.h>
-#include <vconf.h>
-#include <dd-display.h>
-#if 0 // Disable temporarily for TIZEN 2.3 build
-#include <message_port.h>
-#endif
-
-#include "starter_w.h"
-#include "dbus-util_w.h"
-#include "util.h"
-
-
-#define APP_CONTROL_OPERATION_MAIN_KEY "__APP_SVC_OP_TYPE__"
-#define APP_CONTROL_OPERATION_MAIN_VALUE "http://tizen.org/appcontrol/operation/main"
-#define APP_CONTROL_OPERATION_DEFAULT_VALUE "http://tizen.org/appcontrol/operation/default"
-
-
-#ifndef VCONFKEY_SHEALTH_VIEW_TYPE_STR
-#define VCONFKEY_SHEALTH_VIEW_TYPE_STR "memory/shealth/view_type"
-#endif
-
-#ifndef VCONFKEY_HERE_TBT_STATUS_INT
-#define VCONFKEY_HERE_TBT_STATUS_INT "memory/private/navigation/guidance"
-#endif
-
-#ifndef VCONFKEY_STARTER_RESERVED_APPS_STATUS
-#define VCONFKEY_STARTER_RESERVED_APPS_STATUS "memory/starter/reserved_apps_status" /* 2 digits for reserved apps & popup
- * 10 : popup
- * 01 : apps
- * */
-#endif
-
-#ifndef VCONFKEY_SETTING_SIMPLE_CLOCK_MODE
-#define VCONFKEY_SETTING_SIMPLE_CLOCK_MODE "db/setting/simpleclock_mode"
-#endif
-
-
-
-#define W_LOCKSCREEN_PKGNAME "com.samsung.w-lockscreen"
-
-#define W_ALPM_CLOCK_PKGNAME "com.samsung.alpm-clock-manager"
-#define ALPM_CLOCK_OP "ALPM_CLOCK_OP"
-#define ALPM_CLOCK_SHOW "alpm_clock_show"
-#define ALPM_CLOCK_HIDE "alpm_clock_hide"
-
-#define HOME_OPERATION_KEY "home_op"
-#define POWERKEY_VALUE "powerkey"
-
-#define PM_UNLOCK_TIMER_SEC 0.3
-
-#define RESERVED_DISPLAY_MESSAGE_PORT_ID "Home.Reserved.Display"
-#define RESERVED_DISPLAY_MESSAGE_KEY_STATE "state"
-#define RESERVED_DISPLAY_MESSAGE_STATE_SHOW "show"
-#define RESERVED_DISPLAY_MESSAGE_STATE_HIDE "hide"
-#define RESERVED_DISPLAY_MESSAGE_STATE_POPUP_SHOW "popup_show"
-#define RESERVED_DISPLAY_MESSAGE_STATE_POPUP_HIDE "popup_hide"
-
-#define SHEALTH_SLEEP_PKGNAME "com.samsung.shealth.sleep"
-
-static int _check_reserved_popup_status(void *data)
-{
- int val = 0;
- int tmp = 0;
- struct appdata *ad = (struct appdata *)data;
- if (ad == NULL) {
- _E("ad is NULL");
- return -1;
- }
-
- vconf_get_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, &val);
-
- _W("Current reserved apps status : %x", val);
-
- tmp = val;
- tmp = tmp & 0x10;
- if(tmp == 0x10){
- if(aul_app_is_running(ad->reserved_popup_app_id) == 1){
- return TRUE;
- }
- else{
- _E("%s is not running now.", ad->reserved_popup_app_id);
- ad->reserved_popup_app_id = NULL;
- val = val ^ 0x10;
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, val);
- _W("now reserved apps status %x", val);
- return FALSE;
- }
- }
- else{
- return FALSE;
- }
-
-}
-
-static int _check_reserved_apps_status(void *data)
-{
- int val = 0;
- struct appdata *ad = (struct appdata *)data;
- if (ad == NULL) {
- _E("ad is NULL");
- return -1;
- }
-
- vconf_get_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, &val);
-
- _W("Current reserved apps status : %x", val);
-
- if(val > 0){
- val = TRUE;
- }
- else{
- val = FALSE;
- }
-
- return val;
-}
-
-static void reserved_apps_message_received_cb(int local_port_id, const char *remote_app_id, const char *remote_port, bool trusted_port, bundle* msg)
-{
- ret_if(remote_app_id == NULL);
- ret_if(msg == NULL);
- struct appdata *ad = starter_get_app_data();
- Eina_List *l = NULL;
- char *state = NULL;
- char *data = NULL;
- char *appid = NULL;
- int count = 0;
- int i = 0;
- int val = 0;
- int tmp = 0;
-
- vconf_get_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, &val);
- _W("current reserved apps status : %x", val);
-
- state = bundle_get_val(msg, RESERVED_DISPLAY_MESSAGE_KEY_STATE);
- _W("appid [%s], msg value[%s]", remote_app_id, state);
- if (strncmp(state, RESERVED_DISPLAY_MESSAGE_STATE_SHOW, strlen(state)) == 0) {
- //reserved app is start
- EINA_LIST_FOREACH(ad->reserved_apps_list, l, data){
- if(strncmp(data, remote_app_id, strlen(data)) == 0){
- _W("%s is already in the list", data);
- ad->reserved_apps_list = eina_list_remove_list(ad->reserved_apps_list, l);
- break;
- }
- }
- appid = strdup(remote_app_id);
- ad->reserved_apps_list = eina_list_append(ad->reserved_apps_list, appid);
- val = val | 0x01;
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, val);
- _W("now reserved apps status %x", val);
- }
- else if (strncmp(state, RESERVED_DISPLAY_MESSAGE_STATE_HIDE, strlen(state)) == 0){
- //reserved app is stop
- EINA_LIST_FOREACH(ad->reserved_apps_list, l, data){
- if(strncmp(data, remote_app_id, strlen(data)) == 0){
- ad->reserved_apps_list = eina_list_remove_list(ad->reserved_apps_list, l);
- break;
- }
- }
- count = eina_list_count(ad->reserved_apps_list);
- if(count == 0){
- _W("there is no reserved app.");
- tmp = val;
- val = tmp & 0x01;
- if(val == 0x01){
- tmp = tmp ^ 0x01;
- }
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, tmp);
- _W("now reserved apps status %x", tmp);
- }
- }
- else if (strncmp(state, RESERVED_DISPLAY_MESSAGE_STATE_POPUP_SHOW, strlen(state)) == 0){
- //reserved popup is show
- ad->reserved_popup_app_id = strdup(remote_app_id);
- val = val | 0x0010;
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, val);
- _W("now reserved apps status %x", val);
- }
- else if (strncmp(state, RESERVED_DISPLAY_MESSAGE_STATE_POPUP_HIDE, strlen(state)) == 0){
- //reserved popup is hide
- if(ad->reserved_popup_app_id == NULL){
- _E("there is no reserved popup already");
- }
- else{
- if(strncmp(ad->reserved_popup_app_id, remote_app_id, strlen(ad->reserved_popup_app_id)) == 0){
- ad->reserved_popup_app_id = NULL;
- tmp = val;
- val = tmp & 0x10;
- if(val == 0x10){
- tmp = tmp ^ 0x10;
- }
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, tmp);
- _W("now reserved apps status %x", tmp);
- }
- }
- }
- else{
- // no info
- }
- EINA_LIST_REVERSE_FOREACH(ad->reserved_apps_list, l, data){
- _W("%d. %s", i++, data);
- }
-}
-#if 0
-static void _shealth_view_type_changed_cb(keynode_t* node, void *data)
-{
- char *val = NULL;
- struct appdata *ad = (struct appdata *)data;
-
- _D("%s, %d", __func__, __LINE__);
-
- if (ad == NULL) {
- _E("ad is NULL");
- return;
- }
-
- if (node) {
- val = vconf_keynode_get_str(node);
- } else {
- val = vconf_get_str(VCONFKEY_SHEALTH_VIEW_TYPE_STR);
- }
-
- clock_mgr_set_reserved_apps_status(val, STARTER_RESERVED_APPS_SHEALTH, ad);
-}
-
-static void _here_navigation_status_changed_cb(keynode_t* node, void *data)
-{
- int val = NULL;
- struct appdata *ad = (struct appdata *)data;
-
- _D("%s, %d", __func__, __LINE__);
-
- if (ad == NULL) {
- _E("ad is NULL");
- return;
- }
-
- if (node) {
- val = vconf_keynode_get_int(node);
- } else {
- vconf_get_int(VCONFKEY_HERE_TBT_STATUS_INT, &val);
- }
-
- clock_mgr_set_reserved_apps_status(val, STARTER_RESERVED_APPS_HERE, ad);
-}
-
-void clock_mgr_set_reserved_apps_status(void *info, int type, void *data){
- char *str_info = NULL;
- int int_info = NULL;
- int val = 0;
- int tmp = 0;
- struct appdata *ad = (struct appdata *)data;
- _D("%s, %d", __func__, __LINE__);
- if (ad == NULL) {
- _E("ad is NULL");
- return;
- }
-
- vconf_get_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, &val);
- _W("current reserved apps status : %x", val);
-
- switch(type){
- case STARTER_RESERVED_APPS_SHEALTH:{
- str_info = (char *)info;
- _W("Shealth status is changed (%s)", str_info);
- if (strncmp(str_info, "exercise", strlen(str_info)) == 0){
- val = val | 0x1000;
- if(val >= 0x1100){
- val = val ^ 0x0100;
- }
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, val);
- _W("now reserved apps status %x", val);
- }
- else if (strncmp(str_info, "sleep", strlen(str_info)) == 0){
- val = val | 0x0100;
- if(val >= 0x1100){
- val = val ^ 0x1000;
- }
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, val);
- _W("now reserved apps status %x", val);
- }
- else{
- tmp = val;
- val = tmp & 0x1000;
- if(val == 0x1000){
- tmp = tmp ^ 0x1000;
- }
- val = tmp & 0x0100;
- if(val == 0x0100){
- tmp = tmp ^ 0x0100;
- }
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, tmp);
- _W("now reserved apps status %x", tmp);
- }
- break;
- }
- case STARTER_RESERVED_APPS_NIKE:{
- int_info = (int)info;
- _W("Nike status is changed (%d)", int_info);
- if(int_info == 1){
- val = val | 0x0010;
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, val);
- _W("now reserved apps status %x", val);
- }
- else{
- tmp = val;
- val = tmp & 0x0010;
- if(val == 0x0010){
- tmp = tmp ^ 0x0010;
- }
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, tmp);
- _W("now reserved apps status %x", tmp);
- }
- break;
- }
- case STARTER_RESERVED_APPS_HERE:{
- int_info = (int)info;
- _W("Here status is changed (%d)", int_info);
- if(int_info == 1){
- val = val | 0x0001;
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, val);
- _W("now reserved apps status %x", val);
- }
- else{
- tmp = val;
- val = tmp & 0x0001;
- if(val == 0x0001){
- tmp = tmp ^ 0x0001;
- }
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, tmp);
- _W("now reserved apps status %x", tmp);
- }
- break;
- }
- default:{
- _E("Unknown reserved app.");
- break;
- }
- }
- return 0;
-}
-#endif
-
-static void _wake_up_setting_changed_cb(keynode_t* node, void *data)
-{
- int val = 0;
- struct appdata *ad = (struct appdata *)data;
-
- _D("%s, %d", __func__, __LINE__);
-
- if (ad == NULL) {
- _E("ad is NULL");
- return;
- }
-
- if(vconf_get_int(VCONFKEY_WMS_WAKEUP_BY_GESTURE_SETTING, &val) < 0) {
- _E("Failed to get VCONFKEY_WMS_WAKEUP_BY_GESTURE_SETTING");
- val = 1;
- }
- ad->wake_up_setting = val;
- _W("wake_up_setting is changed to [%d]", ad->wake_up_setting);
-}
-
-static void _ambient_mode_setting_changed_cb(keynode_t* node, void *data)
-{
- int ambient_mode = 0;
- struct appdata *ad = (struct appdata *)data;
- ret_if(!ad);
-
- ambient_mode = vconf_keynode_get_bool(node);
- _D("ambient mode : %d", ambient_mode);
-
- if (ambient_mode) {
- _D("launch w-clock-viewer");
- ad->pid_clock_viewer = w_launch_app(W_CLOCK_VIEWER_PKGNAME, NULL);
- } else {
- _D("kill w-clock-viewer(%d)", ad->pid_clock_viewer);
- if (ad->pid_clock_viewer > 0) {
- aul_kill_pid(ad->pid_clock_viewer);
- ad->pid_clock_viewer = 0;
- }
- }
-
- ad->ambient_mode = ambient_mode;
- _W("ambient_mode_setting is changed to [%d]", ad->ambient_mode);
-}
-
-
-static Eina_Bool _w_lcdoff_idler_cb(void *data)
-{
- struct appdata *ad = (struct appdata *)data;
-
- _D("%s, %d", __func__, __LINE__);
-
- w_open_app(ad->home_pkgname);
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-static Eina_Bool _w_launch_pm_unlock_idler_cb(void *data)
-{
- struct appdata *ad = (struct appdata *)data;
-
- _D("%s, %d", __func__, __LINE__);
- display_unlock_state(LCD_OFF, PM_SLEEP_MARGIN);
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-static Eina_Bool _pm_unlock_timer_cb(void *data){
- _D("%s, %d", __func__, __LINE__);
- ecore_idler_add(_w_launch_pm_unlock_idler_cb, data);
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-static void _notify_pm_lcdoff_cb(keynode_t * node, void *data)
-{
-
- int ret = -1;
- int setup_wizard_state = -1;
- bundle *b = NULL;
- int lock_type = 0;
- int tutorial_state = -1;
- Eina_List *l = NULL;
- char *info = NULL;
- int count = 0;
- int lcdoff_source = vconf_keynode_get_int(node);
- struct appdata *ad = (struct appdata *)data;
-
-
- if (ad == NULL) {
- _E("ad is NULL");
- return;
- }
-
- if (lcdoff_source < 0) {
- _E("Cannot get VCONFKEY, error (%d)", lcdoff_source);
- return;
- }
-
- _W("LCD OFF by lcd off source[%d], wake_up_setting[%d], ALPM_clock_state[%d]", lcdoff_source, ad->wake_up_setting, ad->ALPM_clock_state);
-
-#if 0
- if(csc_feature_get_bool(CSC_FEATURE_DEF_BOOL_HOME_LAUNCH_LOCK_WHEN_LCD_ON) == CSC_FEATURE_BOOL_TRUE){
- _E("CHC bin.");
- vconf_get_int(VCONFKEY_SETAPPL_PRIVACY_LOCK_TYPE_INT, &lock_type);
- if(lock_type == 1){
- int r = 0;
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
- _E("CHC bin & lock type is %d", lock_type);
- r = w_launch_app(W_LOCKSCREEN_PKGNAME, NULL);
-
- ecore_timer_add(PM_UNLOCK_TIMER_SEC, _pm_unlock_timer_cb, ad);
- }
- }
-#endif
-
- if (vconf_get_int(VCONFKEY_SETUP_WIZARD_STATE, &setup_wizard_state) < 0) {
- _E("Failed to get [%s]", VCONFKEY_SETUP_WIZARD_STATE);
- } else {
- if (setup_wizard_state == VCONFKEY_SETUP_WIZARD_LOCK) {
- _E("don't react for lcd off, setup wizard state is [%d]", setup_wizard_state);
- return;
- }
- }
-
-
-
-#if 0
- if (_check_reserved_apps_status(ad)) {
- _E("_check_running_heath = > don't react for lcd off except ALPM");
- if (ad->ambient_mode == 1) {
- //Step1. Launch ALPM clock
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- return;
- }
- //bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_MAIN_VALUE);
- bundle_add(b, ALPM_CLOCK_OP, ALPM_CLOCK_SHOW);
-
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
-
- ad->pid_ALPM_clock = 0;
- ret = w_launch_app(W_ALPM_CLOCK_PKGNAME, b);
- if (ret >= 0) {
- ad->pid_ALPM_clock =ret;
- _SECURE_D("[%s] is launched, pid=[%d]", W_ALPM_CLOCK_PKGNAME, ad->pid_ALPM_clock );
- }
- if(b){
- bundle_free(b);
- }
- //Step2. Do not raise Homescreen
- ecore_timer_add(PM_UNLOCK_TIMER_SEC, _pm_unlock_timer_cb, ad);
- }
- return;
- }
-
-
- if (ad->wake_up_setting == SETTING_WAKE_UP_GESTURE_CLOCK) {
- //Step1. Launch ALPM clock
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- return;
- }
- //bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_MAIN_VALUE);
- bundle_add(b, ALPM_CLOCK_OP, ALPM_CLOCK_SHOW);
-
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
-
- ad->pid_ALPM_clock = 0;
- ret = w_launch_app(W_ALPM_CLOCK_PKGNAME, b);
- if (ret >= 0) {
- ad->pid_ALPM_clock =ret;
- _SECURE_D("[%s] is launched, pid=[%d]", W_ALPM_CLOCK_PKGNAME, ad->pid_ALPM_clock );
- }
- if(b) {
- bundle_free(b);
- }
-
- if(vconf_get_int("db/private/com.samsung.w-home/tutorial", &tutorial_state) < 0) {
- _E("Failed to get tutorial status");
-
- }
- if(!tutorial_state) {
- //Step2. Raise Homescreen
- w_open_app(ad->home_pkgname);
- }
- ecore_timer_add(PM_UNLOCK_TIMER_SEC, _pm_unlock_timer_cb, ad);
- } else if (ad->ambient_mode == 1) {
-
- //Step1. Launch ALPM clock
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- return;
- }
- //bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_MAIN_VALUE);
- bundle_add(b, ALPM_CLOCK_OP, ALPM_CLOCK_SHOW);
-
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
-
- ad->pid_ALPM_clock = 0;
- ret = w_launch_app(W_ALPM_CLOCK_PKGNAME, b);
- if (ret >= 0) {
- ad->pid_ALPM_clock =ret;
- _SECURE_D("[%s] is launched, pid=[%d]", W_ALPM_CLOCK_PKGNAME, ad->pid_ALPM_clock );
- }
- if(b) {
- bundle_free(b);
- }
- //Step2. Do not raise Homescreen
- ecore_timer_add(PM_UNLOCK_TIMER_SEC, _pm_unlock_timer_cb, ad);
- }
-
-
-#else
- if(_check_reserved_popup_status(ad)){
- _W("reserved popup is on top. do nothing");
- if((ad->ambient_mode == 1) && (ad->ALPM_clock_state == 0)){
- starter_dbus_alpm_clock_signal_send(ad);
- }
- return;
- }
-
- if (_check_reserved_apps_status(ad)) {
- _W("reserved app is running now. raise it.");
-
- EINA_LIST_FOREACH(ad->reserved_apps_list, l, info){
- if(strncmp(info, SHEALTH_SLEEP_PKGNAME, strlen(info)) == 0){
- _W("%s is in the list. check running state", info);
- if(aul_app_is_running(info) == 1){
- _W("%s is now running. raise it.", info);
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
- w_open_app(info);
- ecore_timer_add(PM_UNLOCK_TIMER_SEC, _pm_unlock_timer_cb, ad);
- return;
- }
- else{
- _W("%s is not running now", info);
- ad->reserved_apps_list = eina_list_remove_list(ad->reserved_apps_list, l);
- break;
- }
- }
- }
-
- EINA_LIST_REVERSE_FOREACH(ad->reserved_apps_list, l, info){
- if(aul_app_is_running(info) == 1){
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
- w_open_app(info);
- ecore_timer_add(PM_UNLOCK_TIMER_SEC, _pm_unlock_timer_cb, ad);
- break;
- }
- else{
- _W("%s is not running now", info);
- ad->reserved_apps_list = eina_list_remove_list(ad->reserved_apps_list, l);
- continue;
- }
- }
- count = eina_list_count(ad->reserved_apps_list);
- if(count == 0){
- _W("there is no reserved app.");
- vconf_set_int(VCONFKEY_STARTER_RESERVED_APPS_STATUS, 0);
- }
- }
-
- if ((ad->ambient_mode == 1) && (ad->ALPM_clock_state == 0)) {
-#if 0
- //Step1. Launch ALPM clock
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- return;
- }
- //bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_MAIN_VALUE);
- bundle_add(b, ALPM_CLOCK_OP, ALPM_CLOCK_SHOW);
-
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
-
- ad->pid_ALPM_clock = 0;
- ret = w_launch_app(W_ALPM_CLOCK_PKGNAME, b);
- if (ret >= 0) {
- ad->pid_ALPM_clock =ret;
- _SECURE_D("[%s] is launched, pid=[%d]", W_ALPM_CLOCK_PKGNAME, ad->pid_ALPM_clock );
- }
- if(b){
- bundle_free(b);
- }
- //Step2. Do not raise Homescreen
- ecore_timer_add(PM_UNLOCK_TIMER_SEC, _pm_unlock_timer_cb, ad);
-#endif
- starter_dbus_alpm_clock_signal_send(ad);
- } else {
- int val = 0;
- if(vconf_get_bool(VCONFKEY_SETTING_SIMPLE_CLOCK_MODE, &val) < 0) {
- _E("Failed to get VCONFKEY_SETTING_SIMPLE_CLOCK_MODE");
- }
-
-
- // Not yet fix the setting concept.
- //if ((_check_reserved_apps_status(ad) == FALSE) && (val == TRUE) && (ad->wake_up_setting == SETTING_WAKE_UP_GESTURE_CLOCK)) {
- if ((_check_reserved_apps_status(ad) == FALSE) && (ad->wake_up_setting == SETTING_WAKE_UP_GESTURE_CLOCK) && (ad->ALPM_clock_state == 0)) {
- //_W("Not reserved apss status AND wake_up_setting is CLOCK AND simple clock setting is [%d] => show simple clock..!!", val);
- _W("Not reserved apss status AND wake_up_setting is CLOCK => show simple clock..!!");
-#if 0
- //Step1. Launch ALPM clock
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- return;
- }
- //bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_MAIN_VALUE);
- bundle_add(b, ALPM_CLOCK_OP, ALPM_CLOCK_SHOW);
-
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
-
- ad->pid_ALPM_clock = 0;
- ret = w_launch_app(W_ALPM_CLOCK_PKGNAME, b);
- if (ret >= 0) {
- ad->pid_ALPM_clock =ret;
- _SECURE_D("[%s] is launched, pid=[%d]", W_ALPM_CLOCK_PKGNAME, ad->pid_ALPM_clock );
- }
- if(b){
- bundle_free(b);
- }
- //Step2. Do not raise Homescreen
- ecore_timer_add(PM_UNLOCK_TIMER_SEC, _pm_unlock_timer_cb, ad);
-#endif
- starter_dbus_alpm_clock_signal_send(ad);
- }
- }
-#endif
-}
-
-
-void init_clock_mgr(void *data)
-{
- int status = -1;
- int ret = -1;
- int val = -1;
- int reserved_apps_msg_port_id = 0;
- struct appdata *ad = (struct appdata *)data;
-
- _W("init_clock_mgr.!!");
-#if 0
- //register message port for reserved apps
- if ((reserved_apps_msg_port_id = message_port_register_local_port(RESERVED_DISPLAY_MESSAGE_PORT_ID, reserved_apps_message_received_cb)) <= 0) {
- _E("Failed to register reserved_apps message port cb");
- }
- _E("port_id:%d", reserved_apps_msg_port_id);
- ad->reserved_apps_local_port_id = reserved_apps_msg_port_id;
-#endif
- if(init_dbus_ALPM_clock_state_signal(ad) < 0) {
- _E("Failed to init_dbus_ALPM_clock_state_signal");
- }
-
- //register wake up gesture setting changed.
- if(vconf_get_int(VCONFKEY_WMS_WAKEUP_BY_GESTURE_SETTING, &val) < 0) {
- _E("Failed to get VCONFKEY_WMS_WAKEUP_BY_GESTURE_SETTING");
- val = 1;
- }
- ad->wake_up_setting = val;
- _W("wake_up_setting : %d", ad->wake_up_setting);
-
- if (vconf_notify_key_changed(VCONFKEY_WMS_WAKEUP_BY_GESTURE_SETTING, _wake_up_setting_changed_cb, ad) < 0) {
- _E("Failed to add the callback for VCONFKEY_WMS_WAKEUP_BY_GESTURE_SETTING changed");
- }
-
- //register ambient mode changed.
- if(vconf_get_bool(VCONFKEY_SETAPPL_AMBIENT_MODE_BOOL, &val) < 0) {
- _E("Failed to get VCONFKEY_SETAPPL_AMBIENT_MODE_BOOL");
- val = 0;
- }
- ad->ambient_mode = val;
- _W("ambient_mode : %d", ad->ambient_mode);
-
- if (vconf_notify_key_changed(VCONFKEY_SETAPPL_AMBIENT_MODE_BOOL, _ambient_mode_setting_changed_cb, ad) < 0) {
- _E("Failed to add the callback for VCONFKEY_SETAPPL_AMBIENT_MODE_BOOL changed");
- }
-
- if (vconf_notify_key_changed(VCONFKEY_PM_LCDOFF_SOURCE, _notify_pm_lcdoff_cb, ad) != 0) {
- _E("Fail vconf_notify_key_changed : VCONFKEY_PM_LCDOFF_SOURCE");
- }
-
-#if 0
- if (vconf_notify_key_changed(VCONFKEY_SHEALTH_VIEW_TYPE_STR, _shealth_view_type_changed_cb, ad) < 0) {
- _E("Failed to add the callback for VCONFKEY_SHEALTH_VIEW_TYPE_STR changed");
- }
-
- if (vconf_notify_key_changed(VCONFKEY_HERE_TBT_STATUS_INT, _here_navigation_status_changed_cb, ad) < 0) {
- _E("Failed to add the callback for VCONFKEY_HERE_TBT_STATUS_INT changed");
- }
-#endif
-}
-
-
-
-void fini_clock_mgr(void *data)
-{
- struct appdata *ad = (struct appdata *)data;
-
- if(vconf_ignore_key_changed(VCONFKEY_WMS_WAKEUP_BY_GESTURE_SETTING, _wake_up_setting_changed_cb) < 0) {
- _E("Failed to ignore the VCONFKEY_WMS_WAKEUP_BY_GESTURE_SETTING");
- }
-
- if(vconf_ignore_key_changed(VCONFKEY_PM_LCDOFF_SOURCE, _notify_pm_lcdoff_cb) < 0) {
- _E("Failed to ignore the VCONFKEY_PM_LCDOFF_SOURCE");
- }
-
- if (vconf_ignore_key_changed(VCONFKEY_SETAPPL_AMBIENT_MODE_BOOL, _ambient_mode_setting_changed_cb) < 0) {
- _E("Failed to ignore the VCONFKEY_SETAPPL_AMBIENT_MODE_BOOL");
- }
-
-#if 0
- if(vconf_ignore_key_changed(VCONFKEY_SHEALTH_VIEW_TYPE_STR, _shealth_view_type_changed_cb) < 0) {
- _E("Failed to ignore the VCONFKEY_SHEALTH_VIEW_TYPE_STR");
- }
-
- if(vconf_ignore_key_changed(VCONFKEY_HERE_TBT_STATUS_INT, _here_navigation_status_changed_cb) < 0) {
- _E("Failed to ignore the VCONFKEY_HERE_TBT_STATUS_INT");
- }
-#endif
-
-#if 0 // Disable temporarily for TIZEN 2.3 build
- if (ad->reserved_apps_local_port_id >= 0) {
- if (message_port_unregister_local_port(ad->reserved_apps_local_port_id) != MESSAGE_PORT_ERROR_NONE) {
- _E("Failed to unregister reserved apps message port cb");
- }
- }
-#endif
-
-}
-
-
-
-// End of a file
diff --git a/src/dbus-util.c b/src/dbus-util.c
deleted file mode 100755
index ba47cbf..0000000
--- a/src/dbus-util.c
+++ /dev/null
@@ -1,225 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <E_DBus.h>
-#include <dbus/dbus-glib.h>
-
-#include "starter.h"
-#include "starter-util.h"
-#include "util.h"
-
-#define DBUS_HOME_BUS_NAME "org.tizen.coreapps.home"
-#define DBUS_HOME_RAISE_PATH "/Org/Tizen/Coreapps/home/raise"
-#define DBUS_HOME_RAISE_INTERFACE DBUS_HOME_BUS_NAME".raise"
-#define DBUS_HOME_RAISE_MEMBER "homeraise"
-
-#define DEVICED_BUS_NAME "org.tizen.system.deviced"
-#define DEVICED_OBJECT_PATH "/Org/Tizen/System/DeviceD"
-#define DEVICED_INTERFACE_NAME DEVICED_BUS_NAME
-
-#define DEVICED_PATH DEVICED_OBJECT_PATH"/Process"
-#define DEVICED_INTERFACE DEVICED_INTERFACE_NAME".Process"
-
-#define DEVICED_SET_METHOD "oomadj_set"
-
-#define DBUS_REPLY_TIMEOUT (120 * 1000)
-
-static struct _info {
- DBusConnection *connection;
-} s_info = {
- .connection = NULL,
-};
-
-static DBusConnection *_dbus_connection_get(void) {
- if (s_info.connection == NULL) {
- _W("no connection for dbus. get dbus connection");
- DBusError derror;
- DBusConnection *connection = NULL;
-
- dbus_error_init(&derror);
- connection = dbus_bus_get_private(DBUS_BUS_SYSTEM, &derror);
- if (connection == NULL) {
- _E("Failed to get dbus connection:%s", derror.message);
- dbus_error_free(&derror);
- return NULL;
- }
- dbus_connection_setup_with_g_main(connection, NULL);
- dbus_error_free(&derror);
-
- s_info.connection = connection;
- }
-
- return s_info.connection;
-}
-
-static int _append_variant(DBusMessageIter *iter, const char *sig, char *param[])
-{
- char *ch;
- int i;
- int int_type;
- uint64_t int64_type;
-
- if (!sig || !param)
- return 0;
-
- for (ch = (char*)sig, i = 0; *ch != '\0'; ++i, ++ch) {
- switch (*ch) {
- case 'i':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &int_type);
- break;
- case 'u':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT32, &int_type);
- break;
- case 't':
- int64_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT64, &int64_type);
- break;
- case 's':
- dbus_message_iter_append_basic(iter, DBUS_TYPE_STRING, &param[i]);
- break;
- default:
- return -EINVAL;
- }
- }
-
- return 0;
-}
-
-static int _invoke_dbus_method_sync(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r, ret;
-
- DBusConnection *conn = NULL;
-
- conn = (DBusConnection *)_dbus_connection_get();
- if (!conn) {
- _E("dbus_bus_get error");
- return -1;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- _E("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return -EBADMSG;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _append_variant(&iter, sig, param);
- if (r < 0) {
- _E("append_variant error(%d)", r);
- dbus_message_unref(msg);
- return -EBADMSG;
- }
-
- dbus_error_init(&err);
-
- reply = dbus_connection_send_with_reply_and_block(conn, msg, DBUS_REPLY_TIMEOUT, &err);
- dbus_message_unref(msg);
- if (!reply) {
- _E("dbus_connection_send error(%s:%s)", err.name, err.message);
- dbus_error_free(&err);
- return -EBADMSG;
- }
-
- return reply;
-}
-
-static int _dbus_message_send(const char *path, const char *interface, const char *member)
-{
- int ret = 0;
- DBusMessage *msg = NULL;
- DBusConnection *conn = NULL;
-
- conn = (DBusConnection *)_dbus_connection_get();
- if (!conn) {
- _E("dbus_bus_get error");
- return -1;
- }
-
- msg = dbus_message_new_signal(path, interface, member);
- if (!msg) {
- _E("dbus_message_new_signal(%s:%s-%s)", path, interface, member);
- return -1;
- }
-
- ret = dbus_connection_send(conn, msg, NULL); //async call
- dbus_message_unref(msg);
- if (ret != TRUE) {
- _E("dbus_connection_send error(%s:%s-%s)", path, interface, member);
- return -ECOMM;
- }
- _D("dbus_connection_send, ret=%d", ret);
- return 0;
-}
-
-void starter_dbus_home_raise_signal_send(void)
-{
- int ret = 0;
-
- ret = _dbus_message_send(
- DBUS_HOME_RAISE_PATH,
- DBUS_HOME_RAISE_INTERFACE,
- DBUS_HOME_RAISE_MEMBER);
- _E("Sending HOME RAISE signal, result:%d", ret);
-}
-
-int starter_dbus_set_oomadj(int pid, int oom_adj_value)
-{
- if(pid <= 0){
- _E("Pid is invalid");
- return -1;
- }
- DBusError err;
- DBusMessage *msg;
- char *pa[4];
- char buf1[16];
- char buf2[16];
- int ret, val;
-
- snprintf(buf1, sizeof(buf1), "%d", pid);
- snprintf(buf2, sizeof(buf2), "%d", oom_adj_value);
-
- pa[0] = DEVICED_SET_METHOD;
- pa[1] = "2";
- pa[2] = buf1;
- pa[3] = buf2;
-
- msg = _invoke_dbus_method_sync(DEVICED_BUS_NAME, DEVICED_PATH, DEVICED_INTERFACE, DEVICED_SET_METHOD, "siss", pa);
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &val, DBUS_TYPE_INVALID);
- if (!ret) {
- _E("no message : [%s:%s]", err.name, err.message);
- val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- _D("%s-%s : %d", DEVICED_INTERFACE, pa[0], val);
- return val;
-}
diff --git a/src/dbus-util_w.c b/src/dbus-util_w.c
deleted file mode 100755
index 751adf2..0000000
--- a/src/dbus-util_w.c
+++ /dev/null
@@ -1,745 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <Ecore.h>
-#include <dd-display.h>
-#include <aul.h>
-
-#include "starter_w.h"
-#include "dbus-util_w.h"
-#include "util.h"
-
-
-#define DEVICED_BUS_NAME "org.tizen.system.deviced"
-#define DEVICED_OBJECT_PATH "/Org/Tizen/System/DeviceD"
-#define DEVICED_INTERFACE_NAME DEVICED_BUS_NAME
-
-#define POWEROFF_BUS_NAME "org.tizen.system.popup"
-#define POWEROFF_OBJECT_PATH "/Org/Tizen/System/Popup/Poweroff"
-#define POWEROFF_INTERFACE_NAME POWEROFF_BUS_NAME".Poweroff"
-#define METHOD_POWEROFF_NAME "PopupLaunch"
-#define DBUS_REPLY_TIMEOUT (120 * 1000)
-
-#define DISPLAY_OBJECT_PATH DEVICED_OBJECT_PATH"/Display"
-#define DEVICED_INTERFACE_DISPLAY DEVICED_INTERFACE_NAME".display"
-#define MEMBER_ALPM_ON "ALPMOn"
-#define MEMBER_ALPM_OFF "ALPMOff"
-#define MEMBER_LCD_ON "LCDOn"
-#define MEMBER_LCD_OFF "LCDOff"
-#define LCD_ON_BY_GESTURE "gesture"
-
-
-#define CPU_BOOSTER_OBJECT_PATH DEVICED_OBJECT_PATH"/PmQos"
-#define CPU_BOOSTER_INTERFACE DEVICED_BUS_NAME".PmQos"
-#define METHOD_CPU_BOOSTER "AppLaunchHome"
-#define DBUS_CPU_BOOSTER_SEC 200
-
-#define COOL_DOWN_MODE_PATH DEVICED_OBJECT_PATH"/SysNoti"
-#define COOL_DOWN_MODE_INTERFACE DEVICED_BUS_NAME".SysNoti"
-#define SIGNAL_COOL_DOWN_MODE "CoolDownChanged"
-#define METHOD_COOL_DOWN_MODE "GetCoolDownStatus"
-#define COOL_DOWN_MODE_RELEASE "Release"
-#define COOL_DOWN_MODE_LIMITACTION "LimitAction"
-
-#define NIKE_RUNNING_STATUS_PATH "/Com/Nike/Nrunning/RunningMgr"
-#define NIKE_RUNNING_STATUS_INTERFACE "com.nike.nrunning.runningmgr"
-#define NIKE_RUNNING_STATUS_SIGNAL "RunningStatus"
-#define NIKE_RUNNING_STATUS_START "start"
-#define NIKE_RUNNING_STATUS_END "end"
-
-#define DBUS_ALPM_CLOCK_PATH "/Org/Tizen/System/AlpmMgr"
-#define DBUS_ALPM_CLOCK_INTERFACE "org.tizen.system.alpmmgr"
-#define DBUS_ALPM_CLOCK_MEMBER_STATUS "ALPMStatus"
-#define ALPM_CLOCK_SHOW "show"
-
-#define DBUS_STARTER_ALPMCLOCK_PATH "/Org/Tizen/Coreapps/starter"
-#define DBUS_STARTER_ALPMCLOCK_INTERFACE "org.tizen.coreapps.starter.alpmclock"
-#define DBUS_STARTER_ALPMCLOCK_MEMBER "show"
-
-
-static struct _info {
- DBusConnection *connection;
-} s_info = {
- .connection = NULL,
-};
-
-static int pid_ALPM_clock = 0;
-
-static int _append_variant(DBusMessageIter *iter, const char *sig, char *param[])
-{
- char *ch;
- int i;
- int int_type;
- uint64_t int64_type;
-
- if (!sig || !param)
- return 0;
-
- for (ch = (char*)sig, i = 0; *ch != '\0'; ++i, ++ch) {
- switch (*ch) {
- case 'i':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &int_type);
- break;
- case 'u':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT32, &int_type);
- break;
- case 't':
- int64_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT64, &int64_type);
- break;
- case 's':
- dbus_message_iter_append_basic(iter, DBUS_TYPE_STRING, &param[i]);
- break;
- default:
- return -EINVAL;
- }
- }
-
- return 0;
-}
-
-DBusConnection *starter_dbus_connection_get(void) {
- if (s_info.connection == NULL) {
- _W("no connection for dbus. get dbus connection");
- DBusError derror;
- DBusConnection *connection = NULL;
-
- dbus_error_init(&derror);
- connection = dbus_bus_get_private(DBUS_BUS_SYSTEM, &derror);
- if (connection == NULL) {
- _E("Failed to get dbus connection:%s", derror.message);
- dbus_error_free(&derror);
- return NULL;
- }
- dbus_connection_setup_with_g_main(connection, NULL);
- dbus_error_free(&derror);
-
- s_info.connection = connection;
- }
-
- return s_info.connection;
-}
-
-static int _dbus_message_send(const char *path, const char *interface, const char *member)
-{
- int ret = 0;
- DBusMessage *msg = NULL;
- DBusConnection *conn = NULL;
-
- conn = (DBusConnection *)starter_dbus_connection_get();
- if (!conn) {
- _E("dbus_bus_get error");
- return -1;
- }
- _E("dbus_message_new_signal(%s:%s-%s)", path, interface, member);
-
- msg = dbus_message_new_signal(path, interface, member);
- if (!msg) {
- _E("dbus_message_new_signal(%s:%s-%s)", path, interface, member);
- return -1;
- }
-
- ret = dbus_connection_send(conn, msg, NULL); //async call
- dbus_message_unref(msg);
- if (ret != TRUE) {
- _E("dbus_connection_send error(%s:%s-%s)", path, interface, member);
- return -ECOMM;
- }
- _D("dbus_connection_send, ret=%d", ret);
- return 0;
-}
-
-void starter_dbus_alpm_clock_signal_send(void *data)
-{
- int ret = 0;
-
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return;
- }
-#if 0
- if(ad->lcd_status == 1){
- _W("LCD is already on. Do not send alpm clock show msg.");
- return;
- }
-#endif
-
- ret = _dbus_message_send(
- DBUS_STARTER_ALPMCLOCK_PATH,
- DBUS_STARTER_ALPMCLOCK_INTERFACE,
- DBUS_STARTER_ALPMCLOCK_MEMBER);
- _E("Sending alpmclock show signal, result:%d", ret);
-}
-
-
-DBusMessage *_invoke_dbus_method_sync(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- _E("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- _E("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _append_variant(&iter, sig, param);
- if (r < 0) {
- _E("append_variant error(%d)", r);
- return NULL;
- }
-
- dbus_error_init(&err);
-
- reply = dbus_connection_send_with_reply_and_block(conn, msg, DBUS_REPLY_TIMEOUT, &err);
-
- if (!reply) {
- _E("dbus_connection_send error(No reply)");
- }
-
- if (dbus_error_is_set(&err)) {
- _E("dbus_connection_send error(%s:%s)", err.name, err.message);
- reply = NULL;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- return reply;
-}
-
-DBusMessage *_invoke_dbus_method_async(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- _E("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- _E("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _append_variant(&iter, sig, param);
- if (r < 0) {
- _E("append_variant error(%d)", r);
- return NULL;
- }
-
- r = dbus_connection_send(conn, msg, NULL);
- dbus_message_unref(msg);
- if (r != TRUE) {
- _E("dbus_connection_send error(%s:%s:%s-%s)", dest, path, interface, method);
- return -ECOMM;
- }
- _D("dbus_connection_send, ret=%d", r);
- return NULL;
-}
-
-int get_dbus_cool_down_mode(void *data)
-{
- _D();
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return -1;
- }
- DBusError err;
- DBusMessage *msg;
- int ret = 0;
- char *str = NULL;
- int ret_val = 0;
-
- msg = _invoke_dbus_method_sync(DEVICED_BUS_NAME, COOL_DOWN_MODE_PATH, COOL_DOWN_MODE_INTERFACE,
- METHOD_COOL_DOWN_MODE, NULL, NULL);
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_STRING, &str, DBUS_TYPE_INVALID);
- if (!ret) {
- _E("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- _D("%s-%s : %s", COOL_DOWN_MODE_INTERFACE, METHOD_COOL_DOWN_MODE, str);
-
- if(!strncmp(str, COOL_DOWN_MODE_RELEASE, strlen(COOL_DOWN_MODE_RELEASE))){
- _D("%s", COOL_DOWN_MODE_RELEASE);
- ad->cool_down_mode = 0;
- return ret_val;
- }
- if(!strncmp(str, COOL_DOWN_MODE_LIMITACTION, strlen(COOL_DOWN_MODE_LIMITACTION))){
- _D("%s", COOL_DOWN_MODE_LIMITACTION);
- ad->cool_down_mode = 1;
- return ret_val;
- }
-}
-
-int request_dbus_cpu_booster(void)
-{
- DBusError err;
- DBusMessage *msg;
- int ret, ret_val;
- char *arr[1];
- char val[32];
-
- snprintf(val, sizeof(val), "%d", DBUS_CPU_BOOSTER_SEC);
- arr[0] = val;
-
- msg = _invoke_dbus_method_async(DEVICED_BUS_NAME, CPU_BOOSTER_OBJECT_PATH, CPU_BOOSTER_INTERFACE,
- METHOD_CPU_BOOSTER, "i", arr);
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &ret_val, DBUS_TYPE_INVALID);
- if (!ret) {
- _E("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- _D("%s-%s : %d", CPU_BOOSTER_INTERFACE, METHOD_CPU_BOOSTER, ret_val);
- return ret_val;
-}
-
-
-int request_Poweroff(void)
-{
- DBusError err;
- DBusMessage *msg;
- int ret, ret_val;
-
- msg = _invoke_dbus_method_async(POWEROFF_BUS_NAME, POWEROFF_OBJECT_PATH, POWEROFF_INTERFACE_NAME,
- METHOD_POWEROFF_NAME, NULL, NULL);
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &ret_val, DBUS_TYPE_INVALID);
- if (!ret) {
- _E("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- _D("%s-%s : %d", POWEROFF_INTERFACE_NAME, METHOD_POWEROFF_NAME, ret_val);
- return ret_val;
-}
-
-
-#define W_CLOCK_ALPM_PKGNAME "com.samsung.idle-clock-alpm"
-static void _on_ALPM_changed_receive(void *data, DBusMessage *msg)
-{
- DBusError err;
- char *str;
- int response;
- int r;
- int alpm_on = 0;
- int alpm_off = 0;
-
- _D("ALPM signal is received");
-
- alpm_on = dbus_message_is_signal(msg, DEVICED_INTERFACE_DISPLAY, MEMBER_ALPM_ON);
- alpm_off = dbus_message_is_signal(msg, DEVICED_INTERFACE_DISPLAY, MEMBER_ALPM_OFF);
-
- if (alpm_on) {
- pid_ALPM_clock = w_launch_app(W_CLOCK_ALPM_PKGNAME, NULL);
- _D("Launch ALPM clock[%s], pid[%d]", W_CLOCK_ALPM_PKGNAME, pid_ALPM_clock);
- } else if (alpm_off) {
-#if 1
- aul_terminate_pid(pid_ALPM_clock);
-#else
- if (!pid_ALPM_clock) {
- aul_terminate_pid(pid_ALPM_clock);
- _D("Terminate ALPM clock pid[%d]", pid_ALPM_clock);
- pid_ALPM_clock = 0;
- } else {
- _E(" ALPM clock pid is 0");
- }
-#endif
- } else {
- _E("%s dbus_message_is_signal error", DEVICED_INTERFACE_DISPLAY);
- }
-}
-
-
-int init_dbus_ALPM_signal(void *data)
-{
- E_DBus_Connection *conn;
- E_DBus_Signal_Handler *handler;
- int r;
-
- g_type_init();
- e_dbus_init();
-
- conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
- if (conn == NULL) {
- _E("e_dbus_bus_get error");
- return -1;
- }
-
- handler = e_dbus_signal_handler_add(conn, NULL, DISPLAY_OBJECT_PATH,
- DEVICED_INTERFACE_DISPLAY, MEMBER_ALPM_ON,
- _on_ALPM_changed_receive, NULL);
- if (handler == NULL) {
- _E("e_dbus_signal_handler_add error");
- return -1;
- }
-
-
- handler = e_dbus_signal_handler_add(conn, NULL, DISPLAY_OBJECT_PATH,
- DEVICED_INTERFACE_DISPLAY, MEMBER_ALPM_OFF,
- _on_ALPM_changed_receive, NULL);
- if (handler == NULL) {
- _E("e_dbus_signal_handler_add error");
- return -1;
- }
-}
-
-static void _on_COOL_DOWN_MODE_changed_receive(void *data, DBusMessage *msg)
-{
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return;
- }
- DBusError err;
- const char *str = NULL;
- int response;
- int r;
- int mode_release = 0;
- int mode_limitaction = 0;
-
- _W("COOL DOWN MODE signal is received");
- dbus_error_init(&err);
-
- r = dbus_message_is_signal(msg, COOL_DOWN_MODE_INTERFACE, SIGNAL_COOL_DOWN_MODE);
-
- r = dbus_message_get_args(msg, &err, DBUS_TYPE_STRING, &str, DBUS_TYPE_INVALID);
- if (!r) {
- _E("no message : [%s:%s]", err.name, err.message);
- return;
- }
-
- _D("received siganl : %s", str);
-
- if (!strncmp(str, COOL_DOWN_MODE_RELEASE, strlen(COOL_DOWN_MODE_RELEASE))) {
- _W("%s", COOL_DOWN_MODE_RELEASE);
- ad->cool_down_mode = 0;
- } else if (!strncmp(str, COOL_DOWN_MODE_LIMITACTION, strlen(COOL_DOWN_MODE_LIMITACTION))) {
- _W("%s", COOL_DOWN_MODE_LIMITACTION);
- ad->cool_down_mode = 1;
- } else {
- _E("%s dbus_message_is_signal error", SIGNAL_COOL_DOWN_MODE);
- }
-}
-
-int init_dbus_COOL_DOWN_MODE_signal(void *data)
-{
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return -1;
- }
- E_DBus_Connection *conn;
- E_DBus_Signal_Handler *handler;
- int r;
-
- g_type_init();
- e_dbus_init();
-
- conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
- if (conn == NULL) {
- _E("e_dbus_bus_get error");
- return -1;
- }
-
- handler = e_dbus_signal_handler_add(conn, NULL, COOL_DOWN_MODE_PATH,
- COOL_DOWN_MODE_INTERFACE, SIGNAL_COOL_DOWN_MODE,
- _on_COOL_DOWN_MODE_changed_receive, ad);
- if (handler == NULL) {
- _E("e_dbus_signal_handler_add error");
- return -1;
- }
-}
-#if 0
-static void _on_NIKE_RUNNING_STATUS_changed_receive(void *data, DBusMessage *msg)
-{
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return;
- }
- DBusError err;
- const char *str = NULL;
- int response;
- int r;
- int mode_release = 0;
- int mode_limitaction = 0;
-
- _W("NIKE RUNNING STATUS signal is received");
- dbus_error_init(&err);
-
- r = dbus_message_is_signal(msg, NIKE_RUNNING_STATUS_INTERFACE, NIKE_RUNNING_STATUS_SIGNAL);
-
- r = dbus_message_get_args(msg, &err, DBUS_TYPE_STRING, &str, DBUS_TYPE_INVALID);
- if (!r) {
- _E("no message : [%s:%s]", err.name, err.message);
- return;
- }
-
- _W("received siganl : %s", str);
-
- if (!strncmp(str, NIKE_RUNNING_STATUS_START, strlen(NIKE_RUNNING_STATUS_START))) {
- _W("%s", NIKE_RUNNING_STATUS_START);
- ad->nike_running_status = 1;
- } else if (!strncmp(str, NIKE_RUNNING_STATUS_END, strlen(NIKE_RUNNING_STATUS_END))) {
- _W("%s", NIKE_RUNNING_STATUS_END);
- ad->nike_running_status = 0;
- } else {
- _E("%s dbus_message_is_signal error", NIKE_RUNNING_STATUS_SIGNAL);
- }
- clock_mgr_set_reserved_apps_status(ad->nike_running_status, STARTER_RESERVED_APPS_NIKE, ad);
-}
-
-int init_dbus_NIKE_RUNNING_STATUS_signal(void *data)
-{
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return -1;
- }
- E_DBus_Connection *conn;
- E_DBus_Signal_Handler *handler;
- int r;
-
- g_type_init();
- e_dbus_init();
-
- conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
- if (conn == NULL) {
- _E("e_dbus_bus_get error");
- return -1;
- }
-
- handler = e_dbus_signal_handler_add(conn, NULL, NIKE_RUNNING_STATUS_PATH,
- NIKE_RUNNING_STATUS_INTERFACE, NIKE_RUNNING_STATUS_SIGNAL,
- _on_NIKE_RUNNING_STATUS_changed_receive, ad);
- if (handler == NULL) {
- _E("e_dbus_signal_handler_add error");
- return -1;
- }
-}
-#endif
-
-static void _on_lcd_changed_receive(void *data, DBusMessage *msg)
-{
- DBusError err;
- const char *str = NULL;
- int response;
- int r;
- int lcd_on = 0;
- int lcd_off = 0;
-
- struct appdata *ad = (struct appdata *)data;
-
- _D("LCD signal is received");
-
- lcd_on = dbus_message_is_signal(msg, DEVICED_INTERFACE_DISPLAY, MEMBER_LCD_ON);
- lcd_off = dbus_message_is_signal(msg, DEVICED_INTERFACE_DISPLAY, MEMBER_LCD_OFF);
-
-
- if (lcd_on) {
-#if 0
- dbus_error_init(&err);
-
- r = dbus_message_get_args(msg, &err, DBUS_TYPE_STRING, &str, DBUS_TYPE_INVALID);
-
- if (!r) {
- _E("no message : [%s:%s]", err.name, err.message);
- return;
- }
-
- _W("%s, %d, str=[%s]", __func__, __LINE__, str);
-
- if (!strncmp(str, LCD_ON_BY_GESTURE, strlen(LCD_ON_BY_GESTURE))) {
- _W("LCD ON by [%s], do not terminate ALPM clock", LCD_ON_BY_GESTURE);
- } else {
- if (ad->pid_ALPM_clock > 0) {
- _W("LCD ON by [%s], terminate ALPM clock pid[%d]", str, ad->pid_ALPM_clock);
- aul_terminate_pid(ad->pid_ALPM_clock);
- ad->pid_ALPM_clock = 0;
- }
- }
-#endif
- _W("LCD on");
- ad->lcd_status = 1;
- }
- else if(lcd_off){
- _W("LCD off");
- ad->lcd_status = 0;
- } else {
- _E("%s dbus_message_is_signal error", DEVICED_INTERFACE_DISPLAY);
- }
-}
-
-
-int init_dbus_lcd_on_off_signal(void *data)
-{
- E_DBus_Connection *conn;
- E_DBus_Signal_Handler *handler;
- int r;
-
- g_type_init();
- e_dbus_init();
-
- conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
- if (conn == NULL) {
- _E("e_dbus_bus_get error");
- return -1;
- }
-
-
- handler = e_dbus_signal_handler_add(conn, NULL, DISPLAY_OBJECT_PATH,
- DEVICED_INTERFACE_DISPLAY, MEMBER_LCD_ON,
- _on_lcd_changed_receive, data);
- if (handler == NULL) {
- _E("e_dbus_signal_handler_add error");
- return -1;
- }
-
- handler = e_dbus_signal_handler_add(conn, NULL, DISPLAY_OBJECT_PATH,
- DEVICED_INTERFACE_DISPLAY, MEMBER_LCD_OFF,
- _on_lcd_changed_receive, data);
- if (handler == NULL) {
- _E("e_dbus_signal_handler_add error");
- return -1;
- }
-}
-
-
-
-static void _on_ALPM_clock_state_changed_receive(void *data, DBusMessage *msg)
-{
- DBusError err;
- const char *str = NULL;
- int response;
- int r;
- int lcd_on = 0;
-
- struct appdata *ad = (struct appdata *)data;
-
- _D("ALPM clock state is received");
-
- lcd_on = dbus_message_is_signal(msg, DBUS_ALPM_CLOCK_INTERFACE, DBUS_ALPM_CLOCK_MEMBER_STATUS);
-
-
- if (lcd_on) {
- dbus_error_init(&err);
-
- r = dbus_message_get_args(msg, &err, DBUS_TYPE_STRING, &str, DBUS_TYPE_INVALID);
-
- if (!r) {
- _E("no message : [%s:%s]", err.name, err.message);
- return;
- }
-
- _D("%s, %d, str=[%s]", __func__, __LINE__, str);
- if (!strncmp(str, ALPM_CLOCK_SHOW, strlen(ALPM_CLOCK_SHOW))) {
- _W("ALPM clock state is [%s]", ALPM_CLOCK_SHOW);
- ad->ALPM_clock_state = 1;
- } else {
- ad->ALPM_clock_state = 0;
- }
- } else {
- _E("%s dbus_message_is_signal error", DBUS_ALPM_CLOCK_INTERFACE);
- }
-}
-
-int init_dbus_ALPM_clock_state_signal(void *data)
-{
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return -1;
- }
- E_DBus_Connection *conn;
- E_DBus_Signal_Handler *handler;
- int r;
-
- g_type_init();
- e_dbus_init();
-
- ad->ALPM_clock_state = 0;
- conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
- if (conn == NULL) {
- _E("e_dbus_bus_get error");
- return -1;
- }
-
- handler = e_dbus_signal_handler_add(conn, NULL, DBUS_ALPM_CLOCK_PATH,
- DBUS_ALPM_CLOCK_INTERFACE, DBUS_ALPM_CLOCK_MEMBER_STATUS,
- _on_ALPM_clock_state_changed_receive, ad);
-
- if (handler == NULL) {
- _E("e_dbus_signal_handler_add error");
- return -1;
- }
-
- return 1;
-}
-
-
diff --git a/src/dbus_util.c b/src/dbus_util.c
new file mode 100644
index 0000000..0147607
--- /dev/null
+++ b/src/dbus_util.c
@@ -0,0 +1,395 @@
+/*
+ * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <E_DBus.h>
+#include <dbus/dbus-glib.h>
+#include <dbus/dbus-glib-lowlevel.h>
+
+#include "dbus_util.h"
+#include "util.h"
+
+#define DBUS_HOME_BUS_NAME "org.tizen.coreapps.home"
+#define DBUS_HOME_RAISE_PATH "/Org/Tizen/Coreapps/home/raise"
+#define DBUS_HOME_RAISE_INTERFACE DBUS_HOME_BUS_NAME".raise"
+#define DBUS_HOME_RAISE_MEMBER "homeraise"
+
+#define DBUS_REPLY_TIMEOUT (120 * 1000)
+
+#define POWEROFF_BUS_NAME "org.tizen.system.popup"
+#define POWEROFF_OBJECT_PATH "/Org/Tizen/System/Popup/Poweroff"
+#define POWEROFF_INTERFACE_NAME POWEROFF_BUS_NAME".Poweroff"
+#define METHOD_POWEROFF_NAME "PopupLaunch"
+
+#define CPU_BOOSTER_OBJECT_PATH DEVICED_OBJECT_PATH"/PmQos"
+#define CPU_BOOSTER_INTERFACE DEVICED_BUS_NAME".PmQos"
+#define METHOD_CPU_BOOSTER "AppLaunchHome"
+#define DBUS_CPU_BOOSTER_SEC 200
+
+#define METHOD_LOCK_PMQOS_NAME "LockScreen"
+#define DBUS_LOCK_PMQOS_SEC (2 * 1000)
+
+static struct _info {
+ DBusConnection *connection;
+} s_info = {
+ .connection = NULL,
+};
+
+
+
+static DBusConnection *_dbus_connection_get(void)
+{
+ DBusError derror;
+ DBusConnection *connection = NULL;
+
+ if (s_info.connection) {
+ return s_info.connection;
+ }
+
+ _W("no connection for dbus. get dbus connection");
+
+ dbus_error_init(&derror);
+ connection = dbus_bus_get_private(DBUS_BUS_SYSTEM, &derror);
+ if (!connection) {
+ _E("Failed to get dbus connection:%s", derror.message);
+ dbus_error_free(&derror);
+ return NULL;
+ }
+ dbus_connection_setup_with_g_main(connection, NULL);
+ dbus_error_free(&derror);
+
+ s_info.connection = connection;
+
+ return s_info.connection;
+}
+
+
+
+static int _append_variant(DBusMessageIter *iter, const char *sig, char *param[])
+{
+ char *ch;
+ int i;
+ int int_type;
+ uint64_t int64_type;
+
+ if (!sig || !param)
+ return 0;
+
+ for (ch = (char*)sig, i = 0; *ch != '\0'; ++i, ++ch) {
+ switch (*ch) {
+ case 'i':
+ int_type = atoi(param[i]);
+ dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &int_type);
+ break;
+ case 'u':
+ int_type = atoi(param[i]);
+ dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT32, &int_type);
+ break;
+ case 't':
+ int64_type = atoi(param[i]);
+ dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT64, &int64_type);
+ break;
+ case 's':
+ dbus_message_iter_append_basic(iter, DBUS_TYPE_STRING, &param[i]);
+ break;
+ default:
+ return -EINVAL;
+ }
+ }
+
+ return 0;
+}
+
+
+
+static DBusMessage *_invoke_dbus_method_sync(const char *dest, const char *path,
+ const char *interface, const char *method,
+ const char *sig, char *param[])
+{
+ DBusConnection *conn = NULL;
+ DBusMessage *msg;
+ DBusMessageIter iter;
+ DBusMessage *reply;
+ DBusError err;
+ int r;
+
+ conn = (DBusConnection *)_dbus_connection_get();
+ if (!conn) {
+ _E("dbus_bus_get error");
+ return NULL;
+ }
+
+ msg = dbus_message_new_method_call(dest, path, interface, method);
+ if (!msg) {
+ _E("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
+ return NULL;
+ }
+
+ dbus_message_iter_init_append(msg, &iter);
+ r = _append_variant(&iter, sig, param);
+ if (r < 0) {
+ _E("append_variant error(%d)", r);
+ dbus_message_unref(msg);
+ return NULL;
+ }
+
+ dbus_error_init(&err);
+
+ reply = dbus_connection_send_with_reply_and_block(conn, msg, DBUS_REPLY_TIMEOUT, &err);
+ dbus_message_unref(msg);
+ if (!reply) {
+ _E("dbus_connection_send error(%s:%s)", err.name, err.message);
+ dbus_error_free(&err);
+ return NULL;
+ }
+
+ return reply;
+}
+
+
+
+static int _invoke_dbus_method_async(const char *dest, const char *path,
+ const char *interface, const char *method,
+ const char *sig, char *param[])
+{
+ DBusConnection *conn;
+ DBusMessage *msg;
+ DBusMessageIter iter;
+ int r;
+
+ conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
+ if (!conn) {
+ _E("dbus_bus_get error");
+ return 0;
+ }
+
+ msg = dbus_message_new_method_call(dest, path, interface, method);
+ if (!msg) {
+ _E("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
+ return 0;
+ }
+
+ dbus_message_iter_init_append(msg, &iter);
+ r = _append_variant(&iter, sig, param);
+ if (r < 0) {
+ _E("append_variant error(%d)", r);
+ dbus_message_unref(msg);
+ return 0;
+ }
+
+ r = dbus_connection_send(conn, msg, NULL);
+ dbus_message_unref(msg);
+ if (r != TRUE) {
+ _E("dbus_connection_send error(%s:%s:%s-%s)", dest, path, interface, method);
+ return 0;
+ }
+
+ _D("dbus_connection_send, ret=%d", r);
+ return 1;
+}
+
+
+
+static int _dbus_message_send(const char *path, const char *interface, const char *member)
+{
+ int ret = 0;
+ DBusMessage *msg = NULL;
+ DBusConnection *conn = NULL;
+
+ conn = (DBusConnection *)_dbus_connection_get();
+ if (!conn) {
+ _E("dbus_bus_get error");
+ return -1;
+ }
+
+ msg = dbus_message_new_signal(path, interface, member);
+ if (!msg) {
+ _E("dbus_message_new_signal(%s:%s-%s)", path, interface, member);
+ return -1;
+ }
+
+ ret = dbus_connection_send(conn, msg, NULL); //async call
+ dbus_message_unref(msg);
+ if (ret != TRUE) {
+ _E("dbus_connection_send error(%s:%s-%s)", path, interface, member);
+ return -ECOMM;
+ }
+ _D("dbus_connection_send, ret=%d", ret);
+ return 0;
+}
+
+
+
+void dbus_util_send_home_raise_signal(void)
+{
+ int ret = 0;
+
+ ret = _dbus_message_send(
+ DBUS_HOME_RAISE_PATH,
+ DBUS_HOME_RAISE_INTERFACE,
+ DBUS_HOME_RAISE_MEMBER);
+ _E("Sending HOME RAISE signal, result:%d", ret);
+}
+
+
+
+int dbus_util_send_oomadj(int pid, int oom_adj_value)
+{
+ DBusError err;
+ DBusMessage *msg;
+ char *pa[4];
+ char buf1[BUF_SIZE_16];
+ char buf2[BUF_SIZE_16];
+ int ret, val;
+
+ if(pid <= 0){
+ _E("Pid is invalid");
+ return -1;
+ }
+
+ snprintf(buf1, sizeof(buf1), "%d", pid);
+ snprintf(buf2, sizeof(buf2), "%d", oom_adj_value);
+
+ pa[0] = DEVICED_SET_METHOD;
+ pa[1] = "2";
+ pa[2] = buf1;
+ pa[3] = buf2;
+
+ msg = _invoke_dbus_method_sync(DEVICED_BUS_NAME, DEVICED_PATH, DEVICED_INTERFACE, DEVICED_SET_METHOD, "siss", pa);
+ if (!msg)
+ return -EBADMSG;
+
+ dbus_error_init(&err);
+
+ ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &val, DBUS_TYPE_INVALID);
+ if (!ret) {
+ _E("no message : [%s:%s]", err.name, err.message);
+ val = -EBADMSG;
+ }
+
+ dbus_message_unref(msg);
+ dbus_error_free(&err);
+
+ _D("%s-%s : %d", DEVICED_INTERFACE, pa[0], val);
+ return val;
+}
+
+
+
+void dbus_util_send_cpu_booster_signal(void)
+{
+ int ret = 0;
+ char *arr[1];
+ char val[BUF_SIZE_32];
+
+ snprintf(val, sizeof(val), "%d", DBUS_CPU_BOOSTER_SEC);
+ arr[0] = val;
+
+ ret = _invoke_dbus_method_async(DEVICED_BUS_NAME, CPU_BOOSTER_OBJECT_PATH, CPU_BOOSTER_INTERFACE,
+ METHOD_CPU_BOOSTER, "i", arr);
+ ret_if(!ret);
+
+ _D("%s-%s", CPU_BOOSTER_INTERFACE, METHOD_CPU_BOOSTER);
+}
+
+
+
+void dbus_util_send_poweroff_signal(void)
+{
+ int ret = 0;
+
+ ret = _invoke_dbus_method_async(POWEROFF_BUS_NAME, POWEROFF_OBJECT_PATH, POWEROFF_INTERFACE_NAME,
+ METHOD_POWEROFF_NAME, NULL, NULL);
+ ret_if(!ret);
+
+ _D("%s-%s", POWEROFF_INTERFACE_NAME, METHOD_POWEROFF_NAME);
+}
+
+
+
+void dbus_util_send_lock_PmQos_signal(void)
+{
+ int ret = 0;
+
+ char *arr[1];
+ char val[BUF_SIZE_32];
+
+ snprintf(val, sizeof(val), "%d", DBUS_LOCK_PMQOS_SEC);
+ arr[0] = val;
+
+ ret = _invoke_dbus_method_async(DEVICED_BUS_NAME, CPU_BOOSTER_OBJECT_PATH, CPU_BOOSTER_INTERFACE,
+ METHOD_LOCK_PMQOS_NAME, "i", arr);
+ ret_if(!ret);
+
+ _D("%s-%s", CPU_BOOSTER_INTERFACE, METHOD_LOCK_PMQOS_NAME);
+}
+
+
+
+int dbus_util_receive_lcd_status(void (*changed_cb)(void *data, DBusMessage *msg), void *data)
+{
+ E_DBus_Connection *conn;
+ E_DBus_Signal_Handler *handler;
+
+ e_dbus_init();
+
+ conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
+ if (conn == NULL) {
+ _E("e_dbus_bus_get error");
+ return 0;
+ }
+
+ handler = e_dbus_signal_handler_add(conn, NULL, DISPLAY_OBJECT_PATH,
+ DEVICED_INTERFACE_DISPLAY, MEMBER_LCD_ON,
+ changed_cb, data);
+ if (handler == NULL) {
+ _E("e_dbus_signal_handler_add error");
+ return 0;
+ }
+
+ handler = e_dbus_signal_handler_add(conn, NULL, DISPLAY_OBJECT_PATH,
+ DEVICED_INTERFACE_DISPLAY, MEMBER_LCD_OFF,
+ changed_cb, data);
+ if (handler == NULL) {
+ _E("e_dbus_signal_handler_add error");
+ return 0;
+ }
+
+ return 1;
+}
+
+char *dbus_util_msg_arg_get_str(DBusMessage *msg)
+{
+ int ret = 0;
+ DBusError derror;
+ const char *state = NULL;
+ dbus_error_init(&derror);
+
+ ret = dbus_message_get_args(msg, &derror, DBUS_TYPE_STRING, &state, DBUS_TYPE_INVALID);
+ goto_if(!ret, ERROR);
+
+ dbus_error_free(&derror);
+
+ return strdup(state);
+
+ERROR:
+ _E("Failed to get reply (%s:%s)", derror.name, derror.message);
+ dbus_error_free(&derror);
+
+ return NULL;
+}
+
+
+
diff --git a/src/direct-access.c b/src/direct-access.c
deleted file mode 100755
index bfeaa84..0000000
--- a/src/direct-access.c
+++ /dev/null
@@ -1,476 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <stdio.h>
-#include <Ecore.h>
-#include <dd-display.h>
-#include <dd-led.h>
-#include <aul.h>
-#include <vconf.h>
-#include <Ecore_X.h>
-#include <Ecore_Input.h>
-#include <utilX.h>
-#include <feedback.h>
-#include<Elementary.h>
-#ifndef FEATURE_LITE
-#include <tts.h>
-#endif
-
-#include "starter.h"
-#include "util.h"
-#include "direct-access.h"
-
-#define _(str) dgettext("starter", str)
-
-#define DBUS_REPLY_TIMEOUT (120 * 1000)
-#define DEVICED_BUS_NAME "org.tizen.system.deviced"
-#define DEVICED_OBJECT_PATH "/Org/Tizen/System/DeviceD"
-#define DEVICED_INTERFACE_NAME DEVICED_BUS_NAME
-
-#define ALWAYS_ASK_BUS_NAME "org.tizen.system.popup"
-#define ALWAYS_ASK_OBJECT_PATH "/Org/Tizen/System/Popup/System"
-#define ALWAYS_ASK_INTERFACE_NAME ALWAYS_ASK_BUS_NAME".System"
-#define METHOD_ALWAYS_ASK_NAME "AccessibilityPopupLaunch"
-#define ALWAYS_ASK_PARAM_1 "_SYSPOPUP_CONTENT_"
-#define ALWAYS_ASK_PARAM_2 "accessibility"
-
-#ifndef FEATURE_LITE
-static tts_h tts;
-#endif
-static int tts_status;
-
-static int _append_variant(DBusMessageIter *iter, const char *sig, char *param[])
-{
- char *ch;
- int i;
- int int_type;
- uint64_t int64_type;
-
- if (!sig || !param)
- return 0;
-
- for (ch = (char*)sig, i = 0; *ch != '\0'; ++i, ++ch) {
- switch (*ch) {
- case 'i':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &int_type);
- break;
- case 'u':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT32, &int_type);
- break;
- case 't':
- int64_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT64, &int64_type);
- break;
- case 's':
- dbus_message_iter_append_basic(iter, DBUS_TYPE_STRING, &param[i]);
- break;
- default:
- return -EINVAL;
- }
- }
-
- return 0;
-}
-
-
-DBusMessage *invoke_dbus_method_sync(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- _E("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- _E("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _append_variant(&iter, sig, param);
- if (r < 0) {
- _E("append_variant error(%d)", r);
- return NULL;
- }
-
- dbus_error_init(&err);
-
- reply = dbus_connection_send_with_reply_and_block(conn, msg, DBUS_REPLY_TIMEOUT, &err);
- if (!reply) {
- _E("dbus_connection_send error(No reply)");
- }
-
- if (dbus_error_is_set(&err)) {
- _E("dbus_connection_send error(%s:%s)", err.name, err.message);
- reply = NULL;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- return reply;
-}
-
-
-DBusMessage *invoke_dbus_method(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- _E("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- _E("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _append_variant(&iter, sig, param);
- if (r < 0) {
- _E("append_variant error(%d)", r);
- return NULL;
- }
-
- r = dbus_connection_send(conn, msg, NULL);
- dbus_message_unref(msg);
- if (r != TRUE) {
- _E("dbus_connection_send error(%s:%s:%s-%s)", dest, path, interface, method);
- return -ECOMM;
- }
- _D("dbus_connection_send, ret=%d", r);
- return NULL;
-}
-
-
-
-
-
-
-
-
-static void _set_assistive_light(void)
-{
- int max, state, ret;
-
- max = led_get_max_brightness();
- if (max < 0)
- max = 1;
-
- state = led_get_brightness();
- if (state > 0) {
- ret = led_set_brightness_with_noti(0, true);
- if (ret == 0)
- vconf_set_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_TORCH_LIGHT, 0);
- } else {
- ret = led_set_brightness_with_noti(max, true);
- if (ret == 0)
- vconf_set_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_TORCH_LIGHT, 1);
- }
-
- if(feedback_initialize() == FEEDBACK_ERROR_NONE)
- {
- _D("make vibration effect");
- feedback_play_type(FEEDBACK_TYPE_VIBRATION, FEEDBACK_PATTERN_TAP);
- feedback_deinitialize();
- }
-}
-
-
-
-#define LIVE_SETTING_APP "com.samsung.live-setting-app"
-static int _launch_live_setting_app(void)
-{
- bundle *b;
- int ret;
-
- b = bundle_create();
- if (!b) {
- _E("Failed to create bundle");
- return -ENOMEM;
- }
-
- ret = bundle_add(b, "popup", "zoom");
- if (ret < 0) {
- _E("Failed to add parameters to bundle");
- goto out;
- }
-
- ret = aul_launch_app(LIVE_SETTING_APP, b);
- if (ret < 0)
- _E("Failed to launch app(%s)", LIVE_SETTING_APP);
-
-out:
- bundle_free(b);
- return ret;
-}
-
-static bool _is_aircommand_on(void)
-{
- int state;
- if (vconf_get_bool(VCONFKEY_AIRCOMMAND_ENABLED, &state) == 0
- && state == 1)
- return true;
- return false;
-}
-
-#define PROP_ZOOM "_E_ACC_ENABLE_ZOOM_UI_"
-static void _set_zoom(void)
-{
- int ret;
- unsigned int value;
- Ecore_X_Window rootWin;
- Ecore_X_Atom atomZoomUI;
-
- rootWin = ecore_x_window_root_first_get();
- atomZoomUI = ecore_x_atom_get(PROP_ZOOM);
-
- ret = ecore_x_window_prop_card32_get(rootWin, atomZoomUI, &value, 1);
- if (ret == 1 && value == 1)
- value = 0;
- else
- value = 1;
-
- ecore_x_window_prop_card32_set(rootWin, atomZoomUI, &value, 1);
- ecore_x_flush();
-
- vconf_set_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_SCREEN_ZOOM, value);
-}
-
-
-
-#define PROP_HIGH_CONTRAST "_E_ACC_ENABLE_HIGH_CONTRAST_"
-static void _set_contrast(void)
-{
- int ret;
- unsigned int value;
- Ecore_X_Window rootWin;
- Ecore_X_Atom atomHighContrast;
-
- rootWin = ecore_x_window_root_first_get();
- atomHighContrast = ecore_x_atom_get(PROP_HIGH_CONTRAST);
-
- ret = ecore_x_window_prop_card32_get(rootWin, atomHighContrast, &value, 1);
- if (ret == 1 && value == 1)
- value = 0;
- else
- value = 1;
-
- ecore_x_window_prop_card32_set(rootWin, atomHighContrast, &value, 1);
- ecore_x_flush();
-
- vconf_set_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_HIGH_CONTRAST, value);
-}
-#ifndef FEATURE_LITE
-void utterance_completed_callback(tts_h tts, int utt_id, void* user_data){
- _D("");
- int ret = 0;
- int u_id = 0;
- ret = tts_stop(tts);
- if(ret != TTS_ERROR_NONE){
- _E("fail to stop(%d)", ret);
- return;
- }
- ret = tts_unprepare(tts);
- if(ret != TTS_ERROR_NONE){
- _E("fail to unprepare(%d)", ret);
- return;
- }
- if(tts){
- ret = tts_destroy(tts);
- tts = NULL;
- }
- return;
-}
-
-void _tts_state_changed_cb(tts_h tts, tts_state_e previous, tts_state_e current, void* data){
- int ret = 0;
- int u_id = 0;
- bindtextdomain("starter", "/usr/share/locale");
- appcore_set_i18n();
- if(TTS_STATE_CREATED == previous && current == TTS_STATE_READY){
- if(tts_status){
- ret = tts_add_text(tts, _("IDS_TPLATFORM_BODY_SCREEN_READER_ENABLED_T_TTS"), NULL, TTS_VOICE_TYPE_AUTO, TTS_SPEED_AUTO, &u_id);
- if(ret != TTS_ERROR_NONE){
- _E("fail to add text(%d)", ret);
- return;
- }
- }
- else{
- ret = tts_add_text(tts, _("IDS_TPLATFORM_BODY_SCREEN_READER_DISABLED_T_TTS"), NULL, TTS_VOICE_TYPE_AUTO, TTS_SPEED_AUTO, &u_id);
- if(ret != TTS_ERROR_NONE){
- _E("fail to add text(%d)", ret);
- return;
- }
- }
- ret = tts_play(tts);
- if(ret != TTS_ERROR_NONE){
- _E("fail to play(%d)", ret);
- return;
- }
- }
-}
-
-static void _starter_tts_play(void){
- int ret = 0;
- int u_id = 0;
-
- ret = tts_create(&tts);
- if(ret != TTS_ERROR_NONE){
- _E("fail to get handle(%d)", ret);
- return;
- }
- ret = tts_set_state_changed_cb(tts, _tts_state_changed_cb, NULL);
- if(ret != TTS_ERROR_NONE){
- _E("fail to set state changed cb(%d)", ret);
- return;
- }
- ret = tts_set_mode(tts, TTS_MODE_NOTIFICATION);
- if(ret != TTS_ERROR_NONE){
- _E("fail to set mode(%d)", ret);
- return;
- }
- ret = tts_set_utterance_completed_cb(tts, utterance_completed_callback, NULL);
- if(ret != TTS_ERROR_NONE){
- _E("fail to prepare(%d)", ret);
- return;
- }
- ret = tts_prepare(tts);
- if(ret != TTS_ERROR_NONE){
- _E("fail to prepare(%d)", ret);
- return;
- }
- return;
-}
-#endif
-static int _set_accessibility_tts(void)
-{
- if (vconf_get_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_TTS, &tts_status) < 0) {
- _E("FAIL: vconf_get_bool()");
- return -1;
- }
-
- if (tts_status == FALSE)
- tts_status = TRUE;
- else
- tts_status = FALSE;
- if (vconf_set_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_TTS, tts_status) < 0) {
- _E("FAIL: vconf_set_bool()");
- return -1;
- }
-#ifndef FEATURE_LITE
- _starter_tts_play();
-#endif
- return 0;
-}
-
-
-
-static int _launch_always_ask(void)
-{
- DBusError err;
- DBusMessage *msg;
- int ret, ret_val;
- char *arr[2];
- char val[32];
-
- arr[0] = ALWAYS_ASK_PARAM_1;
- arr[1] = ALWAYS_ASK_PARAM_2;
-
- msg = invoke_dbus_method(ALWAYS_ASK_BUS_NAME, ALWAYS_ASK_OBJECT_PATH, ALWAYS_ASK_INTERFACE_NAME,
- METHOD_ALWAYS_ASK_NAME, "ss", arr);
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &ret_val, DBUS_TYPE_INVALID);
- if (!ret) {
- _E("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- _D("%s-%s : %d", ALWAYS_ASK_INTERFACE_NAME, METHOD_ALWAYS_ASK_NAME, ret_val);
- return ret_val;
-}
-
-
-
-int launch_direct_access(int access_val)
-{
- int ret = 0;
- _D("launch_direct_access [%d]", access_val);
-
- /* Direct Access Operation */
- switch (access_val) {
- case SETTING_POWERKEY_SHORTCUT_ALWAYS_ASK:
- if (!_launch_always_ask())
- ret = -1;
- break;
- case SETTING_POWERKEY_SHORTCUT_SCREEN_READER_TTS:
- if (!_set_accessibility_tts())
- ret = -1;
- break;
- case SETTING_POWERKEY_SHORTCUT_NEGATIVE_COLOURS:
- _set_contrast();
- break;
- case SETTING_POWERKEY_SHORTCUT_ZOOM:
- if (_is_aircommand_on()) {
- ret = -1;
- if (_launch_live_setting_app() < 0)
- _E("Failed to launch (%s)", LIVE_SETTING_APP);
- return ret;
- }
- _set_zoom();
- break;
- case SETTING_POWERKEY_SHORTCUT_ASSISTIVE_LIGHT:
- _set_assistive_light();
- break;
- case SETTING_POWERKEY_SHORTCUT_SHOT_READER:
-
- break;
- default:
- ret = -1;
- break;
- }
- return ret;
-}
-
diff --git a/src/hw_key.c b/src/hw_key.c
deleted file mode 100755
index 6ddd9e0..0000000
--- a/src/hw_key.c
+++ /dev/null
@@ -1,1600 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <ail.h>
-#include <bundle.h>
-#include <Elementary.h>
-#include <Ecore_X.h>
-#include <Ecore_Input.h>
-#include <dd-deviced.h>
-#include <syspopup_caller.h>
-#include <utilX.h>
-#include <vconf.h>
-#include <system/media_key.h>
-#include <aul.h>
-#include <feedback.h>
-
-#include "direct-access.h"
-#include "hw_key.h"
-#include "lock-daemon.h"
-#include "menu_daemon.h"
-#include "util.h"
-#include "dbus-util.h"
-
-#define _DEF_BEZEL_AIR_COMMAND 0
-
-#define CAMERA_PKG_NAME "com.samsung.camera-app"
-#define CALLLOG_PKG_NAME "com.samsung.calllog"
-#define SVOICE_PKG_NAME "com.samsung.svoice"
-#define MUSIC_PLAYER_PKG_NAME "com.samsung.music-player"
-#define MUSIC_PLAYER_LITE_PKG_NAME "com.samsung.music-player-lite"
-
-#ifdef FEATURE_LITE
-#define SAFETY_ASSURANCE_PKG_NAME "com.samsung.emergency-message-lite"
-#else
-#define SAFETY_ASSURANCE_PKG_NAME "com.samsung.emergency-message"
-#endif
-
-#define WEBPAGE_PKG_NAME "com.samsung.browser"
-#define MAIL_PKG_NAME "com.samsung.email"
-#define DIALER_PKG_NAME "com.samsung.phone"
-#define STR_ATOM_XKEY_COMPOSITION "_XKEY_COMPOSITION"
-#define STR_ATOM_KEYROUTER_NOTIWINDOW "_KEYROUTER_NOTIWINDOW"
-
-#define SERVICE_OPERATION_MAIN_KEY "__APP_SVC_OP_TYPE__"
-#define SERVICE_OPERATION_MAIN_VALUE "http://tizen.org/appcontrol/operation/main"
-
-#define SVOICE_LAUNCH_BUNDLE_KEY "domain"
-#define SVOICE_LAUNCH_BUNDLE_VALUE "earjack"
-#define SVOICE_LAUNCH_BUNDLE_HOMEKEY_VALUE "home_key"
-
-#define _VCONF_QUICK_COMMADN_NAME "db/aircommand/enabled"
-#define _VCONF_QUICK_COMMADN_FLOATING "db/aircommand/floating"
-#define HALL_COVERED_STATUS 0
-
-#define POWERKEY_TIMER_SEC 0.700
-#define POWERKEY_TIMER_MSEC 700
-#define POWERKEY_CODE "XF86PowerOff"
-
-#define LONG_PRESS_TIMER_SEC 0.4
-#define HOMEKEY_TIMER_SEC 0.2
-#define UNLOCK_TIMER_SEC 0.8
-#define CANCEL_KEY_TIMER_SEC 0.3
-
-static struct {
- Ecore_X_Window win;
- Ecore_Event_Handler *key_up;
- Ecore_Event_Handler *key_down;
- Ecore_Event_Handler *client_msg_hd;
- Ecore_Event_Handler *two_finger_double_tap;
- Ecore_Event_Handler *two_finger_long_tap;
- Ecore_Event_Handler *bezel_gesture;
- Ecore_Timer *long_press_timer;
- Ecore_Timer *single_timer;
- Ecore_Timer *homekey_timer;
- Ecore_Timer *media_long_press;
- Ecore_Timer *client_msg_timer;
- Ecore_Timer *cancel_key_timer;
- Eina_Bool cancel;
- Eina_Bool is_cancel;
- Eina_Bool ignore_home_key;
- Eina_Bool enable_safety_assurance;
- Ecore_X_Window keyrouter_notiwindow;
- int homekey_count;
- int powerkey_count;
- unsigned int powerkey_time_stamp;
-} key_info = {
- .win = 0x0,
- .key_up = NULL,
- .key_down = NULL,
- .client_msg_hd = NULL,
- .long_press_timer = NULL,
- .single_timer = NULL,
- .homekey_timer = NULL,
- .media_long_press = NULL,
- .client_msg_timer = NULL,
- .cancel_key_timer = NULL,
- .cancel = EINA_FALSE,
- .is_cancel = EINA_FALSE,
- .ignore_home_key = EINA_FALSE,
- .enable_safety_assurance = EINA_FALSE,
- .keyrouter_notiwindow = 0x0,
- .two_finger_double_tap = NULL,
- .two_finger_long_tap = NULL,
- .homekey_count = 0,
- .powerkey_count = 0,
- .powerkey_time_stamp = 0,
-};
-
-static Ecore_Timer *gtimer_launch = NULL;
-static bool gbenter_idle = false;
-static bool gbinit_floatwin = false;
-static int gbRegisterDuobleTap = 0;
-
-
-
-static Eina_Bool _launch_taskmgr_cb(void* data)
-{
- int val = -1;
- _D("Launch TASKMGR");
-
- key_info.long_press_timer = NULL;
-
- if (vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &val) < 0) {
- _E("Cannot get VCONFKEY for lock state");
- }
- if (val == VCONFKEY_IDLE_LOCK) {
- _E("lock state, ignore home key long press..!!");
- return ECORE_CALLBACK_CANCEL;
- }
-
- if (lockd_get_hall_status() == HALL_COVERED_STATUS) {
- _E("scover is closed, ignore home key long press..!!");
- return ECORE_CALLBACK_CANCEL;
- }
-
- bundle *b;
- b = bundle_create();
- retv_if(NULL == b, ECORE_CALLBACK_CANCEL);
- bundle_add(b, "HIDE_LAUNCH", "0");
-
- int ret = menu_daemon_launch_app(menu_daemon_get_taskmgr_pkgname(), b);
- goto_if(0 > ret, OUT);
-
- if(ret > 0){
- if(starter_dbus_set_oomadj(ret, OOM_ADJ_VALUE_DEFAULT) < 0){
- _E("failed to send oom dbus signal");
- }
- }
-
-OUT:
- bundle_free(b);
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-
-#define DESKDOCK_PKG_NAME "com.samsung.desk-dock"
-static Eina_Bool _launch_by_home_key(void *data)
-{
- int lock_state = (int) data;
- int ret = 0;
- _D("lock_state : %d ", lock_state);
-
- key_info.single_timer = NULL;
-
- if (lock_state == VCONFKEY_IDLE_LOCK) {
- return ECORE_CALLBACK_CANCEL;
- }
-
- if (lockd_get_hall_status() == HALL_COVERED_STATUS) {
- _D("scover is closed, ignore home key..!!");
- return ECORE_CALLBACK_CANCEL;
- }
-
- if (lockd_get_lock_state() > VCONFKEY_IDLE_UNLOCK) {
- return ECORE_CALLBACK_CANCEL;
- }
-
- int cradle_status = menu_daemon_get_cradle_status();
- if (0 < cradle_status) {
- int ret;
- _SECURE_D("Cradle is enabled to [%d], we'll launch the desk dock[%s]", cradle_status, DESKDOCK_PKG_NAME);
- ret = menu_daemon_open_app(DESKDOCK_PKG_NAME);
- if (ret < 0) {
- _SECURE_E("cannot launch package %s(err:%d)", DESKDOCK_PKG_NAME, ret);
- }
- }
-
- ret = menu_daemon_open_homescreen(NULL);
-
- if(ret > 0){
- starter_dbus_home_raise_signal_send();
- }
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-
-inline static Eina_Bool _launch_svoice(void)
-{
- const char *pkg_name = NULL;
- bundle *b = NULL;
- int val;
-
- pkg_name = menu_daemon_get_svoice_pkg_name();
- retv_if(NULL == pkg_name, EINA_FALSE);
-
-#if 1
- if (vconf_get_int(VCONFKEY_SETAPPL_PSMODE , &val) < 0) {
- _E("Cannot get VCONFKEY");
- }
- if (val == SETTING_PSMODE_EMERGENCY) {
- _D("Emergency mode, ignore svoice key..!!");
- return EINA_FALSE;
- }
-#endif
-
- if (vconf_get_int(VCONFKEY_SVOICE_OPEN_VIA_HOME_KEY, &val) < 0) {
- _D("Cannot get VCONFKEY");
- }
-
- if (val != 1) {
- _D("Launch nothing");
- return EINA_FALSE;
- }
-
-#if 1
- if (!strcmp(pkg_name, SVOICE_PKG_NAME)) {
- b = bundle_create();
- retv_if(!b, EINA_FALSE);
-
- bundle_add(b, SVOICE_LAUNCH_BUNDLE_KEY, SVOICE_LAUNCH_BUNDLE_HOMEKEY_VALUE);
- bundle_add(b, SERVICE_OPERATION_MAIN_KEY, SERVICE_OPERATION_MAIN_VALUE);
- }
-
- if (menu_daemon_launch_app(pkg_name, b) < 0)
- _SECURE_E("Failed to launch %s", pkg_name);
-
- if (b != NULL)
- bundle_free(b);
-#else
- if (menu_daemon_open_app(pkg_name) < 0)
- _SECURE_E("Failed to open %s", pkg_name);
-#endif
- return EINA_TRUE;
-}
-
-
-
-static void _launch_safety_assurance(void)
-{
- _SECURE_D("Launch %s", SAFETY_ASSURANCE_PKG_NAME);
- if (menu_daemon_open_app(SAFETY_ASSURANCE_PKG_NAME) < 0) {
- _SECURE_E("Cannot open %s", SAFETY_ASSURANCE_PKG_NAME);
- }
-}
-
-
-static Eina_Bool _launch_svoice_cb(void* data)
-{
- key_info.media_long_press = NULL;
-
- int val = -1;
-
- if (vconf_get_int(VCONFKEY_SETAPPL_PSMODE , &val) < 0) {
- _E("Cannot get VCONFKEY");
- }
- if (val == SETTING_PSMODE_EMERGENCY) {
- _D("Emergency mode, ignore KEY_MEDIA key..!!");
- return ECORE_CALLBACK_CANCEL;
- }
-
- if (vconf_get_int(VCONFKEY_SVOICE_OPEN_VIA_EARPHONE_KEY, &val) < 0) {
- _E("Cannot get VCONFKEY");
- }
- if (1 == val) {
- _D("Launch SVOICE");
-#if 1
- bundle *b;
- b = bundle_create();
- retv_if(!b, ECORE_CALLBACK_CANCEL);
-
- bundle_add(b, SVOICE_LAUNCH_BUNDLE_KEY, SVOICE_LAUNCH_BUNDLE_VALUE);
- bundle_add(b, SERVICE_OPERATION_MAIN_KEY, SERVICE_OPERATION_MAIN_VALUE);
- if (menu_daemon_launch_app(SVOICE_PKG_NAME, b) < 0)
- _SECURE_E("Failed to launch %s", SVOICE_PKG_NAME);
- bundle_free(b);
-#else
- if (menu_daemon_open_app(SVOICE_PKG_NAME) < 0)
- _SECURE_E("Failed to open %s", SVOICE_PKG_NAME);
-#endif
- }
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-
-#if 0
-static Eina_Bool _client_msg_timer_cb(void* data)
-{
- _D("_client_msg_timer_cb, safety assurance is enable");
-
- key_info.enable_safety_assurance = EINA_TRUE;
- _D("Launch SafetyAssurance");
- _launch_safety_assurance();
- key_info.client_msg_timer = NULL;
-
- return ECORE_CALLBACK_CANCEL;
-}
-#endif
-
-
-
-static Eina_Bool _set_unlock(void *data)
-{
- _D("_set_unlock");
- vconf_set_int(VCONFKEY_IDLE_LOCK_STATE, VCONFKEY_IDLE_UNLOCK);
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-inline static int _release_home_key(int lock_state)
-{
- int val = -1;
-
- if (vconf_get_int(VCONFKEY_SETAPPL_PSMODE , &val) < 0) {
- _E("Cannot get VCONFKEY");
- }
- if (val != SETTING_PSMODE_EMERGENCY) {
- retv_if(NULL == key_info.long_press_timer, EXIT_SUCCESS);
- ecore_timer_del(key_info.long_press_timer);
- key_info.long_press_timer = NULL;
- }
-
- if (NULL == key_info.single_timer) {
- key_info.single_timer = ecore_timer_add(0.3, _launch_by_home_key, (void *) lock_state);
- return EXIT_SUCCESS;
- }
- ecore_timer_del(key_info.single_timer);
- key_info.single_timer = NULL;
-
- if(EINA_TRUE == _launch_svoice()) {
- if (lock_state == VCONFKEY_IDLE_LOCK) {
- ecore_timer_add(0.8, _set_unlock, NULL);
- }
- }
- return EXIT_SUCCESS;
-}
-
-
-
-inline static void _release_multimedia_key(const char *value)
-{
- ret_if(NULL == value);
-
- _D("Multimedia key is released with %s", value);
-
- bundle *b;
- b = bundle_create();
- if (!b) {
- _E("Cannot create bundle");
- return;
- }
- bundle_add(b, "multimedia_key", value);
-
- int ret;
-#ifdef FEATURE_LITE
- ret = menu_daemon_launch_app(MUSIC_PLAYER_LITE_PKG_NAME, b);
-#else
- ret = menu_daemon_launch_app(MUSIC_PLAYER_PKG_NAME, b);
-#endif
- if (ret < 0)
- _E("Failed to launch the running apps, ret : %d", ret);
-
- bundle_free(b);
-}
-
-
-static Eina_Bool _homekey_timer_cb(void *data)
-{
- int direct_access_val = -1;
- int lock_state = (int) data;
-
- _W("%s, homekey count[%d], lock state[%d]", __func__, key_info.homekey_count, lock_state);
- key_info.homekey_timer = NULL;
-
-
- /* Check Direct Access */
- if (vconf_get_int(VCONFKEY_SETAPPL_ACCESSIBILITY_POWER_KEY_HOLD, &direct_access_val) < 0) {
- _E("Cannot get VCONFKEY_SETAPPL_ACCESSIBILITY_POWER_KEY_HOLD");
- direct_access_val = SETTING_POWERKEY_SHORTCUT_OFF;
- }
-
-
- if (SETTING_POWERKEY_SHORTCUT_OFF == direct_access_val) {
- /* Direct Access OFF */
- if(key_info.homekey_count%2 == 0) {
- /* double press operation */
- key_info.homekey_count = 0; //initialize powerkey count
- if(EINA_TRUE == _launch_svoice()) {
- if (lock_state == VCONFKEY_IDLE_LOCK) {
- ecore_timer_add(UNLOCK_TIMER_SEC, _set_unlock, NULL);
- }
- }
- return ECORE_CALLBACK_CANCEL;
- }
- } else {
- /* Direct Access ON */
- if(key_info.homekey_count == 2) {
- /* double press operation*/
- key_info.homekey_count = 0; //initialize powerkey count
- if(EINA_TRUE == _launch_svoice()) {
- if (lock_state == VCONFKEY_IDLE_LOCK) {
- ecore_timer_add(UNLOCK_TIMER_SEC, _set_unlock, NULL);
- }
- }
- return ECORE_CALLBACK_CANCEL;
- } else if(key_info.homekey_count >= 3) {
- _W("Launch Direct Access : %d", direct_access_val);
- key_info.homekey_count = 0; //initialize powerkey count
-#ifdef FEATURE_LITE
- _E("Not supported in Lite feature");
-#else
- if (launch_direct_access(direct_access_val) < 0) {
- _E("Fail Launch Direct Access..!!");
- }
-#endif
- return ECORE_CALLBACK_CANCEL;
- }
- }
-
- /* Single homekey operation */
- key_info.homekey_count = 0; //initialize powerkey count
- _launch_by_home_key(data);
- return ECORE_CALLBACK_CANCEL;
-
-}
-
-
-static Eina_Bool _key_release_cb(void *data, int type, void *event)
-{
- Evas_Event_Key_Up *ev = event;
- int val = -1;
- int lock_state = -1;
-
- if (!ev) {
- _D("_key_release_cb : Invalid event object");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (!ev->keyname) {
- _D("_key_release_cb : Invalid event keyname object");
- return ECORE_CALLBACK_RENEW;
- } else {
- _D("_key_release_cb : %s Released", ev->keyname);
- }
-
- /* Safety Assistance */
- if (!strcmp(ev->keyname, POWERKEY_CODE)) {
- //double current_timestamp = ecore_loop_time_get();
- unsigned int current_timestamp = ev->timestamp;
- _D("current_timestamp[%d] previous_timestamp[%d]", current_timestamp, key_info.powerkey_time_stamp);
-
- if ((current_timestamp - key_info.powerkey_time_stamp) > POWERKEY_TIMER_MSEC) {
- key_info.powerkey_count = 0;
- }
- key_info.powerkey_count++;
- if (key_info.powerkey_count >= 3) {
- _launch_safety_assurance();
- key_info.powerkey_count = 0;
- }
- _D("powerkey count:%d", key_info.powerkey_count);
- key_info.powerkey_time_stamp = current_timestamp;
- } else {
- key_info.powerkey_count = 0;
- }
-
-
- if (!strcmp(ev->keyname, KEY_END)) {
- } else if (!strcmp(ev->keyname, KEY_CONFIG)) {
- } else if (!strcmp(ev->keyname, KEY_SEND)) {
- } else if (!strcmp(ev->keyname, KEY_HOME)) {
- _W("Home Key is released");
-
- if (vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &lock_state) < 0) {
- _D("Cannot get VCONFKEY");
- }
- if ((lock_state == VCONFKEY_IDLE_LOCK) && (lockd_get_lock_type() == 1)) {
- _D("phone lock state, ignore home key..!!");
- key_info.homekey_count = 0; //initialize homekey count
- return ECORE_CALLBACK_RENEW;
- }
-
- if (lockd_get_hall_status() == HALL_COVERED_STATUS) {
- _D("scover is closed, ignore home key..!!");
- key_info.homekey_count = 0; //initialize homekey count
- return ECORE_CALLBACK_RENEW;
- }
-#if 0
- _release_home_key(val);
-#else
- // Check homekey timer
- if(key_info.homekey_timer) {
- ecore_timer_del(key_info.homekey_timer);
- key_info.homekey_timer = NULL;
- _D("delete homekey timer");
- }
-
- // Cancel key operation
- if (EINA_TRUE == key_info.cancel) {
- _D("Cancel key is activated");
- key_info.cancel = EINA_FALSE;
- key_info.homekey_count = 0; //initialize homekey count
- return ECORE_CALLBACK_RENEW;
- }
- else{
- ecore_timer_del(key_info.cancel_key_timer);
- key_info.cancel_key_timer = NULL;
- key_info.is_cancel = EINA_FALSE;
- syspopup_destroy_all();
- _D("delete cancelkey timer");
- }
-
-#if 0
- if (vconf_get_int(VCONFKEY_SETAPPL_PSMODE , &val) < 0) {
- _E("Cannot get VCONFKEY");
- }
- if (val != SETTING_PSMODE_EMERGENCY) {
- // Check long press timer
- if(key_info.long_press_timer) {
- ecore_timer_del(key_info.long_press_timer);
- key_info.long_press_timer = NULL;
- _D("delete long press timer");
- } else {
- key_info.homekey_count = 0; //initialize homekey count
- return ECORE_CALLBACK_RENEW;
- }
- }
-#else
- // Check long press timer
- if(key_info.long_press_timer) {
- ecore_timer_del(key_info.long_press_timer);
- key_info.long_press_timer = NULL;
- _D("delete long press timer");
- } else {
- key_info.homekey_count = 0; //initialize homekey count
- return ECORE_CALLBACK_RENEW;
- }
-#endif
- key_info.homekey_timer = ecore_timer_add(HOMEKEY_TIMER_SEC, _homekey_timer_cb, (void *) lock_state);
- return ECORE_CALLBACK_RENEW;
-#endif
- } else if (!strcmp(ev->keyname, KEY_PAUSE)) {
- } else if (!strcmp(ev->keyname, KEY_CANCEL)) {
- _D("CANCEL Key is released");
- key_info.cancel = EINA_FALSE;
- } else if (!strcmp(ev->keyname, KEY_MEDIA)) {
- if (key_info.media_long_press) { // Short press
- ecore_timer_del(key_info.media_long_press);
- key_info.media_long_press = NULL;
-
- _release_multimedia_key("KEY_PLAYCD");
- }
- } else if (!strcmp(ev->keyname, KEY_APPS)) {
- _D("App tray key is released");
- menu_daemon_launch_app_tray();
- } else if (!strcmp(ev->keyname, KEY_TASKSWITCH)) {
- _D("Task switch key is released");
- _launch_taskmgr_cb(NULL);
- } else if (!strcmp(ev->keyname, KEY_WEBPAGE)) {
- _D("Web page key is released");
- if (menu_daemon_open_app(WEBPAGE_PKG_NAME) < 0)
- _E("Failed to launch the web page");
- } else if (!strcmp(ev->keyname, KEY_MAIL)) {
- _D("Mail key is released");
- if (menu_daemon_open_app(MAIL_PKG_NAME) < 0)
- _E("Failed to launch the mail");
- } else if (!strcmp(ev->keyname, KEY_CONNECT)) {
- _D("Connect key is released");
- if (menu_daemon_open_app(DIALER_PKG_NAME) < 0)
- _E("Failed to launch the dialer");
- } else if (!strcmp(ev->keyname, KEY_SEARCH)) {
- _D("Search key is released");
-#if 0
- if (menu_daemon_open_app(SEARCH_PKG_NAME) < 0)
- _E("Failed to launch the search");
-#else
- if (vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &val) < 0) {
- _D("Cannot get VCONFKEY");
- }
- if (val == VCONFKEY_IDLE_LOCK) {
- _D("lock state, ignore search key..!!");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (lockd_get_hall_status() == HALL_COVERED_STATUS) {
- _D("scover is closed, ignore search key..!!");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (menu_daemon_launch_search() < 0)
- _E("Failed to launch the search");
-#endif
- } else if (!strcmp(ev->keyname, KEY_VOICE)) {
- _D("Voice key is released");
- if (EINA_FALSE == _launch_svoice())
- _E("Failed to launch the svoice");
- }
-
- return ECORE_CALLBACK_RENEW;
-}
-
-static Eina_Bool _destroy_syspopup_cb(void* data)
-{
- _D("timer for cancel key operation");
- key_info.cancel_key_timer = NULL;
- if(key_info.is_cancel == EINA_TRUE){
- _W("cancel key is activated. Do not destroy syspopup");
- key_info.is_cancel = EINA_FALSE;
- return ECORE_CALLBACK_CANCEL;
- }
- key_info.is_cancel = EINA_FALSE;
- syspopup_destroy_all();
- return ECORE_CALLBACK_CANCEL;
-}
-
-static Eina_Bool _key_press_cb(void *data, int type, void *event)
-{
- Evas_Event_Key_Down *ev = event;
- int val = -1;
-
- if (!ev) {
- _D("_key_press_cb : Invalid event object");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (!ev->keyname) {
- _D("_key_press_cb : Invalid event keyname object");
- return ECORE_CALLBACK_RENEW;
- } else {
- _D("_key_press_cb : %s Pressed", ev->keyname);
- }
-
- if (!strcmp(ev->keyname, KEY_SEND)) {
- _D("Launch calllog");
- if (menu_daemon_open_app(CALLLOG_PKG_NAME) < 0)
- _SECURE_E("Failed to launch %s", CALLLOG_PKG_NAME);
- } else if(!strcmp(ev->keyname, KEY_CONFIG)) {
- _D("Launch camera");
- if (menu_daemon_open_app(CAMERA_PKG_NAME) < 0)
- _SECURE_E("Failed to launch %s", CAMERA_PKG_NAME);
- } else if (!strcmp(ev->keyname, KEY_HOME)) {
- _W("Home Key is pressed");
- if (key_info.long_press_timer) {
- ecore_timer_del(key_info.long_press_timer);
- key_info.long_press_timer = NULL;
- }
-
-// syspopup_destroy_all();
- key_info.cancel_key_timer = ecore_timer_add(CANCEL_KEY_TIMER_SEC, _destroy_syspopup_cb, NULL);
-
- if (vconf_get_int(VCONFKEY_SETAPPL_PSMODE , &val) < 0) {
- _E("Cannot get VCONFKEY");
- }
- if (val == SETTING_PSMODE_EMERGENCY) {
- key_info.homekey_count = 1;
- _D("Emergency mode, ignore home key..!!");
- } else {
- // Check homekey press count
- key_info.homekey_count++;
- _W("homekey count : %d", key_info.homekey_count);
-
- // Check homekey timer
- if(key_info.homekey_timer) {
- ecore_timer_del(key_info.homekey_timer);
- key_info.homekey_timer = NULL;
- _D("delete homekey timer");
- }
- }
- _D("create long press timer");
- key_info.long_press_timer = ecore_timer_add(LONG_PRESS_TIMER_SEC, _launch_taskmgr_cb, NULL);
- if (!key_info.long_press_timer)
- _E("Failed to add timer for long press detection");
- } else if (!strcmp(ev->keyname, KEY_CANCEL)) {
- _D("Cancel button is pressed");
- key_info.cancel = EINA_TRUE;
- key_info.is_cancel = EINA_TRUE;
- if (key_info.long_press_timer) {
- ecore_timer_del(key_info.long_press_timer);
- key_info.long_press_timer = NULL;
- }
- } else if (!strcmp(ev->keyname, KEY_MEDIA)) {
- _D("Media key is pressed");
-
- if (key_info.media_long_press) {
- ecore_timer_del(key_info.media_long_press);
- key_info.media_long_press = NULL;
- }
-
- key_info.media_long_press = ecore_timer_add(0.5, _launch_svoice_cb, NULL);
- if (!key_info.media_long_press)
- _E("Failed to add timer for long press detection");
- } else if (!strcmp(ev->keyname, KEY_APPS)) {
- _D("App tray key is pressed");
- } else if (!strcmp(ev->keyname, KEY_TASKSWITCH)) {
- _D("Task switch key is pressed");
- } else if (!strcmp(ev->keyname, KEY_WEBPAGE)) {
- _D("Web page key is pressed");
- } else if (!strcmp(ev->keyname, KEY_MAIL)) {
- _D("Mail key is pressed");
- } else if (!strcmp(ev->keyname, KEY_SEARCH)) {
- _D("Search key is pressed");
- } else if (!strcmp(ev->keyname, KEY_VOICE)) {
- _D("Voice key is pressed");
- } else if (!strcmp(ev->keyname, KEY_CONNECT)) {
- _D("Connect key is pressed");
- }
-
- return ECORE_CALLBACK_RENEW;
-}
-
-
-
-void _media_key_event_cb(media_key_e key, media_key_event_e status, void *user_data)
-{
- _D("MEDIA KEY EVENT : %d", key);
- if (MEDIA_KEY_STATUS_PRESSED == status) return;
-
- if (MEDIA_KEY_PAUSE == key) {
- _release_multimedia_key("KEY_PAUSECD");
- } else if (MEDIA_KEY_PLAY == key) {
- _release_multimedia_key("KEY_PLAYCD");
- } else if (MEDIA_KEY_PLAYPAUSE == key) {
- _release_multimedia_key("KEY_PLAYPAUSECD");
- }
-}
-
-
-#define APP_ID_SPLIT_LAUNCHER "com.samsung.split-launcher"
-#define APP_ID_MINIAPPS_LAUNCHER "com.samsung.mini-apps"
-#define STR_ATOM_KEY_BACK_LONGPRESS "KEY_BACK_LONGPRESS"
-#define STR_ATOM_KEY_MENU_LONGPRESS "KEY_MENU_LONGPRESS"
-static Eina_Bool _client_message_cb(void *data, int type, void *event)
-{
- Ecore_X_Event_Client_Message *ev = event;
- Ecore_X_Atom safety_assurance_atom;
- Ecore_X_Atom atomMenuLongPress;
- Ecore_X_Atom atomBackLongPress;
-
- if (ev->format != 32)
- return ECORE_CALLBACK_RENEW;
-
- safety_assurance_atom = ecore_x_atom_get(STR_ATOM_XKEY_COMPOSITION);
- atomMenuLongPress = ecore_x_atom_get(STR_ATOM_KEY_MENU_LONGPRESS);
- atomBackLongPress = ecore_x_atom_get(STR_ATOM_KEY_BACK_LONGPRESS);
-#if 0
- _D("_client_message_cb, safety_assurance_atom=[0x%x] atomMenuLongPress=[0x%x] atomBackLongPress=[0x%x]",
- safety_assurance_atom, atomMenuLongPress, atomBackLongPress);
-#endif
- if ((ev->win == key_info.keyrouter_notiwindow) &&
- (ev->message_type == safety_assurance_atom) && (ev->format == 32)) {
-#if 0 /* Safety Assistance is changed to power key */
- int press = ev->data.l[2];
- int key_sum = ev->data.l[0]+ev->data.l[1];
- if (key_sum == 245) {
- _D("check key_sum[%d] to 122(volume_down)+123(volume_up), press=[%d]", key_sum, press);
- if (press) {
- if (key_info.client_msg_timer) {
- ecore_timer_del(key_info.client_msg_timer);
- key_info.client_msg_timer = NULL;
- }
- key_info.enable_safety_assurance = EINA_FALSE;
- key_info.client_msg_timer = ecore_timer_add(3, _client_msg_timer_cb, NULL);
- if (!key_info.client_msg_timer)
- _E("Failed to add timer for clent message");
- } else {
- if (key_info.client_msg_timer) {
- ecore_timer_del(key_info.client_msg_timer);
- key_info.client_msg_timer = NULL;
- }
-#if 0
- if (key_info.enable_safety_assurance == EINA_TRUE) {
- _D("Launch SafetyAssurance");
- _launch_safety_assurance();
- }
- key_info.enable_safety_assurance = EINA_FALSE;
-#endif
- }
- }
-#endif
- } else if (ev->message_type == atomBackLongPress) {
- // Back key is long-pressed.
- _D("ev->message_type=[0x%x], Back key long press", ev->message_type);
-
- int val = 0;
- if (vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &val) < 0) {
- _D("Cannot get VCONFKEY");
- }
-
- if (VCONFKEY_IDLE_LOCK == val) {
- _D("Lock state, ignore back key long-press.");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (vconf_get_int(VCONFKEY_PWLOCK_STATE, &val) < 0) {
- _E("Cannot get VCONFKEY_PWLOCK_STATE");
- }
-
- if (VCONFKEY_PWLOCK_BOOTING_LOCK == val || VCONFKEY_PWLOCK_RUNNING_LOCK == val) {
- _E("PW-lock state, ignore back key long-press.");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (lockd_get_hall_status() == HALL_COVERED_STATUS) {
- _D("Scover is closed, ignore back ke long-press.");
- return ECORE_CALLBACK_RENEW;
- }
-
-#ifdef SPLIT_LAUNCHER_ENABLE //ORG
- int multiwindow_enabled = 0;
- if (vconf_get_bool(VCONFKEY_QUICKSETTING_MULTIWINDOW_ENABLED, &multiwindow_enabled) < 0) {
- _E("Cannot get VCONFKEY");
- multiwindow_enabled = 0;
- }
-
- if (vconf_get_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_TTS, &val) < 0) {
- _D("Cannot get VCONFKEY");
- val = 0;
- }
-
- if ((val == 1) || (multiwindow_enabled == 0)) {
- _D("TTS : %d, Multiwindow enabled : %d", val, multiwindow_enabled);
- return ECORE_CALLBACK_RENEW;
- }
-
- _D("Launch the split-launcher");
-
- int ret = aul_launch_app(APP_ID_SPLIT_LAUNCHER, NULL);
- if (0 > ret) _E("cannot launch the split-launcher (%d)", ret);
-#else //DCM
- char *package = menu_daemon_get_selected_pkgname();
- if (!package) return ECORE_CALLBACK_RENEW;
-
- int apptray_enabled = !strcmp(package, CLUSTER_HOME_PKG_NAME);
- free(package);
- if (!apptray_enabled) return ECORE_CALLBACK_RENEW;
-
- _D("Launch the app-tray");
-
- bundle *b = bundle_create();
- retv_if(NULL == b, false);
- bundle_add(b, "LAUNCH", "ALL_APPS");
- int ret = aul_launch_app(APP_TRAY_PKG_NAME, b);
- if (0 > ret) _E("cannot launch the app-tray (%d)", ret);
- bundle_free(b);
-#endif
- } else if (ev->message_type == atomMenuLongPress) {
- // Menu key is long-pressed.
- _D("ev->message_type=[0x%x], Menu key long press", ev->message_type);
-
- int val = 0;
- if (vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &val) < 0) {
- _E("Cannot get VCONFKEY_IDLE_LOCK_STATE");
- }
-
- if (VCONFKEY_IDLE_LOCK == val) {
- _E("Lock state, ignore menu key long-press.");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (vconf_get_int(VCONFKEY_PWLOCK_STATE, &val) < 0) {
- _E("Cannot get VCONFKEY_PWLOCK_STATE");
- }
-
- if (VCONFKEY_PWLOCK_BOOTING_LOCK == val || VCONFKEY_PWLOCK_RUNNING_LOCK == val) {
- _E("PW-lock state, ignore menu key long-press.");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (vconf_get_int(VCONFKEY_SETAPPL_PSMODE, &val) < 0) {
- _E("Cannot get VCONFKEY_SETAPPL_PSMODE");
- }
-
- if (SETTING_PSMODE_EMERGENCY == val) {
- _E("Emergency mode, ignore menu key long-press.");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (lockd_get_hall_status() == HALL_COVERED_STATUS) {
- _D("Scover is closed, ignore menu key long-press.");
- return ECORE_CALLBACK_RENEW;
- }
-
- _D("Launch the mini-apps");
- int ret_aul;
- bundle *b;
- b = bundle_create();
- retv_if(NULL == b, ECORE_CALLBACK_RENEW);
- bundle_add(b, "HIDE_LAUNCH", "0");
- ret_aul = aul_launch_app("com.samsung.mini-apps", b);
- if (0 > ret_aul) _E("cannot launch the mini apps (%d)", ret_aul);
- bundle_free(b);
- }
- return ECORE_CALLBACK_RENEW;
-}
-
-
-static bool gesture_is_availble_key(void)
-{
-
- int ret = 0;
- int status = 0;
-
-
- ret = vconf_get_int(VCONFKEY_PWLOCK_STATE, &status);
- if (ret != 0)
- {
- _E("fail to get memory/pwlock/state%d", ret);
- return false;
- }
-
-
- if( status == VCONFKEY_PWLOCK_RUNNING_UNLOCK || status == VCONFKEY_PWLOCK_BOOTING_UNLOCK)
- {
- _D("enter the idle mode (%d)", status);
- }
- else
- {
- _D("don't enter the idle mode(%d)", status);
- return false;
- }
-
- _D("checking idle lock");
-
- ret = vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &status);
- if (ret != 0)
- {
- _E("fail to get memory/pwlock/state%d", ret);
- return false;
- }
-
-
- if( status == VCONFKEY_IDLE_LOCK)
- {
- _D("enter the lock mode(%d)", status);
- return false;
- }
- else
- {
- _D("unlock state");
- }
-
- return true;
-}
-
-
-static inline void launch_app(int x, int y)
-{
- // e->cx, e->cy
- bundle *param;
- int pid;
- int status = 0;
- int ret = 0;
-
- if(gesture_is_availble_key() == false)
- {
- _D("can't launch");
- return;
- }
-
- _D("checking status");
- ret = vconf_get_int(VCONFKEY_SETAPPL_PSMODE , &status);
- if (ret != 0) _D("fail to VCONFKEY_SETAPPL_PSMODE", ret);
-
- if( status == SETTING_PSMODE_EMERGENCY)
- {
- _D(" emergency on");
- return;
- }
-
- ret = vconf_get_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_TTS , &status);
- if (ret != 0) _D("fail to VCONFKEY_SETAPPL_ACCESSIBILITY_TTS", ret);
-
- if( status == 1)
- {
- _D(" tts on");
- return;
- }
-
- ret = vconf_get_bool(_VCONF_QUICK_COMMADN_NAME, &status);
- if (ret != 0) _E("fail to get db/aircommand/enabled:%d", ret);
-
- if( status == 0)
- {
- _D("can't launch because of off");
- return;
- }
-
- ret = vconf_get_bool("db/aircommand/floating", &status);
- if (ret != 0) _E("fail to get db/aircommand/floating:%d", ret);
-
- if( status == 1)
- {
- _D("only floating");
- return;
- }
-
- param = bundle_create();
- if (param) {
- char coord[16];
- snprintf(coord, sizeof(coord), "%dx%d", x, y);
- bundle_add(param, "coordinate", coord);
- }
-
- feedback_play_type(FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TOUCH_TAP);
-
- pid = aul_launch_app("com.samsung.air-command", param);
- _D("Launch Pie Menu: %d\n", pid);
-
- if (param) {
- bundle_free(param);
- }
-}
-
-
-
-#if 0
-static int gesture_hold_cb(void *data, int ev_type, void *ev)
-{
- Ecore_X_Event_Gesture_Notify_Hold *e = ev;
-
- if (e->num_fingers != 2) {
- return 1;
- }
-
- switch (e->subtype) {
- case ECORE_X_GESTURE_BEGIN:
- _D("Begin: hold[%d]\n", e->hold_time);
- launch_app(e->cx, e->cy);
- break;
- case ECORE_X_GESTURE_UPDATE:
- _D("Update: hold[%d]\n", e->hold_time);
- break;
- case ECORE_X_GESTURE_END:
- _D("End: hold[%d]\n", e->hold_time);
- break;
- default:
- break;
- }
-
- return 1;
-}
-#endif
-
-
-
-static int gesture_cb(void *data, int ev_type, void *ev)
-{
- Ecore_X_Event_Gesture_Notify_Tap *e = ev;
-
- _D("key");
-
- if (e->tap_repeat != 2) {
- return 1;
- }
-
- if (e->num_fingers == 2) {
- launch_app(e->cx, e->cy);
- }
-
- return 1;
-}
-
-
-
-static int gesture_flick_cb(void *data, int ev_type, void *ev)
-{
- Ecore_X_Event_Gesture_Notify_Flick *e = ev;
-
- _D(" input bezel");
-
- if(e->num_fingers == 1)
- {
- launch_app(0, 0);
- }
-
- return 1;
-}
-
-
-
-static void gesture_key_init(void)
-{
- int status;
-
- _D("Init gesture for quick command");
-
- if( gbRegisterDuobleTap > 1)
- {
- _E("Already registered callback cnt[%d]", gbRegisterDuobleTap);
- return;
- }
-
- gbRegisterDuobleTap++;
-
- status = ecore_x_gesture_event_grab(key_info.win, ECORE_X_GESTURE_EVENT_TAP, 2);
- if (!status) {
- _E("%d\n", status);
- return;
- }
-#if _DEF_BEZEL_AIR_COMMAND
- status = ecore_x_gesture_event_grab(key_info.win, ECORE_X_GESTURE_EVENT_FLICK, 1);
- if (!status) {
- _E("%d\n", status);
- return;
- }
-#endif
-/*
- status = ecore_x_gesture_event_grab(key_info.win, ECORE_X_GESTURE_EVENT_HOLD, 2);
- if (!status) {
- _E("%d\n", status);
- return;
- }
-*/
- key_info.two_finger_double_tap = ecore_event_handler_add(ECORE_X_EVENT_GESTURE_NOTIFY_TAP, (Ecore_Event_Handler_Cb)gesture_cb, NULL);
- if (!key_info.two_finger_double_tap) {
- _E("Failed to add handler\n");
- }
-#if _DEF_BEZEL_AIR_COMMAND
- key_info.bezel_gesture = ecore_event_handler_add(ECORE_X_EVENT_GESTURE_NOTIFY_FLICK, (Ecore_Event_Handler_Cb)gesture_flick_cb, NULL);
- if (!key_info.bezel_gesture) {
- _E("Failed to add handle about bezel_gesture\n");
- }
-#endif
-/*
- key_info.two_finger_long_tap = ecore_event_handler_add(ECORE_X_EVENT_GESTURE_NOTIFY_HOLD, (Ecore_Event_Handler_Cb)gesture_hold_cb, NULL);
- if (!key_info.two_finger_long_tap) {
- _E("Failed to add handler\n");
- }
-*/
-// feedback_initialize();
-}
-
-static void gesture_key_fini(void)
-{
- int status;
-
- _D("fini gesture for quick command");
-
- gbRegisterDuobleTap--;
-
- if( gbRegisterDuobleTap < 0 )
- {
- _D("register value can't be decreased");
- gbRegisterDuobleTap = 0;
- }
-
- if (key_info.two_finger_double_tap) {
- ecore_event_handler_del(key_info.two_finger_double_tap);
- key_info.two_finger_double_tap = NULL;
- }
-
- if (key_info.two_finger_long_tap) {
- ecore_event_handler_del(key_info.two_finger_long_tap);
- key_info.two_finger_long_tap = NULL;
- }
-
-#if _DEF_BEZEL_AIR_COMMAND
- if (key_info.bezel_gesture) {
- ecore_event_handler_del(key_info.bezel_gesture);
- key_info.bezel_gesture = NULL;
- }
-#endif
-
- status = ecore_x_gesture_event_ungrab(key_info.win, ECORE_X_GESTURE_EVENT_TAP, 2);
- if (!status) {
- _E("%d\n", status);
- }
-
- status = ecore_x_gesture_event_ungrab(key_info.win, ECORE_X_GESTURE_EVENT_HOLD, 2);
- if (!status) {
- _E("%d\n", status);
- }
-#if _DEF_BEZEL_AIR_COMMAND
- status = ecore_x_gesture_event_ungrab(key_info.win, ECORE_X_GESTURE_EVENT_FLICK, 1);
- if (!status) {
- _E("%d\n", status);
- }
-#endif
-// feedback_deinitialize();
-}
-
-static void gesture_key_vconf_cb(keynode_t *key, void* pUserData)
-{
- char *keynode_name = vconf_keynode_get_name(key);
- ret_if(!keynode_name);
-
- if(!memcmp(keynode_name, _VCONF_QUICK_COMMADN_NAME, strlen(_VCONF_QUICK_COMMADN_NAME)))
- {
- if(vconf_keynode_get_int(key))
- {
- int ret = 0;
- int status = 0;
-
- ret = vconf_get_bool(_VCONF_QUICK_COMMADN_NAME, &status);
- if (ret != 0) _E("fail to get db/aircommand/enabled:%d", ret);
-
- if( status == 1)
- {
-// _D(" quick command on");
-// gesture_key_init();
-
- int nRet = 0;
- int nStatus = 0;
-
- _D(" quick command on");
-
- nRet = vconf_get_bool("db/aircommand/floating", &nStatus);
- if (nRet != 0) _E("fail to get db/aircommand/floating:%d", nRet);
-
- if( nStatus == 1)
- {
- int pid = aul_launch_app("com.samsung.air-command", NULL);
- _D("run a floating window after booting(%d)", pid);
-// gesture_key_fini();
- }
- else
- {
- _D(" quick command double tap");
- gesture_key_init();
- }
-
- }
- else
- {
- _D(" quick command off");
-
- gesture_key_fini();
- }
- }
- }
-}
-
-static Eina_Bool gesture_wating_launch_cb(void *data)
-{
- int pid = -1;
-
- pid = aul_launch_app("com.samsung.air-command", NULL);
- _D("launch callback (%d)", pid);
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-static void gesture_floating_vconf_cb(keynode_t *key, void* pUserData)
-{
- char *keynode_name = vconf_keynode_get_name(key);
- ret_if(!keynode_name);
-
- if(!memcmp(keynode_name, _VCONF_QUICK_COMMADN_FLOATING, strlen(_VCONF_QUICK_COMMADN_FLOATING)))
- {
- if(vconf_keynode_get_int(key))
- {
- int ret = 0;
- int status = 0;
-
- _D("changed floating mode");
-
- ret = vconf_get_bool(_VCONF_QUICK_COMMADN_NAME, &status);
- if (ret != 0) _E("fail to get db/aircommand/enabled:%d", ret);
-
- if( status == 1)
- {
- int nRet = 0;
- int nStatus = 0;
-
- _D(" quick command on");
-
- nRet = vconf_get_bool(_VCONF_QUICK_COMMADN_FLOATING, &nStatus);
- if (nRet != 0) _E("fail to get db/aircommand/floating:%d", nRet);
-
- if( nStatus == 1)
- {
-
- if(gtimer_launch)
- {
- ecore_timer_del(gtimer_launch);
- gtimer_launch = NULL;
- }
-
- gtimer_launch = ecore_timer_add(0.100f, gesture_wating_launch_cb, NULL);
-
-
-
-/*
- service_h hService;
-
- _D(" quick floating window: on");
-
- service_create(&hService);
- service_set_package(hService, "com.samsung.air-command");
-
- if (service_send_launch_request(hService, NULL, this) != SERVICE_ERROR_NONE)
- {
- DLOG_QCOMMAND_ERR("Failed to com.samsung.air-command");
- }
- else
- {
- DLOG_QCOMMAND_DBG("Success to com.samsung.air-command");
- }
-
- service_destroy(hService);
-*/
- }
- else
- {
- _D(" quick command double tap");
- }
-
- }
- else
- {
- _D(" already quick command off status");
- }
-
- }
- }
-}
-
-
-static void gesture_enter_idle_initialize(void)
-{
- int ret = 0;
- int status = 0;
-
- _D("Idle enter checking...");
-
- ret = vconf_get_bool(_VCONF_QUICK_COMMADN_NAME, &status);
- if (ret != 0) _E("fail to get db/aircommand/enabled:%d", ret);
-
- if( status == 0)
- {
- _D("disabled qujick command");
- return;
- }
-
- status = 0;
- ret = vconf_get_int(VCONFKEY_PWLOCK_STATE, &status);
- if (ret != 0)
- {
- _E("fail to get db/aircommand/enabled:%d", ret);
- return;
- }
-
- if( status == VCONFKEY_PWLOCK_RUNNING_UNLOCK || status == VCONFKEY_PWLOCK_BOOTING_UNLOCK)
- {
- gbenter_idle = true;
- status = 0;
-
- /* If it has a floating window, run it*/
- ret = vconf_get_bool(_VCONF_QUICK_COMMADN_FLOATING, &status);
- if (ret != 0) _E("fail to get db/aircommand/floating:%d", ret);
-
- if( status == 1)
- {
- if( gbinit_floatwin == false)
- {
- int pid = aul_launch_app("com.samsung.air-command", NULL);
- _D("run a floating window after booting(%d)", pid);
-
- gbinit_floatwin = true;
- }
- }
- else
- {
- if( gbinit_floatwin == false)
- {
- _D("register touch grap");
-
- gesture_key_init();
-
- gbinit_floatwin = true;
- }
-
- }
- }
- else
- {
- _D("already no idle state(%d)", status);
- }
-}
-
-static void gesture_enter_idle_vconf_cb(keynode_t *key, void* pUserData)
-{
- char *keynode_name = vconf_keynode_get_name(key);
- ret_if(!keynode_name);
-
- if(!memcmp(keynode_name, VCONFKEY_PWLOCK_STATE, strlen(VCONFKEY_PWLOCK_STATE)))
- {
- if(vconf_keynode_get_int(key))
- {
- _D("received cb");
- gesture_enter_idle_initialize();
- }
-
- }
-
-}
-
-
-static void gesture_key_register(void)
-{
- int ret;
- char buf[1024] = { 0, };
-
- ret = vconf_notify_key_changed(_VCONF_QUICK_COMMADN_NAME, (vconf_callback_fn)gesture_key_vconf_cb, NULL);
- if (ret < 0){
-
- _E("Error: Failed to sigaction[%s]", strerror_r(errno, buf, sizeof(buf)));
- }
-
- ret = vconf_notify_key_changed(_VCONF_QUICK_COMMADN_FLOATING, (vconf_callback_fn)gesture_floating_vconf_cb, NULL);
- if (ret < 0){
-
- _E("Error: Failed to sigaction[%s]", strerror_r(errno, buf, sizeof(buf)));
- }
-
- ret = vconf_notify_key_changed(VCONFKEY_PWLOCK_STATE, (vconf_callback_fn)gesture_enter_idle_vconf_cb, NULL);
- if (ret < 0){
-
- _E("Error: Failed to sigaction[%s]", strerror_r(errno, buf, sizeof(buf)));
- }
-
- gesture_enter_idle_initialize();
-}
-
-#define PROP_HWKEY_EMULATION "_HWKEY_EMULATION"
-static void _set_long_press_time(void)
-{
- Ecore_X_Window *keyrouter_input_window;
- Ecore_X_Atom atom_keyrouter = ecore_x_atom_get(PROP_HWKEY_EMULATION);
-
- int num = 0;
- if (EINA_FALSE == ecore_x_window_prop_property_get(ecore_x_window_root_first_get(),
- atom_keyrouter,
- ECORE_X_ATOM_WINDOW,
- 32,
- (unsigned char **) &keyrouter_input_window,
- &num))
- {
- _E("Cannot get the property");
- return;
- }
-
- int longpress_timeout = 500; // miliseconds
- int menu_keycode = ecore_x_keysym_keycode_get(KEY_MENU);
- ecore_x_client_message32_send(*keyrouter_input_window,
- atom_keyrouter,
- ECORE_X_EVENT_MASK_NONE,
- key_info.win,
- menu_keycode,
- longpress_timeout,
- 0,
- 0);
-
- int back_keycode = ecore_x_keysym_keycode_get(KEY_BACK);
- ecore_x_client_message32_send(*keyrouter_input_window,
- atom_keyrouter,
- ECORE_X_EVENT_MASK_NONE,
- key_info.win,
- back_keycode,
- longpress_timeout,
- 0,
- 0);
-}
-
-void create_key_window(void)
-{
- int ret;
- Ecore_X_Atom atomNotiWindow;
- Ecore_X_Window keyrouter_notiwindow;
-
- key_info.win = ecore_x_window_input_new(0, 0, 0, 1, 1);
- if (!key_info.win) {
- _D("Failed to create hidden window");
- return;
- }
- ecore_x_event_mask_unset(key_info.win, ECORE_X_EVENT_MASK_NONE);
- /*
- ecore_x_event_mask_unset(key_info.win, ECORE_X_EVENT_MASK_MOUSE_DOWN);
- ecore_x_event_mask_unset(key_info.win, ECORE_X_EVENT_MASK_MOUSE_UP);
- ecore_x_event_mask_unset(key_info.win, ECORE_X_EVENT_MASK_MOUSE_IN);
- ecore_x_event_mask_unset(key_info.win, ECORE_X_EVENT_MASK_MOUSE_OUT);
- ecore_x_event_mask_unset(key_info.win, ECORE_X_EVENT_MASK_MOUSE_MOVE);
- */
-
- ecore_x_icccm_title_set(key_info.win, "menudaemon,key,receiver");
- ecore_x_netwm_name_set(key_info.win, "menudaemon,key,receiver");
- ecore_x_netwm_pid_set(key_info.win, getpid());
-
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_HOME, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_VOLUMEDOWN, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_VOLUMEUP, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_CONFIG, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_MEDIA, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_APPS, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_TASKSWITCH, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_WEBPAGE, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_MAIL, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_SEARCH, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_VOICE, SHARED_GRAB);
- utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_CONNECT, SHARED_GRAB);
- ret = utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_POWER, SHARED_GRAB);
- if (ret != 0) {
- _E("utilx_grab_key KEY_POWER GrabSHARED_GRAB failed, ret[%d]", ret);
- }
-
- key_info.key_up = ecore_event_handler_add(ECORE_EVENT_KEY_UP, _key_release_cb, NULL);
- if (!key_info.key_up)
- _E("Failed to register a key up event handler");
-
- key_info.key_down = ecore_event_handler_add(ECORE_EVENT_KEY_DOWN, _key_press_cb, NULL);
- if (!key_info.key_down)
- _E("Failed to register a key down event handler");
-
- /* Get notifwindow */
- atomNotiWindow = ecore_x_atom_get(STR_ATOM_KEYROUTER_NOTIWINDOW);
- ret = ecore_x_window_prop_window_get(ecore_x_window_root_first_get(), atomNotiWindow, &keyrouter_notiwindow, 1);
- if (ret > 0) {
- _D("Succeed to get keyrouter notiwindow ! ret = %d (win=0x%x)\n", ret, keyrouter_notiwindow);
- /* mask set for keyrouter notiwindow */
- ecore_x_window_sniff(keyrouter_notiwindow);
- key_info.keyrouter_notiwindow = keyrouter_notiwindow;
- //xkey_composition = ecore_x_atom_get(STR_ATOM_XKEY_COMPOSITION);
- /* Register client msg */
- key_info.client_msg_hd = ecore_event_handler_add(ECORE_X_EVENT_CLIENT_MESSAGE,
- _client_message_cb, NULL);
- if (!key_info.client_msg_hd)
- _E("failed to add handler(ECORE_X_EVENT_CLIENT_MESSAGE)");
- } else {
- _E("Failed to get keyrouter notiwindow!! ret = %d, atomNotiWindow = 0x%x, keyrouter_notiwindow = 0x%x", ret, atomNotiWindow, keyrouter_notiwindow);
- }
-
- media_key_reserve(_media_key_event_cb, NULL);
- //gesture_key_register();
- _set_long_press_time();
-// gesture_key_init();
-}
-
-
-
-void destroy_key_window(void)
-{
- gesture_key_fini();
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_HOME);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_VOLUMEDOWN);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_VOLUMEUP);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_CONFIG);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_MEDIA);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_APPS);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_TASKSWITCH);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_WEBPAGE);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_MAIL);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_SEARCH);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_VOICE);
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_CONNECT);
-
- if (key_info.key_up) {
- ecore_event_handler_del(key_info.key_up);
- key_info.key_up = NULL;
- }
-
- if (key_info.key_down) {
- ecore_event_handler_del(key_info.key_down);
- key_info.key_down = NULL;
- }
-
- ecore_x_window_delete_request_send(key_info.win);
- key_info.win = 0x0;
-
- media_key_release();
-}
-
-
-
-// End of a file
diff --git a/src/hw_key_w.c b/src/hw_key_w.c
deleted file mode 100755
index 7dc3d6c..0000000
--- a/src/hw_key_w.c
+++ /dev/null
@@ -1,1480 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <ail.h>
-#include <bundle.h>
-#include <Elementary.h>
-#include <Ecore_X.h>
-#include <Ecore_Input.h>
-#include <utilX.h>
-#include <vconf.h>
-
-#include <syspopup_caller.h>
-#include <dd-display.h>
-#include <E_DBus.h>
-#include <feedback.h>
-#include <pkgmgr-info.h>
-#include <system/media_key.h>
-
-#include "starter_w.h"
-#include "hw_key_w.h"
-#include "util.h"
-
-#define GRAB_TWO_FINGERS 2
-#define POWERKEY_TIMER_SEC 0.25
-#define POWERKEY_LCDOFF_TIMER_SEC 0.4
-#define LONG_PRESS_TIMER_SEC 0.7
-#define SYSPOPUP_END_TIMER_SEC 0.5
-
-#define APP_CONTROL_OPERATION_MAIN_KEY "__APP_SVC_OP_TYPE__"
-#define APP_CONTROL_OPERATION_MAIN_VALUE "http://tizen.org/appcontrol/operation/main"
-#define APP_CONTROL_OPERATION_DEFAULT_VALUE "http://tizen.org/appcontrol/operation/default"
-#define HOME_OPERATION_KEY "home_op"
-#define POWERKEY_VALUE "powerkey"
-
-#define USE_DBUS_POWEROFF 1
-
-#define POWEROFF_BUS_NAME "org.tizen.system.popup"
-#define POWEROFF_OBJECT_PATH "/Org/Tizen/System/Popup/Poweroff"
-#define POWEROFF_INTERFACE_NAME POWEROFF_BUS_NAME".Poweroff"
-#define METHOD_POWEROFF_NAME "PopupLaunch"
-#define DBUS_REPLY_TIMEOUT (120 * 1000)
-
-#define DOUBLE_PRESS_NONE "none"
-#define DOUBLE_PRESS_RECENT_APPS "recent"
-#define W_TASKMGR_PKGNAME "com.samsung.w-taskmanager"
-#define W_CONTROLS_PKGNAME "com.samsung.windicator"
-#define MUSIC_PLAYER_PKG_NAME "com.samsung.w-music-player"
-#define W_EMERGENCY_MESSAGE_PKGNAME "com.samsung.emergency-message"
-
-#define SVOICE_PKG_NAME "com.samsung.svoice"
-#define SVOICE_LAUNCH_BUNDLE_KEY "domain"
-#define SVOICE_LAUNCH_BUNDLE_HOMEKEY_VALUE "home_key"
-
-#define VCONFKEY_HOME_IS_TUTORIAL "memory/private/org.tizen.w-home/tutorial"
-#define VCONFKEY_SIMPLECLOCK_UI_STATUS "memory/alpm-clock-manager/simpleclock_ui_status"
-#define VCONFKEY_CALL_FORWARD_REQUESTING "memory/ciss/call_forward_requesting"
-#define VCONFKEY_REMOTE_LOCK_ISLOCKED "db/private/com.samsung.wfmw/is_locked"
-
-static struct {
- Ecore_X_Window win;
- Ecore_Event_Handler *key_up;
- Ecore_Event_Handler *key_down;
- Ecore_Event_Handler *two_fingers_hold_hd;
- Ecore_Timer *long_press_timer;
- Ecore_Timer *powerkey_timer;
- Eina_Bool is_lcd_on;
- int is_simple_clock_display;
- Eina_Bool is_long_press;
- int powerkey_count;
- Eina_Bool is_cancel;
- char *home_pkgname;
-} key_info = {
- .win = 0x0,
- .key_up = NULL,
- .key_down = NULL,
- .two_fingers_hold_hd = NULL,
- .long_press_timer = NULL,
- .powerkey_timer = NULL,
- .is_lcd_on = EINA_FALSE,
- .is_simple_clock_display = EINA_FALSE,
- .is_long_press = EINA_FALSE,
- .powerkey_count = 0,
- .is_cancel = EINA_FALSE,
- .home_pkgname = W_HOME_PKGNAME,
-};
-
-#if 0 // This is not W code
-/* NOTE: THIS FUNCTION Is ONLY USED FOR CONFIDENTIAL FEATURE. REMOVE ME */
-static inline int _launch_running_apps_FOR_TEMPORARY(void)
-{
- bundle *kb = NULL;
- char *package;
- int ret;
-
- package = menu_daemon_get_selected_pkgname();
- if (!package)
- return -ENOENT;
-
- if (!strcmp(package, MENU_SCREEN_PKG_NAME)) {
- free(package);
- return -EINVAL;
- }
-
- free(package);
-
- kb = bundle_create();
- if (!kb) {
- _E("Failed to create a bundle");
- return -EFAULT;
- }
-
- bundle_add(kb, "LONG_PRESS", "1");
- ret = menu_daemon_launch_app(APP_TRAY_PKG_NAME, kb);
- bundle_free(kb);
-
- if (ret < 0) {
- _E("Failed to launch the running apps, ret : %d", ret);
- return -EFAULT;
- } else if (ret > 0) {
- if (-1 == deviced_conf_set_mempolicy_bypid(ret, OOM_IGNORE)) {
- _E("Cannot set the memory policy for App tray(%d)", ret);
- } else {
- _E("Set the memory policy for App tray(%d)", ret);
- }
- }
-
- return 0;
-}
-
-
-
-#define DESKDOCK_PKG_NAME "com.samsung.desk-dock"
-static Eina_Bool _launch_by_home_key(void *data)
-{
- int lock_state = (int) data;
- _D("lock_state : %d ", lock_state);
-
- key_info.single_timer = NULL;
-
- if (lock_state == VCONFKEY_IDLE_LOCK) {
- return ECORE_CALLBACK_CANCEL;
- }
-
- int cradle_status = menu_daemon_get_cradle_status();
- if (0 < cradle_status) {
- int ret;
- _SECURE_D("Cradle is enabled to [%d], we'll launch the desk dock[%s]", cradle_status, DESKDOCK_PKG_NAME);
- ret = menu_daemon_open_app(DESKDOCK_PKG_NAME);
- if (ret < 0) {
- _SECURE_E("cannot launch package %s(err:%d)", DESKDOCK_PKG_NAME, ret);
- }
- }
-
- menu_daemon_open_homescreen(NULL);
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-
-inline static Eina_Bool _launch_svoice(void)
-{
- const char *pkg_name = NULL;
- bundle *b;
-
- pkg_name = menu_daemon_get_svoice_pkg_name();
- retv_if(NULL == pkg_name, EINA_FALSE);
-
- if (!strcmp(pkg_name, SVOICE_PKG_NAME)) {
- int val = -1;
-
- if (vconf_get_int(VCONFKEY_SVOICE_OPEN_VIA_HOME_KEY, &val) < 0) {
- _D("Cannot get VCONFKEY");
- }
-
- if (val != 1) {
- _D("Launch nothing");
- return EINA_FALSE;
- }
- }
-
- b = bundle_create();
- retv_if(!b, EINA_FALSE);
-
- bundle_add(b, SVOICE_LAUNCH_BUNDLE_KEY, SVOICE_LAUNCH_BUNDLE_HOMEKEY_VALUE);
- if (menu_daemon_launch_app(pkg_name, b) < 0)
- _SECURE_E("Failed to launch %s", pkg_name);
- bundle_free(b);
-
- return EINA_TRUE;
-}
-
-
-
-static void _launch_safety_assurance(void)
-{
- _SECURE_D("Launch %s", SAFETY_ASSURANCE_PKG_NAME);
- if (menu_daemon_open_app(SAFETY_ASSURANCE_PKG_NAME) < 0) {
- _SECURE_E("Cannot open %s", SAFETY_ASSURANCE_PKG_NAME);
- }
-}
-
-
-static Eina_Bool _launch_svoice_cb(void* data)
-{
- key_info.media_long_press = NULL;
-
- int val = -1;
- if (vconf_get_int(VCONFKEY_SVOICE_OPEN_VIA_EARPHONE_KEY, &val) < 0) {
- _D("Cannot get VCONFKEY");
- }
- if (1 == val) {
- _D("Launch SVOICE");
-
- bundle *b;
- b = bundle_create();
- retv_if(!b, ECORE_CALLBACK_CANCEL);
-
- bundle_add(b, SVOICE_LAUNCH_BUNDLE_KEY, SVOICE_LAUNCH_BUNDLE_VALUE);
- if (menu_daemon_launch_app(SVOICE_PKG_NAME, b) < 0)
- _SECURE_E("Failed to launch %s", TASKMGR_PKG_NAME);
- bundle_free(b);
- }
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-static Eina_Bool _client_msg_timer_cb(void* data)
-{
- _D("_client_msg_timer_cb, safety assurance is enable");
-
- key_info.enable_safety_assurance = EINA_TRUE;
- _D("Launch SafetyAssurance");
- _launch_safety_assurance();
- key_info.client_msg_timer = NULL;
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-static Eina_Bool _set_unlock(void *data)
-{
- _D("_set_unlock");
- vconf_set_int(VCONFKEY_IDLE_LOCK_STATE, VCONFKEY_IDLE_UNLOCK);
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-inline static int _release_home_key(int lock_state)
-{
- retv_if(NULL == key_info.long_press, EXIT_SUCCESS);
- ecore_timer_del(key_info.long_press);
- key_info.long_press = NULL;
-
- if (NULL == key_info.single_timer) {
- key_info.single_timer = ecore_timer_add(0.3, _launch_by_home_key, (void *) lock_state);
- return EXIT_SUCCESS;
- }
- ecore_timer_del(key_info.single_timer);
- key_info.single_timer = NULL;
-
- if(EINA_TRUE == _launch_svoice()) {
- if (lock_state == VCONFKEY_IDLE_LOCK) {
- ecore_timer_add(0.8, _set_unlock, NULL);
- }
- }
- return EXIT_SUCCESS;
-}
-
-
-
-inline static void _release_multimedia_key(const char *value)
-{
- ret_if(NULL == value);
-
- _D("Multimedia key is released with %s", value);
-
- bundle *b;
- b = bundle_create();
- if (!b) {
- _E("Cannot create bundle");
- return;
- }
- bundle_add(b, "multimedia_key", value);
-
- int ret;
- ret = menu_daemon_launch_app(MUSIC_PLAYER_PKG_NAME, b);
- if (ret < 0)
- _E("Failed to launch the running apps, ret : %d", ret);
-
- bundle_free(b);
-}
-
-
-static Eina_Bool _client_message_cb(void *data, int type, void *event)
-{
- int key_sum;
- int press;
- Ecore_X_Event_Client_Message *ev = event;
- Ecore_X_Atom safety_assurance_atom;
-
- if (ev->format != 32)
- return ECORE_CALLBACK_RENEW;
-
- safety_assurance_atom = ecore_x_atom_get(ATOM_KEY_COMPOSITION);
- if (ev->message_type == safety_assurance_atom) {
- press = ev->data.l[2];
- key_sum = ev->data.l[0]+ev->data.l[1];
- if (key_sum == 245) {
- _D("check key_sum[%d] to 122(volume_down)+123(volume_up), press=[%d]", key_sum, press);
- if (press) {
- if (key_info.client_msg_timer) {
- ecore_timer_del(key_info.client_msg_timer);
- key_info.client_msg_timer = NULL;
- }
- key_info.enable_safety_assurance = EINA_FALSE;
- key_info.client_msg_timer = ecore_timer_add(3, _client_msg_timer_cb, NULL);
- if (!key_info.client_msg_timer)
- _E("Failed to add timer for clent message");
- } else {
- if (key_info.client_msg_timer) {
- ecore_timer_del(key_info.client_msg_timer);
- key_info.client_msg_timer = NULL;
- }
-#if 0
- if (key_info.enable_safety_assurance == EINA_TRUE) {
- _D("Launch SafetyAssurance");
- _launch_safety_assurance();
- }
- key_info.enable_safety_assurance = EINA_FALSE;
-#endif
- }
- }
- }
- return ECORE_CALLBACK_RENEW;
-}
-
-#endif // This is not W code
-
-
-#if 0
-static int _append_variant(DBusMessageIter *iter, const char *sig, char *param[])
-{
- char *ch;
- int i;
- int int_type;
- uint64_t int64_type;
-
- if (!sig || !param)
- return 0;
-
- for (ch = (char*)sig, i = 0; *ch != '\0'; ++i, ++ch) {
- switch (*ch) {
- case 'i':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &int_type);
- break;
- case 'u':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT32, &int_type);
- break;
- case 't':
- int64_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT64, &int64_type);
- break;
- case 's':
- dbus_message_iter_append_basic(iter, DBUS_TYPE_STRING, &param[i]);
- break;
- default:
- return -EINVAL;
- }
- }
-
- return 0;
-}
-
-
-DBusMessage *_invoke_dbus_method_sync(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- _E("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- _E("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _append_variant(&iter, sig, param);
- if (r < 0) {
- _E("append_variant error(%d)", r);
- return NULL;
- }
-
-#if 0 //Temp block sync call from power off popup.
- dbus_error_init(&err);
-
- reply = dbus_connection_send_with_reply_and_block(conn, msg, DBUS_REPLY_TIMEOUT, &err);
-
- if (!reply) {
- _E("dbus_connection_send error(No reply)");
- }
-
- if (dbus_error_is_set(&err)) {
- _E("dbus_connection_send error(%s:%s)", err.name, err.message);
- reply = NULL;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- return reply;
-#else //Temp async call
- r = dbus_connection_send(conn, msg, NULL);
- dbus_message_unref(msg);
- if (r != TRUE) {
- _E("dbus_connection_send error(%s:%s:%s-%s)", dest, path, interface, method);
- return -ECOMM;
- }
- _D("dbus_connection_send, ret=%d", r);
- return NULL;
-#endif
-}
-
-
-static int _request_Poweroff(void)
-{
- DBusError err;
- DBusMessage *msg;
- int ret, ret_val;
-
- msg = _invoke_dbus_method_sync(POWEROFF_BUS_NAME, POWEROFF_OBJECT_PATH, POWEROFF_INTERFACE_NAME,
- METHOD_POWEROFF_NAME, NULL, NULL);
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &ret_val, DBUS_TYPE_INVALID);
- if (!ret) {
- _E("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- _D("%s-%s : %d", POWEROFF_INTERFACE_NAME, METHOD_POWEROFF_NAME, ret_val);
- return ret_val;
-}
-#endif
-
-char *_get_app_type(const char *pkgname)
-{
- int ret = 0;
- char *apptype = NULL;
- char *re_apptype = NULL;
- pkgmgrinfo_pkginfo_h handle;
- ret = pkgmgrinfo_pkginfo_get_pkginfo(pkgname, &handle);
- if (ret != PMINFO_R_OK)
- return NULL;
- ret = pkgmgrinfo_pkginfo_get_type(handle, &apptype);
- if (ret != PMINFO_R_OK) {
- pkgmgrinfo_pkginfo_destroy_pkginfo(handle);
- return NULL;
- }
-
- /*after call pkgmgrinfo_appinfo_destroy_appinfo, mainappid is destroyed with handle, so must copy it*/
- re_apptype = strdup(apptype);
- _SECURE_D("apptype : %s - %s", apptype, re_apptype);
- pkgmgrinfo_pkginfo_destroy_pkginfo(handle);
-
- return re_apptype;
-}
-
-static Eina_Bool _launch_home_by_powerkey(void)
-{
- bundle *b = NULL;
- int pid = 0;
-
- _D("%s", __func__);
-
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- return EINA_FALSE;
- }
- bundle_add(b, HOME_OPERATION_KEY, POWERKEY_VALUE);
-
- pid = w_launch_app(key_info.home_pkgname, b);
- _SECURE_D("launch[%s], pid[%d]", key_info.home_pkgname, pid);
-
- if(pid < AUL_R_OK) {
- if(b) {
- bundle_free(b);
- }
- return EINA_FALSE;
- }
-
- if(b) {
- bundle_free(b);
- }
- return EINA_TRUE;
-}
-
-
-static Eina_Bool _syspopup_end_timer_cb(void *data)
-{
- /* terminate syspopup */
- syspopup_destroy_all();
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-#define APP_TYPE_WIDGET "wgt"
-#define W_CAMERA_PKGNAME "com.samsung.w-camera-app"
-static Eina_Bool _launch_app_by_double_press(void *data)
-{
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return EINA_FALSE;
- }
- char *appid = NULL;
- char *pkgname = NULL;
- char *pkgtype = NULL;
- bundle *b = NULL;
- int pid = 0;
- int ret = 0;
- int ret_aul = 0;
- int val = 0;
- int tts_status = 0;
- int pwlock_status = 0;
-
- _D("%s", __func__);
-
- /* Check home tutorial mode */
- if(vconf_get_int(VCONFKEY_HOME_IS_TUTORIAL, &val) < 0) {
- _E("Failed to get vconfkey[VCONFKEY_HOME_IS_TUTORIAL]");
- }
- if(val == 1) { // Home tutorial on
- _E("Home Tutorial ON, ignore double key");
- return EINA_FALSE;
- }
-
- /* Check UPS mode */
- if(vconf_get_int(VCONFKEY_SETAPPL_PSMODE, &val) < 0) {
- _E("Failed to get vconfkey[VCONFKEY_SETAPPL_PSMODE]");
- }
- if(val == SETTING_PSMODE_WEARABLE_ENHANCED) { //UPS Mode
- _E("UPS Mode, ignore double key");
- return EINA_FALSE;
- }
-
- /* Check TTS mode */
- if (vconf_get_bool(VCONFKEY_SETAPPL_ACCESSIBILITY_TTS, &tts_status) < 0) {
- _E("Failed to get vconfkey[VCONFKEY_SETAPPL_ACCESSIBILITY_TTS]");
- }
- if(tts_status == 1){ //TTS mode
- _E("TTS Mode, ignore double key");
- return EINA_FALSE;
- }
-
- /* Check Cool down mode */
- if(ad->cool_down_mode != 0){
- _E("Cool down mode is LimitAction(%d), ignore double key", ad->cool_down_mode);
- return EINA_FALSE;
- }
-
- /* Check PW Lock state */
- if(vconf_get_int(VCONFKEY_PWLOCK_STATE, &pwlock_status) < 0){
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_PWLOCK_STATE);
- }
- if((pwlock_status == VCONFKEY_PWLOCK_BOOTING_LOCK) || (pwlock_status == VCONFKEY_PWLOCK_RUNNING_LOCK)){
- _E("pwlock state (%d), ignore double key", pwlock_status);
- return EINA_FALSE;
- }
-
- /* Check Privacy Lock state */
- if(vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &val) < 0){
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_IDLE_LOCK_STATE);
- }
- if(val > VCONFKEY_IDLE_UNLOCK){
- _E("lock state (%d), ignore double key", val);
- return EINA_FALSE;
- }
-
- /* Check Call state */
- if(vconf_get_int(VCONFKEY_CALL_STATE, &val) < 0){
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_CALL_STATE);
- }
- if(val != VCONFKEY_CALL_OFF){
- _E("call state (%d), ignore double key", val);
- return EINA_FALSE;
- }
-
- /* Check remote-lock state */
- if(vconf_get_bool(VCONFKEY_REMOTE_LOCK_ISLOCKED, &val) < 0){
- _E("failed to get %s", VCONFKEY_REMOTE_LOCK_ISLOCKED);
- }
-
- if(val == true){
- _E("remote lock is on top (%d), ignore double key", val);
- return EINA_FALSE;
- }
-
- appid = vconf_get_str(VCONFKEY_WMS_POWERKEY_DOUBLE_PRESSING);
-
- if (appid == NULL) {
- _E("appid is NULL");
- } else if (!strcmp(appid, DOUBLE_PRESS_NONE)) {
- _D("none : DOUBLE_PRESS_NONE !!");
- return EINA_TRUE;
- } else if (!strcmp(appid, DOUBLE_PRESS_RECENT_APPS)) {
- _D("recent : launch task mgr..!!");
-
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- return EINA_FALSE;
- }
- bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_MAIN_VALUE);
-
- request_dbus_cpu_booster();
- ret = w_launch_app(W_TASKMGR_PKGNAME, NULL);
- if (ret >= 0) {
- _SECURE_D("[%s] is launched, pid=[%d]", W_TASKMGR_PKGNAME, ret);
- }
- if(b) {
- bundle_free(b);
- }
- return EINA_TRUE;
- } else {
- char *last = NULL;
- char *temp = NULL;
- char *new_appid = NULL;
- last = strrchr(appid, '/');
- if (last == NULL || *(last + 1) == NULL) {
- _E("Invaild data");
- } else {
- _D("appid has class name");
- new_appid = strdup(last + 1);
- if(new_appid == NULL) {
- _E("appid is NULL");
- }
- temp = strtok(appid, "/");
- if(temp == NULL){
- _E("Invalid data");
- }
- else{
- pkgname = strdup(temp);
- }
- }
- free(appid);
- appid = new_appid;
- }
-
- if(appid == NULL) {
- _E("appid is NULL. set default to none.");
- return EINA_FALSE;
- }
-
- pkgtype = _get_app_type(pkgname);
- if(pkgtype == NULL) {
- _E("Failed to get app_type. app_type is NULL");
- if(appid){
- free(appid);
- }
- if(pkgname){
- free(pkgname);
- }
- return EINA_FALSE;
- }
-
- _SECURE_D("appid : %s, pkgname : %s, pkgtype : %s", appid, pkgname, pkgtype);
-
- if(!strcmp(pkgtype, APP_TYPE_WIDGET)){
- ret_aul = aul_open_app(appid);
- if(ret_aul < AUL_R_OK) {
- _D("Launching app ret : [%d]", ret_aul);
- free(appid);
- free(pkgname);
- free(pkgtype);
- return EINA_FALSE;
- }
- if(appid) {
- free(appid);
- }
- }
- else{
-
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- if(appid) {
- free(appid);
- }
- return EINA_FALSE;
- }
- bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_MAIN_VALUE);
-
- if (!strcmp(appid, SVOICE_PKG_NAME)) {
- bundle_add(b, SVOICE_LAUNCH_BUNDLE_KEY, SVOICE_LAUNCH_BUNDLE_HOMEKEY_VALUE);
- }
-
- request_dbus_cpu_booster();
- pid = w_launch_app(appid, b);
- _SECURE_D("launch[%s], pid[%d]", appid, pid);
-
- if(pid < AUL_R_OK) {
- if(b) {
- bundle_free(b);
- }
- if(appid) {
- free(appid);
- }
- return EINA_FALSE;
- }
-
-#if 0
- if (strcmp(appid, W_CONTROLS_PKGNAME)) {
- /* terminate syspopup */
- //syspopup_destroy_all();
- ecore_timer_add(SYSPOPUP_END_TIMER_SEC, _syspopup_end_timer_cb, NULL);
- }
-#endif
- if(b) {
- bundle_free(b);
- }
- if(appid) {
- free(appid);
- }
- }
- if(pkgname){
- free(pkgname);
- }
- if(pkgtype){
- free(pkgtype);
- }
- return EINA_TRUE;
-}
-
-
-static Eina_Bool _powerkey_timer_cb(void *data)
-{
- int val = -1;
- int trigger_val = -1;
- int ret = -1;
-
- _W("%s, powerkey count[%d]", __func__, key_info.powerkey_count);
-#if 0
- if(key_info.long_press_timer) {
- ecore_timer_del(key_info.long_press_timer);
- key_info.long_press_timer = NULL;
- _D("delete long_press_timer");
- }
-
- if(key_info.powerkey_timer) {
- ecore_timer_del(key_info.powerkey_timer);
- key_info.powerkey_timer = NULL;
- _D("delete powerkey_timer");
- }
-#endif
-
- key_info.powerkey_timer = NULL;
-
- /* setdup_wizard is running : should not turn off LCD*/
- if(vconf_get_int(VCONFKEY_SETUP_WIZARD_STATE, &val) < 0) {
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_SETUP_WIZARD_STATE);
- val = -1;
- }
- if(val == VCONFKEY_SETUP_WIZARD_LOCK) {
- _E("setdup_wizard is running");
- key_info.powerkey_count = 0;
- return ECORE_CALLBACK_CANCEL;
- }
-
- /* Check critical low batt clock mode */
- if(vconf_get_int(VCONFKEY_PM_KEY_IGNORE, &val) < 0) {
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_PM_KEY_IGNORE);
- val = -1;
- }
- if(val == 1) { //Critical Low Batt Clock Mode
- _E("Critical Low Batt Clock Mode");
- key_info.powerkey_count = 0; //initialize powerkey count
- if(!key_info.is_lcd_on) {
- _W("just turn on LCD by powerkey.. starter ignore powerkey operation");
- } else {
- _W("just turn off LCD");
- display_change_state(LCD_OFF);
- }
- return ECORE_CALLBACK_CANCEL;
- }
-
-
- /* Safety Assitance */
- if(vconf_get_int(VCONFKEY_WMS_SAFETY_ENABLE, &val) < 0) {
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_WMS_SAFETY_ENABLE);
- val = -1;
- }
- if(val == 1) { //Safety Assistance is ON
- if(key_info.powerkey_count == 2) {
- /* double press */
- _W("powerkey double press");
- key_info.powerkey_count = 0;
- if(!_launch_app_by_double_press(data)) {
- _E("Failed to launch by double press");
- }
- return ECORE_CALLBACK_CANCEL;
- } else if(key_info.powerkey_count >= 3) {
- _E("Safety Assistance : safety is enabled");
- key_info.powerkey_count = 0;
-#ifdef TELEPHONY_DISABLE //B2
- if(vconf_get_int(VCONFKEY_WMS_SAFETY_MESSAGE_TRIGGER, &trigger_val) < 0) {
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_WMS_SAFETY_MESSAGE_TRIGGER);
- }
- _E("Safety Assistance trigger status : [%d]", trigger_val);
- if(trigger_val == 0) {
- //set wms trigger
- if(vconf_set_int(VCONFKEY_WMS_SAFETY_MESSAGE_TRIGGER, 2) < 0) {
- _SECURE_E("Failed to set vconfkey[%s]", VCONFKEY_WMS_SAFETY_MESSAGE_TRIGGER);
- }
-
- feedback_initialize();
- feedback_play(FEEDBACK_PATTERN_SAFETY_ASSISTANCE);
- feedback_deinitialize();
- }
-#else //B2-3G
- bundle *b;
- b = bundle_create();
- if (!b) {
- _E("Cannot create bundle");
- return ECORE_CALLBACK_CANCEL;
- }
- bundle_add(b, "starter_call", "true");
-
- ret = w_launch_app(W_EMERGENCY_MESSAGE_PKGNAME, b);
- if (ret < 0)
- _E("Failed to launch emergency-message, ret : %d", ret);
-
- bundle_free(b);
-#endif
- return ECORE_CALLBACK_CANCEL;
- }
- } else { //Safety Assistance is OFF
- if(key_info.powerkey_count%2 == 0) {
- /* double press */
- _W("powerkey double press");
- key_info.powerkey_count = 0;
- if(!_launch_app_by_double_press(data)) {
- _E("Failed to launch by double press");
- }
- return ECORE_CALLBACK_CANCEL;
- }
- }
- key_info.powerkey_count = 0; //initialize powerkey count
-
- if (key_info.is_simple_clock_display == 1) {
- _W("Simple clock is displayed.. starter ignore powerkey operation");
- return ECORE_CALLBACK_CANCEL;
- }
-
- if(!key_info.is_lcd_on) {
- _W("just turn on LCD by powerkey.. starter ignore powerkey operation");
- return ECORE_CALLBACK_CANCEL;
- } else {
- // Check LCD status
- if(vconf_get_int(VCONFKEY_PM_STATE, &val) < 0) {
- _E("Cannot get VCONFKEY_PM_STATE");
- }
- _W("LCD ON when powerkey & current LCD state : %d", val);
- if(val >= VCONFKEY_PM_STATE_LCDOFF) {
- _E("Already lcd state was changed while powerkey op. starter ignore powerkey operation");
- return ECORE_CALLBACK_CANCEL;
- }
- }
-
- /* check Call state */
- if(vconf_get_int(VCONFKEY_CALL_STATE, &val) < 0) {
- _E("Failed to get call state");
- val = -1;
- }
- if(val == VCONFKEY_CALL_VOICE_ACTIVE) {
- _W("call state is [%d] -> just turn off LCD", val);
- display_change_state(LCD_OFF);
- return ECORE_CALLBACK_CANCEL;
- }
-
- /* checkLockstate */
- if(vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &val) < 0) {
- _E("Failed to get lock state");
- val = -1;
- }
- if(val == VCONFKEY_IDLE_LOCK) {
- _W("lock state is [%d] -> just turn off LCD", val);
- display_change_state(LCD_OFF);
- return ECORE_CALLBACK_CANCEL;
- }
-
- /* Check remote-lock state */
- if(vconf_get_bool(VCONFKEY_REMOTE_LOCK_ISLOCKED, &val) < 0){
- _E("failed to get %s", VCONFKEY_REMOTE_LOCK_ISLOCKED);
- val = -1;
- }
-
- if(val == true){
- _W("remote lock is on top (%d), -> just turn off LCD", val);
- display_change_state(LCD_OFF);
- return ECORE_CALLBACK_CANCEL;
- }
-
- /* Show Idle-Clock */
- if(!_launch_home_by_powerkey())
- _E("Failed to send powerkey to home..!!");
-#if 0
- /* terminate syspopup */
- syspopup_destroy_all();
-#endif
-
- /* To notify powerkey to fmd & fmw */
- vconf_set_int("memory/wfmd/wfmd_end_key", 1);
- vconf_set_int("memory/wfmw/wfmw_end_key", 1);
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-static Eina_Bool _long_press_timer_cb(void* data)
-{
- int pid;
- bundle *b;
- int test_mode = -1;
- int call_forward_requesting = -1;
- int remote_lock_status = -1;
-
- _W("%s", __func__);
-
- key_info.long_press_timer = NULL;
- key_info.is_long_press = EINA_TRUE;
- key_info.powerkey_count = 0; //initialize powerkey count
-
- vconf_get_int(VCONFKEY_TESTMODE_POWER_OFF_POPUP, &test_mode);
- if (test_mode == VCONFKEY_TESTMODE_POWER_OFF_POPUP_DISABLE) {
- _E("test mode => skip poweroff popup");
- return ECORE_CALLBACK_CANCEL;
- }
-
- vconf_get_bool(VCONFKEY_CALL_FORWARD_REQUESTING, &call_forward_requesting);
- if (call_forward_requesting == TRUE) {
- _E("call forward requesting => skip poweroff popup");
- return ECORE_CALLBACK_CANCEL;
- }
-
- /* Check remote-lock state */
- if(vconf_get_bool(VCONFKEY_REMOTE_LOCK_ISLOCKED, &remote_lock_status) < 0){
- _E("failed to get %s", VCONFKEY_REMOTE_LOCK_ISLOCKED);
- }
-
- if(remote_lock_status == true){
- _E("remote lock is on top (%d), ignore double key", remote_lock_status);
- return ECORE_CALLBACK_CANCEL;
- }
-
-#ifdef TARGET
- if (bincfg_is_factory_binary() == 1) {
- _E("Factory binary..!!");
- return ECORE_CALLBACK_CANCEL;
- }
-#endif
-
- //Check single powerkey press/release
- if(key_info.powerkey_timer) {
- ecore_timer_del(key_info.powerkey_timer);
- key_info.powerkey_timer = NULL;
- _D("delete powerkey_timer");
- }
-
-#if USE_DBUS_POWEROFF
- //_request_Poweroff();
- request_Poweroff();
-#else
- b = bundle_create();
- if (!b)
- return ECORE_CALLBACK_CANCEL;
- pid = syspopup_launch("poweroff-syspopup", b);
- _D("launch power off syspopup, pid : %d", pid);
- bundle_free(b);
-#endif
- feedback_initialize();
- feedback_play_type(FEEDBACK_TYPE_VIBRATION, FEEDBACK_PATTERN_HOLD);
- feedback_deinitialize();
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-static Eina_Bool _key_release_cb(void *data, int type, void *event)
-{
- Evas_Event_Key_Up *ev = event;
- int val = -1;
-
- if (!ev) {
- _D("Invalid event object");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (!ev->keyname) {
- _D("_key_release_cb : Invalid event keyname object");
- return ECORE_CALLBACK_RENEW;
- } else {
- _D("_key_release_cb : %s Released", ev->keyname);
- }
-
- if (!strcmp(ev->keyname, KEY_POWER)) {
-
- _W("POWER Key is released");
-
- // Check long press timer
- if(key_info.long_press_timer) {
- ecore_timer_del(key_info.long_press_timer);
- key_info.long_press_timer = NULL;
- _D("delete long press timer");
- }
-
- // Check powerkey timer
- if(key_info.powerkey_timer) {
- ecore_timer_del(key_info.powerkey_timer);
- key_info.powerkey_timer = NULL;
- _D("delete powerkey timer");
- }
-
- // Cancel key operation
- if (EINA_TRUE == key_info.is_cancel) {
- _D("Cancel key is activated");
- key_info.is_cancel = EINA_FALSE;
- key_info.powerkey_count = 0; //initialize powerkey count
- return ECORE_CALLBACK_RENEW;
- }
-
- // Check long press operation
- if(key_info.is_long_press) {
- _D("ignore power key release by long poress");
- key_info.is_long_press = EINA_FALSE;
- return ECORE_CALLBACK_RENEW;
- }
-
- if(!key_info.is_lcd_on) {
- _D("lcd off --> [%f]sec timer", POWERKEY_LCDOFF_TIMER_SEC);
- key_info.powerkey_timer = ecore_timer_add(POWERKEY_LCDOFF_TIMER_SEC, _powerkey_timer_cb, data);
- } else {
- key_info.powerkey_timer = ecore_timer_add(POWERKEY_TIMER_SEC, _powerkey_timer_cb, data);
- }
-
- } else if (!strcmp(ev->keyname, KEY_CANCEL)) {
- _D("CANCEL Key is released");
- key_info.is_cancel = EINA_FALSE;
- }
-
- return ECORE_CALLBACK_RENEW;
-}
-
-
-
-static Eina_Bool _key_press_cb(void *data, int type, void *event)
-{
- Evas_Event_Key_Down *ev = event;
- int pm_val = -1;
- int val = -1;
-
-
- if (!ev) {
- _D("Invalid event object");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (!ev->keyname) {
- _D("_key_press_cb : Invalid event keyname object");
- return ECORE_CALLBACK_RENEW;
- } else {
- _D("_key_press_cb : %s Pressed", ev->keyname);
- }
-
- if (!strcmp(ev->keyname, KEY_POWER)) {
-
- _W("POWER Key is pressed");
-
- // Check LCD status
- if(vconf_get_int(VCONFKEY_PM_STATE, &val) < 0) {
- _E("Cannot get VCONFKEY_PM_STATE");
- }
- _W("LCD state : %d", val);
- if(val <= VCONFKEY_PM_STATE_LCDDIM) {
- key_info.is_lcd_on = EINA_TRUE;
- } else if(val >= VCONFKEY_PM_STATE_LCDOFF) {
- key_info.is_lcd_on = EINA_FALSE;
- }
-
- // Check Simple Clock status
- if(vconf_get_int(VCONFKEY_SIMPLECLOCK_UI_STATUS, &val) < 0) {
- _E("Failed to get VCONFKEY_SIMPLECLOCK_UI_STATUS");
- val = 0;
- }
- _W("Simple Clock state : %d", val);
- key_info.is_simple_clock_display = val;
-
- // Check powerkey press count
- key_info.powerkey_count++;
- _W("powerkey count : %d", key_info.powerkey_count);
-
- // Check powerkey timer
- if(key_info.powerkey_timer) {
- ecore_timer_del(key_info.powerkey_timer);
- key_info.powerkey_timer = NULL;
- _D("delete powerkey timer");
- }
-
- // Check long press
- if (key_info.long_press_timer) {
- ecore_timer_del(key_info.long_press_timer);
- key_info.long_press_timer = NULL;
- }
- _D("create long press timer");
- key_info.is_long_press = EINA_FALSE;
- key_info.long_press_timer = ecore_timer_add(LONG_PRESS_TIMER_SEC, _long_press_timer_cb, NULL);
- if(!key_info.long_press_timer) {
- _E("Failed to add long_press_timer");
- }
-
- } else if (!strcmp(ev->keyname, KEY_CANCEL)) {
- _D("CANCEL key is pressed");
- key_info.is_cancel = EINA_TRUE;
- }
-
- return ECORE_CALLBACK_RENEW;
-}
-
-
-
-static int _w_gesture_hold_cb(void *data, int ev_type, void *ev)
-{
- struct appdata *ad = (struct appdata *)data;
- if(ad == NULL){
- _E("app data is NULL");
- return ECORE_CALLBACK_RENEW;
- }
- Ecore_X_Event_Gesture_Notify_Hold *e = ev;
- int ret = 0;
- int val = -1;
- bundle *b = NULL;
-
- _D("_w_gesture_hold_cb..!!");
-
-#ifdef TARGET
- if (bincfg_is_factory_binary() == 1) {
- _E("Factory binary..!!");
- return ECORE_CALLBACK_RENEW;
- }
-#endif
-
- /* Check Simple clock ui status */
- if(vconf_get_int(VCONFKEY_SIMPLECLOCK_UI_STATUS, &val) < 0) {
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_SIMPLECLOCK_UI_STATUS);
- }
- if(val == 1) { //Simple Clock ui Show.
- _E("Simple Clock ui Show, ignore gesture");
- return ECORE_CALLBACK_RENEW;
- }
-
- /* Check critical low batt clock mode */
- if(vconf_get_int(VCONFKEY_PM_KEY_IGNORE, &val) < 0) {
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_PM_KEY_IGNORE);
- }
- if(val == 1) { //Critical Low Batt Clock Mode
- _E("Critical Low Batt Clock Mode, ignore gesture");
- return ECORE_CALLBACK_RENEW;
- }
-
- /* Check UPS mode */
- if(vconf_get_int(VCONFKEY_SETAPPL_PSMODE, &val) < 0) {
- _SECURE_E("Failed to get vconfkey[%s]", VCONFKEY_SETAPPL_PSMODE);
- }
- if(val == SETTING_PSMODE_WEARABLE_ENHANCED) { //UPS Mode
- _E("UPS Mode, ignore gesture");
- return ECORE_CALLBACK_RENEW;
- }
-
- /* Check Cool Down mode */
- if(ad->cool_down_mode !=0){
- _E("Cool down mode is LimitAction(%d), ignore double key", ad->cool_down_mode);
- return ECORE_CALLBACK_RENEW;
- }
-
- if(e->num_fingers == GRAB_TWO_FINGERS) {
- _D("subtype[%d]: hold[%d]\n", e->subtype, e->hold_time);
- if (e->subtype == ECORE_X_GESTURE_BEGIN) {
- _D("Begin : launch task mgr..!!");
-
- b = bundle_create();
- if(!b) {
- _E("Failed to create bundle");
- return EINA_FALSE;
- }
- bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_MAIN_VALUE);
-
- request_dbus_cpu_booster();
-
- ret = w_launch_app(W_TASKMGR_PKGNAME, NULL);
- if (ret >= 0) {
- _SECURE_D("[%s] is launched, pid=[%d]", W_TASKMGR_PKGNAME, ret);
-#if 0
- /* terminate syspopup */
- //syspopup_destroy_all();
- ecore_timer_add(SYSPOPUP_END_TIMER_SEC*2, _syspopup_end_timer_cb, NULL);
-#endif
- }
- if(b) {
- bundle_free(b);
- }
- }
- }
-
- return ECORE_CALLBACK_RENEW;
-}
-
-
-
-inline static void _release_multimedia_key(const char *value)
-{
- int pid = 0;
-
- ret_if(NULL == value);
-
- _D("Multimedia key is released with %s", value);
-
- bundle *b;
- b = bundle_create();
- if (!b) {
- _E("Cannot create bundle");
- return;
- }
- bundle_add(b, "multimedia_key", value);
- bundle_add(b, APP_CONTROL_OPERATION_MAIN_KEY, APP_CONTROL_OPERATION_DEFAULT_VALUE);
-
- pid = w_launch_app(MUSIC_PLAYER_PKG_NAME, b);
- if (pid < 0)
- _E("Failed to launch music player, ret : %d", pid);
-
- bundle_free(b);
-}
-
-
-void _media_key_event_cb(media_key_e key, media_key_event_e status, void *user_data)
-{
- _D("MEDIA KEY EVENT : %d", key);
- if (MEDIA_KEY_STATUS_PRESSED == status) return;
-
- if (MEDIA_KEY_PAUSE == key) {
- _release_multimedia_key("KEY_PAUSECD");
- } else if (MEDIA_KEY_PLAY == key) {
- _release_multimedia_key("KEY_PLAYCD");
- } else if (MEDIA_KEY_PLAYPAUSE == key) {
- _release_multimedia_key("KEY_PLAYPAUSECD");
- }
-}
-
-static Eina_Bool _key_release_in_factory_cb(void *data, int type, void *event)
-{
- Evas_Event_Key_Up *ev = event;
- int val = -1;
-
- if (!ev) {
- _D("Invalid event object");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (!ev->keyname) {
- _D("_key_release_cb : Invalid event keyname object");
- return ECORE_CALLBACK_RENEW;
- } else {
- _D("_key_release_cb : %s Released", ev->keyname);
- }
-
- if (!strcmp(ev->keyname, KEY_POWER)) {
-
- _W("POWER Key is released");
- if(!key_info.is_lcd_on) {
- _W("just turn on LCD by powerkey.. starter ignore powerkey operation");
- } else {
- _W("just turn off LCD");
- display_change_state(LCD_OFF);
- }
- return ECORE_CALLBACK_CANCEL;
- }
- return ECORE_CALLBACK_RENEW;
-}
-
-static Eina_Bool _key_press_in_factory_cb(void *data, int type, void *event)
-{
- Evas_Event_Key_Down *ev = event;
- int pm_val = -1;
- int val = -1;
-
-
- if (!ev) {
- _D("Invalid event object");
- return ECORE_CALLBACK_RENEW;
- }
-
- if (!ev->keyname) {
- _D("_key_press_cb : Invalid event keyname object");
- return ECORE_CALLBACK_RENEW;
- } else {
- _D("_key_press_cb : %s Pressed", ev->keyname);
- }
-
- if (!strcmp(ev->keyname, KEY_POWER)) {
-
- _W("POWER Key is pressed");
- // Check LCD status
- if(vconf_get_int(VCONFKEY_PM_STATE, &val) < 0) {
- _E("Cannot get VCONFKEY_PM_STATE");
- }
- _W("LCD state : %d", val);
- if(val <= VCONFKEY_PM_STATE_LCDDIM) {
- key_info.is_lcd_on = EINA_TRUE;
- } else if(val >= VCONFKEY_PM_STATE_LCDOFF) {
- key_info.is_lcd_on = EINA_FALSE;
- }
- }
- return ECORE_CALLBACK_RENEW;
-}
-
-void create_key_window_factory_mode(char *home_pkgname, void *data)
-{
- int status = -1;
- int ret = -1;
-
- _W("create_key_window in factory mode!!");
-
- key_info.win = ecore_x_window_input_new(0, 0, 0, 1, 1);
- if (!key_info.win) {
- _E("Failed to create hidden window");
- return;
- }
- ecore_x_event_mask_unset(key_info.win, ECORE_X_EVENT_MASK_NONE);
- ecore_x_icccm_title_set(key_info.win, "w_starter,key,receiver");
- ecore_x_netwm_name_set(key_info.win, "w_starter,key,receiver");
- ecore_x_netwm_pid_set(key_info.win, getpid());
-
- ret = utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_POWER, SHARED_GRAB);
- if (ret != 0) {
- _E("utilx_grab_key KEY_POWER GrabSHARED_GRAB failed, ret[%d]", ret);
- }
-
- key_info.key_up = ecore_event_handler_add(ECORE_EVENT_KEY_UP, _key_release_in_factory_cb, data);
- if (!key_info.key_up)
- _E("Failed to register a key up event handler");
-
- key_info.key_down = ecore_event_handler_add(ECORE_EVENT_KEY_DOWN, _key_press_in_factory_cb, NULL);
- if (!key_info.key_down)
- _E("Failed to register a key down event handler");
-}
-
-
-
-void create_key_window(char *home_pkgname, void *data)
-{
- int status = -1;
- int ret = -1;
-
- _W("create_key_window..!!");
-
- key_info.win = ecore_x_window_input_new(0, 0, 0, 1, 1);
- if (!key_info.win) {
- _E("Failed to create hidden window");
- return;
- }
- ecore_x_event_mask_unset(key_info.win, ECORE_X_EVENT_MASK_NONE);
- ecore_x_icccm_title_set(key_info.win, "w_starter,key,receiver");
- ecore_x_netwm_name_set(key_info.win, "w_starter,key,receiver");
- ecore_x_netwm_pid_set(key_info.win, getpid());
-
-#if 0
- g_type_init();
- e_dbus_init();
-
- init_dbus_ALPM_signal(NULL);
-#endif
-
- key_info.home_pkgname = home_pkgname;
-
- ret = utilx_grab_key(ecore_x_display_get(), key_info.win, KEY_POWER, SHARED_GRAB);
- if (ret != 0) {
- _E("utilx_grab_key KEY_POWER GrabSHARED_GRAB failed, ret[%d]", ret);
- }
-
- key_info.key_up = ecore_event_handler_add(ECORE_EVENT_KEY_UP, _key_release_cb, data);
- if (!key_info.key_up)
- _E("Failed to register a key up event handler");
-
- key_info.key_down = ecore_event_handler_add(ECORE_EVENT_KEY_DOWN, _key_press_cb, NULL);
- if (!key_info.key_down)
- _E("Failed to register a key down event handler");
-
- status = ecore_x_gesture_event_grab(key_info.win, ECORE_X_GESTURE_EVENT_HOLD, GRAB_TWO_FINGERS);
- _E("ECORE_X_GESTURE_EVENT_HOLD Grab(%d fingers) status[%d]\n", GRAB_TWO_FINGERS, status);
-
- key_info.two_fingers_hold_hd = ecore_event_handler_add(ECORE_X_EVENT_GESTURE_NOTIFY_HOLD,
- (Ecore_Event_Handler_Cb)_w_gesture_hold_cb, data);
- if (!key_info.two_fingers_hold_hd) {
- _E("Failed to register handler : ECORE_X_EVENT_GESTURE_NOTIFY_TAPNHOLD\n");
- }
-
- media_key_reserve(_media_key_event_cb, NULL);
-
-}
-
-
-
-void destroy_key_window(void)
-{
- int status;
-
- if (key_info.two_fingers_hold_hd) {
- ecore_event_handler_del(key_info.two_fingers_hold_hd);
- key_info.two_fingers_hold_hd = NULL;
- }
-
- status = ecore_x_gesture_event_ungrab(key_info.win, ECORE_X_GESTURE_EVENT_HOLD, GRAB_TWO_FINGERS);
- if (!status) {
- _E("ECORE_X_GESTURE_EVENT_HOLD UnGrab(%d fingers) failed, status[%d]\n", GRAB_TWO_FINGERS, status);
- }
-
- utilx_ungrab_key(ecore_x_display_get(), key_info.win, KEY_POWER);
-
- if (key_info.key_up) {
- ecore_event_handler_del(key_info.key_up);
- key_info.key_up = NULL;
- }
-
- if (key_info.key_down) {
- ecore_event_handler_del(key_info.key_down);
- key_info.key_down = NULL;
- }
-
- ecore_x_window_delete_request_send(key_info.win);
- key_info.win = 0x0;
-
-}
-
-
-
-// End of a file
diff --git a/src/lock-daemon-lite.c b/src/lock-daemon-lite.c
deleted file mode 100755
index 5351c58..0000000
--- a/src/lock-daemon-lite.c
+++ /dev/null
@@ -1,2185 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <Elementary.h>
-
-#include <vconf.h>
-#include <vconf-keys.h>
-
-#include <glib.h>
-#include <poll.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <sys/socket.h>
-#include <sys/un.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-#include <errno.h>
-#include <unistd.h>
-#include <sys/param.h>
-#include <errno.h>
-//#include <sensors.h>
-#include <feedback.h>
-#include <alarm.h>
-#include <time.h>
-#include <dd-deviced.h>
-#include <dd-display.h>
-#include <E_DBus.h>
-#include <aul.h>
-
-#ifndef FEATURE_LITE
-#include <context_manager.h>
-#endif
-
-#include "lockd-debug.h"
-#include "lock-daemon-lite.h"
-#include "lockd-process-mgr.h"
-#include "lockd-window-mgr.h"
-#include "starter-util.h"
-#include "menu_daemon.h"
-#include "hw_key.h"
-#include "lockd-bt.h"
-#include "dbus-util.h"
-#include "util.h"
-
-static int phone_lock_pid;
-static int auto_lock_pid;
-static bool lock_state_available = TRUE;
-
-struct lockd_data {
- int lock_app_pid;
- int phone_lock_app_pid;
- int lock_type; /* -1: None, 0:Normal, 1:Security, 2:Other */
- Eina_Bool is_sensor; /* EINA_TRUE : can use sensor EINA_FALSE : cannot use */
- Eina_Bool request_recovery;
- Eina_Bool back_to_app;
- Eina_Bool start_ready;
- lockw_data *lockw;
- GPollFD *gpollfd;
- Eina_Bool is_alarm; /* EINA_TRUE : can use alarm EINA_FALSE : cannot use */
- alarm_id_t alarm_id; /* -1 : None, others : set alarm */
- Eina_Bool is_first_boot; /* EINA_TRUE : first boot */
- int hall_status; /* 0: cover is closed, 1:cover is opened */
- E_DBus_Connection *hall_conn;
- E_DBus_Signal_Handler *hall_handler;
- E_DBus_Connection *display_conn;
- E_DBus_Signal_Handler *display_handler;
-
-};
-
-
-
-/* Local features*/
-#define _FEATURE_LCD_OFF_DBUS 0 //Check to apply lcd off dbus by PM part
-#define _FEATURE_SCOVER 0 //Scover view
-
-#define VCONFKEY_LOCKSCREEN_FESTIVAL_WALLPAPER_DISPLAYING "db/lockscreen/festival_wallpaper"
-
-
-#define PHLOCK_SOCK_PREFIX "/tmp/phlock"
-#define PHLOCK_SOCK_MAXBUFF 1024
-
-#define VOLUNE_APP_CMDLINE "/usr/apps/org.volume.volume/bin/volume" // LOCK_EXIT_CMD
-#define PHLOCK_APP_CMDLINE "/usr/apps/org.volume.lockscreen/bin/lockscreen" //PHLOCK_UNLOCK_CMD
-#define MDM_APP_CMDLINE "/usr/bin/mdm-server" //PHLOCK_LAUNCH_CMD
-#define VOICE_CALL_APP_CMDLINE "/usr/apps/com.samsung.call/bin/calls" //HOME_RAISE_CMD, LOCK_SHOW_CMD
-#define VIDEO_CALL_APP_CMDLINE "/usr/apps/com.samsung.vtmain/bin/vtmain" //HOME_RAISE_CMD, LOCK_SHOW_CMD
-#define OMA_DRM_AGENT_CMDLINE "/usr/bin/oma-dm-agent" //PHLOCK_UNLOCK_RESET_CMD
-
-#define PHLOCK_UNLOCK_CMD "unlock"
-#define PHLOCK_LAUNCH_CMD "launch_phone_lock"
-#define PHLOCK_UNLOCK_RESET_CMD "unlock_reset"
-#define HOME_RAISE_CMD "raise_homescreen"
-#define LOCK_SHOW_CMD "show_lockscreen"
-#define LOCK_LAUNCH_CMD "launch_lockscreen"
-#define LOCK_EXIT_CMD "exit_lockscreen"
-
-#define LAUNCH_INTERVAL 100*1000
-
-#define HALL_COVERED_STATUS 0
-#define BUS_NAME "org.tizen.system.deviced"
-#define OBJECT_PATH "/Org/Tizen/System/DeviceD"
-#define INTERFACE_NAME BUS_NAME
-#define DEVICED_PATH_HALL OBJECT_PATH"/Hall"
-#define DEVICED_INTERFACE_HALL INTERFACE_NAME".hall"
-#define SIGNAL_HALL_STATE "ChangeState"
-#define METHOD_GET_STATUS "getstatus"
-#define DBUS_REPLY_TIMEOUT (120 * 1000)
-#define DEVICED_PATH_PMQOS OBJECT_PATH"/PmQos"
-#define DEVICED_INTERFACE_PMQOS INTERFACE_NAME".PmQos"
-#define METHOD_PMQOS_NAME "LockScreen"
-#define REQUEST_PMQOS_DURATION (2 * 1000)
-
-#define DEVICED_PATH_LCD_OFF OBJECT_PATH"/Display"
-#define DEVICED_INTERFACE_LCD_OFF INTERFACE_NAME".display"
-#define METHOD_LCD_OFF_NAME "LCDOffByPowerkey"
-
-#define VOLUME_PKG_NAME "org.tizen.volume"
-#define WALLPAPER_UI_SERVICE_PKG_NAME "com.samsung.wallpaper-ui-service"
-#define SHOW_LOCK "show_lock"
-#define ISTRUE "TRUE"
-#define SMART_ALERT_INTERVAL 0.5
-
-#define PASSWORD_LOCK_PROGRESS "/tmp/.passwordlock"
-static int checkfd = 0;
-
-enum {
- LOCK_TYPE_NONE = -1,
- LOCK_TYPE_NORMAL = 0,
- LOCK_TYPE_SECURITY,
- LOCK_TYPE_AUTO_LOCK,
- LOCK_TYPE_OTHER,
- LOCK_TYPE_MAX
-};
-
-static int lockd_launch_app_lockscreen_lite(struct lockd_data *lockd);
-static int lockd_launch_app_other_lockscreen(struct lockd_data *lockd);
-static void lockd_unlock_other_lockscreen(struct lockd_data *lockd);
-static void lockd_init_vconf(struct lockd_data *lockd);
-static void lockd_fini_vconf(struct lockd_data *lockd);
-static void _lockd_check_ongoing(bool ongoing);
-#if 0
-static Eina_Bool lockd_start_sensor(void *data);
-static void lockd_stop_sensor(void *data);
-#endif
-
-static void _lockd_set_lock_state(int lock_state)
-{
- LOCKD_DBG("%s, %d, %d", __func__, __LINE__, lock_state);
- if(lock_state < VCONFKEY_IDLE_UNLOCK || lock_state > VCONFKEY_IDLE_LAUNCHING_LOCK) {
- LOCKD_ERR("Can't set lock_state : %d out of range", lock_state);
- } else {
- vconf_set_int(VCONFKEY_IDLE_LOCK_STATE, lock_state);
- }
-}
-
-static void _lockd_play_sound(bool unlock)
-{
- int ret = -1, val = 0;
- ret = vconf_get_bool(VCONFKEY_SETAPPL_SOUND_LOCK_BOOL, &val);
-
- if(ret == 0 && val == 1) {
- feedback_initialize();
- feedback_play_type(FEEDBACK_TYPE_SOUND, unlock ? FEEDBACK_PATTERN_UNLOCK : FEEDBACK_PATTERN_LOCK);
- }
-}
-
-int lockd_get_lock_type(void)
-{
- int lock_type = 0;
- int ret = 0;
-
- vconf_get_int(VCONFKEY_SETAPPL_SCREEN_LOCK_TYPE_INT, &lock_type);
-
- if (lock_type == SETTING_SCREEN_LOCK_TYPE_NONE) {
- ret = LOCK_TYPE_NONE;
- } else if (lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD ||
- lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD ||
- lock_type == SETTING_SCREEN_LOCK_TYPE_FINGERPRINT ||
- lock_type == SETTING_SCREEN_LOCK_TYPE_FACE_AND_VOICE) {
- ret = LOCK_TYPE_SECURITY;
- } else if (lock_type == SETTING_SCREEN_LOCK_TYPE_SWIPE ||
- lock_type == SETTING_SCREEN_LOCK_TYPE_MOTION) {
- ret = LOCK_TYPE_NORMAL;
- } else if (lock_type == SETTING_SCREEN_LOCK_TYPE_AUTO_LOCK) {
- ret = LOCK_TYPE_AUTO_LOCK;
- } else {
- ret = LOCK_TYPE_OTHER;
- }
-
- LOCKD_DBG("lockd_get_lock_type ret(%d), lock_type (%d)", ret, lock_type);
-
- return ret;
-}
-
-static int _lockd_append_variant(DBusMessageIter *iter, const char *sig, char *param[])
-{
- char *ch;
- int i;
- int int_type;
- uint64_t int64_type;
-
- if (!sig || !param)
- return 0;
-
- for (ch = (char*)sig, i = 0; *ch != '\0'; ++i, ++ch) {
- switch (*ch) {
- case 'i':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &int_type);
- break;
- case 'u':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT32, &int_type);
- break;
- case 't':
- int64_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT64, &int64_type);
- break;
- case 's':
- dbus_message_iter_append_basic(iter, DBUS_TYPE_STRING, &param[i]);
- break;
- default:
- return -EINVAL;
- }
- }
-
- return 0;
-}
-
-DBusMessage *_lockd_invoke_dbus_method_async(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- LOCKD_ERR("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- LOCKD_ERR("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _lockd_append_variant(&iter, sig, param);
- if (r < 0) {
- LOCKD_ERR("append_variant error(%d)", r);
- return NULL;
- }
-
- r = dbus_connection_send(conn, msg, NULL);
- dbus_message_unref(msg);
- if (r != TRUE) {
- LOCKD_ERR("dbus_connection_send error(%s:%s:%s-%s)", dest, path, interface, method);
- return -ECOMM;
- }
- LOCKD_DBG("dbus_connection_send, ret=%d", r);
- return NULL;
-}
-
-DBusMessage *_lockd_invoke_dbus_method_sync(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- LOCKD_ERR("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- LOCKD_ERR("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _lockd_append_variant(&iter, sig, param);
- if (r < 0) {
- LOCKD_ERR("append_variant error(%d)", r);
- return NULL;
- }
-
- dbus_error_init(&err);
-
- reply = dbus_connection_send_with_reply_and_block(conn, msg, DBUS_REPLY_TIMEOUT, &err);
- if (!reply) {
- LOCKD_ERR("dbus_connection_send error(No reply)");
- }
-
- if (dbus_error_is_set(&err)) {
- LOCKD_ERR("dbus_connection_send error(%s:%s)", err.name, err.message);
- reply = NULL;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- return reply;
-}
-
-int lockd_get_hall_status(void)
-{
- DBusError err;
- DBusMessage *msg;
- int ret, ret_val;
-
- LOCKD_DBG("[ == %s == ]", __func__);
- msg = _lockd_invoke_dbus_method_sync(BUS_NAME, DEVICED_PATH_HALL, DEVICED_INTERFACE_HALL,
- METHOD_GET_STATUS, NULL, NULL);
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &ret_val, DBUS_TYPE_INVALID);
- if (!ret) {
- LOCKD_ERR("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- LOCKD_DBG("%s-%s : %d", DEVICED_INTERFACE_HALL, METHOD_GET_STATUS, ret_val);
- return ret_val;
-}
-
-int lockd_get_lock_state(void)
-{
- int idle_lock_state = VCONFKEY_IDLE_UNLOCK;
-
- if (vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &idle_lock_state) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- idle_lock_state = VCONFKEY_IDLE_UNLOCK;
- }
- LOCKD_DBG("Get lock state : %d", idle_lock_state);
- return idle_lock_state;
-}
-
-static void _lockd_on_changed_receive(void *data, DBusMessage *msg)
-{
- DBusError err;
- char *str;
- int response;
- int r;
- int automatic_unlock = 0;
-
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- LOCKD_DBG("hall signal is received");
-
- r = dbus_message_is_signal(msg, DEVICED_INTERFACE_HALL, SIGNAL_HALL_STATE);
- if (!r) {
- LOCKD_ERR("dbus_message_is_signal error");
- return;
- }
-
- LOCKD_DBG("%s - %s", DEVICED_INTERFACE_HALL, SIGNAL_HALL_STATE);
-
- dbus_error_init(&err);
- r = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &response, DBUS_TYPE_INVALID);
- if (!r) {
- LOCKD_ERR("dbus_message_get_args error");
- return;
- }
-
- LOCKD_DBG("receive data : %d", response);
- lockd->hall_status = response;
-
-}
-
-static int _lockd_request_PmQos(int duration)
-{
- DBusError err;
- DBusMessage *msg;
- int ret, ret_val;
- char *arr[1];
- char val[32];
-
- snprintf(val, sizeof(val), "%d", duration);
- arr[0] = val;
-
- //msg = _lockd_invoke_dbus_method_sync(BUS_NAME, DEVICED_PATH_PMQOS, DEVICED_INTERFACE_PMQOS,
- // METHOD_PMQOS_NAME, "i", arr);
- msg = _lockd_invoke_dbus_method_async(BUS_NAME, DEVICED_PATH_PMQOS, DEVICED_INTERFACE_PMQOS,
- METHOD_PMQOS_NAME, "i", arr);
-
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &ret_val, DBUS_TYPE_INVALID);
- if (!ret) {
- LOCKD_ERR("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- LOCKD_DBG("%s-%s : %d", DEVICED_INTERFACE_PMQOS, METHOD_PMQOS_NAME, ret_val);
- return ret_val;
-}
-
-static void _lockd_delete_alarm_lite(alarm_id_t id, void * user_param)
-{
- int ret_val = ALARMMGR_RESULT_SUCCESS;
- LOCKD_DBG("Del alarm_id(%d)", id);
- ret_val = alarmmgr_remove_alarm(id);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_enum_alarm_ids() failed");
- }
-}
-
-static void _lockd_unset_alarms_lite(void)
-{
- LOCKD_DBG("[ == %s == ]", __func__);
- int ret_val = ALARMMGR_RESULT_SUCCESS;
- ret_val = alarmmgr_enum_alarm_ids(_lockd_delete_alarm_lite, NULL);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_enum_alarm_ids() failed");
- }
-}
-
-static void _lockd_lauch_other_lockscreen(alarm_id_t alarm_id, void *data)
-{
- struct lockd_data *lockd = (struct lockd_data *)data;
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- int ret_val = ALARMMGR_RESULT_SUCCESS;
-
- LOCKD_DBG("[ == %s == ], alarm_id(%d)", __func__, alarm_id);
-
- lockd_launch_app_other_lockscreen(lockd);
-
- if(alarm_id != -1) {
- if(alarm_id != lockd->alarm_id) {
- LOCKD_ERR("alarm ids are different callback->id(%d), lockd->alarm_id(%d)", alarm_id, lockd->alarm_id);
- /* delete all registering alarm*/
- _lockd_unset_alarms_lite();
- lockd->alarm_id = -1;
- } else {
- ret_val = alarmmgr_remove_alarm(alarm_id);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_remove_alarm() failed");
- /* delete all registering alarm*/
- _lockd_unset_alarms_lite();
- }
- lockd->alarm_id = -1;
- }
- }
-}
-
-static Eina_Bool _lockd_set_alarm(int sec, void *data)
-{
- struct lockd_data *lockd = (struct lockd_data *)data;
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return EINA_FALSE;
- }
-
- time_t current_time;
- struct tm current_tm;
- alarm_entry_t *alarm_info;
- alarm_id_t alarm_id;
- alarm_date_t alarm_time;
- int ret_val = ALARMMGR_RESULT_SUCCESS;
-
- /* delete before registering alarm ids */
- if(lockd->alarm_id != -1){
- LOCKD_ERR("ad->alarm_id(%d) deleted", lockd->alarm_id);
- ret_val = alarmmgr_remove_alarm(lockd->alarm_id);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_remove_alarm(%d) failed", lockd->alarm_id);
- _lockd_unset_alarms_lite();
- }
- lockd->alarm_id = -1;
- }
-
- /* set alarm after sec */
- time(&current_time);
-
- localtime_r(&current_time, &current_tm);
-
- alarm_info = alarmmgr_create_alarm();
- if(alarm_info == NULL) {
- LOCKD_ERR("alarmmgr_create_alarm() is failed\n");
- return EINA_FALSE;
- }
-
- alarm_time.year = 0;
- alarm_time.month = 0;
- alarm_time.day = 0;
- alarm_time.hour = current_tm.tm_hour;
- alarm_time.min = current_tm.tm_min;
- alarm_time.sec = current_tm.tm_sec + sec;
-
- alarmmgr_set_repeat_mode(alarm_info, ALARM_REPEAT_MODE_ONCE, 0);
- alarmmgr_set_time(alarm_info, alarm_time);
- alarmmgr_set_type(alarm_info, ALARM_TYPE_VOLATILE);
-
- ret_val = alarmmgr_add_alarm_with_localtime(alarm_info, NULL, &alarm_id);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_add_alarm_with_localtime() failed");
- alarmmgr_free_alarm(alarm_info) ;
- return EINA_FALSE;
- }
-
- LOCKD_DBG("alarm id(%d) is set", alarm_id);
- lockd->alarm_id = alarm_id;
- alarmmgr_free_alarm(alarm_info) ;
-
- return EINA_TRUE;
-}
-
-
-#ifndef FEATURE_LITE
-static Eina_Bool _lockd_play_smart_alert_cb(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- feedback_initialize();
- feedback_play_type(FEEDBACK_TYPE_VIBRATION, FEEDBACK_PATTERN_REACTIVE_ALERT);
- //feedback_deinitialize();
- //lockd_stop_sensor(lockd);
-
- return ECORE_CALLBACK_CANCEL;
-}
-
-void _lockd_context_update_cb(int error, context_item_e context, char* context_data, void* user_data, int req_id)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- struct lockd_data *lockd = (struct lockd_data *)user_data;
-
- if (error == CONTEXT_ERROR_NONE && context == CONTEXT_ITEM_MOVEMENT) {
- int action = -1;
- int ret = 0;
- int calls = 0;
- int messages = 0;
-
- context_context_data_get_int(context_data, CONTEXT_MOTION_ACTION, &action);
-
- switch (action) {
- case CONTEXT_MOVEMENT_ACTION:
- ret = vconf_get_int(VCONFKEY_STARTER_MISSED_CALL, &calls);
- if(ret != 0)
- calls = 0;
-
- ret = vconf_get_int(VCONFKEY_STARTER_UNREAD_MESSAGE, &messages);
- if(ret != 0)
- messages = 0;
-
- if(calls > 0 || messages > 0) {
- LOCKD_WARN("[ sensor ] SMART ALERT calls = %d messages = %d", calls, messages);
- ecore_timer_add(SMART_ALERT_INTERVAL, _lockd_play_smart_alert_cb, user_data);
- }
- break;
- case CONTEXT_MOVEMENT_NONE:
- break;
- default:
- break;
- }
- context_unset_changed_callback(CONTEXT_ITEM_MOVEMENT);
- free(context_data);
- }
-}
-
-static Eina_Bool _lockd_smart_alert_idelr_cb(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- int val = -1;
- struct lockd_data *lockd = (struct lockd_data *)data;
- if (vconf_get_int(VCONFKEY_PM_STATE, &val) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY_PM_STATE");
- return ECORE_CALLBACK_CANCEL;
- }
-
- if ((val == VCONFKEY_PM_STATE_LCDOFF) || (val == VCONFKEY_PM_STATE_SLEEP)) {
- LOCKD_DBG("LCD OFF ==> smart alert start");
-
- int ret = 0;
- int is_motion = 0;
- int is_pickup = 0;
-
- ret = vconf_get_bool(VCONFKEY_SETAPPL_MOTION_ACTIVATION, &is_motion);
- LOCKD_DBG("[ sensor ] ret = %d is_motion = %d", ret, is_motion);
- if(ret == 0 && is_motion == 1) {
- ret = vconf_get_bool(VCONFKEY_SETAPPL_USE_PICK_UP, &is_pickup);
- LOCKD_DBG("[ sensor ] ret = %d is_pickup = %d", ret, is_pickup);
- if(ret == 0 && is_pickup == 1) {
- int ret = 0;
- int calls = 0;
- int messages = 0;
- int req_id, r;
-
- ret = vconf_get_int(VCONFKEY_STARTER_MISSED_CALL, &calls);
- if(ret != 0)
- calls = 0;
-
- ret = vconf_get_int(VCONFKEY_STARTER_UNREAD_MESSAGE, &messages);
- if(ret != 0)
- messages = 0;
-
- if(calls > 0 || messages > 0) {
- r = context_set_changed_callback(CONTEXT_ITEM_MOVEMENT, NULL, _lockd_context_update_cb, lockd, &req_id);
- if (r != CONTEXT_ERROR_NONE) {
- LOCKD_ERR("[ sensor ] context_set_changed_callback fail");
- }
- LOCKD_WARN("[ sensor ] context_set_changed_callback, r=[%d]", r);
- }
- }
- }
- } else {
- LOCKD_DBG("Not LCD OFF ==> cancel smart alert");
- }
- return ECORE_CALLBACK_CANCEL;
-}
-#endif
-
-
-
-static Eina_Bool _lockd_sensor_idelr_cb(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- int val = -1;
- if (vconf_get_int(VCONFKEY_PM_STATE, &val) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY_PM_STATE");
- return ECORE_CALLBACK_CANCEL;
- }
-
- if ((val == VCONFKEY_PM_STATE_LCDOFF) || (val == VCONFKEY_PM_STATE_SLEEP)) {
- LOCKD_DBG("LCD OFF ==> sensor start");
-
- int ret = 0;
- int calls = 0;
- int messages = 0;
-
- ret = vconf_get_int(VCONFKEY_STARTER_MISSED_CALL, &calls);
- if(ret != 0)
- calls = 0;
-
- ret = vconf_get_int(VCONFKEY_STARTER_UNREAD_MESSAGE, &messages);
- if(ret != 0)
- messages = 0;
-
- if(calls > 0 || messages > 0) {
- if(lockd_start_sensor(data) == EINA_FALSE) {
- LOCKD_ERR("smart_alert sensor start is failed");
- }
- } else {
- LOCKD_ERR("[ sensor ] sensor is not started calls = %d messages = %d", calls, messages);
- }
- } else {
- LOCKD_DBG("Not LCD OFF ==> cancel sensor start");
- }
- return ECORE_CALLBACK_CANCEL;
-}
-
-static Eina_Bool _lockd_alarm_idelr_cb(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
- struct lockd_data *lockd = (struct lockd_data *)data;
- _lockd_unset_alarms_lite();
- lockd->alarm_id = -1;
- return ECORE_CALLBACK_CANCEL;
-}
-
-static Eina_Bool _lockd_launch_idelr_cb(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
- struct lockd_data *lockd = (struct lockd_data *)data;
- _lockd_lauch_other_lockscreen(-1, lockd);
- return ECORE_CALLBACK_CANCEL;
-}
-
-static void _lockd_notify_pm_state_cb_lite(keynode_t * node, void *data)
-{
- struct lockd_data *lockd = (struct lockd_data *)data;
- int val = -1;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- if (vconf_get_int(VCONFKEY_PM_STATE, &val) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- return;
- }
-
- LOCKD_DBG("[ == %s == ] pm_state(%d)", __func__, val);
-
- if (val == VCONFKEY_PM_STATE_NORMAL) {
- LOCKD_DBG("LCD ON");
- /* delete all alarm registering */
- LOCKD_DBG("%d", lockd->alarm_id);
-
- _lockd_unset_alarms_lite();
- lockd->alarm_id = -1;
-
- if(lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_NONE) {
- LOCKD_DBG("Lockscreen type is none, unlock");
- }
- }
-}
-
-static int _show_lock_bg(void)
-{
- bundle *b;
- int r = 0;
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- if (menu_daemon_get_volume_pid() <0) {
- LOCKD_DBG("volume is not running");
- return -1;
- }
-
- b = bundle_create();
-
- bundle_add(b, SHOW_LOCK, ISTRUE);
- r = aul_launch_app(VOLUME_PKG_NAME, b);
- if(b) {
- bundle_free(b);
- }
-
- return r;
-}
-
-static void _lockd_notify_pm_lcdoff_cb_lite(keynode_t * node, void *data)
-{
- struct lockd_data *lockd = (struct lockd_data *)data;
- int val = -1;
- int lcdoff_source = vconf_keynode_get_int(node);
- int accessbility_lock_time = 0;
- int idle_lock_state = VCONFKEY_IDLE_UNLOCK;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- if (lcdoff_source < 0) {
- LOCKD_ERR("Cannot get VCONFKEY, error (%d)", lcdoff_source);
- return;
- }
-
- LOCKD_DBG("[ %s ] LCD OFF by lcd off source(%d)", __func__, lcdoff_source);
-
- idle_lock_state = lockd_get_lock_state();
-
- if(lcdoff_source == VCONFKEY_PM_LCDOFF_BY_POWERKEY) {
- LOCKD_DBG("lcd off by powerkey");
-#if (!_FEATURE_LCD_OFF_DBUS) // move to dbus signal handler.
- if (idle_lock_state == VCONFKEY_IDLE_UNLOCK) {
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD || lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD || lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SWIPE) {
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
- _lockd_request_PmQos(REQUEST_PMQOS_DURATION);
- }
- }
- lockd_launch_app_other_lockscreen(lockd);
-#endif
- } else if (lcdoff_source == 3) {
- LOCKD_DBG("lcd off by proximity sensor..");
- return;
- } else {
- LOCKD_DBG("lcd off by timeout");
-
- if(idle_lock_state == VCONFKEY_IDLE_LOCK) {
- LOCKD_DBG("VCONFKEY is set(not need to set alarm)");
- return;
- }
-
- if(lockd->alarm_id != -1) {
- LOCKD_ERR("Alarm is set yet (alarm_id = %d) : do nothing", lockd->alarm_id);
- return;
- }
-
- if(vconf_get_int(VCONFKEY_SETAPPL_ACCESSIBILITY_LOCK_TIME_INT, &accessbility_lock_time) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- accessbility_lock_time = 0;
- }
-
- if(accessbility_lock_time == 0) {
- LOCKD_ERR("accessbility_lock_time is 0");
- _lockd_lauch_other_lockscreen(-1, lockd);
- return;
- } else {
- if(lockd->is_alarm) {
- LOCKD_DBG("set alarm %d sec", accessbility_lock_time);
- if(_lockd_set_alarm(accessbility_lock_time, lockd) != EINA_TRUE) {
- LOCKD_ERR("_lockd_set_alarm() failed");
- _lockd_lauch_other_lockscreen(-1, lockd);
- }
- }
- else {
- LOCKD_ERR("is_alarm is EINA_FALSE");
- _lockd_lauch_other_lockscreen(-1, lockd);
- }
- }
- }
-}
-
-static void _lockd_notify_time_changed_cb(keynode_t * node, void *data)
-{
- int festival_wallpaper = 0;
- LOCKD_DBG("system time chanded!!");
-
- if(vconf_get_bool(VCONFKEY_LOCKSCREEN_FESTIVAL_WALLPAPER_DISPLAYING, &festival_wallpaper) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- festival_wallpaper = 0;
- }
- LOCKD_DBG("festival wallpaper : %d", festival_wallpaper);
- if(festival_wallpaper){
- bundle *b;
- b = bundle_create();
- if(b == NULL){
- LOCKD_ERR("bundle create failed.\n");
- return;
- }
- bundle_add(b, "popup_type", "festival");
- bundle_add(b, "festival_type", "festival_create");
- aul_launch_app(WALLPAPER_UI_SERVICE_PKG_NAME, b);
- bundle_free(b);
- }
-}
-
-static void _lockd_notify_factory_mode_cb(keynode_t * node, void *data)
-{
- int factory_mode = -1;
- LOCKD_DBG("Factory mode Notification!!");
-
- vconf_get_int(VCONFKEY_TELEPHONY_SIM_FACTORY_MODE, &factory_mode);
- if (factory_mode == VCONFKEY_TELEPHONY_SIM_FACTORYMODE_ON) {
- LOCKD_DBG("Factory mode ON, lock screen can't be launched..!!");
- _lockd_set_lock_state(VCONFKEY_IDLE_UNLOCK);
- }
-}
-
-static void
-_lockd_notify_pwlock_state_changed_cb(keynode_t * node, void *data)
-{
- LOCKD_DBG("pwlock state changed!!");
-
- struct lockd_data *lockd = (struct lockd_data *)data;
- int val = -1;
- int pwlock_state = -1;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- pwlock_state = vconf_keynode_get_int(node);
-
- if(pwlock_state == VCONFKEY_PWLOCK_BOOTING_UNLOCK){
- if(checkfd){
- LOCKD_WARN("remove the progress file.");
- _lockd_check_ongoing(EINA_FALSE);
- }
- if (vconf_ignore_key_changed
- (VCONFKEY_PWLOCK_STATE, _lockd_notify_pwlock_state_changed_cb) != 0) {
- LOCKD_ERR("Fail vconf_ignore_key_changed : VCONFKEY_PWLOCK_STATE");
- }
- }
-}
-
-static void
-_lockd_notify_lock_state_cb(keynode_t * node, void *data)
-{
- LOCKD_DBG("lock state changed!!");
-
- struct lockd_data *lockd = (struct lockd_data *)data;
- int val = -1;
- int pwlock_state = -1;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- val = lockd_get_lock_state();
- vconf_get_int(VCONFKEY_PWLOCK_STATE, &pwlock_state);
-
- if (val == VCONFKEY_IDLE_UNLOCK) {
- LOCKD_DBG("unlocked..!!");
-
- if(lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD || lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD){
- if(pwlock_state == VCONFKEY_PWLOCK_BOOTING_UNLOCK){
- if(checkfd){
- LOCKD_WARN("remove the progress file.");
- _lockd_check_ongoing(EINA_FALSE);
- }
- }
- else if(pwlock_state == VCONFKEY_PWLOCK_BOOTING_LOCK){
- LOCKD_WARN("PWLOCK is not ready yet.");
- if (vconf_notify_key_changed
- (VCONFKEY_PWLOCK_STATE, _lockd_notify_pwlock_state_changed_cb, lockd) != 0) {
- LOCKD_ERR("Fail vconf_notify_key_changed : VCONFKEY_SETAPPL_SCREEN_LOCK_TYPE_INT");
- }
- }
- }
-
- if (vconf_set_bool(VCONFKEY_SAT_NORMAL_PRIORITY_AVAILABLE_BOOL, EINA_FALSE) < 0) {
- LOCKD_ERR("Cannot set VCONFKEY");
- }
-
- if (lockd->lock_app_pid > 0) {
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_OTHER) {
- LOCKD_DBG("terminate lock app..!!");
- lockd_process_mgr_terminate_lock_app(lockd->lock_app_pid, 1);
- lockd->lock_app_pid = 0;
- }
- }
- }else if (val == VCONFKEY_IDLE_LOCK) {
- display_unlock_state(LCD_OFF, PM_SLEEP_MARGIN);
- }
-}
-
-static Eina_Bool lockd_set_lock_state_cb(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
- _lockd_set_lock_state(VCONFKEY_IDLE_LOCK);
- return ECORE_CALLBACK_CANCEL;
-}
-
-static void
-_lockd_notify_phone_lock_verification_cb(keynode_t * node, void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- struct lockd_data *lockd = (struct lockd_data *)data;
- int val = -1;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- if (vconf_get_bool(VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION, &val) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- return;
- }
-
- if (val == TRUE) {
- /* password verified */
- /* lockd_unlock_lockscreen(lockd); */
- lockd_window_mgr_finish_lock(lockd->lockw);
- _lockd_set_lock_state(VCONFKEY_IDLE_UNLOCK);
- }
-}
-
-static int lockd_app_dead_cb_lite(int pid, void *data)
-{
- LOCKD_DBG("app dead cb call! (pid : %d)", pid);
-
- struct lockd_data *lockd = (struct lockd_data *)data;
- int val = 0;
-
- if(pid == lockd->lock_app_pid || pid == lockd->phone_lock_app_pid){
- if (vconf_get_int(VCONFKEY_PM_STATE, &val) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- }
- LOCKD_DBG("lock daemon(%d) is terminated, lock type : %d pm state : %d", pid, lockd->lock_type, val);
- if(lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_OTHER){
- lockd_unlock_other_lockscreen(lockd);
- _lockd_play_sound(TRUE);
- }
- else{
- if(val < VCONFKEY_PM_STATE_LCDOFF){
- lockd->start_ready = TRUE;
- lockd_launch_app_lockscreen_lite(lockd);
- }
- else{
- lockd_launch_app_lockscreen_lite(lockd);
- }
- }
- }
-
- menu_daemon_check_dead_signal(pid);
-
- return 0;
-}
-
-static Eina_Bool lockd_other_app_create_cb(void *data, int type, void *event)
-{
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- if (lockd == NULL) {
- return ECORE_CALLBACK_PASS_ON;
- }
- LOCKD_DBG("%s, %d", __func__, __LINE__);
- if (lockd_window_set_window_effect(lockd->lockw, lockd->lock_app_pid,
- event) == EINA_TRUE) {
- //FIXME sometimes show cb is not called.
- if(lockd_window_set_window_property(lockd->lockw, lockd->lock_app_pid,
- event) == EINA_FALSE) {
- LOCKD_ERR("window is not matched..!!");
- }
- }
- return ECORE_CALLBACK_PASS_ON;
-}
-
-static Eina_Bool lockd_other_app_show_cb(void *data, int type, void *event)
-{
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- if (lockd == NULL) {
- return EINA_TRUE;
- }
- LOCKD_DBG("%s, %d", __func__, __LINE__);
- if (lockd_window_set_window_property(lockd->lockw, lockd->lock_app_pid,
- event)) {
- lockd_window_set_scroll_property(lockd->lockw, 0);
- ecore_idler_add(lockd_set_lock_state_cb, NULL);
- }
- return EINA_FALSE;
-}
-
-static Eina_Bool _lockd_play_idelr_cb(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
- _lockd_play_sound(FALSE);
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-static int lockd_launch_app_lockscreen_lite(struct lockd_data *lockd)
-{
- LOCKD_DBG("launch app lock screen");
-
- int call_state = -1, factory_mode = -1, test_mode = -1;
- int r = 0;
- int lcdoff_source = 0;
- int focus_win_pid = 0;
- int pw_type = 0;
- int automatic_unlock = 0;
-
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
-
- vconf_get_int(VCONFKEY_TELEPHONY_SIM_FACTORY_MODE, &factory_mode);
- if (factory_mode == VCONFKEY_TELEPHONY_SIM_FACTORYMODE_ON) {
- LOCKD_ERR("Factory mode ON, lock screen can't be launched..!!");
- goto launch_out;
- }
- vconf_get_int(VCONFKEY_TESTMODE_SCREEN_LOCK, &test_mode);
- if (test_mode == VCONFKEY_TESTMODE_SCREEN_LOCK_DISABLE) {
- LOCKD_ERR("Test mode ON, lock screen can't be launched..!!");
- goto launch_out;
- }
-
- if (lockd->is_first_boot == TRUE) {
- if(vconf_get_int(VCONFKEY_PWLOCK_STATE, &pw_type) < 0)
- {
- LOCKD_ERR("vconf_get_int() failed");
- pw_type = VCONFKEY_PWLOCK_RUNNING_UNLOCK;
- }
- if(pw_type == VCONFKEY_PWLOCK_BOOTING_LOCK || pw_type == VCONFKEY_PWLOCK_RUNNING_LOCK) {
- LOCKD_ERR("First boot & pwlock state[%d], lock screen can't be launched..!!", pw_type);
- goto launch_out;
- }
- }
-
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_NONE) {
- LOCKD_ERR("Lock screen type is None..!!");
- goto launch_out;
- }
-
- LOCKD_WARN("lock type : %d", lockd->lock_type);
- switch (lockd->lock_type) {
-
- case SETTING_SCREEN_LOCK_TYPE_SWIPE:
- if(lockd->start_ready == TRUE){
- lockd->lock_app_pid =
- lockd_process_mgr_start_ready_lock();
- lockd->start_ready = FALSE;
- }
- else{
- lockd->lock_app_pid =
- lockd_process_mgr_start_normal_lock(lockd, lockd_app_dead_cb_lite);
- if (lockd->lock_app_pid < 0) {
- goto launch_out;
- }
- }
- break;
-
- case SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD:
- case SETTING_SCREEN_LOCK_TYPE_PASSWORD:
- vconf_set_bool(VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION, FALSE);
-
- /* TO DO : Recovery should be checked by EAS interface later */
- /* After getting EAS interface, we should remove lockd->request_recovery */
- if (lockd->request_recovery == TRUE) {
- lockd->phone_lock_app_pid =
- lockd_process_mgr_start_recovery_lock();
- lockd->request_recovery = FALSE;
- } else if (lockd->back_to_app == TRUE) {
- lockd->phone_lock_app_pid =
- lockd_process_mgr_start_back_to_app_lock();
- lockd->back_to_app = FALSE;
- } else if (lockd->start_ready == TRUE) {
- lockd->phone_lock_app_pid =
- lockd_process_mgr_start_ready_lock();
- lockd->start_ready = FALSE;
- } else {
- lockd->phone_lock_app_pid =
- lockd_process_mgr_start_phone_lock();
- }
- phone_lock_pid = lockd->phone_lock_app_pid;
- LOCKD_WARN("%s, %d, phone_lock_pid = %d", __func__, __LINE__,
- phone_lock_pid);
- lockd_window_set_phonelock_pid(lockd->lockw, phone_lock_pid);
- if (phone_lock_pid > 0) {
- if(starter_dbus_set_oomadj(phone_lock_pid, OOM_ADJ_VALUE_DEFAULT) < 0){
- LOCKD_ERR("failed to send oom dbus signal");
- }
- if(lockd_process_mgr_check_home(focus_win_pid)) {
- if(vconf_set_bool(VCONFKEY_SAT_NORMAL_PRIORITY_AVAILABLE_BOOL, EINA_TRUE) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- }
- }
- }
- else{
- LOCKD_ERR("failed to launch phone lock.");
- goto launch_out;
- }
- lockd_process_mgr_set_lockscreen_priority(phone_lock_pid);
- display_unlock_state(LCD_OFF, PM_SLEEP_MARGIN);
- return 1;
- break;
-
- default:
- goto launch_out;
- }
-
-
- if (lockd->lock_app_pid > 0) {
- if(starter_dbus_set_oomadj(lockd->lock_app_pid, OOM_ADJ_VALUE_DEFAULT) < 0){
- LOCKD_ERR("failed to send oom dbus signal");
- }
- if(lockd_process_mgr_check_home(focus_win_pid)) {
- if(vconf_set_bool(VCONFKEY_SAT_NORMAL_PRIORITY_AVAILABLE_BOOL, EINA_TRUE) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- }
- }
- }
- else{
- LOCKD_ERR("failed to launch lock");
- goto launch_out;
- }
- LOCKD_WARN("lock app pid : %d", lockd->lock_app_pid);
- lockd_process_mgr_set_lockscreen_priority(lockd->lock_app_pid);
- display_unlock_state(LCD_OFF, PM_SLEEP_MARGIN);
- return 1;
-
-
-launch_out:
- display_unlock_state(LCD_OFF, PM_SLEEP_MARGIN);
- return -1;
-}
-
-
-static int lockd_launch_app_other_lockscreen(struct lockd_data *lockd)
-{
- LOCKD_DBG("launch app other lock screen");
-
- int call_state = -1, factory_mode = -1, test_mode = -1;
- int r = 0;
- int lcdoff_source = 0;
- int focus_win_pid = 0;
- int pw_type = 0;
- int automatic_unlock = 0;
-
- //PM LOCK - don't go to sleep
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
-
- vconf_get_int(VCONFKEY_TELEPHONY_SIM_FACTORY_MODE, &factory_mode);
- if (factory_mode == VCONFKEY_TELEPHONY_SIM_FACTORYMODE_ON) {
- LOCKD_ERR("Factory mode ON, lock screen can't be launched..!!");
- goto launch_out;
- }
- vconf_get_int(VCONFKEY_TESTMODE_SCREEN_LOCK, &test_mode);
- if (test_mode == VCONFKEY_TESTMODE_SCREEN_LOCK_DISABLE) {
- LOCKD_ERR("Test mode ON, lock screen can't be launched..!!");
- goto launch_out;
- }
-
- if (lockd->is_first_boot == TRUE) {
- if(vconf_get_int(VCONFKEY_PWLOCK_STATE, &pw_type) < 0)
- {
- LOCKD_ERR("vconf_get_int() failed");
- pw_type = VCONFKEY_PWLOCK_RUNNING_UNLOCK;
- }
- if(pw_type == VCONFKEY_PWLOCK_BOOTING_LOCK || pw_type == VCONFKEY_PWLOCK_RUNNING_LOCK) {
- LOCKD_ERR("First boot & pwlock state[%d], lock screen can't be launched..!!", pw_type);
- goto launch_out;
- }
- }
-
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_NONE) {
- LOCKD_ERR("Lock screen type is None..!!");
- goto launch_out;
- }
-
- /* Get Call state */
- if(vconf_get_int(VCONFKEY_PM_LCDOFF_SOURCE, &lcdoff_source) < 0)
- {
- LOCKD_ERR("Cannot get VCONFKEY");
- }
- focus_win_pid = lockd_window_mgr_get_focus_win_pid();
- vconf_get_int(VCONFKEY_CALL_STATE, &call_state);
- if(lcdoff_source == VCONFKEY_PM_LCDOFF_BY_POWERKEY) {
- if ((call_state != VCONFKEY_CALL_OFF) && (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_OTHER)) {
- if (focus_win_pid >0) {
- if (lockd_process_mgr_check_call(focus_win_pid) == TRUE) {
- LOCKD_ERR("Call is FG => not allow to launch lock screen!!");
- goto launch_out;
- } else {
- LOCKD_DBG("Call is BG => allow to launch lock screen!!");
- }
- }
- }
- } else {
- if ((call_state != VCONFKEY_CALL_OFF) && (lockd->back_to_app == FALSE)) {
- LOCKD_ERR("Current call state(%d) does not allow to launch lock screen.",
- call_state);
- goto launch_out;
- }
- }
-
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_OTHER) {
- if (lockd_process_mgr_check_lock(lockd->lock_app_pid) == TRUE) {
- LOCKD_WARN("Lock Screen App is already running.");
- display_unlock_state(LCD_OFF, PM_SLEEP_MARGIN);
- return 1;
- }
-
- if (lockd->lock_app_pid > 0) {
- LOCKD_ERR("Lock Screen App is remained, pid[%d].", lockd->lock_app_pid);
- lockd_process_mgr_kill_lock_app(lockd->lock_app_pid);
- lockd->lock_app_pid = 0;
- }
- if(lcdoff_source == VCONFKEY_PM_LCDOFF_BY_POWERKEY)
- ecore_idler_add(_lockd_play_idelr_cb, NULL);
-
- lockd->lock_app_pid =
- lockd_process_mgr_start_lock(lockd, lockd_app_dead_cb_lite,
- lockd->lock_type);
- if (lockd->lock_app_pid < 0) {
- LOCKD_ERR("launch 3rd party lockscreen failed.");
- goto launch_out;
- }
- /* reset window mgr before start win mgr */
- lockd_window_mgr_finish_lock(lockd->lockw);
- lockd_window_mgr_ready_lock(lockd, lockd->lockw, lockd_other_app_create_cb,
- lockd_other_app_show_cb);
- }
-
- if (lockd->lock_app_pid > 0) {
- if(starter_dbus_set_oomadj(lockd->lock_app_pid, OOM_ADJ_VALUE_DEFAULT) < 0){
- LOCKD_ERR("failed to send oom dbus signal");
- }
- if(lockd_process_mgr_check_home(focus_win_pid)) {
- if(vconf_set_bool(VCONFKEY_SAT_NORMAL_PRIORITY_AVAILABLE_BOOL, EINA_TRUE) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- }
- }
- }
- LOCKD_WARN("lock app pid : %d", lockd->lock_app_pid);
- display_unlock_state(LCD_OFF, PM_SLEEP_MARGIN);
- return 1;
-
-
- launch_out:
- _lockd_set_lock_state(VCONFKEY_IDLE_UNLOCK);
- display_unlock_state(LCD_OFF, PM_SLEEP_MARGIN);
- return -1;
-}
-
-static void lockd_unlock_other_lockscreen(struct lockd_data *lockd)
-{
- LOCKD_DBG("unlock other lock screen");
- lockd->lock_app_pid = 0;
-
- _lockd_set_lock_state(VCONFKEY_IDLE_UNLOCK);
- lockd_window_mgr_finish_lock(lockd->lockw);
-}
-
-inline static void lockd_set_sock_option(int fd, int cli)
-{
- int size;
- int ret;
- struct timeval tv = { 1, 200 * 1000 }; /* 1.2 sec */
-
- size = PHLOCK_SOCK_MAXBUFF;
- ret = setsockopt(fd, SOL_SOCKET, SO_SNDBUF, &size, sizeof(size));
- if(ret != 0)
- return;
- ret = setsockopt(fd, SOL_SOCKET, SO_RCVBUF, &size, sizeof(size));
- if(ret != 0)
- return;
- if (cli) {
- ret = setsockopt(fd, SOL_SOCKET, SO_RCVTIMEO, &tv, sizeof(tv));
- if(ret != 0)
- return;
- }
-}
-
-static int lockd_create_sock(void)
-{
- struct sockaddr_un saddr;
- int fd;
-
- fd = socket(AF_UNIX, SOCK_STREAM, 0); /* support above version 2.6.27 */
- if (fd < 0) {
- if (errno == EINVAL) {
- fd = socket(AF_UNIX, SOCK_STREAM, 0);
- if (fd < 0) {
- LOCKD_ERR
- ("second chance - socket create error");
- return -1;
- }
- } else {
- LOCKD_ERR("socket error");
- return -1;
- }
- }
-
- bzero(&saddr, sizeof(saddr));
- saddr.sun_family = AF_UNIX;
-
- strncpy(saddr.sun_path, PHLOCK_SOCK_PREFIX, sizeof(saddr.sun_path)-1);
- saddr.sun_path[strlen(PHLOCK_SOCK_PREFIX)] = 0;
-
- unlink(saddr.sun_path);
-
- if (bind(fd, (struct sockaddr *)&saddr, sizeof(saddr)) < 0) {
- LOCKD_ERR("bind error");
- close(fd);
- return -1;
- }
-
- if (chmod(saddr.sun_path, (S_IRWXU | S_IRWXG | S_IRWXO)) < 0) {
- /* Flawfinder: ignore */
- LOCKD_ERR("failed to change the socket permission");
- close(fd);
- return -1;
- }
-
- lockd_set_sock_option(fd, 0);
-
- if (listen(fd, 10) == -1) {
- LOCKD_ERR("listen error");
- close(fd);
- return -1;
- }
-
- return fd;
-}
-
-static gboolean lockd_glib_check(GSource * src)
-{
- GSList *fd_list;
- GPollFD *tmp;
-
- fd_list = src->poll_fds;
- do {
- tmp = (GPollFD *) fd_list->data;
- if ((tmp->revents & (POLLIN | POLLPRI)))
- return TRUE;
- fd_list = fd_list->next;
- } while (fd_list);
-
- return FALSE;
-}
-
-static char *lockd_read_cmdline_from_proc(int pid)
-{
- int memsize = 32;
- char path[32];
- char *cmdline = NULL, *tempptr = NULL;
- FILE *fp = NULL;
-
- snprintf(path, sizeof(path), "/proc/%d/cmdline", pid);
-
- fp = fopen(path, "r");
- if (fp == NULL) {
- LOCKD_ERR("Cannot open cmdline on pid[%d]", pid);
- return NULL;
- }
-
- cmdline = malloc(32);
- if (cmdline == NULL) {
- LOCKD_ERR("%s", "Out of memory");
- fclose(fp);
- return NULL;
- }
-
- bzero(cmdline, memsize);
- if (fgets(cmdline, 32, fp) == NULL) {
- LOCKD_ERR("%s", "Cannot read cmdline");
- free(cmdline);
- fclose(fp);
- return NULL;
- }
-
- while (cmdline[memsize - 2] != 0) {
- cmdline[memsize - 1] = (char)fgetc(fp);
- tempptr = realloc(cmdline, memsize + 32);
- if (tempptr == NULL) {
- fclose(fp);
- LOCKD_ERR("%s", "Out of memory");
- return NULL;
- }
- cmdline = tempptr;
- bzero(cmdline + memsize, 32);
- fgets(cmdline + memsize, 32, fp);
- memsize += 32;
- }
-
- if (fp != NULL)
- fclose(fp);
- return cmdline;
-}
-
-static int lockd_sock_handler(void *data)
-{
- int cl;
- int len;
- int sun_size;
- int clifd = -1;
- char cmd[PHLOCK_SOCK_MAXBUFF];
- char *cmdline = NULL;
- int fd = -1;
- int recovery_state = -1;
- GPollFD *gpollfd;
-
- struct ucred cr;
- struct sockaddr_un lockd_addr;
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- if ((lockd == NULL) || (lockd->gpollfd == NULL)) {
- LOCKD_ERR("lockd->gpollfd is NULL");
- return -1;
- }
- gpollfd = (GPollFD *)lockd->gpollfd;
- fd = gpollfd->fd;
-
- cl = sizeof(cr);
- sun_size = sizeof(struct sockaddr_un);
-
- if ((clifd =
- accept(fd, (struct sockaddr *)&lockd_addr,
- (socklen_t *) & sun_size)) == -1) {
- if (errno != EINTR)
- LOCKD_ERR("accept error");
- return -1;
- }
-
- if (getsockopt(clifd, SOL_SOCKET, SO_PEERCRED, &cr, (socklen_t *) & cl)
- < 0) {
- LOCKD_ERR("peer information error");
- close(clifd);
- return -1;
- }
- LOCKD_ERR("Peer's pid=%d, uid=%d, gid=%d\n", cr.pid, cr.uid, cr.gid);
-
- memset(cmd, 0, PHLOCK_SOCK_MAXBUFF);
-
- lockd_set_sock_option(clifd, 1);
-
- /* receive single packet from socket */
- len = recv(clifd, cmd, PHLOCK_SOCK_MAXBUFF, 0);
-
- if (len < 0) {
- LOCKD_ERR("recv error, read number is less than zero");
- close(clifd);
- return -1;
- }
-
- cmd[PHLOCK_SOCK_MAXBUFF - 1] = '\0';
-
- LOCKD_ERR("cmd %s", cmd);
-
- /* Read command line of the PID from proc fs */
- cmdline = lockd_read_cmdline_from_proc(cr.pid);
- if (cmdline == NULL) {
- /* It's weired. no file in proc file system, */
- LOCKD_ERR("Error on opening /proc/%d/cmdline", cr.pid);
- close(clifd);
- return -1;
- }
- LOCKD_SECURE_ERR("/proc/%d/cmdline : %s", cr.pid, cmdline);
-
- if ((!strncmp(cmd, PHLOCK_UNLOCK_RESET_CMD, strlen(cmd)))
- && (!strncmp(cmdline, OMA_DRM_AGENT_CMDLINE, strlen(cmdline)))) {
- LOCKD_SECURE_ERR("%s request %s \n", cmdline, cmd);
- if(phone_lock_pid > 0) {
- LOCKD_SECURE_ERR("pid [%d] %s is verified, unlock..!!\n", cr.pid,
- cmdline);
- vconf_set_bool(VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION, TRUE);
- // reset lockscreen type
- if (vconf_set_int(VCONFKEY_SETAPPL_SCREEN_LOCK_TYPE_INT, SETTING_SCREEN_LOCK_TYPE_SWIPE) < 0) {
- LOCKD_ERR("%s set to %d is failed. error \n",
- VCONFKEY_SETAPPL_SCREEN_LOCK_TYPE_INT, SETTING_SCREEN_LOCK_TYPE_SWIPE);
- }
- }
- } else if (!strncmp(cmd, PHLOCK_LAUNCH_CMD, strlen(cmd))) {
- if (!strncmp(cmdline, MDM_APP_CMDLINE, strlen(cmdline))) {
- LOCKD_ERR("%s request %s \n", cmdline, cmd);
- if (vconf_get_int(VCONFKEY_EAS_RECOVERY_MODE, &recovery_state) < 0) {
- LOCKD_ERR("Cannot get vconfkey", VCONFKEY_EAS_RECOVERY_MODE);
- lockd->request_recovery = FALSE;
- } else if (recovery_state == 1) {
- LOCKD_ERR("recovery mode : %d \n", recovery_state);
- lockd->request_recovery = TRUE;
- } else {
- lockd->request_recovery = FALSE;
- }
- }
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD || lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD) {
- lockd_launch_app_lockscreen_lite(lockd);
- } else {
- lockd->request_recovery = FALSE;
- }
- } else if (!strncmp(cmd, HOME_RAISE_CMD, strlen(cmd))) {
- if ((!strncmp(cmdline, VOICE_CALL_APP_CMDLINE, strlen(cmdline)))
- || (!strncmp(cmdline, VIDEO_CALL_APP_CMDLINE, strlen(cmdline)))) {
- LOCKD_SECURE_ERR("%s request %s \n", cmdline, cmd);
- menu_daemon_open_homescreen(NULL);
- }
- } else if (!strncmp(cmd, LOCK_SHOW_CMD, strlen(cmd))) {
- if ((!strncmp(cmdline, VOICE_CALL_APP_CMDLINE, strlen(cmdline)))
- || (!strncmp(cmdline, VIDEO_CALL_APP_CMDLINE, strlen(cmdline)))) {
- LOCKD_SECURE_ERR("%s request %s \n", cmdline, cmd);
- lockd->back_to_app = TRUE;
- }
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD || lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD){
- lockd_launch_app_lockscreen_lite(lockd);
- } else {
- lockd->back_to_app = FALSE;
- }
- } else if (!strncmp(cmd, LOCK_LAUNCH_CMD, strlen(cmd))) {
- LOCKD_SECURE_ERR("%s request %s \n", cmdline, cmd);
- if (!strncmp(cmdline, VOICE_CALL_APP_CMDLINE, strlen(cmdline))) {
- lockd_launch_app_lockscreen_lite(lockd);
- }
- }
-
- if(cmdline != NULL) {
- free(cmdline);
- cmdline = NULL;
- }
-
- close(clifd);
- return 0;
-}
-
-static gboolean lockd_glib_handler(gpointer data)
-{
- if (lockd_sock_handler(data) < 0) {
- LOCKD_ERR("lockd_sock_handler is failed..!!");
- }
- return TRUE;
-}
-
-static gboolean lockd_glib_dispatch(GSource * src, GSourceFunc callback,
- gpointer data)
-{
- callback(data);
- return TRUE;
-}
-
-static gboolean lockd_glib_prepare(GSource * src, gint * timeout)
-{
- return FALSE;
-}
-
-static GSourceFuncs funcs = {
- .prepare = lockd_glib_prepare,
- .check = lockd_glib_check,
- .dispatch = lockd_glib_dispatch,
- .finalize = NULL
-};
-
-static int lockd_init_sock(struct lockd_data *lockd)
-{
- int fd;
- GPollFD *gpollfd;
- GSource *src;
- int ret;
-
- fd = lockd_create_sock();
- if (fd < 0) {
- LOCKD_ERR("lock daemon create sock failed..!!");
- }
-
- src = g_source_new(&funcs, sizeof(GSource));
-
- gpollfd = (GPollFD *) g_malloc(sizeof(GPollFD));
- if (!gpollfd) {
- LOCKD_ERR("gpollfd is NULL");
- g_source_unref(src);
- return -1;
- }
- gpollfd->events = POLLIN;
- gpollfd->fd = fd;
-
- lockd->gpollfd = gpollfd;
-
- g_source_add_poll(src, lockd->gpollfd);
- g_source_set_callback(src, (GSourceFunc) lockd_glib_handler,
- (gpointer) lockd, NULL);
- g_source_set_priority(src, G_PRIORITY_LOW);
-
- ret = g_source_attach(src, NULL);
- if (ret == 0)
- return -1;
-
- g_source_unref(src);
-
- return 0;
-}
-
-
-
-
-static void _lockd_notify_bt_device_connected_status_cb(keynode_t * node, void *data)
-{
- int is_connected = 0;
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- vconf_get_bool(VCONFKEY_SETAPPL_AUTO_LOCK_DEVICE_STATUS_BOOL , &is_connected);
- LOCKD_WARN("BT connect status is changed to [%d]", is_connected);
-
- if (is_connected) {
- if (lockd_start_bt_monitor() < 0) {
- LOCKD_ERR("Fail starter BT monitor");
- }
- } else {
- lockd_stop_bt_monitor();
- lockd_change_security_auto_lock(is_connected);
- }
-}
-
-
-static void _lockd_notify_lock_type_changed_cb(keynode_t * node, void *data)
-{
- int lock_type = -1;
- struct lockd_data *lockd = (struct lockd_data *)data;
- LOCKD_DBG("lock type is changed..!!");
-
- lock_type = vconf_keynode_get_int(node);
- lockd->lock_type = lock_type;
-
- if(lock_type == SETTING_SCREEN_LOCK_TYPE_OTHER){
- LOCKD_DBG("lock type is 3rd party lock");
- lockd_init_vconf(lockd);
- if(lockd->lock_app_pid > 0){
- lockd_process_mgr_terminate_lock_app(lockd->lock_app_pid, 1);
- lockd->lock_app_pid = 0;
- }
- if(lockd->phone_lock_app_pid > 0){
- lockd_process_mgr_terminate_lock_app(lockd->phone_lock_app_pid, 1);
- lockd->phone_lock_app_pid = 0;
- }
- }
- else{
- LOCKD_DBG("lock type is not 3rd party lock");
- lockd_fini_vconf(lockd);
- lockd->start_ready = TRUE;
- lockd_launch_app_lockscreen_lite(lockd);
- }
-}
-
-
-static void lockd_fini_vconf(struct lockd_data *lockd)
-{
- int val = -1;
-
- if (vconf_ignore_key_changed
- (VCONFKEY_PM_STATE, _lockd_notify_pm_state_cb_lite) != 0) {
- LOCKD_ERR("Fail vconf_ignore_key_changed : VCONFKEY_PM_STATE");
- }
-
- if (vconf_ignore_key_changed
- (VCONFKEY_PM_LCDOFF_SOURCE, _lockd_notify_pm_lcdoff_cb_lite) != 0) {
- LOCKD_ERR("Fail vconf_ignore_key_changed : VCONFKEY_PM_LCDOFF_SOURCE");
- }
-
- if (vconf_ignore_key_changed
- (VCONFKEY_TELEPHONY_SIM_FACTORY_MODE, _lockd_notify_factory_mode_cb) != 0) {
- LOCKD_ERR("Fail vconf_ignore_key_changed : VCONFKEY_TELEPHONY_SIM_FACTORY_MODE");
- }
-#if 0
- if (vconf_ignore_key_changed
- (VCONFKEY_SYSTEM_TIME_CHANGED, _lockd_notify_time_changed_cb) != 0) {
- LOCKD_ERR("Fail vconf_ignore_key_changed : VCONFKEY_SYSTEM_TIME_CHANGED");
- }
-#endif
- if (vconf_ignore_key_changed
- (VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION, _lockd_notify_phone_lock_verification_cb) != 0) {
- LOCKD_ERR("Fail vconf_ignore_key_changed : VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION");
- }
- if (vconf_ignore_key_changed
- (VCONFKEY_IDLE_LOCK_STATE, _lockd_notify_lock_state_cb) != 0) {
- LOCKD_ERR("Fail vconf_ignore_key_changed : VCONFKEY_IDLE_LOCK_STATE");
- }
-}
-
-
-static void lockd_init_vconf(struct lockd_data *lockd)
-{
- int val = -1;
-
- if (vconf_notify_key_changed
- (VCONFKEY_PM_STATE, _lockd_notify_pm_state_cb_lite, lockd) != 0) {
- LOCKD_ERR("Fail vconf_notify_key_changed : VCONFKEY");
- }
-
- if (vconf_notify_key_changed
- (VCONFKEY_PM_LCDOFF_SOURCE, _lockd_notify_pm_lcdoff_cb_lite, lockd) != 0) {
- LOCKD_ERR("Fail vconf_notify_key_changed : VCONFKEY");
- }
-
- if (vconf_notify_key_changed
- (VCONFKEY_TELEPHONY_SIM_FACTORY_MODE, _lockd_notify_factory_mode_cb, NULL) != 0) {
- LOCKD_ERR("Fail vconf_notify_key_changed : VCONFKEY");
- }
-#if 0
- if (vconf_notify_key_changed
- (VCONFKEY_SYSTEM_TIME_CHANGED, _lockd_notify_time_changed_cb, NULL) != 0) {
- LOCKD_ERR("Fail vconf_notify_key_changed : VCONFKEY");
- }
-#endif
- if (vconf_notify_key_changed
- (VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION,
- _lockd_notify_phone_lock_verification_cb, lockd) != 0) {
- if (vconf_get_bool(VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION, &val) < 0) {
- LOCKD_ERR
- ("Cannot get VCONFKEY");
- vconf_set_bool(VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION, 0);
- if (vconf_notify_key_changed
- (VCONFKEY_LOCKSCREEN_PHONE_LOCK_VERIFICATION,
- _lockd_notify_phone_lock_verification_cb,
- lockd) != 0) {
- LOCKD_ERR
- ("Fail vconf_notify_key_changed " );
- }
- } else {
- LOCKD_ERR
- ("Fail vconf_notify_key_changed " );
- }
- }
-
- if (vconf_notify_key_changed
- (VCONFKEY_IDLE_LOCK_STATE,
- _lockd_notify_lock_state_cb,
- lockd) != 0) {
- LOCKD_ERR
- ("[Error] vconf notify : lock state");
- }
-}
-
-
-static Eina_Bool lockd_init_alarm(void *data)
-{
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- if(!lockd) {
- LOCKD_ERR("parameter is NULL");
- return EINA_FALSE;
- }
-
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- int ret_val = 0;
- /* alarm id initialize */
- lockd->alarm_id = -1;
-
- g_type_init();
- ret_val = alarmmgr_init(PACKAGE_NAME);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_init() failed(%d)", ret_val);
- return EINA_FALSE;
- }
- ret_val = alarmmgr_set_cb((alarm_cb_t)_lockd_lauch_other_lockscreen, lockd);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_init() failed");
- return EINA_FALSE;
- }
-
- LOCKD_DBG("alarm init success");
- return EINA_TRUE;
-}
-
-static int lockd_init_hall_signal(void *data)
-{
- E_DBus_Connection *conn;
- E_DBus_Signal_Handler *handler;
-
- struct lockd_data *lockd = (struct lockd_data *)data;
- if(!lockd) {
- LOCKD_ERR("parameter is NULL");
- return EINA_FALSE;
- }
-
- conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
- if (conn == NULL) {
- LOCKD_ERR("e_dbus_bus_get error");
- return -1;
- }
- lockd->hall_conn = conn;
-
-#if 0
- int r;
- r = e_dbus_request_name(conn, BUS_NAME, 0, NULL, NULL);
- if (!r) {
- LOCKD_ERR("e_dbus_request_name erro");
- return -1;
- }
-#endif
-
- handler = e_dbus_signal_handler_add(conn, NULL, DEVICED_PATH_HALL,
- DEVICED_INTERFACE_HALL, SIGNAL_HALL_STATE,
- _lockd_on_changed_receive, lockd);
- if (handler == NULL) {
- LOCKD_ERR("e_dbus_signal_handler_add error");
- return -1;
- }
- lockd->hall_handler = handler;
- /* S-Cover Lock : Signal <!-- END --> */
-}
-
-
-
-static Eina_Bool _lockd_launch_lockscreen_by_pwr_key(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- int idle_lock_state = VCONFKEY_IDLE_UNLOCK;
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- LOCKD_DBG("lcd off by powerkey");
-
- if (idle_lock_state == VCONFKEY_IDLE_UNLOCK) {
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD || lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD || lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SWIPE) {
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
- _lockd_request_PmQos(REQUEST_PMQOS_DURATION);
- }
- }
- lockd_launch_app_lockscreen_lite(lockd);
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-static void _lockd_receive_lcd_off(void *data, DBusMessage *msg)
-{
- DBusError err;
- int r;
- int idle_lock_state = VCONFKEY_IDLE_UNLOCK;
-
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- LOCKD_DBG("lcd off signal is received");
-
- r = dbus_message_is_signal(msg, DEVICED_INTERFACE_LCD_OFF, METHOD_LCD_OFF_NAME);
- if (!r) {
- LOCKD_ERR("dbus_message_is_signal error");
- return;
- }
-
- LOCKD_DBG("%s - %s", DEVICED_INTERFACE_LCD_OFF, METHOD_LCD_OFF_NAME);
-
-#if 0 //need to check if lockscreen is displayed before lcd off.
- idle_lock_state = lockd_get_lock_state();
-
- LOCKD_DBG("lcd off by powerkey");
-
- if (idle_lock_state == VCONFKEY_IDLE_UNLOCK) {
- if (lockd->lock_type == LOCK_TYPE_SECURITY || lockd->lock_type == LOCK_TYPE_NORMAL) {
- _lockd_request_PmQos(REQUEST_PMQOS_DURATION);
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
- }
- }
- lockd_launch_app_lockscreen_lite(lockd);
-#else
- ecore_idler_add(_lockd_launch_lockscreen_by_pwr_key, lockd);
-#endif
-}
-
-
-static int lockd_init_lcd_off_signal(void *data)
-{
- E_DBus_Connection *conn;
- E_DBus_Signal_Handler *handler;
-
- struct lockd_data *lockd = (struct lockd_data *)data;
- if(!lockd) {
- LOCKD_ERR("parameter is NULL");
- return EINA_FALSE;
- }
-
- conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
- if (conn == NULL) {
- LOCKD_ERR("e_dbus_bus_get error");
- return -1;
- }
- lockd->display_conn = conn;
-
- handler = e_dbus_signal_handler_add(conn, NULL, DEVICED_PATH_LCD_OFF,
- DEVICED_INTERFACE_LCD_OFF, METHOD_LCD_OFF_NAME,
- _lockd_receive_lcd_off, lockd);
- if (handler == NULL) {
- LOCKD_ERR("e_dbus_signal_handler_add error");
- return -1;
- }
- lockd->display_handler = handler;
-}
-
-void lockd_check_vconf_festival_wallpaper(void *data){
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
- int festival_wallpaper = 0;
-
- if(vconf_get_bool(VCONFKEY_LOCKSCREEN_FESTIVAL_WALLPAPER_DISPLAYING, &festival_wallpaper) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- festival_wallpaper = 0;
- }
- LOCKD_DBG("festival wallpaper : %d", festival_wallpaper);
- if(festival_wallpaper){
- bundle *b;
- b = bundle_create();
- if(b == NULL){
- LOCKD_ERR("bundle create failed.\n");
- return;
- }
- bundle_add(b, "popup_type", "festival");
- bundle_add(b, "festival_type", "festival_create");
- aul_launch_app(WALLPAPER_UI_SERVICE_PKG_NAME, b);
- bundle_free(b);
- }
-
-}
-
-static void _lockd_check_ongoing(bool ongoing)
-{
- if (ongoing) {
- /* check previous process */
- if (checkfd) {
- LOCKD_ERR("checkfd fail\n");
- return;
- }
-
- /* make tmp file */
- FILE *fp = fopen(PASSWORD_LOCK_PROGRESS, "w+");
- if (!fp) {
- LOCKD_ERR("Failed to open file : %s", PASSWORD_LOCK_PROGRESS);
- checkfd = 0;
- return;
- }
- LOCKD_WARN("make %s file\n", PASSWORD_LOCK_PROGRESS);
- checkfd = 1;
- fclose(fp);
- } else {
- if (!checkfd) return;
- if (unlink(PASSWORD_LOCK_PROGRESS) < 0)
- LOCKD_ERR("fail to remove %s file\n", PASSWORD_LOCK_PROGRESS);
- close(checkfd);
- checkfd = 0;
- LOCKD_WARN("delete %s file\n", PASSWORD_LOCK_PROGRESS);
- }
-}
-
-static void lockd_start_lock_daemon_lite(void *data)
-{
- struct lockd_data *lockd = NULL;
- int r = 0;
-
- lockd = (struct lockd_data *)data;
-
- if (!lockd) {
- return;
- }
-
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- lockd_process_mgr_init();
-
- /* init alarm manager */
-// lockd_check_vconf_festival_wallpaper(lockd);
-
- lockd->is_alarm = lockd_init_alarm(lockd);
-
-
- /* Initialize socket */
- r = lockd_init_sock(lockd);
- if (r < 0) {
- LOCKD_ERR("lockd init socket failed: %d", r);
- }
-
- /* Create internal 1x1 window */
- lockd->lockw = lockd_window_init();
-
- aul_listen_app_dead_signal(lockd_app_dead_cb_lite, data);
-}
-
-static Eina_Bool _lockd_check_wallpaper_service(void *data)
-{
- LOCKD_DBG("%s, %d", __func__, __LINE__);
- struct lockd_data *lockd = (struct lockd_data *)data;
- lockd_check_vconf_festival_wallpaper(lockd);
- return ECORE_CALLBACK_CANCEL;
-}
-
-
-int start_lock_daemon_lite(int launch_lock, int is_first_boot)
-{
- struct lockd_data *lockd = NULL;
- int recovery_state = -1;
- int lock_type = 0;
- int first_boot = 0;
- int ret = 0;
-
- LOCKD_DBG("%s, %d", __func__, __LINE__);
-
- lockd = (struct lockd_data *)malloc(sizeof(struct lockd_data));
- retv_if(!lockd, 0);
- memset(lockd, 0x0, sizeof(struct lockd_data));
- lockd_start_lock_daemon_lite(lockd);
-
- vconf_get_int(VCONFKEY_SETAPPL_SCREEN_LOCK_TYPE_INT, &lock_type);
- lockd->lock_type = lock_type;
- if(lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD || lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD){
- if(checkfd){
- _lockd_check_ongoing(EINA_FALSE);
- }
- else{
- _lockd_check_ongoing(EINA_TRUE);
- }
- }
-
- if (vconf_notify_key_changed
- (VCONFKEY_SETAPPL_SCREEN_LOCK_TYPE_INT, _lockd_notify_lock_type_changed_cb, lockd) != 0) {
- LOCKD_ERR("Fail vconf_notify_key_changed : VCONFKEY_SETAPPL_SCREEN_LOCK_TYPE_INT");
- }
-
- if (vconf_notify_key_changed
- (VCONFKEY_SYSTEM_TIME_CHANGED, _lockd_notify_time_changed_cb, NULL) != 0) {
- LOCKD_ERR("Fail vconf_notify_key_changed : VCONFKEY");
- }
-
- if (vconf_notify_key_changed
- (VCONFKEY_IDLE_LOCK_STATE,
- _lockd_notify_lock_state_cb,
- lockd) != 0) {
- LOCKD_ERR
- ("[Error] vconf notify : lock state");
- }
-
- lockd->back_to_app = FALSE;
-
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_NONE)
- return -1;
- if ((lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD) || (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD)) {
- if (vconf_get_int(VCONFKEY_EAS_RECOVERY_MODE, &recovery_state) < 0) {
- LOCKD_ERR("Cannot get vconfkey" );
- lockd->request_recovery = FALSE;
- } else if (recovery_state == 1) {
- LOCKD_DBG("recovery mode : %d \n", recovery_state);
- lockd->request_recovery = TRUE;
- } else {
- lockd->request_recovery = FALSE;
- }
- } else {
- lockd->request_recovery = FALSE;
- }
-
- vconf_set_bool(VCONFKEY_SAT_NORMAL_PRIORITY_AVAILABLE_BOOL, EINA_TRUE);
-
- if (launch_lock == FALSE) {
- LOCKD_ERR("Don't launch lockscreen..");
- ecore_idler_add(_lockd_check_wallpaper_service, lockd);
- return 0;
- }
-
- lockd->is_first_boot = is_first_boot;
- if (lockd->is_first_boot == TRUE){
- LOCKD_ERR("first_boot : %d \n", lockd->is_first_boot);
- lockd->start_ready = TRUE;
- ret = lockd_launch_app_lockscreen_lite(lockd);
- if(ret < 0){
- LOCKD_ERR("launch lockscreen failed. retry one more time.");
- ret = lockd_launch_app_lockscreen_lite(lockd);
- if(ret < 0){
- LOCKD_ERR("failed to launch lockscreen.");
- }
- }
- ecore_idler_add(_lockd_check_wallpaper_service, lockd);
- return 0;
- }
-
- if (lockd->lock_type == SETTING_SCREEN_LOCK_TYPE_OTHER) {
- lockd_init_vconf(lockd);
- ret = lockd_launch_app_other_lockscreen(lockd);
- if(ret < 0){
- LOCKD_ERR("launch 3rd party lockscreen failed. retry one more time.");
- ret = lockd_launch_app_other_lockscreen(lockd);
- if(ret < 0){
- LOCKD_ERR("failed to launch 3rd party lockscreen.");
- }
- }
- } else {
- ret = lockd_launch_app_lockscreen_lite(lockd);
- if(ret < 0){
- LOCKD_ERR("launch lockscreen failed. retry one more time.");
- ret = lockd_launch_app_lockscreen_lite(lockd);
- if(ret < 0){
- LOCKD_ERR("failed to launch lockscreen.");
- }
- }
- }
- ecore_idler_add(_lockd_check_wallpaper_service, lockd);
-
- if(feedback_initialize() != FEEDBACK_ERROR_NONE) {
- LOCKD_ERR("[CAUTION][ERROR] feedback_initialize() is failed..!!");
- }
-
- return ret;
-}
-
-
diff --git a/src/lock-daemon.c b/src/lock-daemon.c
deleted file mode 100755
index 5e79517..0000000
--- a/src/lock-daemon.c
+++ /dev/null
@@ -1,2125 +0,0 @@
-/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <Elementary.h>
-
-#include <vconf.h>
-#include <vconf-keys.h>
-
-#include <glib.h>
-#include <poll.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <sys/socket.h>
-#include <sys/un.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-#include <errno.h>
-#include <unistd.h>
-#include <sys/param.h>
-#include <errno.h>
-//#include <sensors.h>
-#include <feedback.h>
-#include <alarm.h>
-#include <time.h>
-#include <dd-deviced.h>
-#include <dd-display.h>
-#include <E_DBus.h>
-#include <aul.h>
-
-#ifndef FEATURE_LITE
-#include <context_manager.h>
-#endif
-
-#include "lockd-debug.h"
-#include "lock-daemon.h"
-#include "lockd-process-mgr.h"
-#include "lockd-window-mgr.h"
-#include "starter-util.h"
-#include "menu_daemon.h"
-#include "hw_key.h"
-#include "lockd-bt.h"
-#include "dbus-util.h"
-
-static int phone_lock_pid;
-static int auto_lock_pid;
-static bool lock_state_available = TRUE;
-
-struct lockd_data {
- int lock_app_pid;
- int phone_lock_app_pid;
- int lock_type; /* -1: None, 0:Normal, 1:Security, 2:Other */
- Eina_Bool is_sensor; /* EINA_TRUE : can use sensor EINA_FALSE : cannot use */
- Eina_Bool request_recovery;
- Eina_Bool back_to_app;
- lockw_data *lockw;
- GPollFD *gpollfd;
- Eina_Bool is_alarm; /* EINA_TRUE : can use alarm EINA_FALSE : cannot use */
- alarm_id_t alarm_id; /* -1 : None, others : set alarm */
- Eina_Bool is_first_boot; /* EINA_TRUE : first boot */
- int hall_status; /* 0: cover is closed, 1:cover is opened */
- E_DBus_Connection *hall_conn;
- E_DBus_Signal_Handler *hall_handler;
- E_DBus_Connection *display_conn;
- E_DBus_Signal_Handler *display_handler;
-
-};
-
-
-
-/* Local features*/
-#define _FEATURE_LCD_OFF_DBUS 0 //Check to apply lcd off dbus by PM part
-#define _FEATURE_SCOVER 0 //Scover view
-
-
-
-
-#define PHLOCK_SOCK_PREFIX "/tmp/phlock"
-#define PHLOCK_SOCK_MAXBUFF 65535
-
-#define VOLUNE_APP_CMDLINE "/usr/apps/com.samsung.volume/bin/volume" // LOCK_EXIT_CMD
-#define PHLOCK_APP_CMDLINE "/usr/apps/org.tizen.lockscreen/bin/lockscreen" //PHLOCK_UNLOCK_CMD
-#define MDM_APP_CMDLINE "/usr/bin/mdm-server" //PHLOCK_LAUNCH_CMD
-#define VOICE_CALL_APP_CMDLINE "/usr/apps/com.samsung.call/bin/calls" //HOME_RAISE_CMD, LOCK_SHOW_CMD
-#define VIDEO_CALL_APP_CMDLINE "/usr/apps/com.samsung.vtmain/bin/vtmain" //HOME_RAISE_CMD, LOCK_SHOW_CMD
-#define OMA_DRM_AGENT_CMDLINE "/usr/bin/oma-dm-agent" //PHLOCK_UNLOCK_RESET_CMD
-
-#define PHLOCK_UNLOCK_CMD "unlock"
-#define PHLOCK_LAUNCH_CMD "launch_phone_lock"
-#define PHLOCK_UNLOCK_RESET_CMD "unlock_reset"
-#define HOME_RAISE_CMD "raise_homescreen"
-#define LOCK_SHOW_CMD "show_lockscreen"
-#define LOCK_LAUNCH_CMD "launch_lockscreen"
-#define LOCK_EXIT_CMD "exit_lockscreen"
-
-#define LAUNCH_INTERVAL 100*1000
-
-#define HALL_COVERED_STATUS 0
-#define BUS_NAME "org.tizen.system.deviced"
-#define OBJECT_PATH "/Org/Tizen/System/DeviceD"
-#define INTERFACE_NAME BUS_NAME
-#define DEVICED_PATH_HALL OBJECT_PATH"/Hall"
-#define DEVICED_INTERFACE_HALL INTERFACE_NAME".hall"
-#define SIGNAL_HALL_STATE "ChangeState"
-#define METHOD_GET_STATUS "getstatus"
-#define DBUS_REPLY_TIMEOUT (120 * 1000)
-#define DEVICED_PATH_PMQOS OBJECT_PATH"/PmQos"
-#define DEVICED_INTERFACE_PMQOS INTERFACE_NAME".PmQos"
-#define METHOD_PMQOS_NAME "LockScreen"
-#define REQUEST_PMQOS_DURATION (2 * 1000)
-
-#define DEVICED_PATH_LCD_OFF OBJECT_PATH"/Display"
-#define DEVICED_INTERFACE_LCD_OFF INTERFACE_NAME".display"
-#define METHOD_LCD_OFF_NAME "LCDOffByPowerkey"
-
-#define VOLUME_PKG_NAME "org.tizen.volume"
-#define WALLPAPER_UI_SERVICE_PKG_NAME "com.samsung.wallpaper-ui-service"
-#define SHOW_LOCK "show_lock"
-#define ISTRUE "TRUE"
-#define SMART_ALERT_INTERVAL 0.5
-
-enum {
- LOCK_TYPE_NONE = -1,
- LOCK_TYPE_NORMAL = 0,
- LOCK_TYPE_SECURITY,
- LOCK_TYPE_AUTO_LOCK,
- LOCK_TYPE_OTHER,
- LOCK_TYPE_MAX
-};
-
-static int lockd_launch_app_lockscreen(struct lockd_data *lockd);
-static void lockd_unlock_lockscreen(struct lockd_data *lockd);
-#if 0
-static Eina_Bool lockd_start_sensor(void *data);
-static void lockd_stop_sensor(void *data);
-#endif
-
-static void _lockd_set_lock_state(int lock_state)
-{
- LOCKD_DBG("%s, %d, %d", __func__, __LINE__, lock_state);
- if(lock_state < VCONFKEY_IDLE_UNLOCK || lock_state > VCONFKEY_IDLE_LAUNCHING_LOCK) {
- LOCKD_ERR("Can't set lock_state : %d out of range", lock_state);
- } else {
- vconf_set_int(VCONFKEY_IDLE_LOCK_STATE, lock_state);
- }
-}
-
-static void _lockd_play_sound(bool unlock)
-{
- int ret = -1, val = 0;
- ret = vconf_get_bool(VCONFKEY_SETAPPL_SOUND_LOCK_BOOL, &val);
-
- if(ret == 0 && val == 1) {
- feedback_initialize();
- feedback_play_type(FEEDBACK_TYPE_SOUND, unlock ? FEEDBACK_PATTERN_UNLOCK : FEEDBACK_PATTERN_LOCK);
- }
-}
-
-int lockd_get_lock_type(void)
-{
- int lock_type = 0;
- int ret = 0;
-
- vconf_get_int(VCONFKEY_SETAPPL_SCREEN_LOCK_TYPE_INT, &lock_type);
-
- if (lock_type == SETTING_SCREEN_LOCK_TYPE_NONE) {
- ret = LOCK_TYPE_NONE;
- } else if (lock_type == SETTING_SCREEN_LOCK_TYPE_PASSWORD ||
- lock_type == SETTING_SCREEN_LOCK_TYPE_SIMPLE_PASSWORD ||
- lock_type == SETTING_SCREEN_LOCK_TYPE_FINGERPRINT ||
- lock_type == SETTING_SCREEN_LOCK_TYPE_FACE_AND_VOICE) {
- ret = LOCK_TYPE_SECURITY;
- } else if (lock_type == SETTING_SCREEN_LOCK_TYPE_SWIPE ||
- lock_type == SETTING_SCREEN_LOCK_TYPE_MOTION) {
- ret = LOCK_TYPE_NORMAL;
- } else if (lock_type == SETTING_SCREEN_LOCK_TYPE_AUTO_LOCK) {
- ret = LOCK_TYPE_AUTO_LOCK;
- } else {
- ret = LOCK_TYPE_OTHER;
- }
-
- LOCKD_DBG("lockd_get_lock_type ret(%d), lock_type (%d)", ret, lock_type);
-
- return ret;
-}
-
-static int _lockd_append_variant(DBusMessageIter *iter, const char *sig, char *param[])
-{
- char *ch;
- int i;
- int int_type;
- uint64_t int64_type;
-
- if (!sig || !param)
- return 0;
-
- for (ch = (char*)sig, i = 0; *ch != '\0'; ++i, ++ch) {
- switch (*ch) {
- case 'i':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &int_type);
- break;
- case 'u':
- int_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT32, &int_type);
- break;
- case 't':
- int64_type = atoi(param[i]);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT64, &int64_type);
- break;
- case 's':
- dbus_message_iter_append_basic(iter, DBUS_TYPE_STRING, &param[i]);
- break;
- default:
- return -EINVAL;
- }
- }
-
- return 0;
-}
-
-DBusMessage *_lockd_invoke_dbus_method_async(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- LOCKD_ERR("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- LOCKD_ERR("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _lockd_append_variant(&iter, sig, param);
- if (r < 0) {
- LOCKD_ERR("append_variant error(%d)", r);
- return NULL;
- }
-
- r = dbus_connection_send(conn, msg, NULL);
- dbus_message_unref(msg);
- if (r != TRUE) {
- LOCKD_ERR("dbus_connection_send error(%s:%s:%s-%s)", dest, path, interface, method);
- return -ECOMM;
- }
- LOCKD_DBG("dbus_connection_send, ret=%d", r);
- return NULL;
-}
-
-DBusMessage *_lockd_invoke_dbus_method_sync(const char *dest, const char *path,
- const char *interface, const char *method,
- const char *sig, char *param[])
-{
- DBusConnection *conn;
- DBusMessage *msg;
- DBusMessageIter iter;
- DBusMessage *reply;
- DBusError err;
- int r;
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, NULL);
- if (!conn) {
- LOCKD_ERR("dbus_bus_get error");
- return NULL;
- }
-
- msg = dbus_message_new_method_call(dest, path, interface, method);
- if (!msg) {
- LOCKD_ERR("dbus_message_new_method_call(%s:%s-%s)", path, interface, method);
- return NULL;
- }
-
- dbus_message_iter_init_append(msg, &iter);
- r = _lockd_append_variant(&iter, sig, param);
- if (r < 0) {
- LOCKD_ERR("append_variant error(%d)", r);
- return NULL;
- }
-
- dbus_error_init(&err);
-
- reply = dbus_connection_send_with_reply_and_block(conn, msg, DBUS_REPLY_TIMEOUT, &err);
- if (!reply) {
- LOCKD_ERR("dbus_connection_send error(No reply)");
- }
-
- if (dbus_error_is_set(&err)) {
- LOCKD_ERR("dbus_connection_send error(%s:%s)", err.name, err.message);
- reply = NULL;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- return reply;
-}
-
-int lockd_get_hall_status(void)
-{
- DBusError err;
- DBusMessage *msg;
- int ret, ret_val;
-
- LOCKD_DBG("[ == %s == ]", __func__);
- msg = _lockd_invoke_dbus_method_sync(BUS_NAME, DEVICED_PATH_HALL, DEVICED_INTERFACE_HALL,
- METHOD_GET_STATUS, NULL, NULL);
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &ret_val, DBUS_TYPE_INVALID);
- if (!ret) {
- LOCKD_ERR("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- LOCKD_DBG("%s-%s : %d", DEVICED_INTERFACE_HALL, METHOD_GET_STATUS, ret_val);
- return ret_val;
-}
-
-int lockd_get_lock_state(void)
-{
- int idle_lock_state = VCONFKEY_IDLE_UNLOCK;
-
- if (vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &idle_lock_state) < 0) {
- LOCKD_ERR("Cannot get VCONFKEY");
- idle_lock_state = VCONFKEY_IDLE_UNLOCK;
- }
- LOCKD_DBG("Get lock state : %d", idle_lock_state);
- return idle_lock_state;
-}
-
-static void _lockd_on_changed_receive(void *data, DBusMessage *msg)
-{
- DBusError err;
- char *str;
- int response;
- int r;
- int automatic_unlock = 0;
-
- struct lockd_data *lockd = (struct lockd_data *)data;
-
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- LOCKD_DBG("hall signal is received");
-
- r = dbus_message_is_signal(msg, DEVICED_INTERFACE_HALL, SIGNAL_HALL_STATE);
- if (!r) {
- LOCKD_ERR("dbus_message_is_signal error");
- return;
- }
-
- LOCKD_DBG("%s - %s", DEVICED_INTERFACE_HALL, SIGNAL_HALL_STATE);
-
- dbus_error_init(&err);
- r = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &response, DBUS_TYPE_INVALID);
- if (!r) {
- LOCKD_ERR("dbus_message_get_args error");
- return;
- }
-
- LOCKD_DBG("receive data : %d", response);
- lockd->hall_status = response;
-
-}
-
-static int _lockd_request_PmQos(int duration)
-{
- DBusError err;
- DBusMessage *msg;
- int ret, ret_val;
- char *arr[1];
- char val[32];
-
- snprintf(val, sizeof(val), "%d", duration);
- arr[0] = val;
-
- //msg = _lockd_invoke_dbus_method_sync(BUS_NAME, DEVICED_PATH_PMQOS, DEVICED_INTERFACE_PMQOS,
- // METHOD_PMQOS_NAME, "i", arr);
- msg = _lockd_invoke_dbus_method_async(BUS_NAME, DEVICED_PATH_PMQOS, DEVICED_INTERFACE_PMQOS,
- METHOD_PMQOS_NAME, "i", arr);
-
- if (!msg)
- return -EBADMSG;
-
- dbus_error_init(&err);
-
- ret = dbus_message_get_args(msg, &err, DBUS_TYPE_INT32, &ret_val, DBUS_TYPE_INVALID);
- if (!ret) {
- LOCKD_ERR("no message : [%s:%s]", err.name, err.message);
- ret_val = -EBADMSG;
- }
-
- dbus_message_unref(msg);
- dbus_error_free(&err);
-
- LOCKD_DBG("%s-%s : %d", DEVICED_INTERFACE_PMQOS, METHOD_PMQOS_NAME, ret_val);
- return ret_val;
-}
-
-static void _lockd_delete_alarm(alarm_id_t id, void * user_param)
-{
- int ret_val = ALARMMGR_RESULT_SUCCESS;
- LOCKD_DBG("Del alarm_id(%d)", id);
- ret_val = alarmmgr_remove_alarm(id);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_enum_alarm_ids() failed");
- }
-}
-
-static void _lockd_unset_alarms(void)
-{
- LOCKD_DBG("[ == %s == ]", __func__);
- int ret_val = ALARMMGR_RESULT_SUCCESS;
- ret_val = alarmmgr_enum_alarm_ids(_lockd_delete_alarm, NULL);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_enum_alarm_ids() failed");
- }
-}
-
-static void _lockd_lauch_lockscreen(alarm_id_t alarm_id, void *data)
-{
- struct lockd_data *lockd = (struct lockd_data *)data;
- if (lockd == NULL) {
- LOCKD_ERR("lockd is NULL");
- return;
- }
-
- int ret_val = ALARMMGR_RESULT_SUCCESS;
-
- LOCKD_DBG("[ == %s == ], alarm_id(%d)", __func__, alarm_id);
-
- display_lock_state(LCD_OFF, STAY_CUR_STATE, 0);
- lockd_launch_app_lockscreen(lockd);
-
- if(alarm_id != -1) {
- if(alarm_id != lockd->alarm_id) {
- LOCKD_ERR("alarm ids are different callback->id(%d), lockd->alarm_id(%d)", alarm_id, lockd->alarm_id);
- /* delete all registering alarm*/
- _lockd_unset_alarms();
- lockd->alarm_id = -1;
- } else {
- ret_val = alarmmgr_remove_alarm(alarm_id);
- if(ret_val != ALARMMGR_RESULT_SUCCESS) {
- LOCKD_ERR("alarmmgr_remove_alarm