]> git.saurik.com Git - wxWidgets.git/blobdiff - src/aui/framemanager.cpp
use CPPUNIT_ASSERT_MESSAGE() to show which test exactly failed; use more CPPUNIT_ASSE...
[wxWidgets.git] / src / aui / framemanager.cpp
index 53345802dc604f3982d6262eb8d66c36ec409a07..18453eb82958e0fc52272e1d3da0feb20b56dcb3 100644 (file)
@@ -834,7 +834,14 @@ bool wxAuiManager::AddPane(wxWindow* window, const wxAuiPaneInfo& pane_info)
         button.button_id = wxAUI_BUTTON_MAXIMIZE_RESTORE;
         pinfo.buttons.Add(button);
     }
-
+    
+    if (pinfo.HasPinButton())
+    {
+        wxAuiPaneButton button;
+        button.button_id = wxAUI_BUTTON_PIN;
+        pinfo.buttons.Add(button);
+    }
+    
     if (pinfo.HasCloseButton())
     {
         wxAuiPaneButton button;
@@ -3527,10 +3534,12 @@ void wxAuiManager::OnSetCursor(wxSetCursorEvent& event)
 
 
 void wxAuiManager::UpdateButtonOnScreen(wxAuiDockUIPart* button_ui_part,
-                                          const wxMouseEvent& event)
+                                        const wxMouseEvent& event)
 {
     wxAuiDockUIPart* hit_test = HitTest(event.GetX(), event.GetY());
-
+    if (!hit_test || !button_ui_part)
+        return;
+        
     int state = wxAUI_BUTTON_STATE_NORMAL;
 
     if (hit_test == button_ui_part)