diff options
author | Mun, Gwan-gyeong <kk.moon@samsung.com> | 2014-12-02 19:28:23 +0900 |
---|---|---|
committer | Mun, Gwan-gyeong <kk.moon@samsung.com> | 2014-12-02 23:08:28 +0900 |
commit | 809c84e26a75884edc15be34de493f1665c42bb6 (patch) | |
tree | c75c3cd6d8bbce370c1088e4ce160802ae10e9ae /illume2-tizen | |
parent | 00375af2ad6d4196e21b1f6bc990cebfb6ef33b9 (diff) | |
download | e17-extra-modules-tizen.tar.gz e17-extra-modules-tizen.tar.bz2 e17-extra-modules-tizen.zip |
Apply build option to tizen 3.0
Change-Id: I626b304e38ccacd457359fc8e954b747f21d6646
Diffstat (limited to 'illume2-tizen')
-rw-r--r-- | illume2-tizen/src/e_illume.c | 19 | ||||
-rw-r--r-- | illume2-tizen/src/e_illume.h | 1 | ||||
-rw-r--r-- | illume2-tizen/src/e_mod_policy.c | 6 | ||||
-rw-r--r-- | illume2-tizen/src/policies/illume/illume.c | 2 | ||||
-rw-r--r-- | illume2-tizen/src/policies/illume/policy.c | 252 | ||||
-rw-r--r-- | illume2-tizen/src/policies/illume/policy.h | 3 |
6 files changed, 223 insertions, 60 deletions
diff --git a/illume2-tizen/src/e_illume.c b/illume2-tizen/src/e_illume.c index 64fc746..39326fe 100644 --- a/illume2-tizen/src/e_illume.c +++ b/illume2-tizen/src/e_illume.c @@ -864,6 +864,25 @@ e_illume_border_is_app_selector(E_Border *bd) } EAPI Eina_Bool +e_illume_border_is_app_popup(E_Border *bd) +{ + const char *name = NULL; + const char *clas = NULL; + + if (!bd) return EINA_FALSE; + + name = bd->client.icccm.name; + clas = bd->client.icccm.class; + + if (clas == NULL) return EINA_FALSE; + if (strncmp(clas,"APP_POPUP", strlen("APP_POPUP"))!= 0) return EINA_FALSE; + if (name == NULL) return EINA_FALSE; + if (strncmp(name,"APP_POPUP", strlen("APP_POPUP"))!= 0) return EINA_FALSE; + + return EINA_TRUE; +} + +EAPI Eina_Bool e_illume_border_is_fixed(E_Border *bd) { int min_w = 0, min_h = 0; diff --git a/illume2-tizen/src/e_illume.h b/illume2-tizen/src/e_illume.h index 0586bf4..2389680 100644 --- a/illume2-tizen/src/e_illume.h +++ b/illume2-tizen/src/e_illume.h @@ -408,6 +408,7 @@ EAPI Eina_Bool e_illume_border_is_lock_screen(E_Border *bd); EAPI Eina_Bool e_illume_border_is_notification(E_Border *bd); EAPI Eina_Bool e_illume_border_is_utility(E_Border *bd); EAPI Eina_Bool e_illume_border_is_clipboard(E_Border *bd); +EAPI Eina_Bool e_illume_border_is_app_popup(E_Border *bd); EAPI void e_illume_border_min_get(E_Border *bd, int *w, int *h); EAPI void e_illume_border_max_get(E_Border *bd, int *w, int *h); diff --git a/illume2-tizen/src/e_mod_policy.c b/illume2-tizen/src/e_mod_policy.c index ffccc32..e32f6e4 100644 --- a/illume2-tizen/src/e_mod_policy.c +++ b/illume2-tizen/src/e_mod_policy.c @@ -32,7 +32,9 @@ static void _e_mod_policy_cb_hook_new_border(void *data __UNUSED__, void *data2) #ifdef _F_BORDER_HOOK_PATCH_ static void _e_mod_policy_cb_hook_del_border(void *data __UNUSED__, void *data2); #endif +#ifdef _F_ZONE_WINDOW_ROTATION_ static void _e_mod_policy_cb_hook_rotation_list_add(void *data __UNUSED__, void *data2); +#endif static Eina_Bool _e_mod_policy_cb_window_focus_in(void *data __UNUSED__, int type __UNUSED__, void *event); @@ -469,10 +471,12 @@ _e_mod_policy_hooks_add(void) e_border_hook_add(E_BORDER_HOOK_DEL_BORDER, _e_mod_policy_cb_hook_del_border, NULL)); #endif +#ifdef _F_ZONE_WINDOW_ROTATION_ _policy_hooks = eina_list_append(_policy_hooks, e_border_hook_add(E_BORDER_HOOK_ROTATION_LIST_ADD, _e_mod_policy_cb_hook_rotation_list_add, NULL)); +#endif } static void @@ -1127,6 +1131,7 @@ _e_mod_policy_cb_idle_enterer(void *data __UNUSED__) return ECORE_CALLBACK_RENEW; } +#ifdef _F_ZONE_WINDOW_ROTATION_ static void _e_mod_policy_cb_hook_rotation_list_add(void *data __UNUSED__, void *data2) { @@ -1136,3 +1141,4 @@ _e_mod_policy_cb_hook_rotation_list_add(void *data __UNUSED__, void *data2) if ((_policy) && (_policy->funcs.rotation_list_add)) _policy->funcs.rotation_list_add(bd); } +#endif diff --git a/illume2-tizen/src/policies/illume/illume.c b/illume2-tizen/src/policies/illume/illume.c index e518200..b1896cf 100644 --- a/illume2-tizen/src/policies/illume/illume.c +++ b/illume2-tizen/src/policies/illume/illume.c @@ -71,7 +71,9 @@ e_illume_policy_init(E_Illume_Policy *p) p->funcs.illume_win_state_change_request = _policy_illume_win_state_change_request; +#ifdef _F_ZONE_WINDOW_ROTATION_ p->funcs.rotation_list_add = _policy_border_hook_rotation_list_add; +#endif if (!_policy_init()) return 0; diff --git a/illume2-tizen/src/policies/illume/policy.c b/illume2-tizen/src/policies/illume/policy.c index c3f9f4d..a2728f4 100644 --- a/illume2-tizen/src/policies/illume/policy.c +++ b/illume2-tizen/src/policies/illume/policy.c @@ -170,8 +170,10 @@ static void _policy_border_uniconify_below_borders(E_Border *bd); static void _policy_border_uniconify_top_border(E_Border *bd); /* for supporting rotation */ +#ifdef _F_ZONE_WINDOW_ROTATION_ static void _policy_border_dependent_rotation(E_Border *bd, int rotation); static Eina_Bool _policy_dependent_rotation_check(E_Border *bd, int rotation); +#endif static int _prev_angle_get(Ecore_X_Window win); @@ -864,7 +866,17 @@ _policy_border_del(E_Border *bd) e_illume_border_is_app_tray(bd) || e_illume_border_is_miniapp_tray(bd))) { - _policy_border_uniconify_below_borders_by_illume(xwin_info); + if (E_CONTAINS(bd->x, bd->y, bd->w, bd->h, bd->zone->x, bd->zone->y, bd->zone->w, bd->zone->h)) + { + _policy_border_uniconify_below_borders_by_illume(xwin_info); + } + } + else + { + if (E_CONTAINS(bd->x, bd->y, bd->w, bd->h, bd->zone->x, bd->zone->y, bd->zone->w, bd->zone->h)) + { + _policy_border_uniconify_below_borders_by_illume(xwin_info); + } } } @@ -946,7 +958,8 @@ _policy_border_del(E_Border *bd) e_illume_border_is_miniapp_tray(bd) || (bd->client.illume.win_state.state == ECORE_X_ILLUME_WINDOW_STATE_FLOATING) || e_illume_border_is_syspopup(bd) || - e_illume_border_is_app_selector(bd)) + e_illume_border_is_app_selector(bd) || + e_illume_border_is_app_popup(bd)) dep_rot.list = eina_list_remove(dep_rot.list, bd); if (dep_rot.refer.active_bd == bd) @@ -1047,21 +1060,22 @@ _policy_border_post_fetch(E_Border *bd) } #endif +#ifdef _F_ZONE_WINDOW_ROTATION_ // for supporting rotation such as quickpanel if (e_illume_border_is_quickpanel(bd) || e_illume_border_is_miniapp_tray(bd) || (bd->client.illume.win_state.state == ECORE_X_ILLUME_WINDOW_STATE_FLOATING) || e_illume_border_is_syspopup(bd) || - e_illume_border_is_app_selector(bd)) + e_illume_border_is_app_selector(bd) || + e_illume_border_is_app_popup(bd)) { - bd->client.e.state.rot.type = E_BORDER_ROTATION_TYPE_DEPENDENT; + int ang = -1; + int next_ang = 0; // TODO: what to do if rotation fetch is changed? if (!eina_list_data_find(dep_rot.list, bd)) { - int ang = -1; - int next_ang = 0; - + bd->client.e.state.rot.type = E_BORDER_ROTATION_TYPE_DEPENDENT; if (bd->new_client) { ang = _prev_angle_get(bd->client.win); @@ -1069,20 +1083,22 @@ _policy_border_post_fetch(E_Border *bd) bd->client.e.state.rot.curr = ang; } dep_rot.list = eina_list_append(dep_rot.list, bd); + } - if (dep_rot.refer.active_bd) next_ang = dep_rot.refer.active_bd->client.e.state.rot.curr; - else next_ang = dep_rot.ang; + // WORKAROUND: event if any property changes, E will check rotation state. + if (dep_rot.refer.active_bd) next_ang = dep_rot.refer.active_bd->client.e.state.rot.curr; + else next_ang = dep_rot.ang; - if (next_ang != bd->client.e.state.rot.curr) - { - // if this border's new_client flag is set, - // this border's show time should be posted until done of rotation. - // will call "e_border_rotation_set" in main eval of e17 - if (_policy_dependent_rotation_check(bd, next_ang)) - bd->client.e.state.rot.changes = next_ang; - } + if (next_ang != bd->client.e.state.rot.curr) + { + // if this border's new_client flag is set, + // this border's show time should be posted until done of rotation. + // will call "e_border_rotation_set" in main eval of e17 + if (_policy_dependent_rotation_check(bd, next_ang)) + bd->client.e.state.rot.changes = next_ang; } } +#endif /* tell E the border has changed */ bd->client.border.changed = 1; @@ -1168,6 +1184,19 @@ _policy_border_pre_fetch(E_Border *bd) xwin_info = _policy_xwin_info_find(bd->win); transient_for_win = ecore_x_icccm_transient_for_get(bd->client.win); + if (transient_for_win) + { + bd_parent = e_border_find_by_client_window(transient_for_win); + } + + transient_each_other = _check_parent_in_transient_for_tree(bd, bd_parent); + if (transient_each_other) + { + ELBF(ELBT_ILLUME, 0, bd->client.win, "TRANSEINT_FOR each other.. transient_for:0x%07x. IGNORE...", transient_for_win); + bd->client.icccm.transient_for = transient_for_win; + goto transient_fetch_done; + } + if (bd->client.icccm.transient_for == transient_for_win) { if (!bd->parent) @@ -1177,10 +1206,6 @@ _policy_border_pre_fetch(E_Border *bd) } bd->client.icccm.transient_for = transient_for_win; - if (bd->client.icccm.transient_for) - { - bd_parent = e_border_find_by_client_window(bd->client.icccm.transient_for); - } /* If we already have a parent, remove it */ if (bd->parent) @@ -1188,46 +1213,45 @@ _policy_border_pre_fetch(E_Border *bd) #ifdef _F_DEICONIFY_APPROVE_ if (bd_parent == bd->parent) change_parent = EINA_FALSE; #endif - bd->parent->transients = eina_list_remove(bd->parent->transients, bd); - if (bd->parent->modal == bd) bd->parent->modal = NULL; + if (!e_object_is_del(E_OBJECT(bd->parent))) + { + bd->parent->transients = eina_list_remove(bd->parent->transients, bd); + if (bd->parent->modal == bd) bd->parent->modal = NULL; + } bd->parent = NULL; } L(LT_TRANSIENT_FOR, "[ILLUME2][TRANSIENT_FOR] %s(%d)... win:0x%07x, parent:0x%07x\n", __func__, __LINE__, bd->client.win, bd->client.icccm.transient_for); if (bd_parent) { - transient_each_other = _check_parent_in_transient_for_tree(bd, bd_parent); - if (!transient_each_other) + L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d).. win:0x%07x(iconic:%d, by_wm:%d), parent:0x%07x(iconic:%d)\n", __func__, __LINE__, bd->client.win, bd->iconic, xwin_info ? xwin_info->iconify_by_wm : -100, bd_parent->client.win, bd_parent->iconic); + if (_e_illume_cfg->use_force_iconify) { - L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d).. win:0x%07x(iconic:%d, by_wm:%d), parent:0x%07x(iconic:%d)\n", __func__, __LINE__, bd->client.win, bd->iconic, xwin_info ? xwin_info->iconify_by_wm : -100, bd_parent->client.win, bd_parent->iconic); - if (_e_illume_cfg->use_force_iconify) + if (!bd_parent->iconic) { - if (!bd_parent->iconic) + if (xwin_info && xwin_info->iconify_by_wm) { - if (xwin_info && xwin_info->iconify_by_wm) + if (bd->iconic) { - if (bd->iconic) - { - L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d).. FORCE UNICONIFY... win:0x%07x\n", __func__, __LINE__, bd->client.win); - _policy_border_force_uniconify(bd); - } + L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d).. FORCE UNICONIFY... win:0x%07x\n", __func__, __LINE__, bd->client.win); + _policy_border_force_uniconify(bd); } } } + } - if (bd_parent != bd) - { - bd->parent = bd_parent; - _policy_border_transient_for_layer_set(bd, bd->parent, bd->parent->layer); - bd_parent->transients = eina_list_append(bd_parent->transients, bd); + if (bd_parent != bd) + { + bd->parent = bd_parent; + _policy_border_transient_for_layer_set(bd, bd->parent, bd->parent->layer); + bd_parent->transients = eina_list_append(bd_parent->transients, bd); - if ((e_config->modal_windows) && (bd->client.netwm.state.modal)) - bd->parent->modal = bd; + if ((e_config->modal_windows) && (bd->client.netwm.state.modal)) + bd->parent->modal = bd; - if (e_config->focus_setting == E_FOCUS_NEW_DIALOG || - (bd->parent->focused && (e_config->focus_setting == E_FOCUS_NEW_DIALOG_IF_OWNER_FOCUSED))) - bd->take_focus = 1; - } + if (e_config->focus_setting == E_FOCUS_NEW_DIALOG || + (bd->parent->focused && (e_config->focus_setting == E_FOCUS_NEW_DIALOG_IF_OWNER_FOCUSED))) + bd->take_focus = 1; } } @@ -1344,7 +1368,7 @@ _policy_border_show(E_Border *bd) if (!bd) return; /* make sure we have a name so that we don't handle windows like E's root */ - if (!bd->client.icccm.name) return; +// if (!bd->client.icccm.name) return; // printf("Border Show: %s\n", bd->client.icccm.class); @@ -1377,6 +1401,7 @@ _policy_border_show(E_Border *bd) return; } +#ifdef _F_ZONE_WINDOW_ROTATION_ if (eina_list_data_find(dep_rot.list, bd) == bd) { int next_ang = 0; @@ -1387,6 +1412,7 @@ _policy_border_show(E_Border *bd) if (bd->client.e.state.rot.curr != next_ang) e_border_rotation_set(bd, next_ang); } +#endif } void @@ -1973,7 +1999,7 @@ static void _policy_property_window_state_change (Ecore_X_Event_Window_Property * but do not have a name/class associated with them. Not entirely sure * which ones they are, but I would guess Managers, Containers, or Zones. * At any rate, we're not interested in those types of borders */ - if ((!bd->client.icccm.name) || (!bd->client.icccm.class)) return; +// if ((!bd->client.icccm.name) || (!bd->client.icccm.class)) return; /* NB: If we have reached this point, then it should be a fullscreen * border that has toggled fullscreen on/off */ @@ -2557,6 +2583,7 @@ _policy_border_illume_window_state_change(E_Border *bd, unsigned int state) _policy_border_indicator_control(indi_bd); } +#ifdef _F_ZONE_WINDOW_ROTATION_ // will be check below condition as new_client in post_fetch time, // so skip here. if ((!bd->new_client) && @@ -2573,6 +2600,7 @@ _policy_border_illume_window_state_change(E_Border *bd, unsigned int state) if (next_ang != bd->client.e.state.rot.curr) e_border_rotation_set(bd, next_ang); } +#endif break; case ECORE_X_ILLUME_WINDOW_STATE_NORMAL: @@ -2597,11 +2625,13 @@ _policy_border_illume_window_state_change(E_Border *bd, unsigned int state) _policy_border_indicator_control(indi_bd); } +#ifdef _F_ZONE_WINDOW_ROTATION_ if (eina_list_data_find(dep_rot.list, bd) == bd) { bd->client.e.state.rot.type = E_BORDER_ROTATION_TYPE_NORMAL; dep_rot.list = eina_list_remove(dep_rot.list, bd); } +#endif break; } bd->changes.size = 1; @@ -4634,12 +4664,13 @@ _policy_send_visibility_notify (Ecore_X_Window win, int visibility) } static Eina_Bool -_policy_check_transient_child_visible(E_Border *bd) +_policy_check_transient_child_visible(E_Border *ancestor_bd, E_Border *bd) { Eina_Bool ret = EINA_FALSE; E_Illume_XWin_Info *child_xwin_info = NULL; Eina_List *l; E_Border *child = NULL; + if (!ancestor_bd) return EINA_FALSE; EINA_LIST_FOREACH(bd->transients, l, child) { @@ -4649,7 +4680,25 @@ _policy_check_transient_child_visible(E_Border *bd) child_xwin_info = _policy_xwin_info_find(child->win); if (child_xwin_info) { - if (child_xwin_info->skip_iconify != EINA_TRUE) + if (child_xwin_info->skip_iconify == EINA_TRUE) + { + // special window especially keyboard, keyboard sub + if (child_xwin_info->visibility == E_ILLUME_VISIBILITY_UNOBSCURED) + { + return EINA_TRUE; + } + else + { + if (!child->iconic) + { + if (E_CONTAINS(child->x, child->y, child->w, child->h, ancestor_bd->x, ancestor_bd->y, ancestor_bd->w, ancestor_bd->h)) + { + return EINA_TRUE; + } + } + } + } + else { if ((child_xwin_info->visibility == E_ILLUME_VISIBILITY_UNOBSCURED) || (!child->iconic)) @@ -4663,7 +4712,7 @@ _policy_check_transient_child_visible(E_Border *bd) if (!child->iconic) return EINA_TRUE; } - ret = _policy_check_transient_child_visible(child); + ret = _policy_check_transient_child_visible(ancestor_bd, child); } return ret; @@ -4693,6 +4742,7 @@ _policy_calculate_visibility(void) int set_root_angle = 0; int control_indi = 0; E_Illume_XWin_Info *above_xwin_info = NULL; + Ecore_X_Window above_xwin = 0; if (!_g_visibility_changed) return; _g_visibility_changed = EINA_FALSE; @@ -4726,8 +4776,6 @@ _policy_calculate_visibility(void) if ((xwin_info->viewable == 0) && (xwin_info->iconify_by_wm == 0)) continue; - if (xwin_info->iconic) continue; - if (!xwin_info->is_drawed) continue; // initializing variable @@ -4740,6 +4788,16 @@ _policy_calculate_visibility(void) bd_info = xwin_info->bd_info; if (bd_info) bd = bd_info->border; + // the illume's policy of iconify should be applied to window belonging mobile side. + // so, there is no need to calculate visibility. + if ((bd) && (!E_ILLUME_BORDER_IS_IN_MOBILE(bd))) continue; + + if (xwin_info->iconic && (!xwin_info->iconify_by_wm)) + { + if (bd) goto check_above; + else continue; + } + // 1. calculates window's region and decide it's visibility. if (is_fully_obscured == EINA_FALSE) { @@ -4773,6 +4831,11 @@ _policy_calculate_visibility(void) is_opaque_win = EINA_FALSE; } } + else if (e_illume_border_is_app_tray(bd) || + e_illume_border_is_miniapp_tray(bd)) + { + alpha_opaque = EINA_TRUE; + } if (bd->client.illume.win_state.state == ECORE_X_ILLUME_WINDOW_STATE_FLOATING) @@ -4786,6 +4849,14 @@ _policy_calculate_visibility(void) is_opaque_win = EINA_FALSE; } + if (win_rect.x != visible_rect.x || + win_rect.y != visible_rect.y || + win_rect.width != visible_rect.width || + win_rect.height != visible_rect.height) + { + is_opaque_win = EINA_FALSE; + } + if (is_opaque_win) { win_region = ecore_x_xregion_new(); @@ -4822,7 +4893,6 @@ _policy_calculate_visibility(void) } if (!bd) continue; - if (!E_ILLUME_BORDER_IS_IN_MOBILE(bd)) continue; // decide if it's the border that DO NOT iconify. if (obscured_by_alpha_opaque) @@ -4836,7 +4906,7 @@ _policy_calculate_visibility(void) // DO NOT iconify this border. else if (bd->transients) { - do_not_iconify = _policy_check_transient_child_visible(bd); + do_not_iconify = _policy_check_transient_child_visible(bd, bd); L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d).. win:0x%07x. Do_not_iconify:%d\n", __func__, __LINE__, xwin_info->bd_info->border->client.win, do_not_iconify); } @@ -4914,6 +4984,15 @@ _policy_calculate_visibility(void) } } } + /* check old above win */ + else if (xwin_info->above_xwin != above_xwin) + { + if (!bd->iconic && !do_not_iconify && !xwin_info->skip_iconify) + { + L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d).. Iconify by illume.. win:0x%07x\n", __func__, __LINE__, xwin_info->bd_info->border->client.win); + _policy_border_iconify_by_illume(xwin_info); + } + } } } } @@ -4933,7 +5012,11 @@ _policy_calculate_visibility(void) } } +check_above: + xwin_info->above_xwin = above_xwin; + above_xwin_info = xwin_info; + above_xwin = bd->client.win; } if (control_indi) @@ -5088,7 +5171,7 @@ void _policy_window_destroy (Ecore_X_Event_Window_Destroy *event) // for supporting dependent rotation if (dep_rot.refer.cmd_win == event->win) - dep_rot.refer.cmd_win = NULL; + dep_rot.refer.cmd_win = 0; } @@ -5471,9 +5554,10 @@ _policy_change_root_angle_by_border_angle (E_Border* bd) // make rotation request for the dependent windows such as quickpanel int ang = _policy_window_rotation_angle_get(bd->client.win); if (ang == -1) ang = 0; - +#ifdef _F_ZONE_WINDOW_ROTATION_ if (dep_rot.ang != ang) _policy_border_dependent_rotation(bd, ang); +#endif } } @@ -6062,7 +6146,10 @@ void _policy_border_iconify_cb(E_Border *bd) E_Illume_XWin_Info* xwin_info = _policy_xwin_info_find(bd->win); if (xwin_info == NULL) return; - _policy_border_uniconify_below_borders_by_illume(xwin_info); + if (E_CONTAINS(bd->x, bd->y, bd->w, bd->h, bd->zone->x, bd->zone->y, bd->zone->w, bd->zone->h)) + { + _policy_border_uniconify_below_borders_by_illume(xwin_info); + } if (xwin_info->visibility != E_ILLUME_VISIBILITY_FULLY_OBSCURED) { @@ -6192,6 +6279,8 @@ _policy_border_iconify_by_illume(E_Illume_XWin_Info *xwin_info) if (!E_ILLUME_BORDER_IS_IN_MOBILE(bd)) return; if (e_object_is_del(E_OBJECT(bd))) return; + if (!bd->visible) return; + if ((xwin_info->visibility != E_ILLUME_VISIBILITY_FULLY_OBSCURED) && (bd->parent && (!bd->parent->iconic))) return; @@ -6236,6 +6325,13 @@ static void _policy_border_force_uniconify(E_Border *bd) E_OBJECT_CHECK(bd); E_OBJECT_TYPE_CHECK(bd, E_BORDER_TYPE); + if (bd->client.e.state.deiconify_approve.wait_timer || + bd->client.e.state.deiconify_approve.pending_job) + { + ELB(ELBT_BD, "DEICONIFY_APPROVE is already running", bd->client.win); + return; + } + xwin_info = _policy_xwin_info_find(bd->win); if (!(xwin_info && xwin_info->iconify_by_wm)) return; @@ -6302,7 +6398,11 @@ _policy_border_uniconify_below_borders_by_illume(E_Illume_XWin_Info *xwin_info) if (xwin_info->iconify_by_wm) return; // 2. check if current bd's visibility is fully-obscured or not - if (xwin_info->visibility == E_ILLUME_VISIBILITY_FULLY_OBSCURED) return; + if (xwin_info->visibility == E_ILLUME_VISIBILITY_FULLY_OBSCURED && + bd->iconic) + { + return; + } // 3-1. find bd's below window and un-iconify it L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d)... UNICONIFY Below Windows of win:0x%07x\n", __func__, __LINE__, bd->client.win); @@ -6377,6 +6477,8 @@ static E_Border* _policy_border_find_below(E_Border *bd) if (e_illume_border_is_app_tray(b)) continue; if (e_illume_border_is_miniapp_tray(b)) continue; + if (!ecore_x_window_visible_get(b->client.win)) continue; + return b; } } @@ -6448,10 +6550,36 @@ static void _policy_border_uniconify_top_border(E_Border *bd) if (e_illume_border_is_app_tray(b)) continue; if (e_illume_border_is_miniapp_tray(b)) continue; + if (!ecore_x_window_visible_get(b->client.win)) continue; + if (b->iconic) { - L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d).. FORCE UNICONIFY... win:0x%07x\n", __func__, __LINE__, b->client.win); - _policy_border_force_uniconify(b); + E_Border *parent_bd; + E_Border *target_bd; + E_Illume_XWin_Info *parent_xwin_info; + + target_bd = b; + parent_bd = b->parent; + + while (parent_bd) + { + if (e_object_is_del(E_OBJECT(parent_bd))) break; + + if (parent_bd->iconic) + { + parent_xwin_info = _policy_xwin_info_find(parent_bd->win); + if (!(parent_xwin_info && parent_xwin_info->iconify_by_wm)) + { + break; + } + + target_bd = parent_bd; + } + parent_bd = parent_bd->parent; + } + + L(LT_ICONIFY, "[ILLUME2][ICONIFY] %s(%d).. FORCE UNICONIFY... target win:0x%07x (win:0x%07x)\n", __func__, __LINE__, target_bd->client.win, b->client.win); + _policy_border_force_uniconify(target_bd); } if ((b->x == b->zone->x) && @@ -6613,6 +6741,7 @@ fin: return; } +#ifdef _F_ZONE_WINDOW_ROTATION_ /* for supporting rotation */ void _policy_border_hook_rotation_list_add(E_Border *bd) @@ -6692,6 +6821,7 @@ end: "[DEPENDENT] Couldn't or don't need to rotate it as given angle:%d", rotation); return ret; } +#endif static void _policy_property_indicator_cmd_win_change(Ecore_X_Event_Window_Property *event) @@ -6770,9 +6900,11 @@ _policy_property_active_indicator_win_change(Ecore_X_Event_Window_Property *even ELBF(ELBT_ROT, 0, active_win, "INDICATOR ACTIVE WIN CHANGED:0x%08x", active_win); dep_rot.refer.active_bd = bd; +#ifdef _F_ZONE_WINDOW_ROTATION_ rotation = bd->client.e.state.rot.curr; _policy_border_dependent_rotation(bd, rotation); +#endif } } } diff --git a/illume2-tizen/src/policies/illume/policy.h b/illume2-tizen/src/policies/illume/policy.h index d1f95ff..5d62fa5 100644 --- a/illume2-tizen/src/policies/illume/policy.h +++ b/illume2-tizen/src/policies/illume/policy.h @@ -100,6 +100,7 @@ struct _E_Illume_XWin_Info Eina_Bool is_drawed; Eina_Bool viewable : 1; // map state E_Illume_Border_Info* bd_info; + Ecore_X_Window above_xwin; }; void _policy_border_add(E_Border *bd); @@ -164,5 +165,7 @@ void _policy_idle_enterer(void); void _policy_illume_win_state_change_request(Ecore_X_Event_Client_Message *event); +#ifdef _F_ZONE_WINDOW_ROTATION_ void _policy_border_hook_rotation_list_add(E_Border *bd); #endif +#endif |