g_free(info);
}
+static void _send_app_gesture_support( const char* app_gesture_support )
+{
+ Eldbus_Connection *conn = NULL;
+ Eldbus_Object *dobj = NULL;
+ Eldbus_Proxy *proxy = NULL;
+
+ eldbus_init();
+ if ((conn = eldbus_connection_get(ELDBUS_CONNECTION_TYPE_SYSTEM)) != NULL) {
+ if ((dobj = eldbus_object_get(conn, E_A11Y_SERVICE_BUS_NAME, E_A11Y_SERVICE_NAVI_OBJ_PATH)) != NULL) {
+ if ((proxy = eldbus_proxy_get(dobj, E_A11Y_SERVICE_NAVI_IFC_NAME)) != NULL) {
+ eldbus_proxy_call(proxy, "AppGestureSupport", NULL, NULL, -1, "s", app_gesture_support);
+ }
+ else
+ ERROR("Failed to create proxy object for 'org.tizen.GestureNavigation'");
+ eldbus_object_unref(dobj);
+ }
+ else
+ ERROR("Failed to create eldbus object");
+ eldbus_connection_unref(conn);
+ }
+ else
+ ERROR("Connection to system bus failed");
+ eldbus_shutdown();
+
+}
+
+static void _check_app_gesture_support(AtspiAccessible *obj)
+{
+ Service_Data *sd = get_pointer_to_service_data_struct();
+ if (!sd) {
+ ERROR("Service Data is not available");
+ return;
+ }
+
+ GHashTable *hash_table = atspi_accessible_get_attributes(obj, NULL);
+ if (hash_table) {
+ gchar *app_gesture_support = g_hash_table_lookup(hash_table, "app_gesture_support");
+ if (app_gesture_support) {
+ if (sd->supported_gestures && g_strcmp0(app_gesture_support, sd->supported_gestures) != 0) {
+ _send_app_gesture_support(app_gesture_support);
+ g_free(sd->supported_gestures);
+ sd->supported_gestures = g_strdup(app_gesture_support);
+ }
+ }
+ else {
+ if ( !sd->supported_gestures || (sd->supported_gestures && g_strcmp0(sd->supported_gestures, "") != 0)) {
+ _send_app_gesture_support("");
+ g_free(sd->supported_gestures);
+ sd->supported_gestures = g_strdup("");
+ }
+ }
+ g_hash_table_unref(hash_table);
+ }
+ else
+ if ( !sd->supported_gestures || (sd->supported_gestures && g_strcmp0(sd->supported_gestures, "") == 0)) {
+ _send_app_gesture_support("");
+ g_free(sd->supported_gestures);
+ sd->supported_gestures = g_strdup("");
+ }
+}
+
static void _view_content_changed(AtspiAccessible *root, AtspiRole role, void *data, Eina_Bool default_label_enabled)
{
DEBUG("START");
default:
break;
}
+
+ _check_app_gesture_support(root);
+
if (sound_feedback)
smart_notification(WINDOW_STATE_CHANGE_NOTIFICATION_EVENT, 0, 0);
DEBUG("END");
}
#endif
-static void _send_app_gesture_support( const char* app_gesture_support )
-{
- Eldbus_Connection *conn = NULL;
- Eldbus_Object *dobj = NULL;
- Eldbus_Proxy *proxy = NULL;
-
- eldbus_init();
- if ((conn = eldbus_connection_get(ELDBUS_CONNECTION_TYPE_SYSTEM)) != NULL) {
- if ((dobj = eldbus_object_get(conn, E_A11Y_SERVICE_BUS_NAME, E_A11Y_SERVICE_NAVI_OBJ_PATH)) != NULL) {
- if ((proxy = eldbus_proxy_get(dobj, E_A11Y_SERVICE_NAVI_IFC_NAME)) != NULL) {
- eldbus_proxy_call(proxy, "AppGestureSupport", NULL, NULL, -1, "s", app_gesture_support);
- }
- else
- ERROR("Failed to create proxy object for 'org.tizen.GestureNavigation'");
- eldbus_object_unref(dobj);
- }
- else
- ERROR("Failed to create eldbus object");
- eldbus_connection_unref(conn);
- }
- else
- ERROR("Connection to system bus failed");
- eldbus_shutdown();
-
-}
-
-static void _check_app_gesture_support(AtspiAccessible *obj)
-{
- Service_Data *sd = get_pointer_to_service_data_struct();
- if (!sd) {
- ERROR("Service Data is not available");
- return;
- }
-
- GHashTable *hash_table = atspi_accessible_get_attributes(obj, NULL);
- if (hash_table) {
- gchar *app_gesture_support = g_hash_table_lookup(hash_table, "app_gesture_support");
- if (app_gesture_support) {
- if (sd->supported_gestures && g_strcmp0(app_gesture_support, sd->supported_gestures) != 0) {
- _send_app_gesture_support(app_gesture_support);
- g_free(sd->supported_gestures);
- sd->supported_gestures = g_strdup(app_gesture_support);
- }
- }
- else {
- if ( !sd->supported_gestures || (sd->supported_gestures && g_strcmp0(sd->supported_gestures, "") != 0)) {
- _send_app_gesture_support("");
- g_free(sd->supported_gestures);
- sd->supported_gestures = g_strdup("");
- }
- }
- g_hash_table_unref(hash_table);
- }
- else
- if ( !sd->supported_gestures || (sd->supported_gestures && g_strcmp0(sd->supported_gestures, "") == 0)) {
- _send_app_gesture_support("");
- g_free(sd->supported_gestures);
- sd->supported_gestures = g_strdup("");
- }
-}
-
static Eina_Bool _window_need_to_be_purged(Window_Info *wi)
{
if (!wi->window || object_has_defunct_state(wi->window)) {
g_free(name);
return;
}
-
- _check_app_gesture_support(event->source);
-
_window_append(event->source, EINA_TRUE, EINA_FALSE, window_activate_info_type);
subroot = NULL; //No need to keep subroot if any window gets activated
} else if (!g_strcmp0(event->type, "window:deactivate")) {