rpms/openoffice.org/devel openoffice.org-2.0.4.rh213710.vba.patch, 1.2, 1.3

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Tue Nov 7 10:30:21 UTC 2006


Author: caolanm

Update of /cvs/dist/rpms/openoffice.org/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv1125

Modified Files:
	openoffice.org-2.0.4.rh213710.vba.patch 
Log Message:
partly available already

openoffice.org-2.0.4.rh213710.vba.patch:
 offapi/org/openoffice/vba/XApplication.idl |    1 +
 sc/source/ui/vba/vbaapplication.cxx        |    6 ++++++
 sc/source/ui/vba/vbaapplication.hxx        |    2 ++
 3 files changed, 9 insertions(+)

Index: openoffice.org-2.0.4.rh213710.vba.patch
===================================================================
RCS file: /cvs/dist/rpms/openoffice.org/devel/openoffice.org-2.0.4.rh213710.vba.patch,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- openoffice.org-2.0.4.rh213710.vba.patch	7 Nov 2006 09:51:44 -0000	1.2
+++ openoffice.org-2.0.4.rh213710.vba.patch	7 Nov 2006 10:30:18 -0000	1.3
@@ -1,146 +1,39 @@
---- openoffice.org.orig/offapi/org/openoffice/vba/XApplication.idl	2006-11-06 14:49:03.000000000 +0000
-+++ openoffice.org/offapi/org/openoffice/vba/XApplication.idl	2006-11-06 16:11:20.000000000 +0000
-@@ -29,7 +29,10 @@
- 	// to determine this
- 	[attribute, readonly] XWorkbook ThisWorkbook;
+diff -ru offapi/org/openoffice/vba/XApplication.idl offapi/org/openoffice/vba/XApplication.idl
+--- openoffice.org.orig/offapi/org/openoffice/vba/XApplication.idl	2006-11-07 10:22:47.000000000 +0000
++++ openoffice.org/offapi/org/openoffice/vba/XApplication.idl	2006-11-07 10:23:24.000000000 +0000
+@@ -31,6 +31,7 @@
  	[attribute] boolean ScreenUpdating;
-+        [attribute] boolean DisplayStatusBar;
-+        [attribute] any StatusBar;
+ 	[attribute] boolean DisplayStatusBar;
  	[attribute] any CutCopyMode;
 +        [attribute, readonly] string Version;
+ 	[attribute] any StatusBar;
+     [attribute] long Cursor; 
  	any Workbooks( [in] any aIndex );
- 	any Worksheets( [in] any aIndex );
- 	any Windows( [in] any aIndex );
-diff -u -r sc/source/ui/vba/vbaapplication.cxx sc/source/ui/vba/vbaapplication.cxx
---- openoffice.org.orig/sc/source/ui/vba/vbaapplication.cxx	2006-11-06 14:53:52.000000000 +0000
-+++ openoffice.org/sc/source/ui/vba/vbaapplication.cxx	2006-11-06 16:25:06.000000000 +0000
-@@ -4,6 +4,9 @@
- #include<com/sun/star/view/XSelectionSupplier.hpp>
- #include<org/openoffice/vba/Excel/XlCalculation.hpp>
- #include <com/sun/star/sheet/XCellRangeReferrer.hpp>
-+#include <com/sun/star/frame/XLayoutManager.hpp>
-+#include <com/sun/star/task/XStatusIndicatorSupplier.hpp>
-+#include <com/sun/star/task/XStatusIndicator.hpp>
- 
- #include "vbaapplication.hxx"
- #include "vbaworkbooks.hxx"
-@@ -30,6 +33,8 @@
- #include <basic/sbmeth.hxx>
- //end test includes
- 
-+#define EXCELVERSION "10.0"
-+
- using namespace ::org::openoffice;
- using namespace ::com::sun::star;
- 
-@@ -187,6 +192,88 @@
- {
- 	//# FIXME TODO, implementation
+diff -ru sc/source/ui/vba/vbaapplication.cxx sc/source/ui/vba/vbaapplication.cxx
+--- openoffice.org.orig/sc/source/ui/vba/vbaapplication.cxx	2006-11-07 10:23:33.000000000 +0000
++++ openoffice.org/sc/source/ui/vba/vbaapplication.cxx	2006-11-07 10:24:26.000000000 +0000
+@@ -273,6 +273,12 @@
+             uno::Reference< uno::XInterface >() );
  }
-+
-+sal_Bool
-+ScVbaApplication::getDisplayStatusBar() throw (uno::RuntimeException)
-+{
-+       uno::Reference< frame::XModel > xModel( getCurrentDocument(), uno::UNO_QUERY_THROW );
-+    uno::Reference< frame::XFrame > xFrame( xModel->getCurrentController()->getFrame(), uno::UNO_QUERY_THROW );
-+    uno::Reference< beans::XPropertySet > xProps( xFrame, uno::UNO_QUERY_THROW );
-+
-+    if( xProps.is() ){
-+        uno::Reference< frame::XLayoutManager > xLayoutManager( xProps->getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LayoutManager")) ), uno::UNO_QUERY_THROW );
-+        rtl::OUString url(RTL_CONSTASCII_USTRINGPARAM( "private:resource/statusbar/statusbar" ));
-+        if( xLayoutManager.is() && xLayoutManager->isElementVisible( url ) ){
-+            return sal_True;
-+        }
-+    }
-+    return sal_False;
-+}
-+
-+void
-+ScVbaApplication::setDisplayStatusBar(sal_Bool bDisplayStatusBar) throw (uno::RuntimeException)
-+{
-+       uno::Reference< frame::XModel > xModel( getCurrentDocument(), uno::UNO_QUERY_THROW );
-+    uno::Reference< frame::XFrame > xFrame( xModel->getCurrentController()->getFrame(), uno::UNO_QUERY_THROW );
-+    uno::Reference< beans::XPropertySet > xProps( xFrame, uno::UNO_QUERY_THROW );
-+
-+    if( xProps.is() ){
-+        uno::Reference< frame::XLayoutManager > xLayoutManager( xProps->getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("LayoutManager")) ), uno::UNO_QUERY_THROW );
-+        rtl::OUString url(RTL_CONSTASCII_USTRINGPARAM( "private:resource/statusbar/statusbar" ));
-+        if( xLayoutManager.is() ){
-+            if( bDisplayStatusBar && !xLayoutManager->isElementVisible( url ) ){
-+                if( !xLayoutManager->showElement( url ) )
-+                    xLayoutManager->createElement( url );
-+                return;
-+            }
-+            else if( !bDisplayStatusBar && xLayoutManager->isElementVisible( url ) ){
-+                xLayoutManager->hideElement( url ); 
-+                return;
-+            }
-+        }
-+    }
-+    return;
-+}
-+
-+uno::Any SAL_CALL
-+ScVbaApplication::getStatusBar() throw (uno::RuntimeException)
-+{
-+       return uno::makeAny( !getDisplayStatusBar() );
-+}
-+
-+void SAL_CALL 
-+ScVbaApplication::setStatusBar( const uno::Any& _statusbar ) throw (uno::RuntimeException)
-+{
-+    rtl::OUString sText;
-+    sal_Bool bDefault;
-+       uno::Reference< frame::XModel > xModel( getCurrentDocument(), uno::UNO_QUERY_THROW );
-+    uno::Reference< task::XStatusIndicatorSupplier > xStatusIndicatorSupplier( xModel->getCurrentController(), uno::UNO_QUERY_THROW );
-+    uno::Reference< task::XStatusIndicator > xStatusIndicator( xStatusIndicatorSupplier->getStatusIndicator(), uno::UNO_QUERY_THROW );
-+    if( _statusbar >>= sText )
-+    {
-+        setDisplayStatusBar( sal_True );
-+        xStatusIndicator->start( sText, 100 );
-+        //xStatusIndicator->setText( sText );
-+    }
-+    else if( _statusbar >>= bDefault )
-+    {
-+        if( bDefault == sal_False )
-+        {
-+            xStatusIndicator->end();
-+            setDisplayStatusBar( sal_True );
-+        }
-+    }
-+    else
-+        throw uno::RuntimeException( rtl::OUString::createFromAscii( "Invalid prarameter. It should be a string or False" ),
-+            uno::Reference< uno::XInterface >() );
-+}
-+
+ 
 +::rtl::OUString
 +ScVbaApplication::getVersion() throw (uno::RuntimeException)
 +{
-+	return rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(EXCELVERSION));
++      return rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(EXCELVERSION));
 +}
 +
  double SAL_CALL 
  ScVbaApplication::CountA( const uno::Any& arg1 ) throw (uno::RuntimeException)
  {
-diff -u -r sc/source/ui/vba/vbaapplication.hxx sc/source/ui/vba/vbaapplication.hxx
---- openoffice.org.orig/sc/source/ui/vba/vbaapplication.hxx	2006-11-06 14:53:53.000000000 +0000
-+++ openoffice.org/sc/source/ui/vba/vbaapplication.hxx	2006-11-06 15:58:30.000000000 +0000
-@@ -30,6 +30,8 @@
-  virtual css::uno::Reference< oo::vba::XWorksheet > SAL_CALL getActiveSheet() throw (::com::sun::star::uno::RuntimeException);
- 	virtual sal_Bool SAL_CALL getScreenUpdating() throw (css::uno::RuntimeException);
- 	virtual void SAL_CALL setScreenUpdating(sal_Bool bUpdate) throw (css::uno::RuntimeException);
-+        virtual sal_Bool SAL_CALL getDisplayStatusBar() throw (css::uno::RuntimeException);
-+        virtual void SAL_CALL setDisplayStatusBar(sal_Bool bDisplayStatusBar) throw (css::uno::RuntimeException);
- 	virtual css::uno::Reference< oo::vba::XWorkbook > SAL_CALL getThisWorkbook() throw (css::uno::RuntimeException);
- 	virtual css::uno::Any SAL_CALL Workbooks( const css::uno::Any& aIndex ) throw (css::uno::RuntimeException);
- 	virtual css::uno::Any SAL_CALL Worksheets( const css::uno::Any& aIndex ) throw (css::uno::RuntimeException);
-@@ -38,6 +40,9 @@
- 	virtual css::uno::Any SAL_CALL Dialogs( const css::uno::Any& DialogIndex ) throw (css::uno::RuntimeException);
- 	virtual css::uno::Any SAL_CALL getCutCopyMode() throw (css::uno::RuntimeException);
- 	virtual void SAL_CALL setCutCopyMode( const css::uno::Any& _cutcopymode ) throw (css::uno::RuntimeException);
-+        virtual css::uno::Any SAL_CALL getStatusBar() throw (css::uno::RuntimeException);
-+        virtual void SAL_CALL setStatusBar( const css::uno::Any& _statusbar ) throw (css::uno::RuntimeException);
-+	virtual ::rtl::OUString SAL_CALL getVersion() throw (css::uno::RuntimeException);
+diff -ru sc/source/ui/vba/vbaapplication.hxx sc/source/ui/vba/vbaapplication.hxx
+--- openoffice.org.orig/sc/source/ui/vba/vbaapplication.hxx	2006-11-07 10:23:33.000000000 +0000
++++ openoffice.org/sc/source/ui/vba/vbaapplication.hxx	2006-11-07 10:24:04.000000000 +0000
+@@ -45,6 +45,8 @@
+ 	virtual ::sal_Int32 SAL_CALL getCursor() throw (css::uno::RuntimeException);
+ 	virtual void SAL_CALL setCursor( ::sal_Int32 _cursor ) throw (css::uno::RuntimeException);
  
++        virtual ::rtl::OUString SAL_CALL getVersion() throw (css::uno::RuntimeException);
++
  	virtual double SAL_CALL CountA( const css::uno::Any& arg1 ) throw (css::uno::RuntimeException) ;
  
+ 	virtual css::uno::Any SAL_CALL Windows( const css::uno::Any& aIndex ) throw (css::uno::RuntimeException);




More information about the fedora-cvs-commits mailing list