summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-07-16 00:15:26 +0300
committerAndrei Karas <akaras@inbox.ru>2011-07-16 00:15:26 +0300
commitd074efe8597cbc21375c59d7e6ee17296b4c4899 (patch)
treee8a2589455b54edc368b94b4b3a0469d7e7ee0a4 /src
parentcb82d49bf76c821450934046ff423da51819b521 (diff)
downloadmanaplus-d074efe8597cbc21375c59d7e6ee17296b4c4899.tar.gz
manaplus-d074efe8597cbc21375c59d7e6ee17296b4c4899.tar.bz2
manaplus-d074efe8597cbc21375c59d7e6ee17296b4c4899.tar.xz
manaplus-d074efe8597cbc21375c59d7e6ee17296b4c4899.zip
Highlight first item in npc dialog.
Diffstat (limited to 'src')
-rw-r--r--src/gui/npcdialog.cpp5
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)