diff options
author | RĂ¼diger Timm <rt@openoffice.org> | 2004-11-25 13:26:49 +0000 |
---|---|---|
committer | RĂ¼diger Timm <rt@openoffice.org> | 2004-11-25 13:26:49 +0000 |
commit | 0e524f254817061e6fa443d9c13dc7ca087425f2 (patch) | |
tree | a2605cf971cc01f0527ea2a159dae4b5c5d3b692 /dbaccess/source/ui/app/AppControllerGen.cxx | |
parent | 6f57dc11c398c5c1e2359248c8cd9149a182c900 (diff) |
#i37819# Patch by oj to avoid crash when closing database.
Diffstat (limited to 'dbaccess/source/ui/app/AppControllerGen.cxx')
-rw-r--r-- | dbaccess/source/ui/app/AppControllerGen.cxx | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/dbaccess/source/ui/app/AppControllerGen.cxx b/dbaccess/source/ui/app/AppControllerGen.cxx index 20a3dbe45..1630e575b 100644 --- a/dbaccess/source/ui/app/AppControllerGen.cxx +++ b/dbaccess/source/ui/app/AppControllerGen.cxx @@ -2,9 +2,9 @@ * * $RCSfile: AppControllerGen.cxx,v $ * - * $Revision: 1.7 $ + * $Revision: 1.8 $ * - * last change: $Author: obo $ $Date: 2004-11-22 15:01:17 $ + * last change: $Author: rt $ $Date: 2004-11-25 14:26:49 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -608,15 +608,18 @@ sal_Bool OApplicationController::isRenameDeleteAllowed(ElementType _eType,sal_Bo void OApplicationController::onLoadedMenu(const Reference< drafts::com::sun::star::frame::XLayoutManager >& _xLayoutManager) { - static ::rtl::OUString s_sStatusbar(RTL_CONSTASCII_USTRINGPARAM("private:resource/statusbar/statusbar")); - _xLayoutManager->createElement( s_sStatusbar ); - _xLayoutManager->requestElement( s_sStatusbar ); + if ( _xLayoutManager.is() ) + { + static ::rtl::OUString s_sStatusbar(RTL_CONSTASCII_USTRINGPARAM("private:resource/statusbar/statusbar")); + _xLayoutManager->createElement( s_sStatusbar ); + _xLayoutManager->requestElement( s_sStatusbar ); - if ( getContainer() ) - getContainer()->createIconAutoMnemonics(); + if ( getContainer() ) + getContainer()->createIconAutoMnemonics(); - Execute( SID_DB_APP_VIEW_FORMS, Sequence< PropertyValue >() ); - InvalidateAll(); + Execute( SID_DB_APP_VIEW_FORMS, Sequence< PropertyValue >() ); + InvalidateAll(); + } } // ----------------------------------------------------------------------------- void OApplicationController::doAction(sal_uInt16 _nId ,sal_Bool _bEdit) |