mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[ion/simulator] Relayout on any windows event
We might be relayouting a bit too often, but better safe than sorry! Jokes aside, most SDL_WINDOWEVENT should trigger a relayout, and in general those events aren't triggered on a regular basis anyway.
This commit is contained in:
committed by
EmilieNumworks
parent
85a10ab084
commit
585bf65294
@@ -175,9 +175,8 @@ Event getPlatformEvent() {
|
||||
while (SDL_PollEvent(&event)) {
|
||||
// The while is important: it'll do a fast-pass over all useless SDL events
|
||||
if (event.type == SDL_WINDOWEVENT) {
|
||||
if (event.window.event == SDL_WINDOWEVENT_RESIZED) {
|
||||
Ion::Simulator::Main::relayout();
|
||||
}
|
||||
Ion::Simulator::Main::relayout();
|
||||
break;
|
||||
}
|
||||
if (event.type == SDL_QUIT) {
|
||||
result = Termination;
|
||||
|
||||
Reference in New Issue
Block a user