diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-02-02 22:15:55 +0200 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-02-02 22:15:55 +0200 |
commit | 4ead5c9f65ffbf1de9b0cb60cae06b116badbced (patch) | |
tree | bc94093b90e7b4d3168259b7404ae2f6236f3925 /src/client.cpp | |
parent | 4b0caea6389ab789ff3ae3a267b9002f8a21e8c3 (diff) | |
download | plus-4ead5c9f65ffbf1de9b0cb60cae06b116badbced.tar.gz plus-4ead5c9f65ffbf1de9b0cb60cae06b116badbced.tar.bz2 plus-4ead5c9f65ffbf1de9b0cb60cae06b116badbced.tar.xz plus-4ead5c9f65ffbf1de9b0cb60cae06b116badbced.zip |
Close npc and other dialogs if reconnecting.
Also save extra layers if network error.
Diffstat (limited to 'src/client.cpp')
-rw-r--r-- | src/client.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/client.cpp b/src/client.cpp index 251144654..3c1c2054d 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -39,6 +39,8 @@ #include "statuseffect.h" #include "units.h" +#include "gui/buy.h" +#include "gui/buysell.h" #include "gui/changeemaildialog.h" #include "gui/changepassworddialog.h" #include "gui/charselectdialog.h" @@ -48,6 +50,8 @@ #include "gui/okdialog.h" #include "gui/quitdialog.h" #include "gui/register.h" +#include "gui/npcdialog.h" +#include "gui/sell.h" #include "gui/sdlinput.h" #include "gui/serverdialog.h" #include "gui/setup.h" @@ -67,6 +71,7 @@ #include "net/logindata.h" #include "net/loginhandler.h" #include "net/net.h" +#include "net/npchandler.h" #include "net/packetcounters.h" #include "net/worldinfo.h" @@ -1999,3 +2004,12 @@ void Client::setFramerate(int fpsLimit) SDL_setFramerate(&instance()->mFpsManager, fpsLimit); } + +void Client::closeDialogs() +{ + Net::getNpcHandler()->clearDialogs(); + BuyDialog::closeAll(); + BuySellDialog::closeAll(); + NpcDialog::closeAll(); + SellDialog::closeAll(); +}
\ No newline at end of file |