From 08a581335008a302a5104d9629359ab6eab61de4 Mon Sep 17 00:00:00 2001 From: =?utf8?q?W=C5=82odzimierz=20Skiba?= Date: Tue, 5 Sep 2006 19:23:15 +0000 Subject: [PATCH] WinCE build fixes. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41018 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/msw/msgdlg.cpp | 2 ++ src/msw/toplevel.cpp | 6 ++++-- src/msw/window.cpp | 8 ++++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/msw/msgdlg.cpp b/src/msw/msgdlg.cpp index c8aaa8ef73..d19261705e 100644 --- a/src/msw/msgdlg.cpp +++ b/src/msw/msgdlg.cpp @@ -97,8 +97,10 @@ int wxMessageDialog::ShowModal() if ( wxStyle & wxSTAY_ON_TOP ) msStyle |= MB_TOPMOST; +#ifndef __WXWINCE__ if ( wxTheApp->GetLayoutDirection() == wxLayout_RightToLeft ) msStyle |= MB_RTLREADING | MB_RIGHT; +#endif if (hWnd) msStyle |= MB_APPLMODAL; diff --git a/src/msw/toplevel.cpp b/src/msw/toplevel.cpp index 214fbc7718..b2af8b2483 100644 --- a/src/msw/toplevel.cpp +++ b/src/msw/toplevel.cpp @@ -503,8 +503,10 @@ bool wxTopLevelWindowMSW::CreateFrame(const wxString& title, const wxSize sz = IsAlwaysMaximized() ? wxDefaultSize : size; +#ifndef __WXWINCE__ if ( wxTheApp->GetLayoutDirection() == wxLayout_RightToLeft ) exflags |= WS_EX_LAYOUTRTL; +#endif return MSWCreate(wxCanvasClassName, title, pos, sz, flags, exflags); } @@ -564,13 +566,13 @@ bool wxTopLevelWindowMSW::Create(wxWindow *parent, // all dialogs are popups dlgTemplate->style |= WS_POPUP; - + +#ifndef __WXWINCE__ if ( wxTheApp->GetLayoutDirection() == wxLayout_RightToLeft ) { dlgTemplate->dwExtendedStyle |= WS_EX_LAYOUTRTL; } -#ifndef __WXWINCE__ // force 3D-look if necessary, it looks impossibly ugly otherwise if ( style & (wxRESIZE_BORDER | wxCAPTION) ) dlgTemplate->style |= DS_MODALFRAME; diff --git a/src/msw/window.cpp b/src/msw/window.cpp index 2ebf6bfbc7..b68d59085d 100644 --- a/src/msw/window.cpp +++ b/src/msw/window.cpp @@ -1024,6 +1024,9 @@ bool wxWindowMSW::ScrollPages(int pages) void wxWindowMSW::SetLayoutDirection(wxLayoutDirection dir) { +#ifdef __WXWINCE__ + wxUnusedVar(dir); +#else const HWND hwnd = GetHwnd(); wxCHECK_RET( hwnd, _T("layout direction must be set after window creation") ); @@ -1049,16 +1052,21 @@ void wxWindowMSW::SetLayoutDirection(wxLayoutDirection dir) { ::SetWindowLong(hwnd, GWL_EXSTYLE, styleNew); } +#endif } wxLayoutDirection wxWindowMSW::GetLayoutDirection() const { +#ifdef __WXWINCE__ + return wxLayout_Default; +#else const HWND hwnd = GetHwnd(); wxCHECK_MSG( hwnd, wxLayout_Default, _T("invalid window") ); return ::GetWindowLong(hwnd, GWL_EXSTYLE) & WS_EX_LAYOUTRTL ? wxLayout_RightToLeft : wxLayout_LeftToRight; +#endif } wxCoord -- 2.45.2