fixes to non-unicode build

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@280 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-04-21 21:09:17 +00:00
parent 61550b9e44
commit fe0f6838b8
4 changed files with 11 additions and 3 deletions
+4
View File
@@ -352,7 +352,11 @@ bool DropDownList::onCharInParent(wxKeyEvent& ev) {
for (size_t i = 0 ; i < count ; ++i) {
size_t index = (si + i) % count;
String c = itemText(index);
#ifdef UNICODE
if (!c.empty() && toUpper(c.GetChar(0)) == toUpper(ev.GetUnicodeKey())) {
#else
if (!c.empty() && toUpper(c.GetChar(0)) == toUpper(ev.GetKeyCode())) {
#endif
// first character matches
selected_item = index;
showSubMenu();