]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/msw/private.h
define wxUSE_REGKEY for WinCE too (closes #10211)
[wxWidgets.git] / include / wx / msw / private.h
index 28ad14f14209b2df568c9ca61985c8384c307fd9..146d2d3a372cc67fd389931bc4818b850c511465 100644 (file)
 
 #include "wx/log.h"
 
+#if wxUSE_GUI
+    #include "wx/window.h"
+#endif // wxUSE_GUI
+
 class WXDLLIMPEXP_FWD_CORE wxFont;
 class WXDLLIMPEXP_FWD_CORE wxWindow;
 class WXDLLIMPEXP_FWD_CORE wxWindowBase;
@@ -900,6 +904,21 @@ inline bool wxStyleHasBorder(long style)
                      wxSUNKEN_BORDER | wxDOUBLE_BORDER)) != 0;
 }
 
+inline long wxGetWindowExStyle(const wxWindowMSW *win)
+{
+    return ::GetWindowLong(GetHwndOf(win), GWL_EXSTYLE);
+}
+
+inline bool wxHasWindowExStyle(const wxWindowMSW *win, long style)
+{
+    return (wxGetWindowExStyle(win) & style) != 0;
+}
+
+inline long wxSetWindowExStyle(const wxWindowMSW *win, long style)
+{
+    return ::SetWindowLong(GetHwndOf(win), GWL_EXSTYLE, style);
+}
+
 // ----------------------------------------------------------------------------
 // functions mapping HWND to wxWindow
 // ----------------------------------------------------------------------------
@@ -911,7 +930,7 @@ extern WXDLLIMPEXP_CORE wxWindow* wxFindWinFromHandle(HWND hwnd);
 // without STRICT WXHWND is the same as HWND anyhow
 inline wxWindow* wxFindWinFromHandle(WXHWND hWnd)
 {
-    return wxFindWinFromHandle(wx_static_cast(HWND, hWnd));
+    return wxFindWinFromHandle(static_cast<HWND>(hWnd));
 }
 
 // find the window for HWND which is part of some wxWindow, i.e. unlike