]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/control.cpp
Better fix
[wxWidgets.git] / src / msw / control.cpp
index fa9989fb1cf011fe81d970f09248f66576c35098..b58195c0cf56d8b274f99f3eb4bc4a068f1467a7 100644 (file)
@@ -144,8 +144,8 @@ bool wxControl::MSWCreateControl(const wxChar *classname,
                         label.wx_str(),     // the window name
                         style,              // the window style
                         x, y, w, h,         // the window position and size
                         label.wx_str(),     // the window name
                         style,              // the window style
                         x, y, w, h,         // the window position and size
-                        GetHwndOf(GetParent()),  // parent
-                        (HMENU)GetId(),     // child id
+                        GetHwndOf(GetParent()),         // parent
+                        (HMENU)wxUIntToPtr(GetId()),    // child id
                         wxGetInstance(),    // app instance
                         NULL                // creation parameters
                        );
                         wxGetInstance(),    // app instance
                         NULL                // creation parameters
                        );
@@ -153,11 +153,11 @@ bool wxControl::MSWCreateControl(const wxChar *classname,
     if ( !m_hWnd )
     {
 #ifdef __WXDEBUG__
     if ( !m_hWnd )
     {
 #ifdef __WXDEBUG__
-        wxFAIL_MSG(wxString::Format
-                   (
-                    _T("CreateWindowEx(\"%s\", flags=%08x, ex=%08x) failed"),
-                    classname, (unsigned int)style, (unsigned int)exstyle
-                   ));
+        wxLogLastError(wxString::Format
+                       (
+                        _T("CreateWindowEx(\"%s\", flags=%08lx, ex=%08lx)"),
+                        classname, style, exstyle
+                       ));
 #endif // __WXDEBUG__
 
         return false;
 #endif // __WXDEBUG__
 
         return false;