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();
+1 -1
View File
@@ -152,7 +152,7 @@ void draw_control_border(Window* win, DC& dc, const wxRect& rect) {
RECT r;
wxUxThemeEngine *themeEngine = wxUxThemeEngine::Get();
if (themeEngine && themeEngine->IsAppThemed()) {
wxUxThemeHandle hTheme(win, _("EDIT"));
wxUxThemeHandle hTheme(win, L"EDIT");
r.left = rect.x -1;
r.top = rect.y -1;
r.right = rect.x + rect.width + 1;
+5 -1
View File
@@ -199,7 +199,11 @@ bool TextValueEditor::onChar(wxKeyEvent& ev) {
// TODO: Find a more correct way to determine normal characters,
// this might not work for internationalized input.
// It might also not be portable!
replaceSelection(escape(String(ev.GetUnicodeKey(), 1)), _("Typing"));
#ifdef UNICODE
replaceSelection(escape(String(ev.GetUnicodeKey(), 1)), _("Typing"));
#else
replaceSelection(escape(String((Char)ev.GetKeyCode(), 1)), _("Typing"));
#endif
} else {
return false;
}
+1 -1
View File
@@ -110,7 +110,7 @@
Name="VCCustomBuildTool"/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="rpcrt4.lib wsock32.lib comctl32.lib wxbase26.lib wxmsw26_core.lib wxjpeg.lib wxpng.lib wxtiff.lib wxzlib.lib wxregex.lib"
AdditionalDependencies="rpcrt4.lib wsock32.lib comctl32.lib wxbase26.lib wxmsw26_core.lib wxjpeg.lib wxpng.lib wxtiff.lib wxzlib.lib wxregex.lib wxbase26_net.lib wxmsw26_html.lib"
OutputFile="$(OutDir)/mse.exe"
LinkIncremental="1"
SuppressStartupBanner="TRUE"