X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9dc44eff0235c5f30940f32ccc6d9d82a236e7d2..11a23db53128bf244a089123b7fd27deb577a889:/src/gtk/notebook.cpp diff --git a/src/gtk/notebook.cpp b/src/gtk/notebook.cpp index 2423006517..71ebdcf3a9 100644 --- a/src/gtk/notebook.cpp +++ b/src/gtk/notebook.cpp @@ -2,7 +2,6 @@ // Name: src/gtk/notebook.cpp // Purpose: // Author: Robert Roebling -// Id: $Id$ // Copyright: (c) 1998 Robert Roebling, Vadim Zeitlin // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// @@ -314,7 +313,7 @@ wxSize wxNotebook::CalcSizeFromPage(const wxSize& sizePage) const for ( size_t n = 0; n < pageCount; n++ ) { GtkRequisition req; - gtk_widget_size_request(GetNotebookPage(n)->m_box, &req); + gtk_widget_get_preferred_size(GetNotebookPage(n)->m_box, NULL, &req); sizeTabMax.IncTo(wxSize(req.width, req.height)); } @@ -429,7 +428,7 @@ bool wxNotebook::InsertPage( size_t position, // first page. pageData->m_imageIndex = imageId; - pageData->m_box = gtk_hbox_new(false, 1); + pageData->m_box = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 1); gtk_container_set_border_width(GTK_CONTAINER(pageData->m_box), 2); pageData->m_image = NULL; @@ -503,7 +502,7 @@ int wxNotebook::HitTest(const wxPoint& pt, long *flags) const const size_t count = GetPageCount(); size_t i = 0; -#if !GTK_CHECK_VERSION(3,0,0) && !defined(GSEAL_ENABLE) +#ifndef __WXGTK3__ GtkNotebook * notebook = GTK_NOTEBOOK(m_widget); if (gtk_notebook_get_scrollable(notebook)) i = g_list_position( notebook->children, notebook->first_tab ); @@ -607,7 +606,7 @@ GdkWindow *wxNotebook::GTKGetWindow(wxArrayGdkWindows& windows) const wxVisualAttributes wxNotebook::GetClassDefaultAttributes(wxWindowVariant WXUNUSED(variant)) { - return GetDefaultAttributesFromGTKWidget(gtk_notebook_new); + return GetDefaultAttributesFromGTKWidget(gtk_notebook_new()); } #endif