From 5ad20736dd11bdf99afe06786411c2fe4ab891d8 Mon Sep 17 00:00:00 2001 From: nyamatongwe Date: Fri, 3 Dec 2004 23:15:54 +0000 Subject: =?UTF-8?q?Safest=20portion=20of=20patch=20from=20R=C3=A9gis=20Vaq?= =?UTF-8?q?uette=20to=20allow=20compilation=20for=20Windows=20CE.=20Change?= =?UTF-8?q?s=20literal=20strings=20to=20have=20TEXT()=20so=20convert=20to?= =?UTF-8?q?=20Unicode=20when=20comiling=20for=20Windows=20CE.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- win32/PlatWin.cxx | 12 ++++++------ win32/ScintillaWin.cxx | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'win32') diff --git a/win32/PlatWin.cxx b/win32/PlatWin.cxx index c8a97fb40..6279340a4 100644 --- a/win32/PlatWin.cxx +++ b/win32/PlatWin.cxx @@ -490,7 +490,7 @@ void SurfaceImpl::FillRectangle(PRectangle rc, ColourAllocated back) { // There is no need to allocate a brush either. RECT rcw = RectFromPRectangle(rc); ::SetBkColor(hdc, back.AsLong()); - ::ExtTextOut(hdc, rc.left, rc.top, ETO_OPAQUE, &rcw, "", 0, NULL); + ::ExtTextOut(hdc, rc.left, rc.top, ETO_OPAQUE, &rcw, TEXT(""), 0, NULL); } void SurfaceImpl::FillRectangle(PRectangle rc, Surface &surfacePattern) { @@ -835,9 +835,9 @@ void Window::SetCursor(Cursor curs) { break; case cursorReverseArrow: { if (!hinstPlatformRes) - hinstPlatformRes = ::GetModuleHandle("Scintilla"); + hinstPlatformRes = ::GetModuleHandle(TEXT("Scintilla")); if (!hinstPlatformRes) - hinstPlatformRes = ::GetModuleHandle("SciLexer"); + hinstPlatformRes = ::GetModuleHandle(TEXT("SciLexer")); if (!hinstPlatformRes) hinstPlatformRes = ::GetModuleHandle(NULL); HCURSOR hcursor = ::LoadCursor(hinstPlatformRes, MAKEINTRESOURCE(IDC_MARGIN)); @@ -966,7 +966,7 @@ void ListBoxX::Create(Window &parent, int ctrlID, int lineHeight_, bool unicodeM unicodeMode = unicodeMode_; HINSTANCE hinstanceParent = GetWindowInstance(reinterpret_cast(parent.GetID())); id = ::CreateWindowEx( - WS_EX_WINDOWEDGE, ListBoxX_ClassName, "", + WS_EX_WINDOWEDGE, ListBoxX_ClassName, TEXT(""), WS_CHILD | WS_THICKFRAME, 100,100, 150,80, reinterpret_cast(parent.GetID()), reinterpret_cast(ctrlID), @@ -1136,7 +1136,7 @@ long ListBoxX::WndProc(HWND hWnd, UINT iMessage, WPARAM wParam, LPARAM lParam) { HINSTANCE hinstanceParent = GetWindowInstance(parent); CREATESTRUCT *pCreate = reinterpret_cast(lParam); ::CreateWindowEx( - WS_EX_WINDOWEDGE, "listbox", "", + WS_EX_WINDOWEDGE, TEXT("listbox"), TEXT(""), WS_CHILD | WS_VSCROLL | WS_VISIBLE | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOTIFY, 0, 0, 150,80, hWnd, @@ -1441,7 +1441,7 @@ int Platform::Clamp(int val, int minVal, int maxVal) { } void Platform_Initialise(void *hInstance) { - OSVERSIONINFO osv = {sizeof(OSVERSIONINFO),0,0,0,0,""}; + OSVERSIONINFO osv = {sizeof(OSVERSIONINFO),0,0,0,0,TEXT("")}; ::GetVersionEx(&osv); onNT = osv.dwPlatformId == VER_PLATFORM_WIN32_NT; ::InitializeCriticalSection(&crPlatformLock); diff --git a/win32/ScintillaWin.cxx b/win32/ScintillaWin.cxx index 1f0b6deeb..8dba14b86 100644 --- a/win32/ScintillaWin.cxx +++ b/win32/ScintillaWin.cxx @@ -1279,7 +1279,7 @@ void ScintillaWin::Paste() { void ScintillaWin::CreateCallTipWindow(PRectangle) { #ifdef TOTAL_CONTROL if (!ct.wCallTip.Created()) { - ct.wCallTip = ::CreateWindow(callClassName, "ACallTip", + ct.wCallTip = ::CreateWindow(callClassName, TEXT("ACallTip"), WS_POPUP, 100, 100, 150, 20, MainHWND(), 0, GetWindowInstance(MainHWND()), @@ -1632,7 +1632,7 @@ void ScintillaWin::ImeStartComposition() { // Since the style creation code has been made platform independent, // The logfont for the IME is recreated here. int styleHere = (pdoc->StyleAt(currentPos)) & 31; - LOGFONT lf = {0,0,0,0,0,0,0,0,0,0,0,0,0,""}; + LOGFONT lf = {0,0,0,0,0,0,0,0,0,0,0,0,0,TEXT("")}; int sizeZoomed = vs.styles[styleHere].size + vs.zoomLevel; if (sizeZoomed <= 2) // Hangs if sizeZoomed <= 1 sizeZoomed = 2; -- cgit v1.2.3