summaryrefslogtreecommitdiff
path: root/src/gui/char_server.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/char_server.cpp')
-rw-r--r--src/gui/char_server.cpp19
1 files changed, 16 insertions, 3 deletions
diff --git a/src/gui/char_server.cpp b/src/gui/char_server.cpp
index 4178a8e5..5b3992f1 100644
--- a/src/gui/char_server.cpp
+++ b/src/gui/char_server.cpp
@@ -116,11 +116,24 @@ void char_server() {
state = LOGIN;
showServerList = 1;
- while (showServerList) {
- login_wallpaper->draw(buffer, 0, 0);
+ while (showServerList)
+ {
+ // Handle SDL events
+ SDL_Event event;
+ while (SDL_PollEvent(&event)) {
+ switch (event.type) {
+ case SDL_QUIT:
+ state = EXIT;
+ break;
+ }
+
+ guiInput->pushInput(event);
+ }
+
+ login_wallpaper->draw(screen, 0, 0);
gui->logic();
gui->draw();
- blit(buffer, screen, 0, 0, 0, 0, 800, 600);
+ guiGraphics->updateScreen();
}
delete dialog;