summaryrefslogtreecommitdiff
path: root/svtools/source/hatchwindow
diff options
context:
space:
mode:
authorRüdiger Timm <rt@openoffice.org>2006-02-09 12:59:36 +0000
committerRüdiger Timm <rt@openoffice.org>2006-02-09 12:59:36 +0000
commiteffb97f3ea267cdee46f7ee0c2bac8d0427ec4e9 (patch)
treeaca2aee6b00707bd147859ae34a6d9f30b6de206 /svtools/source/hatchwindow
parentfe9e4bc3ad2d498bee3b5e191dc9266a14c08168 (diff)
INTEGRATION: CWS fwk32 (1.4.158); FILE MERGED
2006/01/30 11:34:15 mav 1.4.158.1: #120410#,#i59437# allow to close document frame correctly
Diffstat (limited to 'svtools/source/hatchwindow')
-rw-r--r--svtools/source/hatchwindow/hatchwindowfactory.cxx34
-rw-r--r--svtools/source/hatchwindow/makefile.mk5
2 files changed, 33 insertions, 6 deletions
diff --git a/svtools/source/hatchwindow/hatchwindowfactory.cxx b/svtools/source/hatchwindow/hatchwindowfactory.cxx
index 0474f5841e9f..49ea0856437a 100644
--- a/svtools/source/hatchwindow/hatchwindowfactory.cxx
+++ b/svtools/source/hatchwindow/hatchwindowfactory.cxx
@@ -4,9 +4,9 @@
*
* $RCSfile: hatchwindowfactory.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: rt $ $Date: 2005-09-08 15:50:42 $
+ * last change: $Author: rt $ $Date: 2006-02-09 13:59:22 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@@ -40,6 +40,8 @@
#include "cppuhelper/factory.hxx"
#endif
+#include "documentcloser.hxx"
+
using namespace ::com::sun::star;
//-------------------------------------------------------------------------
@@ -127,16 +129,31 @@ SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_writeInfo (
reinterpret_cast< registry::XRegistryKey* >(pRegistryKey));
uno::Reference< registry::XRegistryKey> xNewKey;
+ // OHatchWindowFactory registration
+
xNewKey = xRegistryKey->createKey (
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/") ) +
OHatchWindowFactory::impl_staticGetImplementationName() +
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/UNO/SERVICES") ) );
- const uno::Sequence< ::rtl::OUString > aServices (
- OHatchWindowFactory::impl_staticGetSupportedServiceNames());
+ uno::Sequence< ::rtl::OUString > aServices =
+ OHatchWindowFactory::impl_staticGetSupportedServiceNames();
for (sal_Int32 i = 0, n = aServices.getLength(); i < n; i++ )
xNewKey->createKey( aServices.getConstArray()[i] );
+
+ // ODocumentCloser registration
+
+ xNewKey = xRegistryKey->createKey (
+ ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/") ) +
+ ODocumentCloser::impl_staticGetImplementationName() +
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/UNO/SERVICES") ) );
+
+ aServices = ODocumentCloser::impl_staticGetSupportedServiceNames();
+ for (sal_Int32 i = 0, n = aServices.getLength(); i < n; i++ )
+ xNewKey->createKey( aServices.getConstArray()[i] );
+
+
return sal_True;
}
return sal_False;
@@ -157,6 +174,15 @@ SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory (
OHatchWindowFactory::impl_staticCreateSelfInstance,
OHatchWindowFactory::impl_staticGetSupportedServiceNames());
}
+ else if (ODocumentCloser::impl_staticGetImplementationName().compareToAscii (pImplementationName ) == 0)
+ {
+ xFactory = cppu::createSingleFactory(
+ reinterpret_cast< lang::XMultiServiceFactory* >( pServiceManager ),
+ ODocumentCloser::impl_staticGetImplementationName(),
+ ODocumentCloser::impl_staticCreateSelfInstance,
+ ODocumentCloser::impl_staticGetSupportedServiceNames() );
+ }
+
if (xFactory.is())
{
xFactory->acquire();
diff --git a/svtools/source/hatchwindow/makefile.mk b/svtools/source/hatchwindow/makefile.mk
index a6ef3d253e9d..f34aebfb15a3 100644
--- a/svtools/source/hatchwindow/makefile.mk
+++ b/svtools/source/hatchwindow/makefile.mk
@@ -4,9 +4,9 @@
#
# $RCSfile: makefile.mk,v $
#
-# $Revision: 1.4 $
+# $Revision: 1.5 $
#
-# last change: $Author: rt $ $Date: 2005-09-08 15:51:31 $
+# last change: $Author: rt $ $Date: 2006-02-09 13:59:36 $
#
# The Contents of this file are made available subject to
# the terms of GNU Lesser General Public License Version 2.1.
@@ -49,6 +49,7 @@ DLLPRE=
SLOFILES= \
$(SLO)$/hatchwindow.obj\
$(SLO)$/hatchwindowfactory.obj\
+ $(SLO)$/documentcloser.obj\
$(SLO)$/ipwin.obj
SHL1TARGET= $(TARGET)