aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/ecore_wayland
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2015-10-16 15:49:30 -0400
committerMike Blumenkrantz <zmike@osg.samsung.com>2015-10-16 15:55:40 -0400
commit5ad3c6358f67682816587240a0ff287198549d1a (patch)
tree2d287334b2bc13b0317cfd1d3ca61375c7099f8b /src/lib/ecore_wayland
parentEo do: Reuse stack fetching across eo functions. (diff)
downloadefl-5ad3c6358f67682816587240a0ff287198549d1a.tar.gz
Revert "ecore-wayland: Redo window animators to not use Custom source animators"
This reverts commit bd83d4c03ab9f6f6ae225976b9595a1dfde61237. adding an animator (and then not managing its ticks) causes the animator to fire constantly. in this case, it was causing 100% cpu usage and forcing a compositor re-render for every frame regardless of damages
Diffstat (limited to 'src/lib/ecore_wayland')
-rw-r--r--src/lib/ecore_wayland/ecore_wl_private.h2
-rw-r--r--src/lib/ecore_wayland/ecore_wl_window.c52
2 files changed, 0 insertions, 54 deletions
diff --git a/src/lib/ecore_wayland/ecore_wl_private.h b/src/lib/ecore_wayland/ecore_wl_private.h
index 872409f8fb..349347203f 100644
--- a/src/lib/ecore_wayland/ecore_wl_private.h
+++ b/src/lib/ecore_wayland/ecore_wl_private.h
@@ -157,7 +157,6 @@ struct _Ecore_Wl_Window
Eina_Bool alpha : 1;
Eina_Bool transparent : 1;
Eina_Bool has_buffer : 1;
- Eina_Bool visible : 1;
Ecore_Wl_Window_Type type;
Ecore_Wl_Window_Buffer_Type buffer_type;
@@ -165,7 +164,6 @@ struct _Ecore_Wl_Window
Ecore_Wl_Input *pointer_device;
Ecore_Wl_Input *keyboard_device;
- Ecore_Animator *animator;
Eina_Bool anim_pending : 1;
struct wl_callback *anim_callback;
diff --git a/src/lib/ecore_wayland/ecore_wl_window.c b/src/lib/ecore_wayland/ecore_wl_window.c
index 9f60e884c0..8250e78338 100644
--- a/src/lib/ecore_wayland/ecore_wl_window.c
+++ b/src/lib/ecore_wayland/ecore_wl_window.c
@@ -16,7 +16,6 @@ static void _ecore_xdg_handle_surface_configure(void *data, struct xdg_surface *
static void _ecore_xdg_handle_surface_delete(void *data, struct xdg_surface *xdg_surface);
static void _ecore_xdg_handle_popup_done(void *data, struct xdg_popup *xdg_popup);
static void _ecore_session_recovery_uuid(void *data, struct session_recovery *session_recovery, const char *uuid);
-static void _anim_cb_animate(void *data, struct wl_callback *callback, uint32_t serial EINA_UNUSED);
/* local variables */
static Eina_Hash *_windows = NULL;
@@ -45,44 +44,6 @@ static const struct session_recovery_listener _ecore_session_recovery_listener =
_ecore_session_recovery_uuid,
};
-static const struct wl_callback_listener _anim_listener =
-{
- _anim_cb_animate
-};
-
-static void
-_anim_cb_animate(void *data, struct wl_callback *callback, uint32_t serial EINA_UNUSED)
-{
- Ecore_Wl_Window *win;
-
- win = data;
- if (!win) return;
-
- if ((win->anim_callback) && (callback != win->anim_callback)) return;
-
- wl_callback_destroy(callback);
- win->anim_callback = NULL;
-}
-
-static Eina_Bool
-_ecore_wl_window_cb_animate(void *data)
-{
- Ecore_Wl_Window *win;
-
- win = data;
- if (!win->visible) return ECORE_CALLBACK_CANCEL;
-
- if (!win->anim_callback)
- {
- win->anim_callback = wl_surface_frame(win->surface);
- wl_callback_add_listener(win->anim_callback, &_anim_listener, win);
- }
-
- wl_surface_commit(win->surface);
-
- return ECORE_CALLBACK_RENEW;
-}
-
/* internal functions */
void
_ecore_wl_window_init(void)
@@ -444,11 +405,6 @@ ecore_wl_window_show(Ecore_Wl_Window *win)
default:
break;
}
-
- win->visible = EINA_TRUE;
-
- if (!win->animator)
- win->animator = ecore_animator_add(_ecore_wl_window_cb_animate, win);
}
EAPI void
@@ -458,14 +414,6 @@ ecore_wl_window_hide(Ecore_Wl_Window *win)
if (!win) return;
- win->visible = EINA_FALSE;
-
- if (win->anim_callback) wl_callback_destroy(win->anim_callback);
- win->anim_callback = NULL;
-
- if (win->animator) ecore_animator_del(win->animator);
- win->animator = NULL;
-
if (win->xdg_surface) xdg_surface_destroy(win->xdg_surface);
win->xdg_surface = NULL;