]> git.saurik.com Git - wxWidgets.git/blobdiff - src/aui/auibook.cpp
supporting -1 as 'to' parameter for selections
[wxWidgets.git] / src / aui / auibook.cpp
index 543a7c3cb3cbd1463a511693d729c934e79ea6e1..289faccafaa20ade519b7f6b1ae9a6688ce8dbc4 100644 (file)
@@ -3064,6 +3064,10 @@ bool wxAuiNotebook::InsertPage(size_t page_idx,
                                bool select,
                                const wxBitmap& bitmap)
 {
+    wxASSERT_MSG(page, wxT("page pointer must be non-NULL"));
+    if (!page)
+        return false;
+    
     page->Reparent(this);
 
     wxAuiNotebookPage info;
@@ -4370,13 +4374,6 @@ bool wxAuiNotebook::SetFont(const wxFont& font)
     SetSelectedFont(selectedFont);
     SetMeasuringFont(selectedFont);
 
-    if (GetArtProvider())
-    {
-        GetArtProvider()->SetNormalFont(normalFont);
-        GetArtProvider()->SetSelectedFont(selectedFont);
-        GetArtProvider()->SetMeasuringFont(selectedFont);
-    }
-    
     return true;
 }