summaryrefslogtreecommitdiff
path: root/filter/source/flash
diff options
context:
space:
mode:
authorChristian Lippka <cl@openoffice.org>2002-10-24 15:24:27 +0000
committerChristian Lippka <cl@openoffice.org>2002-10-24 15:24:27 +0000
commit7eb4402675272e78f1aeacea4373b197b26b6834 (patch)
treebf2764781480e3c1dd26d1bbd61210364417670f /filter/source/flash
parenta57090bed33d33b6ecc689d2a577af328d069bd4 (diff)
added initial support for an options dialog
Diffstat (limited to 'filter/source/flash')
-rw-r--r--filter/source/flash/impswfdialog.cxx103
-rw-r--r--filter/source/flash/impswfdialog.hrc68
-rw-r--r--filter/source/flash/impswfdialog.hxx110
-rw-r--r--filter/source/flash/impswfdialog.src138
-rw-r--r--filter/source/flash/makefile.mk14
-rw-r--r--filter/source/flash/swfdialog.cxx322
-rw-r--r--filter/source/flash/swfdialog.hxx125
7 files changed, 876 insertions, 4 deletions
diff --git a/filter/source/flash/impswfdialog.cxx b/filter/source/flash/impswfdialog.cxx
new file mode 100644
index 000000000000..72e041ac087b
--- /dev/null
+++ b/filter/source/flash/impswfdialog.cxx
@@ -0,0 +1,103 @@
+ /*************************************************************************
+ *
+ * $RCSfile: impswfdialog.cxx,v $
+ *
+ * $Revision: 1.1 $
+ *
+ * last change: $Author: cl $ $Date: 2002-10-24 16:24:22 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library 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 for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#include "impswfdialog.hxx"
+#include "impswfdialog.hrc"
+
+using namespace rtl;
+using namespace com::sun::star::uno;
+using namespace com::sun::star::beans;
+
+// ----------------
+// - ImpPDFDialog -
+// ----------------
+
+ImpSWFDialog::ImpSWFDialog( Window* pParent, ResMgr& rResMgr, Sequence< PropertyValue >& rFilterData ) :
+ ModalDialog( pParent, ResId( DLG_OPTIONS, &rResMgr ) ),
+ maFiDescr( this, ResId( FI_DESCR ) ),
+ maNumFldQuality( this, ResId( NUM_FLD_QUALITY ) ),
+ maBtnOK( this, ResId( BTN_OK ) ),
+ maBtnCancel( this, ResId( BTN_CANCEL ) ),
+ maBtnHelp( this, ResId( BTN_HELP ) ),
+ maConfigItem( String( RTL_CONSTASCII_USTRINGPARAM( "Office.Common/Filter/Flash/Export/" ) ), &rFilterData )
+{
+ const ULONG nCompressMode = maConfigItem.ReadInt32( String( RTL_CONSTASCII_USTRINGPARAM( "CompressMode" ) ), 0 );
+
+ FreeResource();
+}
+
+// -----------------------------------------------------------------------------
+
+ImpSWFDialog::~ImpSWFDialog()
+{
+}
+
+// -----------------------------------------------------------------------------
+
+Sequence< PropertyValue > ImpSWFDialog::GetFilterData()
+{
+ sal_Int32 nCompressMode;
+
+ maConfigItem.WriteInt32( OUString( RTL_CONSTASCII_USTRINGPARAM( "CompressMode" ) ), nCompressMode );
+ Sequence< PropertyValue > aRet( maConfigItem.GetFilterData() );
+ return aRet;
+}
+
diff --git a/filter/source/flash/impswfdialog.hrc b/filter/source/flash/impswfdialog.hrc
new file mode 100644
index 000000000000..64e309902540
--- /dev/null
+++ b/filter/source/flash/impswfdialog.hrc
@@ -0,0 +1,68 @@
+/*************************************************************************
+ *
+ * $RCSfile: impswfdialog.hrc,v $
+ *
+ * $Revision: 1.1 $
+ *
+ * last change: $Author: cl $ $Date: 2002-10-24 16:24:23 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library 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 for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#define DLG_OPTIONS 1024
+
+#define BTN_OK 1
+#define BTN_CANCEL 1
+#define BTN_HELP 1
+#define FI_DESCR 1
+#define NUM_FLD_QUALITY 1
diff --git a/filter/source/flash/impswfdialog.hxx b/filter/source/flash/impswfdialog.hxx
new file mode 100644
index 000000000000..00147cdb8316
--- /dev/null
+++ b/filter/source/flash/impswfdialog.hxx
@@ -0,0 +1,110 @@
+/*************************************************************************
+ *
+ * $RCSfile: impswfdialog.hxx,v $
+ *
+ * $Revision: 1.1 $
+ *
+ * last change: $Author: cl $ $Date: 2002-10-24 16:24:24 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library 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 for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#ifndef IMPSWFDIALOG_HXX
+#define IMPSWFDIALOG_HXX
+
+#ifndef _COM_SUN_STAR_UNO_SEQUENCE_H_
+#include <com/sun/star/uno/Sequence.h>
+#endif
+
+#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
+#include <com/sun/star/beans/PropertyValue.hpp>
+#endif
+
+#ifndef _STDCTRL_HXX
+#include <svtools/stdctrl.hxx>
+#endif
+
+#include <vcl/dialog.hxx>
+#include <vcl/button.hxx>
+#include <vcl/fixed.hxx>
+#include <vcl/field.hxx>
+
+#include <svtools/FilterConfigItem.hxx>
+
+// ----------------
+// - ImpSWFDialog -
+// ----------------
+
+class ResMgr;
+class Window;
+
+class ImpSWFDialog : public ModalDialog
+{
+private:
+ FixedInfo maFiDescr;
+ NumericField maNumFldQuality;
+ OKButton maBtnOK;
+ CancelButton maBtnCancel;
+ HelpButton maBtnHelp;
+
+ FilterConfigItem maConfigItem;
+
+public:
+ ImpSWFDialog( Window* pParent, ResMgr& rResMgr,
+ com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue >& rFilterData );
+ ~ImpSWFDialog();
+
+ com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue > GetFilterData();
+};
+
+#endif // IMPDIALOG_HXX
diff --git a/filter/source/flash/impswfdialog.src b/filter/source/flash/impswfdialog.src
new file mode 100644
index 000000000000..924b86f2b921
--- /dev/null
+++ b/filter/source/flash/impswfdialog.src
@@ -0,0 +1,138 @@
+/*************************************************************************
+ *
+ * $RCSfile: impswfdialog.src,v $
+ *
+ * $Revision: 1.1 $
+ *
+ * last change: $Author: cl $ $Date: 2002-10-24 16:24:25 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library 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 for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#include "impswfdialog.hrc"
+
+ModalDialog DLG_OPTIONS
+{
+ Size = MAP_APPFONT ( 159 , 92 ) ;
+ OutputSize = TRUE ;
+ SVLook = TRUE ;
+ Moveable = TRUE ;
+ Closeable = TRUE ;
+ Text = "Flash Optionen" ;
+ Text [ ENGLISH ] = "Flash Optionen" ;
+ Text [ english_us ] = "Flash Options" ;
+
+ OKButton BTN_OK
+ {
+ Pos = MAP_APPFONT ( 103 , 6 ) ;
+ Size = MAP_APPFONT ( 50 , 14 ) ;
+ TabStop = TRUE ;
+ DefButton = TRUE ;
+ };
+ CancelButton BTN_CANCEL
+ {
+ Pos = MAP_APPFONT ( 103 , 23 ) ;
+ Size = MAP_APPFONT ( 50 , 14 ) ;
+ TabStop = TRUE ;
+ };
+ HelpButton BTN_HELP
+ {
+ Pos = MAP_APPFONT ( 103 , 43 ) ;
+ Size = MAP_APPFONT ( 50 , 14 ) ;
+ TabStop = TRUE ;
+ };
+ FixedText FI_DESCR
+ {
+ Pos = MAP_APPFONT ( 12 , 14 ) ;
+ Size = MAP_APPFONT ( 81 , 16 ) ;
+ Text = "1: min. Qualitt\n100: max. Qualitt" ;
+ Text [ ENGLISH ] = "1: min. quality\n100: max. quality" ;
+ Text [ english_us ] = "1: min. quality\n100: max. quality" ;
+ Text [ italian ] = "1: min. qualit\n100: max. qualit" ;
+ Text [ spanish ] = "1: mn. calidad\n100: mx. calidad" ;
+ Text [ french ] = "1 : qualit min.\n100 : qualit max." ;
+ Text [ dutch ] = "1: min. kwaliteit\n100: max. kwaliteit" ;
+ Text [ swedish ] = "1: min. kvalitet\n100: max. kvalitet" ;
+ Text [ danish ] = "~1: min. kvalitet\n100: maks. kvalitet" ;
+ Text [ portuguese_brazilian ] = "0: min. Qualidade\n100: max. Qualidade" ;
+ Text [ portuguese ] = "1: min. qualidade\n100: max. qualidade" ;
+ Text[ chinese_simplified ] = "1: 最差质量 \n100: 最佳质量";
+ Text[ russian ] = "1: \n100: ";
+ Text[ polish ] = "1: min. jako\n100: maks. jako";
+ Text[ japanese ] = "1: 最低\n100: 最高";
+ Text[ chinese_traditional ] = "1: 最差品質 \n100: 最佳品質";
+ Text[ arabic ] = "0: \n100: ";
+ Text[ dutch ] = "1: min. kwaliteit\n100: max. kwaliteit";
+ Text[ chinese_simplified ] = "1: 最差质量 \n100: 最佳质量";
+ Text[ greek ] = "0: \n100: ";
+ Text[ korean ] = "1: 최소 성능\n100: 최대 성능";
+ Text[ turkish ] = "0: asg. kalite\n100: azm. kalite";
+ Text[ language_user1 ] = " ";
+ Text[ catalan ] = "0: mn. qualitat\n100: mx. qualitat";
+ Text[ finnish ] = "1: vhimmislaatu \n100: enimmislaatu";
+ Text[ thai ] = "1: คุณภาพต่ำสุด\n100: คุณภาพสูงสุด";
+ };
+ NumericField NUM_FLD_QUALITY
+ {
+ Border = TRUE ;
+ Pos = MAP_APPFONT ( 12 , 33 ) ;
+ Size = MAP_APPFONT ( 50 , 12 ) ;
+ TabStop = TRUE ;
+ Spin = TRUE ;
+ Minimum = 1;
+ Maximum = 100 ;
+ StrictFormat = TRUE ;
+ Last = 100 ;
+ Repeat = TRUE ;
+ };
+};
diff --git a/filter/source/flash/makefile.mk b/filter/source/flash/makefile.mk
index 57ee79ff1b7d..a7813ef83f72 100644
--- a/filter/source/flash/makefile.mk
+++ b/filter/source/flash/makefile.mk
@@ -2,9 +2,9 @@
#
# $RCSfile: makefile.mk,v $
#
-# $Revision: 1.2 $
+# $Revision: 1.3 $
#
-# last change: $Author: jbu $ $Date: 2002-10-08 09:30:57 $
+# last change: $Author: cl $ $Date: 2002-10-24 16:24:26 $
#
# The Contents of this file are made available subject to the terms of
# either of the following licenses
@@ -96,17 +96,22 @@ UNOTYPES=\
com.sun.star.container.XIndexAccess
# --- Files -------------------------------------
-CFLAGS+=-I..$/swfsource
+SRCFILES = impswfdialog.src
SLOFILES= $(SLO)$/filter.obj \
$(SLO)$/writer.obj \
$(SLO)$/writer1.obj \
$(SLO)$/writer2.obj \
$(SLO)$/uno.obj \
- $(SLO)$/exporter.obj
+ $(SLO)$/exporter.obj \
+ $(SLO)$/swfdialog.obj \
+ $(SLO)$/impswfdialog.obj
# --- Library -----------------------------------
+RESLIB1NAME=$(TARGET)
+RESLIB1SRSFILES= $(SRS)$/$(TARGET).srs
+
SHL1TARGET=$(TARGET)$(UPD)$(DLLPOSTFIX)
SHL1STDLIBS=\
@@ -114,6 +119,7 @@ SHL1STDLIBS=\
$(SVTOOLLIB) \
$(CPPULIB) \
$(CPPUHELPERLIB) \
+ $(COMPHELPERLIB) \
$(VOSLIB) \
$(SALLIB) \
$(TOOLSLIB) \
diff --git a/filter/source/flash/swfdialog.cxx b/filter/source/flash/swfdialog.cxx
new file mode 100644
index 000000000000..47cffc9cf30f
--- /dev/null
+++ b/filter/source/flash/swfdialog.cxx
@@ -0,0 +1,322 @@
+ /*************************************************************************
+ *
+ * $RCSfile: swfdialog.cxx,v $
+ *
+ * $Revision: 1.1 $
+ *
+ * last change: $Author: cl $ $Date: 2002-10-24 16:24:26 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library 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 for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#include "swfdialog.hxx"
+#include "impswfdialog.hxx"
+#include <vcl/svapp.hxx>
+#include <vcl/dialog.hxx>
+#include <svtools/solar.hrc>
+
+#ifndef _COM_SUN_STAR_VIEW_XRENDERABLE_HPP_
+#include <com/sun/star/view/XRenderable.hpp>
+#endif
+#ifndef _COM_SUN_STAR_FRAME_XCONTROLLER_HPP_
+#include <com/sun/star/frame/XController.hpp>
+#endif
+#ifndef _COM_SUN_STAR_VIEW_XSELECTIONSUPPLIER_HPP_
+#include <com/sun/star/view/XSelectionSupplier.hpp>
+#endif
+
+using namespace ::rtl;
+using namespace ::vcl;
+using namespace ::com::sun::star;
+using namespace ::com::sun::star::uno;
+using namespace ::com::sun::star::lang;
+using namespace ::com::sun::star::beans;
+using namespace ::com::sun::star::frame;
+using namespace ::com::sun::star::view;
+using namespace ::com::sun::star::document;
+
+// -----------------------
+// - PDFDialog functions -
+// -----------------------
+
+#define SERVICE_NAME "com.sun.star.Impress.FlashExportDialog"
+
+// -----------------------------------------------------------------------------
+
+OUString SWFDialog_getImplementationName ()
+ throw (RuntimeException)
+{
+ return OUString ( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+}
+
+// -----------------------------------------------------------------------------
+
+Sequence< sal_Int8 > SAL_CALL SWFDialog_getImplementationId()
+ throw(RuntimeException)
+{
+ static ::cppu::OImplementationId aId;
+ return aId.getImplementationId();
+}
+
+// -----------------------------------------------------------------------------
+
+Sequence< OUString > SAL_CALL SWFDialog_getSupportedServiceNames()
+ throw (RuntimeException)
+{
+ Sequence < OUString > aRet(1);
+ OUString* pArray = aRet.getArray();
+ pArray[0] = OUString ( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+ return aRet;
+}
+
+// -----------------------------------------------------------------------------
+
+Reference< XInterface > SAL_CALL SWFDialog_createInstance( const Reference< XMultiServiceFactory > & rSMgr)
+ throw( Exception )
+{
+ return (cppu::OWeakObject*) new SWFDialog( rSMgr );
+}
+
+// -----------------------------------------------------------------------------
+
+#undef SERVICE_NAME
+
+// -------------
+// - SWFDialog -
+// -------------
+
+SWFDialog::SWFDialog( const Reference< XMultiServiceFactory > &rxMSF ) :
+ OGenericUnoDialog( rxMSF )
+{
+ ByteString aResMgrName( "flash" );
+
+ aResMgrName.Append( ByteString::CreateFromInt32( SOLARUPD ) );
+ mpResMgr = ResMgr::CreateResMgr( aResMgrName.GetBuffer(), Application::GetSettings().GetUILanguage() );
+}
+
+// -----------------------------------------------------------------------------
+
+SWFDialog::~SWFDialog()
+{
+ delete mpResMgr;
+}
+
+// -----------------------------------------------------------------------------
+
+Any SAL_CALL SWFDialog::queryInterface( const Type& rType )
+ throw (RuntimeException)
+{
+ Any aReturn = OGenericUnoDialog::queryInterface( rType );
+
+ if( !aReturn.hasValue() )
+ aReturn = ::cppu::queryInterface( rType,
+ static_cast< XPropertyAccess* >( this ),
+ static_cast< XExporter* >( this ) );
+
+ return aReturn;
+}
+
+// -----------------------------------------------------------------------------
+
+void SAL_CALL SWFDialog::acquire()
+ throw ()
+{
+ OWeakObject::acquire();
+}
+
+// -----------------------------------------------------------------------------
+
+void SAL_CALL SWFDialog::release()
+ throw ()
+{
+ OWeakObject::release();
+}
+
+// -----------------------------------------------------------------------------
+
+Sequence< sal_Int8 > SAL_CALL SWFDialog::getImplementationId()
+ throw(RuntimeException)
+{
+ return SWFDialog_getImplementationId();
+}
+
+// -----------------------------------------------------------------------------
+
+OUString SAL_CALL SWFDialog::getImplementationName()
+ throw (RuntimeException)
+{
+ return SWFDialog_getImplementationName();
+}
+
+// -----------------------------------------------------------------------------
+
+Sequence< OUString > SAL_CALL SWFDialog::getSupportedServiceNames()
+ throw (RuntimeException)
+{
+ return SWFDialog_getSupportedServiceNames();
+}
+
+// -----------------------------------------------------------------------------
+
+Dialog* SWFDialog::createDialog( Window* pParent )
+{
+ Dialog* pRet = NULL;
+
+ if( mpResMgr && mxSrcDoc.is() )
+ {
+/* TODO: From the controler we may get information what page is visible and what shapes
+ are selected, if we optionaly want to limit output to that
+ Any aSelection;
+
+ try
+ {
+ Reference< XController > xController( Reference< XModel >( mxSrcDoc, UNO_QUERY )->getCurrentController() );
+
+ if( xController.is() )
+ {
+ Reference< XSelectionSupplier > xView( xController, UNO_QUERY );
+
+ if( xView.is() )
+ xView->getSelection() >>= aSelection;
+ }
+ }
+ catch( RuntimeException )
+ {
+ }
+*/
+ ImpSWFDialog* pDlg = new ImpSWFDialog( pParent, *mpResMgr, maFilterData );
+ pRet = pDlg;
+ }
+
+ return pRet;
+}
+
+// -----------------------------------------------------------------------------
+
+void SWFDialog::executedDialog( sal_Int16 nExecutionResult )
+{
+ if( nExecutionResult && m_pDialog )
+ maFilterData = static_cast< ImpSWFDialog* >( m_pDialog )->GetFilterData();
+
+ destroyDialog();
+}
+
+// -----------------------------------------------------------------------------
+
+Reference< XPropertySetInfo > SAL_CALL SWFDialog::getPropertySetInfo()
+ throw(RuntimeException)
+{
+ Reference< XPropertySetInfo > xInfo( createPropertySetInfo( getInfoHelper() ) );
+ return xInfo;
+}
+
+//-------------------------------------------------------------------------
+::cppu::IPropertyArrayHelper& SWFDialog::getInfoHelper()
+{
+ return *const_cast<SWFDialog*>(this)->getArrayHelper();
+}
+
+//------------------------------------------------------------------------------
+::cppu::IPropertyArrayHelper* SWFDialog::createArrayHelper() const
+{
+ Sequence< Property > aProps;
+ describeProperties(aProps);
+ return new ::cppu::OPropertyArrayHelper( aProps );
+}
+
+// -----------------------------------------------------------------------------
+
+Sequence< PropertyValue > SAL_CALL SWFDialog::getPropertyValues()
+ throw ( RuntimeException )
+{
+ sal_Int32 i, nCount;
+
+ for( i = 0, nCount = maMediaDescriptor.getLength(); i < nCount; i++ )
+ {
+ if( maMediaDescriptor[ i ].Name.equalsAscii( "FilterData" ) )
+ break;
+ }
+
+ if( i == nCount )
+ maMediaDescriptor.realloc( ++nCount );
+
+ maMediaDescriptor[ i ].Name = String( RTL_CONSTASCII_USTRINGPARAM( "FilterData" ) );
+ maMediaDescriptor[ i ].Value <<= maFilterData;
+
+ return maMediaDescriptor;
+}
+
+// -----------------------------------------------------------------------------
+
+void SAL_CALL SWFDialog::setPropertyValues( const Sequence< PropertyValue >& rProps )
+ throw ( UnknownPropertyException, PropertyVetoException, IllegalArgumentException, WrappedTargetException, RuntimeException )
+{
+ maMediaDescriptor = rProps;
+
+ for( sal_Int32 i = 0, nCount = maMediaDescriptor.getLength(); i < nCount; i++ )
+ {
+ if( maMediaDescriptor[ i ].Name.equalsAscii( "FilterData" ) )
+ {
+ maMediaDescriptor[ i ].Value >>= maFilterData;
+ break;
+ }
+ }
+}
+
+// -----------------------------------------------------------------------------
+
+void SAL_CALL SWFDialog::setSourceDocument( const Reference< XComponent >& xDoc )
+ throw(IllegalArgumentException, RuntimeException)
+{
+ mxSrcDoc = xDoc;
+}
diff --git a/filter/source/flash/swfdialog.hxx b/filter/source/flash/swfdialog.hxx
new file mode 100644
index 000000000000..244da96391b5
--- /dev/null
+++ b/filter/source/flash/swfdialog.hxx
@@ -0,0 +1,125 @@
+/*************************************************************************
+ *
+ * $RCSfile: swfdialog.hxx,v $
+ *
+ * $Revision: 1.1 $
+ *
+ * last change: $Author: cl $ $Date: 2002-10-24 16:24:27 $
+ *
+ * The Contents of this file are made available subject to the terms of
+ * either of the following licenses
+ *
+ * - GNU Lesser General Public License Version 2.1
+ * - Sun Industry Standards Source License Version 1.1
+ *
+ * Sun Microsystems Inc., October, 2000
+ *
+ * GNU Lesser General Public License Version 2.1
+ * =============================================
+ * Copyright 2000 by Sun Microsystems, Inc.
+ * 901 San Antonio Road, Palo Alto, CA 94303, USA
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1, as published by the Free Software Foundation.
+ *
+ * This library 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 for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ *
+ *
+ * Sun Industry Standards Source License Version 1.1
+ * =================================================
+ * The contents of this file are subject to the Sun Industry Standards
+ * Source License Version 1.1 (the "License"); You may not use this file
+ * except in compliance with the License. You may obtain a copy of the
+ * License at http://www.openoffice.org/license.html.
+ *
+ * Software provided under this License is provided on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
+ * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
+ * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
+ * See the License for the specific provisions governing your rights and
+ * obligations concerning the Software.
+ *
+ * The Initial Developer of the Original Code is: Sun Microsystems, Inc.
+ *
+ * Copyright: 2000 by Sun Microsystems, Inc.
+ *
+ * All Rights Reserved.
+ *
+ * Contributor(s): _______________________________________
+ *
+ *
+ ************************************************************************/
+
+#ifndef SWFDIALOG_HXX
+#define SWFDIALOG_HXX
+
+#ifndef _COM_SUN_STAR_BEANS_XPROPERTYACCESS_HPP_
+#include <com/sun/star/beans/XPropertyAccess.hpp>
+#endif
+#ifndef _COM_SUN_STAR_DOCUMENT_XEXPORTER_HPP_
+#include <com/sun/star/document/XExporter.hpp>
+#endif
+
+#include <svtools/genericunodialog.hxx>
+
+// -------------
+// - SWFDialog -
+// -------------
+
+class Window;
+class ResMgr;
+
+class SWFDialog : public ::svt::OGenericUnoDialog,
+ public ::comphelper::OPropertyArrayUsageHelper< SWFDialog >,
+ public ::com::sun::star::beans::XPropertyAccess,
+ public ::com::sun::star::document::XExporter
+{
+private:
+
+ ResMgr* mpResMgr;
+ com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > maMediaDescriptor;
+ com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > maFilterData;
+ com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent > mxSrcDoc;
+
+protected:
+
+ // XInterface
+ virtual com::sun::star::uno::Any SAL_CALL queryInterface( const com::sun::star::uno::Type& aType ) throw (com::sun::star::uno::RuntimeException);
+ virtual void SAL_CALL acquire() throw ();
+ virtual void SAL_CALL release() throw ();
+
+ // OGenericUnoDialog
+ virtual com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(com::sun::star::uno::RuntimeException);
+ virtual rtl::OUString SAL_CALL getImplementationName() throw (com::sun::star::uno::RuntimeException);
+ virtual com::sun::star::uno::Sequence< rtl::OUString > SAL_CALL getSupportedServiceNames() throw (com::sun::star::uno::RuntimeException);
+ virtual Dialog* createDialog( Window* pParent );
+ virtual void executedDialog( sal_Int16 nExecutionResult );
+ virtual com::sun::star::uno::Reference< com::sun::star::beans::XPropertySetInfo> SAL_CALL getPropertySetInfo() throw(com::sun::star::uno::RuntimeException);
+ virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper();
+ virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const;
+
+ // XPropertyAccess
+ virtual com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > SAL_CALL getPropertyValues( ) throw (com::sun::star::uno::RuntimeException);
+ virtual void SAL_CALL setPropertyValues( const com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aProps ) throw (com::sun::star::beans::UnknownPropertyException, com::sun::star::beans::PropertyVetoException, com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::WrappedTargetException, com::sun::star::uno::RuntimeException);
+
+ // XExporter
+ virtual void SAL_CALL setSourceDocument( const com::sun::star::uno::Reference< com::sun::star::lang::XComponent >& xDoc ) throw(com::sun::star::lang::IllegalArgumentException, com::sun::star::uno::RuntimeException);
+
+public:
+
+ SWFDialog( const com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >& rxMSF );
+ virtual ~SWFDialog();
+};
+
+// -----------------------------------------------------------------------------
+
+#endif // SWFDialog_HXX