Cleaner gl_init_platform

Simplify the code of gl_init_platform.
I didn't think of using `Deref` when I wrote it.
Also removes a warning.

I could implement `DerefMut` "just in case", even though there are no mut method in `gl_init::Window`. But IIRC some issues arise when this trait is implemented.