should have fixed splash issue on xrandr resize

SVN revision: 26870
This commit is contained in:
Carsten Haitzler 2006-10-30 11:13:34 +00:00
parent eb5e1c17c4
commit b0c5dca69f
2 changed files with 24 additions and 1 deletions

1
TODO
View File

@ -8,7 +8,6 @@ Some of the things (in very short form) that need to be done to E17...
BUGS / FIXES
-------------------------------------------------------------------------------
* BUG: init splash doesn't handle resolution change!
* BUG: smart placement seems to screw up if a shelf is at the top of the screen
* BUG: e17 screen res diaolg doesnt work under xephyr - why?
* BUG: xdaliclock -transparent doesnt use shaped border (not handling shape

View File

@ -7,14 +7,17 @@ static void _e_init_icons_del(void);
static void _e_init_cb_signal_disable(void *data, Evas_Object *obj, const char *emission, const char *source);
static void _e_init_cb_signal_enable(void *data, Evas_Object *obj, const char *emission, const char *source);
static void _e_init_cb_signal_done_ok(void *data, Evas_Object *obj, const char *emission, const char *source);
static int _e_init_cb_window_configure(void *data, int ev_type, void *ev);
/* local subsystem globals */
static Ecore_X_Window _e_init_root_win = 0;
static Ecore_X_Window _e_init_win = 0;
static Ecore_Evas *_e_init_ecore_evas = NULL;
static Evas *_e_init_evas = NULL;
static Evas_Object *_e_init_object = NULL;
static Evas_Object *_e_init_icon_box = NULL;
static E_Pointer *_e_init_pointer = NULL;
static Ecore_Event_Handler *e_init_configure_handler = NULL;
/* startup icons */
static Evas_Coord _e_init_icon_size = 0;
@ -31,6 +34,10 @@ e_init_init(void)
Evas_Object *o;
Evas_List *l, *screens;
const char *s;
e_init_configure_handler =
ecore_event_handler_add(ECORE_X_EVENT_WINDOW_CONFIGURE,
_e_init_cb_window_configure, NULL);
num = 0;
roots = ecore_x_window_root_list(&num);
@ -41,6 +48,7 @@ e_init_init(void)
return 0;
}
root = roots[0];
_e_init_root_win = root;
ecore_x_window_size_get(root, &w, &h);
_e_init_ecore_evas = e_canvas_new(e_config->evas_engine_init, root,
@ -113,6 +121,8 @@ e_init_init(void)
EAPI int
e_init_shutdown(void)
{
ecore_event_handler_del(e_init_configure_handler);
e_init_configure_handler = NULL;
e_init_hide();
e_canvas_cache_flush();
return 1;
@ -266,3 +276,17 @@ _e_init_cb_signal_done_ok(void *data, Evas_Object *obj, const char *emission, co
{
e_init_hide();
}
static int
_e_init_cb_window_configure(void *data, int ev_type, void *ev)
{
Ecore_X_Event_Window_Configure *e;
e = ev;
/* really simple - don't handle xinerama - because this event will only
* happen in single head */
if (e->win != _e_init_root_win) return 1;
ecore_evas_resize(_e_init_ecore_evas, e->w, e->h);
evas_object_resize(_e_init_object, e->w, e->h);
return 1;
}