forked from enlightenment/enlightenment
move X idle flusher to comp_x
This commit is contained in:
parent
fab0b8122f
commit
2654b7e3e7
|
@ -43,6 +43,7 @@ static Eina_Hash *frame_extents = NULL;
|
||||||
static Eina_Hash *alarm_hash = NULL;
|
static Eina_Hash *alarm_hash = NULL;
|
||||||
|
|
||||||
static Ecore_Idle_Enterer *_e_comp_x_post_client_idler = NULL;
|
static Ecore_Idle_Enterer *_e_comp_x_post_client_idler = NULL;
|
||||||
|
static Ecore_Idle_Enterer *_x_idle_flush = NULL;
|
||||||
static Eina_List *post_clients = NULL;
|
static Eina_List *post_clients = NULL;
|
||||||
|
|
||||||
static int _e_comp_x_mapping_change_disabled = 0;
|
static int _e_comp_x_mapping_change_disabled = 0;
|
||||||
|
@ -56,6 +57,13 @@ static Eina_Bool screensaver_dimmed = EINA_FALSE;
|
||||||
static Ecore_X_Atom backlight_atom = 0;
|
static Ecore_X_Atom backlight_atom = 0;
|
||||||
extern double e_bl_val;
|
extern double e_bl_val;
|
||||||
|
|
||||||
|
static Eina_Bool
|
||||||
|
_e_comp_x_flusher(void *data EINA_UNUSED)
|
||||||
|
{
|
||||||
|
ecore_x_flush();
|
||||||
|
return ECORE_CALLBACK_RENEW;
|
||||||
|
}
|
||||||
|
|
||||||
static inline Ecore_X_Window
|
static inline Ecore_X_Window
|
||||||
_e_comp_x_client_window_get(const E_Client *ec)
|
_e_comp_x_client_window_get(const E_Client *ec)
|
||||||
{
|
{
|
||||||
|
@ -5127,6 +5135,7 @@ e_comp_x_init(void)
|
||||||
E_LIST_HANDLER_APPEND(handlers, E_EVENT_RANDR_CHANGE, _e_comp_x_randr_change, NULL);
|
E_LIST_HANDLER_APPEND(handlers, E_EVENT_RANDR_CHANGE, _e_comp_x_randr_change, NULL);
|
||||||
|
|
||||||
ecore_x_sync();
|
ecore_x_sync();
|
||||||
|
_x_idle_flush = ecore_idle_enterer_add(_e_comp_x_flusher, NULL);
|
||||||
|
|
||||||
return EINA_TRUE;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -84,7 +84,6 @@ static void _e_main_desk_save(void);
|
||||||
static void _e_main_desk_restore(void);
|
static void _e_main_desk_restore(void);
|
||||||
static void _e_main_efreet_paths_init(void);
|
static void _e_main_efreet_paths_init(void);
|
||||||
static void _e_main_modules_load(Eina_Bool safe_mode);
|
static void _e_main_modules_load(Eina_Bool safe_mode);
|
||||||
static Eina_Bool _e_main_cb_x_flusher(void *data EINA_UNUSED);
|
|
||||||
static Eina_Bool _e_main_cb_idle_before(void *data EINA_UNUSED);
|
static Eina_Bool _e_main_cb_idle_before(void *data EINA_UNUSED);
|
||||||
static Eina_Bool _e_main_cb_idle_after(void *data EINA_UNUSED);
|
static Eina_Bool _e_main_cb_idle_after(void *data EINA_UNUSED);
|
||||||
static Eina_Bool _e_main_cb_startup_fake_end(void *data EINA_UNUSED);
|
static Eina_Bool _e_main_cb_startup_fake_end(void *data EINA_UNUSED);
|
||||||
|
@ -100,7 +99,6 @@ static int(*_e_main_shutdown_func[MAX_LEVEL]) (void);
|
||||||
|
|
||||||
static Ecore_Idle_Enterer *_idle_before = NULL;
|
static Ecore_Idle_Enterer *_idle_before = NULL;
|
||||||
static Ecore_Idle_Enterer *_idle_after = NULL;
|
static Ecore_Idle_Enterer *_idle_after = NULL;
|
||||||
static Ecore_Idle_Enterer *_idle_flush = NULL;
|
|
||||||
|
|
||||||
static Ecore_Event_Handler *mod_init_end = NULL;
|
static Ecore_Event_Handler *mod_init_end = NULL;
|
||||||
|
|
||||||
|
@ -977,10 +975,6 @@ main(int argc, char **argv)
|
||||||
TS("E_Order Init Done");
|
TS("E_Order Init Done");
|
||||||
_e_main_shutdown_push(e_order_shutdown);
|
_e_main_shutdown_push(e_order_shutdown);
|
||||||
|
|
||||||
TS("Add Idler For X Flush");
|
|
||||||
_idle_flush = ecore_idle_enterer_add(_e_main_cb_x_flusher, NULL);
|
|
||||||
TS("Add Idler For X Flush Done");
|
|
||||||
|
|
||||||
TS("E_Comp_Canvas Keys Grab");
|
TS("E_Comp_Canvas Keys Grab");
|
||||||
e_comp_canvas_keys_grab();
|
e_comp_canvas_keys_grab();
|
||||||
TS("E_Comp_Canvas Keys Grab Done");
|
TS("E_Comp_Canvas Keys Grab Done");
|
||||||
|
@ -1090,8 +1084,6 @@ _e_main_shutdown(int errcode)
|
||||||
_idle_before = NULL;
|
_idle_before = NULL;
|
||||||
if (_idle_after) ecore_idle_enterer_del(_idle_after);
|
if (_idle_after) ecore_idle_enterer_del(_idle_after);
|
||||||
_idle_after = NULL;
|
_idle_after = NULL;
|
||||||
if (_idle_flush) ecore_idle_enterer_del(_idle_flush);
|
|
||||||
_idle_flush = NULL;
|
|
||||||
|
|
||||||
dir = getenv("XDG_RUNTIME_DIR");
|
dir = getenv("XDG_RUNTIME_DIR");
|
||||||
if (dir)
|
if (dir)
|
||||||
|
@ -1743,6 +1735,7 @@ _e_main_cb_idle_after(void *data EINA_UNUSED)
|
||||||
{
|
{
|
||||||
static int first_idle = 1;
|
static int first_idle = 1;
|
||||||
|
|
||||||
|
eet_clearcache();
|
||||||
edje_freeze();
|
edje_freeze();
|
||||||
|
|
||||||
#ifdef E_RELEASE_BUILD
|
#ifdef E_RELEASE_BUILD
|
||||||
|
@ -1764,17 +1757,6 @@ _e_main_cb_idle_after(void *data EINA_UNUSED)
|
||||||
return ECORE_CALLBACK_RENEW;
|
return ECORE_CALLBACK_RENEW;
|
||||||
}
|
}
|
||||||
|
|
||||||
static Eina_Bool
|
|
||||||
_e_main_cb_x_flusher(void *data EINA_UNUSED)
|
|
||||||
{
|
|
||||||
eet_clearcache();
|
|
||||||
#ifndef HAVE_WAYLAND_ONLY
|
|
||||||
if (e_comp->comp_type == E_PIXMAP_TYPE_X)
|
|
||||||
ecore_x_flush();
|
|
||||||
#endif
|
|
||||||
return ECORE_CALLBACK_RENEW;
|
|
||||||
}
|
|
||||||
|
|
||||||
static Eina_Bool
|
static Eina_Bool
|
||||||
_e_main_cb_startup_fake_end(void *data EINA_UNUSED)
|
_e_main_cb_startup_fake_end(void *data EINA_UNUSED)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue