diff options
-rw-r--r-- | basctl/source/basicide/baside3.cxx | 21 | ||||
-rw-r--r-- | basctl/source/dlged/propbrw.cxx | 1 | ||||
-rw-r--r-- | basctl/source/inc/baside3.hxx | 2 |
3 files changed, 10 insertions, 14 deletions
diff --git a/basctl/source/basicide/baside3.cxx b/basctl/source/basicide/baside3.cxx index 528e3acc9133..0f4c9b7463ab 100644 --- a/basctl/source/basicide/baside3.cxx +++ b/basctl/source/basicide/baside3.cxx @@ -1415,6 +1415,15 @@ DialogWindowLayout::DialogWindowLayout (Window* pParent, ObjectCatalog& rObjectC ShowPropertyBrowser(); } +DialogWindowLayout::~DialogWindowLayout() +{ + if (pPropertyBrowser != 0) + { + Remove(pPropertyBrowser); + delete pPropertyBrowser; + } +} + // shows the property browser (and creates if necessary) void DialogWindowLayout::ShowPropertyBrowser () { @@ -1451,18 +1460,6 @@ void DialogWindowLayout::UpdatePropertyBrowser () pPropertyBrowser->Update(GetShell()); } -// Removes the property browser from the layout. -// Called by PropBrw when closed. It'll destroy itself. -void DialogWindowLayout::RemovePropertyBrowser () -{ - if (pPropertyBrowser) - Remove(pPropertyBrowser); - pPropertyBrowser = 0; - // refreshing the button state - if (SfxBindings* pBindings = GetBindingsPtr()) - pBindings->Invalidate(SID_SHOW_PROPERTYBROWSER); -} - void DialogWindowLayout::Activating (BaseWindow& rChild) { assert(dynamic_cast<DialogWindow*>(&rChild)); diff --git a/basctl/source/dlged/propbrw.cxx b/basctl/source/dlged/propbrw.cxx index 4a050e70ad86..60e58df50236 100644 --- a/basctl/source/dlged/propbrw.cxx +++ b/basctl/source/dlged/propbrw.cxx @@ -199,7 +199,6 @@ PropBrw::~PropBrw() { if ( m_xBrowserController.is() ) ImplDestroyController(); - rLayout.RemovePropertyBrowser(); DBG_DTOR(PropBrw,NULL); } diff --git a/basctl/source/inc/baside3.hxx b/basctl/source/inc/baside3.hxx index 2b0b476d3259..eaeefdd64b7b 100644 --- a/basctl/source/inc/baside3.hxx +++ b/basctl/source/inc/baside3.hxx @@ -126,11 +126,11 @@ class DialogWindowLayout : public Layout { public: DialogWindowLayout (Window* pParent, ObjectCatalog&); + ~DialogWindowLayout(); public: void ShowPropertyBrowser (); void UpdatePropertyBrowser (); void DisablePropertyBrowser (); - void RemovePropertyBrowser (); public: // Layout: virtual void Activating (BaseWindow&); |