static int bezel_wakeup = true;
static int booting_check = true;
+static int is_lockscreen_enabled(void)
+{
+ int ret;
+ int enabled;
+
+ ret = vconf_get_int(VCONFKEY_IDLE_LOCK_STATE, &enabled);
+
+ return (ret == 0 && enabled) ? VCONFKEY_IDLE_LOCK : VCONFKEY_IDLE_UNLOCK;
+}
+
static inline int current_state_in_on(void)
{
int ret;
_E("pinput->value : %d", pinput->value);
if (pinput->value == KEY_PRESSED) {
/* Sound & Vibrate only in unlock state */
- if (__get_lock_screen_state() == VCONFKEY_IDLE_UNLOCK
- || get_lock_screen_bg_state())
+ if (is_lockscreen_enabled() == VCONFKEY_IDLE_UNLOCK)
sound_vibrate_hardkey();
} else if (pinput->value == KEY_RELEASED) {
/* if lockscreen is idle lock */
- if (__get_lock_screen_state() == VCONFKEY_IDLE_LOCK) {
+ if (is_lockscreen_enabled() == VCONFKEY_IDLE_LOCK) {
_D("Lock state, key backlight is off when phone is unlocked!");
return;
}