aui: allow m_frame to be null in wxFrameManager
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42807 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -260,6 +260,8 @@ public:
|
|||||||
const wxSize& size = wxDefaultSize,
|
const wxSize& size = wxDefaultSize,
|
||||||
long style = 0);
|
long style = 0);
|
||||||
|
|
||||||
|
~wxAuiTabCtrl();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
void OnPaint(wxPaintEvent& evt);
|
void OnPaint(wxPaintEvent& evt);
|
||||||
|
@@ -952,6 +952,9 @@ wxAuiTabCtrl::wxAuiTabCtrl(wxWindow* parent,
|
|||||||
m_hover_button = NULL;
|
m_hover_button = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
wxAuiTabCtrl::~wxAuiTabCtrl()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
void wxAuiTabCtrl::OnPaint(wxPaintEvent&)
|
void wxAuiTabCtrl::OnPaint(wxPaintEvent&)
|
||||||
{
|
{
|
||||||
|
@@ -486,6 +486,7 @@ wxFrameManager::wxFrameManager(wxWindow* managed_wnd, unsigned int flags)
|
|||||||
m_hint_wnd = NULL;
|
m_hint_wnd = NULL;
|
||||||
m_flags = flags;
|
m_flags = flags;
|
||||||
m_skipping = false;
|
m_skipping = false;
|
||||||
|
m_frame = NULL;
|
||||||
|
|
||||||
if (managed_wnd)
|
if (managed_wnd)
|
||||||
{
|
{
|
||||||
@@ -740,9 +741,12 @@ void wxFrameManager::SetManagedWindow(wxWindow* wnd)
|
|||||||
// of the frame class. If it is not called, usually this
|
// of the frame class. If it is not called, usually this
|
||||||
// will result in a crash upon program exit
|
// will result in a crash upon program exit
|
||||||
void wxFrameManager::UnInit()
|
void wxFrameManager::UnInit()
|
||||||
|
{
|
||||||
|
if (m_frame)
|
||||||
{
|
{
|
||||||
m_frame->RemoveEventHandler(this);
|
m_frame->RemoveEventHandler(this);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// GetManagedWindow() returns the window pointer being managed
|
// GetManagedWindow() returns the window pointer being managed
|
||||||
wxWindow* wxFrameManager::GetManagedWindow() const
|
wxWindow* wxFrameManager::GetManagedWindow() const
|
||||||
|
Reference in New Issue
Block a user