remove e_util_pointer_center()
this is yet another utility function which duplicates code from elsewhere and does it incorrectly fix T3164
This commit is contained in:
parent
9076301213
commit
2afaea3b49
|
@ -851,7 +851,8 @@ ACT_FN_GO(window_move_by, )
|
|||
ec = (E_Client *)(void *)obj;
|
||||
evas_object_move(ec->frame, ec->x + dx, ec->y + dy);
|
||||
|
||||
e_util_pointer_center(ec);
|
||||
if (!e_client_focus_policy_click(ec))
|
||||
e_client_pointer_warp_to_center_now(ec);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -899,7 +900,8 @@ ACT_FN_GO(window_move_to, )
|
|||
{
|
||||
evas_object_move(ec->frame, x, y);
|
||||
|
||||
e_util_pointer_center(ec);
|
||||
if (!e_client_focus_policy_click(ec))
|
||||
e_client_pointer_warp_to_center_now(ec);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -962,7 +964,8 @@ ACT_FN_GO(window_move_to_center, EINA_UNUSED)
|
|||
ec = (E_Client *)(void *)obj;
|
||||
e_comp_object_util_center(ec->frame);
|
||||
|
||||
e_util_pointer_center(ec);
|
||||
if (!e_client_focus_policy_click(ec))
|
||||
e_client_pointer_warp_to_center_now(ec);
|
||||
}
|
||||
|
||||
/***************************************************************************/
|
||||
|
@ -987,7 +990,8 @@ ACT_FN_GO(window_resize_by, )
|
|||
e_client_resize_limit(ec, &dw, &dh);
|
||||
evas_object_resize(ec->frame, dw, dh);
|
||||
|
||||
e_util_pointer_center(ec);
|
||||
if (!e_client_focus_policy_click(ec))
|
||||
e_client_pointer_warp_to_center_now(ec);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1091,7 +1095,8 @@ ACT_FN_GO(window_push, )
|
|||
if ((x != ec->x) || (y != ec->y))
|
||||
{
|
||||
evas_object_move(ec->frame, x, y);
|
||||
e_util_pointer_center(ec);
|
||||
if (!e_client_focus_policy_click(ec))
|
||||
e_client_pointer_warp_to_center_now(ec);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1135,7 +1140,10 @@ window_jump_to(const char *params)
|
|||
|
||||
evas_object_raise(ec->frame);
|
||||
if (ec->zone != current_zone)
|
||||
e_util_pointer_center(ec);
|
||||
{
|
||||
if (!e_client_focus_policy_click(ec))
|
||||
e_client_pointer_warp_to_center_now(ec);
|
||||
}
|
||||
evas_object_focus_set(ec->frame, 1);
|
||||
return 1;
|
||||
}
|
||||
|
|
|
@ -68,19 +68,6 @@ E_API void e_util_memclear(void *s, size_t n);
|
|||
|
||||
E_API Ecore_Exe *e_util_open(const char *exe, void *data);
|
||||
|
||||
static inline void
|
||||
e_util_pointer_center(const E_Client *ec)
|
||||
{
|
||||
int x = 0, y = 0;
|
||||
|
||||
if (ec->zone)
|
||||
x = ec->zone->x, y = ec->zone->y;
|
||||
if ((e_config->focus_policy != E_FOCUS_CLICK) && (!e_config->disable_all_pointer_warps))
|
||||
ecore_evas_pointer_warp(e_comp->ee,
|
||||
x + ec->x + (ec->w / 2),
|
||||
y + ec->y + (ec->h / 2));
|
||||
}
|
||||
|
||||
static inline Eina_Bool
|
||||
isedje(const Evas_Object *obj)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue