ecore-wl2: Remove all code relating to custom window animators

Signed-off-by: Chris Michael <cp.michael@samsung.com>
This commit is contained in:
Chris Michael 2015-10-19 10:46:00 -04:00
parent 232dfd355d
commit 8f338af511
4 changed files with 0 additions and 123 deletions

View File

@ -305,9 +305,6 @@ EAPI struct wl_shm *ecore_wl2_display_shm_get(Ecore_Wl2_Display *display);
*/
EAPI Eina_Iterator *ecore_wl2_display_globals_get(Ecore_Wl2_Display *display);
/* TODO: doxy */
EAPI Eina_Bool ecore_wl2_display_animator_source_set(Ecore_Wl2_Display *display, Ecore_Animator_Source source);
/**
* Retrieves the size of the current screen.
*

View File

@ -267,30 +267,6 @@ static const struct wl_callback_listener _sync_listener =
_cb_sync_done
};
static void
_animator_tick_cb_begin(void *data)
{
Ecore_Wl2_Display *display;
Ecore_Wl2_Window *window;
display = data;
if (!display) return;
EINA_INLIST_FOREACH(display->windows, window)
_ecore_wl2_window_animator_add(window);
}
static void
_animator_tick_cb_end(void *data)
{
Ecore_Wl2_Display *display;
display = data;
if (!display) return;
_ecore_wl2_window_animator_end();
}
static void
_ecore_wl2_display_cleanup(Ecore_Wl2_Display *ewd)
{
@ -559,28 +535,6 @@ ecore_wl2_display_globals_get(Ecore_Wl2_Display *display)
return eina_hash_iterator_data_new(display->globals);
}
EAPI Eina_Bool
ecore_wl2_display_animator_source_set(Ecore_Wl2_Display *display, Ecore_Animator_Source source)
{
switch (source)
{
case ECORE_ANIMATOR_SOURCE_CUSTOM:
ecore_animator_custom_source_tick_begin_callback_set
(_animator_tick_cb_begin, display);
ecore_animator_custom_source_tick_end_callback_set
(_animator_tick_cb_end, display);
break;
case ECORE_ANIMATOR_SOURCE_TIMER:
ecore_animator_custom_source_tick_begin_callback_set(NULL, NULL);
ecore_animator_custom_source_tick_end_callback_set(NULL, NULL);
break;
}
ecore_animator_source_set(source);
return EINA_TRUE;
}
EAPI void
ecore_wl2_display_screen_size_get(Ecore_Wl2_Display *display, int *w, int *h)
{

View File

@ -113,9 +113,6 @@ struct _Ecore_Wl2_Window
struct wl_shell_surface *wl_shell_surface;
struct xdg_surface *xdg_surface;
struct xdg_popup *xdg_popup;
struct wl_callback *anim_cb;
Ecore_Animator *animator;
Eina_Rectangle geometry;
Eina_Rectangle opaque;
@ -249,9 +246,6 @@ struct _Ecore_Wl2_Input
Ecore_Wl2_Window *_ecore_wl2_display_window_surface_find(Ecore_Wl2_Display *display, struct wl_surface *wl_surface);
void _ecore_wl2_window_animator_add(Ecore_Wl2_Window *window);
void _ecore_wl2_window_animator_end(void);
void _ecore_wl2_output_add(Ecore_Wl2_Display *display, unsigned int id);
void _ecore_wl2_output_del(Ecore_Wl2_Output *output);

View File

@ -4,10 +4,6 @@
#include "ecore_wl2_private.h"
static void _anim_cb_animate(void *data, struct wl_callback *callback, uint32_t serial EINA_UNUSED);
static Eina_Bool _animator_busy = EINA_FALSE;
static void
_ecore_wl2_window_configure_send(Ecore_Wl2_Window *window, int w, int h, unsigned int edges)
{
@ -218,57 +214,6 @@ _ecore_wl2_window_type_set(Ecore_Wl2_Window *win)
}
}
static const struct wl_callback_listener _win_anim_listener =
{
_anim_cb_animate
};
static void
_anim_cb_animate(void *data, struct wl_callback *callback, uint32_t serial EINA_UNUSED)
{
Ecore_Wl2_Window *window;
window = data;
if (!window) return;
wl_callback_destroy(callback);
window->anim_cb = NULL;
}
static Eina_Bool
_ecore_wl2_window_cb_animate(void *data)
{
Ecore_Wl2_Window *window;
window = data;
if (!window->surface) return ECORE_CALLBACK_CANCEL;
if (window->anim_cb) return ECORE_CALLBACK_RENEW;
window->anim_cb = wl_surface_frame(window->surface);
wl_callback_add_listener(window->anim_cb, &_win_anim_listener, window);
wl_surface_commit(window->surface);
return ECORE_CALLBACK_RENEW;
}
void
_ecore_wl2_window_animator_add(Ecore_Wl2_Window *window)
{
_animator_busy = EINA_TRUE;
if ((!window->surface) || (window->anim_cb)) return;
window->anim_cb = wl_surface_frame(window->surface);
wl_callback_add_listener(window->anim_cb, &_win_anim_listener, window);
wl_surface_commit(window->surface);
}
void
_ecore_wl2_window_animator_end(void)
{
_animator_busy = EINA_FALSE;
}
EAPI Ecore_Wl2_Window *
ecore_wl2_window_new(Ecore_Wl2_Display *display, Ecore_Wl2_Window *parent, int x, int y, int w, int h)
{
@ -385,13 +330,6 @@ ecore_wl2_window_show(Ecore_Wl2_Window *window)
type_set:
_ecore_wl2_window_type_set(window);
if (!window->animator)
{
window->animator =
ecore_animator_add(_ecore_wl2_window_cb_animate, window);
}
return;
surf_err:
@ -403,12 +341,6 @@ ecore_wl2_window_hide(Ecore_Wl2_Window *window)
{
EINA_SAFETY_ON_NULL_RETURN(window);
if (window->anim_cb) wl_callback_destroy(window->anim_cb);
window->anim_cb = NULL;
if (window->animator) ecore_animator_del(window->animator);
window->animator = NULL;
if (window->xdg_surface) xdg_surface_destroy(window->xdg_surface);
window->xdg_surface = NULL;