OPTION(PROFILE_WEARABLE "Wearable device" ON)
ADD_DEFINITIONS("-DPROFILE_WEARABLE=\"${PROFILE_WEARABLE}\"")
ENDIF()
-IF(PROFILE STREQUAL tv)
- OPTION(PROFILE_TV "TV device" ON)
-ENDIF()
SET(COMMON_DIR "${CMAKE_SOURCE_DIR}/src/common")
SET(COMMON_SRCS
#include "popup-common.h"
#define APP_PID "_APP_PID_"
+#define APP_COMM "_APP_COMM_"
+#define REQ_ID "_REQUEST_ID_"
#define DBUS_POWER_PATH "/Org/Tizen/System/DeviceD/Power"
#define DBUS_POWER_IFACE "org.tizen.system.deviced.power"
static const struct popup_ops power_lock_expired_ops;
static bool signal_broadcasted;
+static char *request_id;
enum button_selected {
ALLOW_APP,
{
int ret;
char buf[8];
- char *param[1];
+ char *param[2];
if (signal_broadcasted)
return;
signal_broadcasted = true;
+ param[0] = request_id;
snprintf(buf, sizeof(buf), "%d", result);
- param[0] = buf;
+ param[1] = buf;
ret = broadcast_dbus_signal(DBUS_POWER_PATH,
DBUS_POWER_IFACE,
METHOD_POWER_LOCK_EXPIRED,
- "i", param);
+ "si", param);
if (ret < 0)
_E("FAIL: broadcast_dbus_signal(%d)", ret);
}
return -ENOENT;
}
+ request_id = (char *)bundle_get_val(obj->b, REQ_ID);
+ if (!request_id) {
+ _E("Failed to get request id");
+ return -ENOENT;
+ }
+
pid = atoi(pid_str);
ret = app_manager_get_app_id(pid, &name);
if (ret != APP_MANAGER_ERROR_NONE) {
- _E("Failed to get app name(%d)", ret);
+ name = (char *)bundle_get_val(obj->b, APP_COMM);
+ if (!name) {
+ _E("Failed to get app command");
return -ENOENT;
}
+ }
text = _("\"%s\" is using too much battery power. Close \"%s\" ?");
ptc->item_style = "padding";
ptc->func.del = NULL;
- utc->item_style = "1text.1icon.1";
+ utc->item_style = "1text.1icon";
utc->func.text_get = _gl_menu_text_get_airplane;
utc->func.content_get = _gl_menu_contents_get_airplane;
utc->func.del = NULL;