summaryrefslogtreecommitdiff
path: root/embedserv/source/embed
diff options
context:
space:
mode:
authorKurt Zenker <kz@openoffice.org>2005-11-04 14:46:09 +0000
committerKurt Zenker <kz@openoffice.org>2005-11-04 14:46:09 +0000
commite66310b728be2a9f2d763ebecf44b66cdb77e8c3 (patch)
tree88226c35e8eeb20e7e4b468d873a67d03be440f3 /embedserv/source/embed
parent3ae08b338055a0cae408a28de7f0d36a151da821 (diff)
INTEGRATION: CWS fwk25 (1.19.2); FILE MERGED
2005/10/21 14:25:49 mav 1.19.2.1: #126265# do not allow to trigger backing component from OLE embedded object
Diffstat (limited to 'embedserv/source/embed')
-rw-r--r--embedserv/source/embed/docholder.cxx28
1 files changed, 26 insertions, 2 deletions
diff --git a/embedserv/source/embed/docholder.cxx b/embedserv/source/embed/docholder.cxx
index ca6a6ca585a4..9e9380ffaa4e 100644
--- a/embedserv/source/embed/docholder.cxx
+++ b/embedserv/source/embed/docholder.cxx
@@ -4,9 +4,9 @@
*
* $RCSfile: docholder.cxx,v $
*
- * $Revision: 1.19 $
+ * $Revision: 1.20 $
*
- * last change: $Author: hr $ $Date: 2005-09-23 15:45:24 $
+ * last change: $Author: kz $ $Date: 2005-11-04 15:46:09 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@@ -97,6 +97,9 @@
#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_
#include <com/sun/star/frame/FrameSearchFlag.hpp>
#endif
+#ifndef _COM_SUN_STAR_FRAME_XSTATUSLISTENER_HPP_
+#include <com/sun/star/frame/XStatusListener.hpp>
+#endif
#ifndef _COM_SUN_STAR_UTIL_XMODIFYBROADCASTER_HPP_
#include <com/sun/star/util/XModifyBroadcaster.hpp>
#endif
@@ -901,6 +904,27 @@ void DocumentHolder::show()
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self")),
0,
aSeq);
+
+ try
+ {
+ // get rid of second closer if it is there
+ uno::Reference< beans::XPropertySet > xProps( m_xFrame, uno::UNO_QUERY );
+ if ( xProps.is() )
+ {
+ uno::Reference< frame::XLayoutManager > xLayoutManager;
+ xProps->getPropertyValue( rtl::OUString::createFromAscii( "LayoutManager" ) ) >>= xLayoutManager;
+ uno::Reference< beans::XPropertySet > xLMProps( xLayoutManager, uno::UNO_QUERY );
+ if ( xLMProps.is() )
+ {
+ xLMProps->setPropertyValue( ::rtl::OUString::createFromAscii( "MenuBarCloser" ),
+ uno::makeAny( uno::Reference< frame::XStatusListener >() ) );
+ }
+ }
+ }
+ catch( uno::Exception& )
+ {
+ OSL_ENSURE( sal_False, "Can not adjust the frame!\n" );
+ }
}
setTitle(m_aDocumentNamePart);
}