forked from enlightenment/efl
ecore-wl2: add internal window flag for determining if opaque/input have been set
This commit is contained in:
parent
ea7d6e11d3
commit
ed743dddf0
|
@ -168,6 +168,9 @@ struct _Ecore_Wl2_Window
|
|||
Eina_Bool resizing : 1;
|
||||
Eina_Bool alpha : 1;
|
||||
Eina_Bool transparent : 1;
|
||||
|
||||
Eina_Bool input_set : 1;
|
||||
Eina_Bool opaque_set : 1;
|
||||
};
|
||||
|
||||
struct _Ecore_Wl2_Output
|
||||
|
|
|
@ -422,10 +422,12 @@ ecore_wl2_window_show(Ecore_Wl2_Window *window)
|
|||
}
|
||||
}
|
||||
|
||||
ecore_wl2_window_input_region_set(window, window->input_rect.x, window->input_rect.x,
|
||||
window->input_rect.w, window->input_rect.h);
|
||||
ecore_wl2_window_opaque_region_set(window, window->opaque.x, window->opaque.x,
|
||||
window->opaque.w, window->opaque.h);
|
||||
if (window->input_set)
|
||||
ecore_wl2_window_input_region_set(window, window->input_rect.x, window->input_rect.x,
|
||||
window->input_rect.w, window->input_rect.h);
|
||||
if (window->opaque_set)
|
||||
ecore_wl2_window_opaque_region_set(window, window->opaque.x, window->opaque.x,
|
||||
window->opaque.w, window->opaque.h);
|
||||
|
||||
if ((window->type != ECORE_WL2_WINDOW_TYPE_DND) &&
|
||||
(window->type != ECORE_WL2_WINDOW_TYPE_NONE))
|
||||
|
@ -634,6 +636,7 @@ ecore_wl2_window_opaque_region_set(Ecore_Wl2_Window *window, int x, int y, int w
|
|||
window->opaque.y = y;
|
||||
window->opaque.w = w;
|
||||
window->opaque.h = h;
|
||||
window->opaque_set = 1;
|
||||
|
||||
if ((window->transparent) || (window->alpha)) return;
|
||||
if (!window->surface) return; //surface not created yet
|
||||
|
@ -676,6 +679,7 @@ ecore_wl2_window_input_region_set(Ecore_Wl2_Window *window, int x, int y, int w,
|
|||
window->input_rect.y = y;
|
||||
window->input_rect.w = w;
|
||||
window->input_rect.h = h;
|
||||
window->input_set = 1;
|
||||
|
||||
if (window->type == ECORE_WL2_WINDOW_TYPE_DND) return;
|
||||
if (!window->surface) return; //surface not created yet
|
||||
|
|
Loading…
Reference in New Issue