From bf487502d9ca029432ca1c91a42d2701c2590e7f Mon Sep 17 00:00:00 2001 From: Paul Cornett Date: Sat, 29 Dec 2012 06:29:52 +0000 Subject: [PATCH] make GTKNeedsParent() private git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73310 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/gtk/menu.h | 8 ++++---- include/wx/gtk/window.h | 10 +++++----- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/include/wx/gtk/menu.h b/include/wx/gtk/menu.h index 7732a9ab84..c2841074ef 100644 --- a/include/wx/gtk/menu.h +++ b/include/wx/gtk/menu.h @@ -41,10 +41,6 @@ public: void SetLayoutDirection(wxLayoutDirection dir); wxLayoutDirection GetLayoutDirection() const; - // wxMenuBar is not a top level window but it still doesn't need a parent - // window - virtual bool GTKNeedsParent() const { return false; } - virtual void Attach(wxFrame *frame); virtual void Detach(); @@ -54,6 +50,10 @@ private: void Init(size_t n, wxMenu *menus[], const wxString titles[], long style); + // wxMenuBar is not a top level window but it still doesn't need a parent + // window + virtual bool GTKNeedsParent() const { return false; } + GtkWidget* m_menubar; DECLARE_DYNAMIC_CLASS(wxMenuBar) diff --git a/include/wx/gtk/window.h b/include/wx/gtk/window.h index 4e4185787b..decd337ac0 100644 --- a/include/wx/gtk/window.h +++ b/include/wx/gtk/window.h @@ -184,11 +184,6 @@ public: static wxLayoutDirection GTKGetLayout(GtkWidget *widget); static void GTKSetLayout(GtkWidget *widget, wxLayoutDirection dir); - // return true if this window must have a non-NULL parent, false if it can - // be created without parent (normally only top level windows but in wxGTK - // there is also the exception of wxMenuBar) - virtual bool GTKNeedsParent() const { return !IsTopLevel(); } - // This is called when capture is taken from the window. It will // fire off capture lost events. void GTKReleaseMouseAndNotify(); @@ -404,6 +399,11 @@ protected: private: void Init(); + // return true if this window must have a non-NULL parent, false if it can + // be created without parent (normally only top level windows but in wxGTK + // there is also the exception of wxMenuBar) + virtual bool GTKNeedsParent() const { return !IsTopLevel(); } + enum ScrollUnit { ScrollUnit_Line, ScrollUnit_Page, ScrollUnit_Max }; // common part of ScrollLines() and ScrollPages() and could be used, in the -- 2.45.2