diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-02-26 21:29:49 +0100 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-02-26 21:29:49 +0100 |
commit | 3008805eea4b972265597ba196ab05ce64c69965 (patch) | |
tree | d3195600e956e496b6b21f200fc04e5b08cab368 /src/net/npchandler.cpp | |
parent | 3ad6ac47d4967870a54fddd66aa9996724115b94 (diff) | |
parent | 6b0cff837b7adae56dc90d12e9c0e256e6aab134 (diff) | |
download | mana-3008805eea4b972265597ba196ab05ce64c69965.tar.gz mana-3008805eea4b972265597ba196ab05ce64c69965.tar.bz2 mana-3008805eea4b972265597ba196ab05ce64c69965.tar.xz mana-3008805eea4b972265597ba196ab05ce64c69965.zip |
Merge branch 'aethyra/master'
Conflicts:
data/graphics/images/login_wallpaper.png
src/being.cpp
src/beingmanager.cpp
src/engine.cpp
src/game.cpp
src/gui/buysell.cpp
src/gui/buysell.h
src/gui/gui.h
src/gui/npc_text.cpp
src/gui/npc_text.h
src/gui/npcintegerdialog.cpp
src/gui/npclistdialog.cpp
src/gui/npclistdialog.h
src/gui/npcstringdialog.cpp
src/gui/sell.cpp
src/gui/shop.cpp
src/gui/table.cpp
src/net/beinghandler.cpp
src/net/npchandler.cpp
src/net/playerhandler.cpp
src/npc.cpp
src/npc.h
src/shopitem.cpp
src/shopitem.h
src/utils/stringutils.cpp
src/utils/stringutils.h
src/utils/trim.h
Diffstat (limited to 'src/net/npchandler.cpp')
-rw-r--r-- | src/net/npchandler.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/net/npchandler.cpp b/src/net/npchandler.cpp index 405217bb..2ecd4726 100644 --- a/src/net/npchandler.cpp +++ b/src/net/npchandler.cpp @@ -19,6 +19,8 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ +#include <SDL_types.h> + #include "messagein.h" #include "npchandler.h" #include "protocol.h" @@ -32,11 +34,6 @@ #include "../gui/npclistdialog.h" #include "../gui/npcstringdialog.h" -extern NpcIntegerDialog *npcIntegerDialog; -extern NpcListDialog *npcListDialog; -extern NpcTextDialog *npcTextDialog; -extern NpcStringDialog *npcStringDialog; - NPCHandler::NPCHandler() { static const Uint16 _messages[] = { @@ -53,7 +50,7 @@ NPCHandler::NPCHandler() void NPCHandler::handleMessage(MessageIn *msg) { - int id; + Uint32 id; switch (msg->getId()) { @@ -63,6 +60,7 @@ void NPCHandler::handleMessage(MessageIn *msg) player_node->setAction(LocalPlayer::STAND); npcListDialog->parseItems(msg->readString(msg->getLength() - 8)); npcListDialog->setVisible(true); + npcListDialog->requestFocus(); break; case SMSG_NPC_MESSAGE: @@ -70,7 +68,6 @@ void NPCHandler::handleMessage(MessageIn *msg) current_npc = msg->readInt32(); player_node->setAction(LocalPlayer::STAND); npcTextDialog->addText(msg->readString(msg->getLength() - 8)); - npcListDialog->setVisible(false); npcTextDialog->setVisible(true); break; |