aboutsummaryrefslogtreecommitdiffhomepage
path: root/win32
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2004-12-03 23:15:54 +0000
committernyamatongwe <devnull@localhost>2004-12-03 23:15:54 +0000
commit5ad20736dd11bdf99afe06786411c2fe4ab891d8 (patch)
tree3aff5ac5f978a3725e055d146e65a4c39ff1cf37 /win32
parentc9b93d87e1ac6f6a11fc42561fc00ae44b17e1ac (diff)
downloadscintilla-mirror-5ad20736dd11bdf99afe06786411c2fe4ab891d8.tar.gz
Safest portion of patch from Régis Vaquette to allow compilation
for Windows CE. Changes literal strings to have TEXT() so convert to Unicode when comiling for Windows CE.
Diffstat (limited to 'win32')
-rw-r--r--win32/PlatWin.cxx12
-rw-r--r--win32/ScintillaWin.cxx4
2 files changed, 8 insertions, 8 deletions
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<HWND>(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<HWND>(parent.GetID()),
reinterpret_cast<HMENU>(ctrlID),
@@ -1136,7 +1136,7 @@ long ListBoxX::WndProc(HWND hWnd, UINT iMessage, WPARAM wParam, LPARAM lParam) {
HINSTANCE hinstanceParent = GetWindowInstance(parent);
CREATESTRUCT *pCreate = reinterpret_cast<CREATESTRUCT *>(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;