ecore_evas/cocoa: fix cursor's visibility

Fixes T5238
This commit is contained in:
Jean Guyomarc'h 2017-03-07 20:19:53 +01:00
parent 4e1567b41e
commit 6f80616a4d
1 changed files with 10 additions and 5 deletions

View File

@ -468,14 +468,19 @@ _ecore_evas_object_cursor_set(Ecore_Evas *ee, Evas_Object *obj,
int layer EINA_UNUSED, int hot_x EINA_UNUSED,
int hot_y EINA_UNUSED)
{
Ecore_Cocoa_Window *win = (Ecore_Cocoa_Window *)(ee->prop.window);
Ecore_Cocoa_Window *const win = (Ecore_Cocoa_Window *)(ee->prop.window);
if (!obj)
ecore_cocoa_window_cursor_show(win, EINA_TRUE);
else if (obj != _ecore_evas_default_cursor_image_get(ee))
if (obj != _ecore_evas_default_cursor_image_get(ee))
ecore_cocoa_window_cursor_show(win, EINA_FALSE);
}
static void
_ecore_evas_object_cursor_unset(Ecore_Evas *ee)
{
Ecore_Cocoa_Window *const win = (Ecore_Cocoa_Window *)(ee->prop.window);
ecore_cocoa_window_cursor_show(win, EINA_TRUE);
}
static void
_ecore_evas_withdrawn_set(Ecore_Evas *ee, Eina_Bool on)
{
@ -574,7 +579,7 @@ static Ecore_Evas_Engine_Func _ecore_cocoa_engine_func =
NULL,
_ecore_evas_size_step_set,
_ecore_evas_object_cursor_set,
NULL,
_ecore_evas_object_cursor_unset,
NULL,
NULL,
_ecore_evas_iconified_set,