General Fixes

* Fixes XLIB cast for the WM_DELETE_WINDOW message, it can be simply cast to Atom.
* Fixes segfault for certain manual events, like game end/room end, we were forgetting to construct instance_event_iterator = new inst_iter(NULL,NULL,NULL); Fixes #731
* Fixes the default draw event, objects now write their subcheck code not only if the event has code, but if it has default code.
* Fixes delay in graphics initialization by not showing the parent window until after the graphics context is created.
* Fixes room switching, the window should only center if the room size changes, I did this by simply adding it as a parameter to window_default()

Tested and confirmed working and can be merged.