diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-05-17 22:43:33 +0200 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-05-17 22:44:47 +0200 |
commit | 7b2b5dabb44ce1448f3af99fcba96eefe6d9147d (patch) | |
tree | cdc6404c5978d79cc7b91c5f41c64a6be8b81907 /src/main.cpp | |
parent | 0b18320693dd428e01ab9810d3bb4e18858c43d2 (diff) | |
download | mana-7b2b5dabb44ce1448f3af99fcba96eefe6d9147d.tar.gz mana-7b2b5dabb44ce1448f3af99fcba96eefe6d9147d.tar.bz2 mana-7b2b5dabb44ce1448f3af99fcba96eefe6d9147d.tar.xz mana-7b2b5dabb44ce1448f3af99fcba96eefe6d9147d.zip |
Make the state variable a bit more type-safe
Should be no change in behaviour.
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main.cpp b/src/main.cpp index bc010d30..fb061818 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -161,7 +161,7 @@ extern Net::Connection *accountServerConnection; Graphics *graphics; Game *game = 0; -unsigned char state = STATE_NULL; +State state = STATE_NULL; std::string errorMessage; Sound sound; @@ -975,7 +975,7 @@ int main(int argc, char *argv[]) desktop->setSize(screenWidth, screenHeight); - unsigned int oldstate = !state; // We start with a status change. + State oldstate = STATE_EXIT; // We start with a status change SDL_Event event; @@ -1429,9 +1429,9 @@ int main(int argc, char *argv[]) } else { - int nextState = STATE_UPDATE; + State nextState = STATE_UPDATE; currentDialog = new ServerSelectDialog(&loginData, - nextState); + nextState); positionDialog(currentDialog, screenWidth, screenHeight); if (options.chooseDefault) |