]> git.saurik.com Git - wxWidgets.git/blobdiff - src/univ/winuniv.cpp
Remove DoSetSizeHints() call from Create()
[wxWidgets.git] / src / univ / winuniv.cpp
index ce34052eb89b80824814e8c965078bab872eed72..87300a6984176c722f957a3e8690dfcd8977ff66 100644 (file)
@@ -1,10 +1,9 @@
 ///////////////////////////////////////////////////////////////////////////////
-// Name:        src/univ/window.cpp
+// Name:        src/univ/winuniv.cpp
 // Purpose:     implementation of extra wxWindow methods for wxUniv port
 // Author:      Vadim Zeitlin
 // Modified by:
 // Created:     06.08.00
-// RCS-ID:      $Id$
 // Copyright:   (c) 2000 SciTech Software, Inc. (www.scitechsoft.com)
 // Licence:     wxWindows licence
 ///////////////////////////////////////////////////////////////////////////////
@@ -94,8 +93,6 @@ public:
     IMPLEMENT_DYNAMIC_CLASS(wxWindow, wxWindowGTK)
 #elif defined(__WXOSX_OR_COCOA__)
     IMPLEMENT_DYNAMIC_CLASS(wxWindow, wxWindowMac)
-#elif defined(__WXMGL__)
-    IMPLEMENT_DYNAMIC_CLASS(wxWindow, wxWindowMGL)
 #elif defined(__WXDFB__)
     IMPLEMENT_DYNAMIC_CLASS(wxWindow, wxWindowDFB)
 #elif defined(__WXX11__)
@@ -258,7 +255,7 @@ void wxWindow::SetBackground(const wxBitmap& bitmap,
 const wxBitmap& wxWindow::GetBackgroundBitmap(int *alignment,
                                                wxStretch *stretch) const
 {
-    if ( m_bitmapBg.Ok() )
+    if ( m_bitmapBg.IsOk() )
     {
         if ( alignment )
             *alignment = m_alignBgBitmap;
@@ -408,7 +405,7 @@ bool wxWindow::DoDrawBackground(wxDC& dc)
 
 void wxWindow::EraseBackground(wxDC& dc, const wxRect& rect)
 {
-    if ( GetBackgroundBitmap().Ok() )
+    if ( GetBackgroundBitmap().IsOk() )
     {
         // Get the bitmap and the flags
         int alignment;
@@ -718,14 +715,9 @@ void wxWindow::OnSize(wxSizeEvent& event)
 #endif
 }
 
-wxSize wxWindow::DoGetBestSize() const
+wxSize wxWindow::DoGetBorderSize() const
 {
-    return AdjustSize(DoGetBestClientSize());
-}
-
-wxSize wxWindow::DoGetBestClientSize() const
-{
-    return wxWindowNative::DoGetBestSize();
+    return AdjustSize(wxSize(0, 0));
 }
 
 wxSize wxWindow::AdjustSize(const wxSize& size) const
@@ -1329,7 +1321,7 @@ void wxWindow::OnKeyDown(wxKeyEvent& event)
         int command = win->GetAcceleratorTable()->GetCommand(event);
         if ( command != -1 )
         {
-            wxCommandEvent eventCmd(wxEVT_COMMAND_MENU_SELECTED, command);
+            wxCommandEvent eventCmd(wxEVT_MENU, command);
             if ( win->GetEventHandler()->ProcessEvent(eventCmd) )
             {
                 // skip "event.Skip()" below
@@ -1360,7 +1352,7 @@ void wxWindow::OnKeyDown(wxKeyEvent& event)
                 wxWindow* child = win->FindWindow(command);
                 if ( child && wxDynamicCast(child, wxButton) )
                 {
-                    wxCommandEvent eventCmd(wxEVT_COMMAND_BUTTON_CLICKED, command);
+                    wxCommandEvent eventCmd(wxEVT_BUTTON, command);
                     eventCmd.SetEventObject(child);
                     if ( child->GetEventHandler()->ProcessEvent(eventCmd) )
                     {
@@ -1435,7 +1427,7 @@ void wxWindow::OnChar(wxKeyEvent& event)
             wxButton *btn = wxDynamicCast(tlw->GetDefaultItem(), wxButton);
             if ( btn )
             {
-                wxCommandEvent evt(wxEVT_COMMAND_BUTTON_CLICKED, btn->GetId());
+                wxCommandEvent evt(wxEVT_BUTTON, btn->GetId());
                 evt.SetEventObject(btn);
                 btn->Command(evt);
                 return;