From 339d25470417e27188d570f69198f5e42ac61b73 Mon Sep 17 00:00:00 2001 From: Doyoun Kang Date: Mon, 11 Apr 2016 11:18:45 +0900 Subject: [PATCH] changed structure - Pol_Lockscreen_Info -> Pol_System_Info Change-Id: I7ade5fe22b27f2327a2cea5659d373456efa8e95 --- src/e_mod_main.c | 5 ++--- src/e_mod_main.h | 13 ++++++++----- src/e_mod_stack.c | 24 ++++++++++++------------ 3 files changed, 22 insertions(+), 20 deletions(-) diff --git a/src/e_mod_main.c b/src/e_mod_main.c index 72fd633..2f8dc12 100644 --- a/src/e_mod_main.c +++ b/src/e_mod_main.c @@ -11,10 +11,9 @@ E_API E_Module_Api e_modapi = { E_MODULE_API_VERSION, "Policy-Mobile" }; Mod *_pol_mod = NULL; Eina_Hash *hash_pol_desks = NULL; Eina_Hash *hash_pol_clients = NULL; -Pol_Lockscreen_Info g_lockscreen_info = +Pol_System_Info g_system_info = { - NULL, - EINA_FALSE + {NULL, EINA_FALSE}, }; static Eina_List *handlers = NULL; diff --git a/src/e_mod_main.h b/src/e_mod_main.h index 636d06b..ea6124a 100644 --- a/src/e_mod_main.h +++ b/src/e_mod_main.h @@ -18,7 +18,7 @@ typedef struct _Config_Desk Config_Desk; typedef struct _Config_Rot Config_Rot; typedef struct _Config Config; typedef struct _Mod Mod; -typedef struct _Pol_Lockscreen_Info Pol_Lockscreen_Info; +typedef struct _Pol_System_Info Pol_System_Info; struct _Pol_Desk { @@ -113,16 +113,19 @@ struct _E_Config_Dialog_Data Evas_Object *o_desks; }; -struct _Pol_Lockscreen_Info +struct _Pol_System_Info { - E_Client *ec; - Eina_Bool show; + struct + { + E_Client *ec; + Eina_Bool show; + } lockscreen; }; extern Mod *_pol_mod; extern Eina_Hash *hash_pol_desks; extern Eina_Hash *hash_pol_clients; -extern Pol_Lockscreen_Info g_lockscreen_info; +extern Pol_System_Info g_system_info; EINTERN void e_mod_pol_conf_init(Mod *mod); diff --git a/src/e_mod_stack.c b/src/e_mod_stack.c index 82945ec..99cf29b 100644 --- a/src/e_mod_stack.c +++ b/src/e_mod_stack.c @@ -315,21 +315,21 @@ e_mod_pol_stack_clients_restack_above_lockscreen(E_Client *ec_lock, Eina_Bool sh if (!new_lock) new_lock = ec_lock; - g_lockscreen_info.show = show; - g_lockscreen_info.ec = new_lock; + g_system_info.lockscreen.show = show; + g_system_info.lockscreen.ec = new_lock; restack_above = EINA_TRUE; } else { - if (ec_lock != g_lockscreen_info.ec) + if (ec_lock != g_system_info.lockscreen.ec) return; - new_lock = _e_mod_pol_stack_find_top_lockscreen(ec_lock, g_lockscreen_info.ec); + new_lock = _e_mod_pol_stack_find_top_lockscreen(ec_lock, g_system_info.lockscreen.ec); if (new_lock) { - g_lockscreen_info.show = EINA_TRUE; - g_lockscreen_info.ec = new_lock; + g_system_info.lockscreen.show = EINA_TRUE; + g_system_info.lockscreen.ec = new_lock; restack_above = EINA_TRUE; } else @@ -338,8 +338,8 @@ e_mod_pol_stack_clients_restack_above_lockscreen(E_Client *ec_lock, Eina_Bool sh Eina_List *restore_list = NULL; Eina_List *l = NULL; - g_lockscreen_info.show = show; - g_lockscreen_info.ec = NULL; + g_system_info.lockscreen.show = show; + g_system_info.lockscreen.ec = NULL; E_CLIENT_FOREACH(ec) { @@ -373,7 +373,7 @@ e_mod_pol_stack_clients_restack_above_lockscreen(E_Client *ec_lock, Eina_Bool sh { Eina_List *restack_list = NULL; Eina_List *l = NULL; - E_Layer lock_layer = g_lockscreen_info.ec->layer; + E_Layer lock_layer = g_system_info.lockscreen.ec->layer; Eina_Bool passed_new_lock = EINA_FALSE; int x, y, w, h; @@ -443,10 +443,10 @@ e_mod_pol_stack_check_above_lockscreen(E_Client *ec, E_Layer layer, E_Layer *new if (!ec->changable_layer[E_CHANGABLE_LAYER_TYPE_ABOVE_NOTIFICATION].set) return EINA_FALSE; - if (g_lockscreen_info.show && - g_lockscreen_info.ec) + if (g_system_info.lockscreen.show && + g_system_info.lockscreen.ec) { - lock_layer = g_lockscreen_info.ec->layer; + lock_layer = g_system_info.lockscreen.ec->layer; if (layer <= lock_layer) { if (ec->changable_layer[E_CHANGABLE_LAYER_TYPE_ABOVE_NOTIFICATION].saved == EINA_FALSE) -- 2.7.4