diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-07-16 00:15:26 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-07-16 00:15:26 +0300 |
commit | d074efe8597cbc21375c59d7e6ee17296b4c4899 (patch) | |
tree | e8a2589455b54edc368b94b4b3a0469d7e7ee0a4 /src/gui/npcdialog.cpp | |
parent | cb82d49bf76c821450934046ff423da51819b521 (diff) | |
download | manaverse-d074efe8597cbc21375c59d7e6ee17296b4c4899.tar.gz manaverse-d074efe8597cbc21375c59d7e6ee17296b4c4899.tar.bz2 manaverse-d074efe8597cbc21375c59d7e6ee17296b4c4899.tar.xz manaverse-d074efe8597cbc21375c59d7e6ee17296b4c4899.zip |
Highlight first item in npc dialog.
Diffstat (limited to 'src/gui/npcdialog.cpp')
-rw-r--r-- | src/gui/npcdialog.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gui/npcdialog.cpp b/src/gui/npcdialog.cpp index e8ea3388f..36677446d 100644 --- a/src/gui/npcdialog.cpp +++ b/src/gui/npcdialog.cpp @@ -333,6 +333,11 @@ void NpcDialog::parseListItems(const std::string &itemString) std::string tmp; while (getline(iss, tmp, ':')) mItems.push_back(tmp); + + if (!mItems.empty()) + mItemList->setSelected(0); + else + mItemList->setSelected(-1); } void NpcDialog::textRequest(const std::string &defaultText) |