parent
d28634b70a
commit
5f042a480c
|
@ -421,6 +421,7 @@ e_border_new(E_Container *con,
|
|||
ecore_x_window_shadow_tree_flush();
|
||||
e_object_del_func_set(E_OBJECT(bd), E_OBJECT_CLEANUP_FUNC(_e_border_del));
|
||||
|
||||
bd->focus_policy = e_config->focus_policy;
|
||||
bd->w = 1;
|
||||
bd->h = 1;
|
||||
/* FIXME: ewww - round trip */
|
||||
|
@ -7457,6 +7458,21 @@ _e_border_eval0(E_Border *bd)
|
|||
bd->client.netwm.update.state = 1;
|
||||
}
|
||||
}
|
||||
else if (bd->client.netwm.type == ECORE_X_WINDOW_TYPE_DESKTOP)
|
||||
{
|
||||
bd->focus_policy = E_FOCUS_CLICK;
|
||||
e_focus_setup(bd);
|
||||
if (!bd->client.netwm.state.skip_pager)
|
||||
{
|
||||
bd->client.netwm.state.skip_pager = 1;
|
||||
bd->client.netwm.update.state = 1;
|
||||
}
|
||||
if (!bd->client.netwm.state.skip_taskbar)
|
||||
{
|
||||
bd->client.netwm.state.skip_taskbar = 1;
|
||||
bd->client.netwm.update.state = 1;
|
||||
}
|
||||
}
|
||||
bd->client.netwm.fetch.type = 0;
|
||||
}
|
||||
if (bd->client.icccm.fetch.machine)
|
||||
|
@ -8250,6 +8266,8 @@ _e_border_eval0(E_Border *bd)
|
|||
bordername = bd->bordername;
|
||||
else if ((bd->client.mwm.borderless) || (bd->borderless))
|
||||
bordername = "borderless";
|
||||
else if (bd->client.netwm.type == ECORE_X_WINDOW_TYPE_DESKTOP)
|
||||
bordername = "borderless";
|
||||
else if (((bd->client.icccm.transient_for != 0) ||
|
||||
(bd->client.netwm.type == ECORE_X_WINDOW_TYPE_DIALOG)) &&
|
||||
(bd->client.icccm.min_w == bd->client.icccm.max_w) &&
|
||||
|
|
|
@ -669,6 +669,7 @@ struct _E_Border
|
|||
Eina_Bool argb;
|
||||
|
||||
int tmp_input_hidden;
|
||||
int focus_policy;
|
||||
};
|
||||
|
||||
struct _E_Border_Pending_Move_Resize
|
||||
|
|
|
@ -27,8 +27,8 @@ e_focus_idler_before(void)
|
|||
EAPI void
|
||||
e_focus_event_mouse_in(E_Border *bd)
|
||||
{
|
||||
if ((e_config->focus_policy == E_FOCUS_MOUSE) ||
|
||||
(e_config->focus_policy == E_FOCUS_SLOPPY))
|
||||
if ((bd->focus_policy == E_FOCUS_MOUSE) ||
|
||||
(bd->focus_policy == E_FOCUS_SLOPPY))
|
||||
{
|
||||
if (bd != e_border_focused_get())
|
||||
e_border_focus_set(bd, 1, 1);
|
||||
|
@ -53,7 +53,7 @@ e_focus_event_mouse_in(E_Border *bd)
|
|||
EAPI void
|
||||
e_focus_event_mouse_out(E_Border *bd)
|
||||
{
|
||||
if (e_config->focus_policy == E_FOCUS_MOUSE)
|
||||
if (bd->focus_policy == E_FOCUS_MOUSE)
|
||||
{
|
||||
/* FIXME: this is such a hack. its a big hack around x's async events
|
||||
* as we dont know always exactly what action causes what event
|
||||
|
@ -82,7 +82,7 @@ e_focus_event_mouse_down(E_Border *bd)
|
|||
{
|
||||
if (!bd->focused)
|
||||
{
|
||||
if (e_config->focus_policy == E_FOCUS_CLICK)
|
||||
if (bd->focus_policy == E_FOCUS_CLICK)
|
||||
e_border_focus_set(bd, 1, 1);
|
||||
else if (e_config->always_click_to_focus)
|
||||
e_border_focus_set(bd, 1, 1);
|
||||
|
@ -102,7 +102,7 @@ e_focus_event_mouse_up(E_Border *bd __UNUSED__)
|
|||
EAPI void
|
||||
e_focus_event_focus_in(E_Border *bd)
|
||||
{
|
||||
if ((e_config->focus_policy == E_FOCUS_CLICK) &&
|
||||
if ((bd->focus_policy == E_FOCUS_CLICK) &&
|
||||
(!e_config->always_click_to_raise) &&
|
||||
(!e_config->always_click_to_focus))
|
||||
{
|
||||
|
@ -126,7 +126,7 @@ e_focus_event_focus_in(E_Border *bd)
|
|||
EAPI void
|
||||
e_focus_event_focus_out(E_Border *bd)
|
||||
{
|
||||
if ((e_config->focus_policy == E_FOCUS_CLICK) &&
|
||||
if ((bd->focus_policy == E_FOCUS_CLICK) &&
|
||||
(!e_config->always_click_to_raise) &&
|
||||
(!e_config->always_click_to_focus))
|
||||
{
|
||||
|
@ -150,7 +150,7 @@ e_focus_event_focus_out(E_Border *bd)
|
|||
EAPI void
|
||||
e_focus_setup(E_Border *bd)
|
||||
{
|
||||
if ((e_config->focus_policy == E_FOCUS_CLICK) ||
|
||||
if ((bd->focus_policy == E_FOCUS_CLICK) ||
|
||||
(e_config->always_click_to_raise) ||
|
||||
(e_config->always_click_to_focus))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue