summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorPhilipp Lohmann [pl] <Philipp.Lohmann@Oracle.COM>2011-01-26 14:01:31 +0100
committerPhilipp Lohmann [pl] <Philipp.Lohmann@Oracle.COM>2011-01-26 14:01:31 +0100
commit096f56c6978a2d6570b0cc47016d344d5ef54a5a (patch)
tree76d7837cb36a6e317678930c3e32857331284d5a /vcl
parentbb3127a8c053434ab1f4c42624b3d70a5fbfa9e6 (diff)
vcl2gnumake: #i116588# move vcl to gbuild (step 2)
Diffstat (limited to 'vcl')
-rw-r--r--vcl/Library_desktop_detector.mk2
-rw-r--r--vcl/Library_vcl.mk136
-rw-r--r--vcl/Library_vclplug_gen.mk2
-rw-r--r--vcl/Library_vclplug_gtk.mk2
-rw-r--r--vcl/Library_vclplug_kde.mk2
-rw-r--r--vcl/Library_vclplug_kde4.mk2
-rw-r--r--vcl/Library_vclplug_svp.mk2
-rw-r--r--vcl/Module_vcl.mk2
-rw-r--r--vcl/aqua/source/dtrans/aqua_service.cxx86
-rw-r--r--vcl/aqua/source/dtrans/test_aquacb.cxx208
10 files changed, 120 insertions, 324 deletions
diff --git a/vcl/Library_desktop_detector.mk b/vcl/Library_desktop_detector.mk
index 4a96d194e7f6..f98be027fa1d 100644
--- a/vcl/Library_desktop_detector.mk
+++ b/vcl/Library_desktop_detector.mk
@@ -27,6 +27,8 @@
$(eval $(call gb_Library_Library,desktop_detector))
+$(eval $(call gb_Library_add_package_headers,vcl,vcl_inc))
+
$(eval $(call gb_Library_add_precompiled_header,desktop_detector,$(SRCDIR)/vcl/inc/pch/precompiled_vcl))
$(eval $(call gb_Library_set_include,desktop_detector,\
diff --git a/vcl/Library_vcl.mk b/vcl/Library_vcl.mk
index a8d39c2bba53..487f9cce5754 100644
--- a/vcl/Library_vcl.mk
+++ b/vcl/Library_vcl.mk
@@ -40,7 +40,7 @@ $(eval $(call gb_Library_set_include,vcl,\
-I$(OUTDIR)/inc/stl \
-I$(OUTDIR)/inc \
))
-ifeq ($(GUI),UNX)
+ifeq ($(GUIBASE),unx)
$(eval $(call gb_Library_set_cxxflags,vcl,\
$$(CXXFLAGS) \
$$(FREETYPE_CFLAGS) \
@@ -78,23 +78,114 @@ $(eval $(call gb_Library_add_linked_static_libs,vcl,\
graphite \
))
endif
-ifeq ($(GUI),UNX)
+ifeq ($(GUIBASE),unx)
$(eval $(call gb_Library_add_linked_libs,vcl,\
freetype \
))
endif
-ifeq ($(GUI),UNX)
+ifeq ($(GUIBASE),aqua)
+$(eval $(call gb_Library_set_cxxflags,vcl,\
+ $$(CXXFLAGS) \
+ $$(OBJCXXFLAGS) \
+))
+$(eval $(call gb_Library_add_add_objcxxobjects,vcl,\
+ vcl/aqua/source/a11y/aqua11yactionwrapper \
+ vcl/aqua/source/a11y/aqua11ycomponentwrapper \
+ vcl/aqua/source/a11y/aqua11yfactory \
+ vcl/aqua/source/a11y/aqua11yrolehelper \
+ vcl/aqua/source/a11y/aqua11yselectionwrapper \
+ vcl/aqua/source/a11y/aqua11ytablewrapper \
+ vcl/aqua/source/a11y/aqua11ytextattributeswrapper \
+ vcl/aqua/source/a11y/aqua11ytextwrapper \
+ vcl/aqua/source/a11y/aqua11yutil \
+ vcl/aqua/source/a11y/aqua11yvaluewrapper \
+ vcl/aqua/source/a11y/aqua11ywrapper \
+ vcl/aqua/source/a11y/aqua11ywrapperbutton \
+ vcl/aqua/source/a11y/aqua11ywrappercheckbox \
+ vcl/aqua/source/a11y/aqua11ywrappercombobox \
+ vcl/aqua/source/a11y/aqua11ywrappergroup \
+ vcl/aqua/source/a11y/aqua11ywrapperlist \
+ vcl/aqua/source/a11y/aqua11ywrapperradiobutton \
+ vcl/aqua/source/a11y/aqua11ywrapperradiogroup \
+ vcl/aqua/source/a11y/aqua11ywrapperrow \
+ vcl/aqua/source/a11y/aqua11ywrapperscrollarea \
+ vcl/aqua/source/a11y/aqua11ywrapperscrollbar \
+ vcl/aqua/source/a11y/aqua11ywrappersplitter \
+ vcl/aqua/source/a11y/aqua11ywrapperstatictext \
+ vcl/aqua/source/a11y/aqua11ywrappertabgroup \
+ vcl/aqua/source/a11y/aqua11ywrappertextarea \
+ vcl/aqua/source/a11y/aqua11ywrappertoolbar \
+ vcl/aqua/source/app/salnstimer \
+ vcl/aqua/source/app/vclnsapp \
+ vcl/aqua/source/gdi/aquaprintaccessoryview \
+ vcl/aqua/source/gdi/aquaprintview \
+ vcl/aqua/source/window/salframeview \
+ vcl/aqua/source/window/salnsmenu \
+))
$(eval $(call gb_Library_add_exception_objects,vcl,\
- vcl/unx/generic/printer/cupsmgr \
- vcl/unx/generic/printer/jobdata \
- vcl/unx/generic/printer/ppdparser \
- vcl/unx/generic/printer/printerinfomanager \
+ vcl/aqua/source/a11y/aqua11yfocuslistener \
+ vcl/aqua/source/a11y/aqua11yfocustracker \
+ vcl/aqua/source/a11y/aqua11ylistener \
+ vcl/aqua/source/a11y/documentfocuslistener \
+ vcl/aqua/source/app/saldata \
+ vcl/aqua/source/app/salinst \
+ vcl/aqua/source/app/salsys \
+ vcl/aqua/source/app/saltimer \
+ vcl/aqua/source/dtrans/DataFlavorMapping \
+ vcl/aqua/source/dtrans/DragActionConversion \
+ vcl/aqua/source/dtrans/DragSource \
+ vcl/aqua/source/dtrans/DragSourceContext \
+ vcl/aqua/source/dtrans/DropTarget \
+ vcl/aqua/source/dtrans/HtmlFmtFlt \
+ vcl/aqua/source/dtrans/OSXTransferable \
+ vcl/aqua/source/dtrans/PictToBmpFlt \
+ vcl/aqua/source/dtrans/aqua_clipboard \
+ vcl/aqua/source/dtrans/service_entry \
+ vcl/aqua/source/gdi/salatslayout \
+ vcl/aqua/source/gdi/salatsuifontutils \
+ vcl/aqua/source/gdi/salbmp \
+ vcl/aqua/source/gdi/salcolorutils \
+ vcl/aqua/source/gdi/salgdi \
+ vcl/aqua/source/gdi/salgdiutils \
+ vcl/aqua/source/gdi/salmathutils \
+ vcl/aqua/source/gdi/salnativewidgets \
+ vcl/aqua/source/gdi/salprn \
+ vcl/aqua/source/gdi/salvd \
+ vcl/aqua/source/window/salframe \
+ vcl/aqua/source/window/salmenu \
+ vcl/aqua/source/window/salobj \
+))
+endif
+
+ifeq ($(GUIBASE),unx)
+$(eval $(call gb_Library_set_defs,vcl,\
+ $$(DEFS) \
+ -DSAL_DLLPREFIX=\"$(gb_Library_SYSPRE)\" \
+ -DSAL_DLLPOSTFIX=\"$(gb_Library_OOOEXT)\" \
+ -D_XSALSET_LIBNAME=\"$(gb_Library_SYSPRE)spa$(gb_Library_OOOEXT)\" \
+))
+ifneq ($(ENABLE_FONTCONFIG),)
+$(eval $(call gb_Library_set_defs,vcl,\
+ $$(DEFS) \
+ -DENABLE_FONTCONFIG \
+))
+endif
+$(eval $(call gb_Library_add_exception_objects,vcl,\
+ vcl/source/glyphs/gcach_ftyp \
+ vcl/source/glyphs/gcach_layout \
+ vcl/source/glyphs/gcach_rbmp \
+ vcl/source/glyphs/glyphcache \
vcl/unx/generic/fontmanager/fontcache \
vcl/unx/generic/fontmanager/fontconfig \
vcl/unx/generic/fontmanager/fontmanager \
vcl/unx/generic/fontmanager/helper \
vcl/unx/generic/fontmanager/parseAFM \
+ vcl/unx/generic/plugadapt/salplug \
+ vcl/unx/generic/printer/cupsmgr \
+ vcl/unx/generic/printer/jobdata \
+ vcl/unx/generic/printer/ppdparser \
+ vcl/unx/generic/printer/printerinfomanager \
))
endif
@@ -218,16 +309,6 @@ $(eval $(call gb_Library_add_exception_objects,vcl,\
vcl/source/gdi/textlayout \
vcl/source/gdi/virdev \
vcl/source/gdi/wall \
- vcl/source/glyphs/gcach_ftyp \
- vcl/source/glyphs/gcach_layout \
- vcl/source/glyphs/gcach_rbmp \
- vcl/source/glyphs/glyphcache \
- vcl/source/glyphs/graphite_adaptors \
- vcl/source/glyphs/graphite_cache \
- vcl/source/glyphs/graphite_features \
- vcl/source/glyphs/graphite_layout \
- vcl/source/glyphs/graphite_serverfont \
- vcl/source/glyphs/graphite_textsrc \
vcl/source/helper/canvasbitmap \
vcl/source/helper/canvastools \
vcl/source/helper/evntpost \
@@ -285,23 +366,20 @@ $(eval $(call gb_Library_add_exception_objects,vcl,\
vcl/source/window/wrkwin \
))
-ifeq ($(GUI),UNX)
-$(eval $(call gb_Library_add_exception_objects,vcl,\
- vcl/unx/generic/plugadapt/salplug \
-))
+ifneq ($(ENABLE_GRAPHITE),)
$(eval $(call gb_Library_set_defs,vcl,\
$$(DEFS) \
- -DSAL_DLLPREFIX=\"$(gb_Library_SYSPRE)\" \
- -DSAL_DLLPOSTFIX=\"$(gb_Library_OOOEXT)\" \
- -D_XSALSET_LIBNAME=\"$(gb_Library_SYSPRE)spa$(gb_Library_OOOEXT)\" \
+ -DENABLE_GRAPHITE \
))
-ifneq ($(ENABLE_FONTCONFIG),)
-$(eval $(call gb_Library_set_defs,vcl,\
- $$(DEFS) \
- -DENABLE_FONTCONFIG \
+$(eval $(call gb_Library_add_exception_objects,vcl,\
+ vcl/source/glyphs/graphite_adaptors \
+ vcl/source/glyphs/graphite_cache \
+ vcl/source/glyphs/graphite_features \
+ vcl/source/glyphs/graphite_layout \
+ vcl/source/glyphs/graphite_serverfont \
+ vcl/source/glyphs/graphite_textsrc \
))
endif
-endif
ifeq ($(OS),LINUX)
$(eval $(call gb_Library_add_linked_libs,vcl,\
diff --git a/vcl/Library_vclplug_gen.mk b/vcl/Library_vclplug_gen.mk
index c7eb9b2b214e..cca106caf419 100644
--- a/vcl/Library_vclplug_gen.mk
+++ b/vcl/Library_vclplug_gen.mk
@@ -27,6 +27,8 @@
$(eval $(call gb_Library_Library,vclplug_gen))
+$(eval $(call gb_Library_add_package_headers,vcl,vcl_inc))
+
$(eval $(call gb_Library_add_precompiled_header,vclplug_gen,$(SRCDIR)/vcl/inc/pch/precompiled_vcl))
$(eval $(call gb_Library_set_include,vclplug_gen,\
diff --git a/vcl/Library_vclplug_gtk.mk b/vcl/Library_vclplug_gtk.mk
index 3107702680a0..1b8e2d881640 100644
--- a/vcl/Library_vclplug_gtk.mk
+++ b/vcl/Library_vclplug_gtk.mk
@@ -27,6 +27,8 @@
$(eval $(call gb_Library_Library,vclplug_gtk))
+$(eval $(call gb_Library_add_package_headers,vcl,vcl_inc))
+
$(eval $(call gb_Library_add_precompiled_header,vclplug_gtk,$(SRCDIR)/vcl/inc/pch/precompiled_vcl))
$(eval $(call gb_Library_set_include,vclplug_gtk,\
diff --git a/vcl/Library_vclplug_kde.mk b/vcl/Library_vclplug_kde.mk
index 4ea34bd0fb8a..560898d94ed7 100644
--- a/vcl/Library_vclplug_kde.mk
+++ b/vcl/Library_vclplug_kde.mk
@@ -27,6 +27,8 @@
$(eval $(call gb_Library_Library,vclplug_kde))
+$(eval $(call gb_Library_add_package_headers,vcl,vcl_inc))
+
$(eval $(call gb_Library_add_precompiled_header,vclplug_kde,$(SRCDIR)/vcl/inc/pch/precompiled_vcl))
$(eval $(call gb_Library_set_include,vclplug_kde,\
diff --git a/vcl/Library_vclplug_kde4.mk b/vcl/Library_vclplug_kde4.mk
index d7204583e8f0..ad1c5530ce79 100644
--- a/vcl/Library_vclplug_kde4.mk
+++ b/vcl/Library_vclplug_kde4.mk
@@ -27,6 +27,8 @@
$(eval $(call gb_Library_Library,vclplug_kde4))
+$(eval $(call gb_Library_add_package_headers,vcl,vcl_inc))
+
$(eval $(call gb_Library_add_precompiled_header,vclplug_kde4,$(SRCDIR)/vcl/inc/pch/precompiled_vcl))
$(eval $(call gb_Library_set_include,vclplug_kde4,\
diff --git a/vcl/Library_vclplug_svp.mk b/vcl/Library_vclplug_svp.mk
index c559cf6d6c8e..845b0c93d320 100644
--- a/vcl/Library_vclplug_svp.mk
+++ b/vcl/Library_vclplug_svp.mk
@@ -27,6 +27,8 @@
$(eval $(call gb_Library_Library,vclplug_svp))
+$(eval $(call gb_Library_add_package_headers,vcl,vcl_inc))
+
$(eval $(call gb_Library_add_precompiled_header,vclplug_svp,$(SRCDIR)/vcl/inc/pch/precompiled_vcl))
$(eval $(call gb_Library_set_include,vclplug_svp,\
diff --git a/vcl/Module_vcl.mk b/vcl/Module_vcl.mk
index 5cb49b312507..636e5a3e367a 100644
--- a/vcl/Module_vcl.mk
+++ b/vcl/Module_vcl.mk
@@ -35,7 +35,7 @@ $(eval $(call gb_Module_add_targets,vcl,\
# FIXME: WiP
# StaticLibrary_vclmain \
-ifeq ($(GUI),UNX)
+ifeq ($(GUIBASE),unx)
$(eval $(call gb_Module_add_targets,vcl,\
Library_vclplug_gen \
Library_vclplug_svp \
diff --git a/vcl/aqua/source/dtrans/aqua_service.cxx b/vcl/aqua/source/dtrans/aqua_service.cxx
deleted file mode 100644
index 57ef1f11175c..000000000000
--- a/vcl/aqua/source/dtrans/aqua_service.cxx
+++ /dev/null
@@ -1,86 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_vcl.hxx"
-#include "aqua_clipboard.hxx"
-#include <cppuhelper/factory.hxx>
-#include <com/sun/star/container/XSet.hpp>
-#include <osl/diagnose.h>
-
-using namespace rtl;
-using namespace com::sun::star::uno;
-using namespace com::sun::star::registry;
-using namespace cppu;
-using namespace com::sun::star::lang;
-using namespace com::sun::star::datatransfer::clipboard;
-using namespace aqua;
-
-namespace aqua {
-
-Reference< XInterface > SAL_CALL createInstance( const Reference< XMultiServiceFactory >& rServiceManager )
-{
- return Reference< XInterface >( static_cast< XClipboard* >( new AquaClipboard(rServiceManager) ) );
-}
-
-} // namespace aqua
-
-extern "C"
-{
-
-void SAL_CALL component_getImplementationEnvironment(
- const sal_Char ** ppEnvTypeName, uno_Environment ** ppEnv )
-{
- *ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
-}
-
-void* SAL_CALL component_getFactory( const sal_Char* pImplName, uno_Interface* pSrvManager, uno_Interface* pRegistryKey )
-{
- void* pRet = 0;
-
- if ( pSrvManager && ( 0 == rtl_str_compare( pImplName, AQUA_CLIPBOARD_IMPL_NAME ) ) )
- {
- Sequence< OUString > aSNS( 1 );
- aSNS.getArray()[0] = OUString( RTL_CONSTASCII_USTRINGPARAM( AQUA_CLIPBOARD_SERVICE_NAME ) );
-
- //OUString( RTL_CONSTASCII_USTRINGPARAM( FPS_IMPL_NAME ) )
- Reference< XSingleServiceFactory > xFactory ( createOneInstanceFactory(
- reinterpret_cast< XMultiServiceFactory* > ( pSrvManager ),
- OUString::createFromAscii( pImplName ),
- createInstance,
- aSNS ) );
- if ( xFactory.is() )
- {
- xFactory->acquire();
- pRet = xFactory.get();
- }
- }
-
- return pRet;
-}
-
-} // extern "C"
diff --git a/vcl/aqua/source/dtrans/test_aquacb.cxx b/vcl/aqua/source/dtrans/test_aquacb.cxx
deleted file mode 100644
index 85c87c6b9ba9..000000000000
--- a/vcl/aqua/source/dtrans/test_aquacb.cxx
+++ /dev/null
@@ -1,208 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-// MARKER(update_precomp.py): autogen include statement, do not remove
-#include "precompiled_vcl.hxx"
-
-#include "aqua_clipboard.hxx"
-#include <cppuhelper/servicefactory.hxx>
-#include <com/sun/star/datatransfer/XTransferable.hpp>
-#include <com/sun/star/datatransfer/clipboard/XClipboardOwner.hpp>
-#include <com/sun/star/datatransfer/clipboard/XClipboardNotifier.hpp>
-#include <com/sun/star/datatransfer/clipboard/XClipboardEx.hpp>
-#include <com/sun/star/lang/XComponent.hpp>
-
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
-#include <cppuhelper/implbase2.hxx>
-#endif
-#include <rtl/ustring.hxx>
-#include <sal/types.h>
-#include <osl/diagnose.h>
-
-#include <stdio.h>
-
-using namespace ::rtl;
-using namespace ::std;
-using namespace ::cppu;
-using namespace ::com::sun::star::datatransfer;
-using namespace ::com::sun::star::datatransfer::clipboard;
-using namespace ::com::sun::star::uno;
-using namespace ::com::sun::star::io;
-using namespace ::com::sun::star::lang;
-
-Reference< XTransferable > rXTransfRead;
-
-class TestTransferable : public WeakImplHelper2< XClipboardOwner, XTransferable >
-{
-public:
- TestTransferable();
- virtual Any SAL_CALL getTransferData( const DataFlavor& aFlavor ) throw(UnsupportedFlavorException, IOException, RuntimeException);
- virtual Sequence< DataFlavor > SAL_CALL getTransferDataFlavors() throw(RuntimeException);
- virtual sal_Bool SAL_CALL isDataFlavorSupported( const DataFlavor& aFlavor ) throw(RuntimeException);
- virtual void SAL_CALL lostOwnership( const Reference< XClipboard >& xClipboard, const Reference< XTransferable >& xTrans ) throw(RuntimeException);
-
-private:
- Sequence< DataFlavor > m_seqDFlv;
- OUString m_Data;
-};
-
-TestTransferable::TestTransferable() :
- m_seqDFlv( 1 ),
- m_Data( RTL_CONSTASCII_USTRINGPARAM( "This is a test string" ) )
-{
- DataFlavor df;
-
- df.MimeType = OUString::createFromAscii( "text/html" );
- df.DataType = getCppuType( ( Sequence< sal_Int8 >* )0 );
-
- m_seqDFlv[0] = df;
-}
-
-Any SAL_CALL TestTransferable::getTransferData( const DataFlavor& aFlavor )
- throw(UnsupportedFlavorException, IOException, RuntimeException)
-{
- Any anyData;
-
- if ( aFlavor.MimeType == m_seqDFlv[0].MimeType )
- {
- OString aStr( m_Data.getStr(), m_Data.getLength(), 1252 );
- Sequence< sal_Int8 > sOfChars( aStr.getLength() );
- sal_Int32 lenStr = aStr.getLength();
-
- for ( sal_Int32 i = 0; i < lenStr; ++i )
- sOfChars[i] = aStr[i];
-
- anyData = makeAny( sOfChars );
- }
-
- return anyData;
-}
-
-Sequence< DataFlavor > SAL_CALL TestTransferable::getTransferDataFlavors()
- throw(RuntimeException)
-{
- return m_seqDFlv;
-}
-
-sal_Bool SAL_CALL TestTransferable::isDataFlavorSupported( const DataFlavor& aFlavor )
- throw(RuntimeException)
-{
- sal_Int32 nLength = m_seqDFlv.getLength();
- sal_Bool bRet = sal_False;
-
- for ( sal_Int32 i = 0; i < nLength; ++i )
- {
- if ( m_seqDFlv[i].MimeType == aFlavor.MimeType )
- {
- bRet = sal_True;
- break;
- }
- }
-
- return bRet;
-}
-
-void SAL_CALL TestTransferable::lostOwnership( const Reference< XClipboard >& xClipboard, const Reference< XTransferable >& xTrans )
- throw(RuntimeException)
-{
-}
-
-int SAL_CALL main( int argc, char** argv )
-{
- if(argc != 2)
- {
- fprintf( stderr, "usage: %s <my rdb file>\n", argv[0] );
- return 1;
- }
-
- //-------------------------------------------------
- // get the global service-manager
- //-------------------------------------------------
- OUString rdbName = OUString::createFromAscii( argv[1] );
- Reference< XMultiServiceFactory > g_xFactory( createRegistryServiceFactory( rdbName ) );
-
- // Print a message if an error occured.
- if ( !g_xFactory.is() )
- {
- OSL_ENSURE(sal_False, "Can't create RegistryServiceFactory");
- return(-1);
- }
-
- //-------------------------------------------------
- // try to get an Interface to a XFilePicker Service
- //-------------------------------------------------
-
- Reference< XTransferable > rXTransf( static_cast< XTransferable* >( new TestTransferable ) );
-
- Reference< XClipboard > xClipboard( g_xFactory->createInstance( OUString( RTL_CONSTASCII_USTRINGPARAM( AQUA_CLIPBOARD_SERVICE_NAME ) ) ), UNO_QUERY );
- if ( !xClipboard.is() )
- {
- OSL_ENSURE( sal_False, "Error creating FolderPicker Service" );
- return(-1);
- }
-
- Reference< XTypeProvider > rXTypProv( xClipboard, UNO_QUERY );
-
- if ( rXTypProv.is() )
- {
- Sequence< Type > seqType = rXTypProv->getTypes();
- sal_Int32 nLen = seqType.getLength();
- for ( sal_Int32 i = 0; i < nLen; i++ )
- {
- Type nxtType = seqType[i];
- }
-
- Sequence< sal_Int8 > seqInt8 = rXTypProv->getImplementationId();
- }
-
- xClipboard->setContents( rXTransf, Reference< XClipboardOwner >( rXTransf, UNO_QUERY ) );
-
- rXTransfRead = xClipboard->getContents();
-
- // destroy the transferable explicitly
- rXTransfRead = Reference< XTransferable>();
-
- // destroy the clipboard
- xClipboard = Reference< XClipboard >();
-
- //--------------------------------------------------
- // shutdown the service manager
- //--------------------------------------------------
-
- // Cast factory to XComponent
- Reference< XComponent > xComponent( g_xFactory, UNO_QUERY );
-
- if ( !xComponent.is() )
- OSL_ENSURE(sal_False, "Error shuting down");
-
- // Dispose and clear factory
- xComponent->dispose();
- g_xFactory.clear();
- g_xFactory = Reference< XMultiServiceFactory >();
-
- return 0;
-}