static Eina_Bool _e_vis_client_grab_cancel(E_Vis_Client *vc);
static void _e_vis_client_job_exec(E_Vis_Client *vc, E_Vis_Job_Type type);
static Eina_Bool _e_vis_grab_job_filter(E_Vis_Grab *grab, E_Vis_Job_Type type);
-static Eina_Bool _e_vis_ec_activity_check(E_Client *ec, Eina_Bool check_alpha);
+static Eina_Bool _e_vis_ec_activity_check(E_Client *ec, E_Client *above, Eina_Bool check_alpha);
static void _e_vis_ec_job_exec(E_Client *ec, E_Vis_Job_Type type);
static void _e_vis_ec_setup(E_Client *ec);
static void _e_vis_ec_reset(E_Client *ec);
if (!evas_object_visible_get(ec->frame)) continue;
pol_vis->fg_clients = eina_list_append(pol_vis->fg_clients, ec);
- if (_e_vis_ec_activity_check(ec, EINA_TRUE))
+ if (_e_vis_ec_activity_check(ec, NULL, EINA_TRUE))
{
fg_activity = ec;
break;
}
static Eina_Bool
-_e_vis_ec_activity_check(E_Client *ec, Eina_Bool check_alpha)
+_e_vis_ec_activity_check(E_Client *ec, E_Client *above, Eina_Bool check_alpha)
{
int x, y, w, h;
+ int ax, ay, aw, ah;
E_Comp_Object_Content_Type type = E_COMP_OBJECT_CONTENT_TYPE_NONE;
int check_mapped = 1;
+ if (above)
+ {
+ e_client_geometry_get(above, &ax, &ay, &aw, &ah);
+ }
+ else
+ {
+ ax = ec->desk->geom.x;
+ ay = ec->desk->geom.y;
+ aw = ec->desk->geom.w;
+ ah = ec->desk->geom.h;
+ }
+
/* check if ignored */
if (e_client_util_ignored_get(ec)) return EINA_FALSE;
/* check transparent */
if (_e_vis_ec_special_check(ec)) return EINA_FALSE;
/* check if full screen */
e_client_geometry_get(ec, &x, &y, &w, &h);
- if (!E_CONTAINS(x, y, w, h, ec->desk->geom.x, ec->desk->geom.y, ec->desk->geom.w, ec->desk->geom.h))
+ E_RECTS_CLIP_TO_RECT(x, y, w, h, ec->desk->geom.x, ec->desk->geom.y, ec->desk->geom.w, ec->desk->geom.h);
+ E_RECTS_CLIP_TO_RECT(ax, ay, aw, ah, ec->desk->geom.x, ec->desk->geom.y, ec->desk->geom.w, ec->desk->geom.h);
+ if (!E_CONTAINS(ax, ay, aw, ah, x, y, w, h))
return EINA_FALSE;
/* check if obscured by force */
if (ec->visibility.force_obscured)
for (below = e_client_below_get(ec); below; below = e_client_below_get(below))
{
- if (!_e_vis_ec_activity_check(below, EINA_FALSE)) continue;
+ if (!_e_vis_ec_activity_check(below, ec, EINA_FALSE)) continue;
E_VIS_CLIENT_GET(vc, below);
if (!vc) continue;
{
if (ec->zone->display_state == E_ZONE_DISPLAY_STATE_OFF)
return EINA_FALSE;
-
- /* if the ec is not fullfilling the screen, no needs to wait below clients' uniconify */
if (ec->zone != e_zone_current_get())
return EINA_FALSE;
- e_client_geometry_get(ec, &x, &y, &w, &h);
- if (!E_CONTAINS(x, y, w, h, ec->zone->x, ec->zone->y, ec->zone->w, ec->zone->h))
- return EINA_FALSE;
}
/* find below activity clients */
e_policy_visibility_client_is_activity(E_Client *ec)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(ec, EINA_FALSE);
- return _e_vis_ec_activity_check(ec, EINA_TRUE);
+ return _e_vis_ec_activity_check(ec, NULL, EINA_TRUE);
}
E_API E_Vis_Grab *