ooo-build r12586 - in branches/ooo-build-2-4-1: . patches/src680 patches/vba
- From: pflin svn gnome org
- To: svn-commits-list gnome org
- Subject: ooo-build r12586 - in branches/ooo-build-2-4-1: . patches/src680 patches/vba
- Date: Mon, 19 May 2008 02:21:46 +0000 (UTC)
Author: pflin
Date: Mon May 19 02:21:45 2008
New Revision: 12586
URL: http://svn.gnome.org/viewvc/ooo-build?rev=12586&view=rev
Log:
* patches/vba/vba-worksheet-change-event.diff: Fixed for n#390082,
back port Worksheet/Workbook change event to 2.4.1.
* patches/vba/vba-pagesetup-object.diff: Fixed for n#390080,
add PageSetup object and PrintArea method.
* patches/src680/apply: apply the patches.
Added:
branches/ooo-build-2-4-1/patches/vba/vba-pagesetup-object.diff
branches/ooo-build-2-4-1/patches/vba/vba-worksheet-change-event.diff
Modified:
branches/ooo-build-2-4-1/ChangeLog
branches/ooo-build-2-4-1/patches/src680/apply
Modified: branches/ooo-build-2-4-1/patches/src680/apply
==============================================================================
--- branches/ooo-build-2-4-1/patches/src680/apply (original)
+++ branches/ooo-build-2-4-1/patches/src680/apply Mon May 19 02:21:45 2008
@@ -1441,6 +1441,7 @@
vba-workbook-worksheet-events.diff
vba-workbook-worksheet-events-buildfix.diff
+vba-worksheet-change-event.diff, n#390082, Fong
vba-keep-codenames-in-sync.diff
@@ -1510,6 +1511,8 @@
vba-fixup-singlerange-sheetref.diff, n#309981, noelpwer
#always (try) to set the default property to an SbxUnoObject
vba-always-set-defaultprop.diff, n#388049, noelpwer
+# fix for n#390080, add PageSetup.PrintArea method
+vba-pagesetup-object.diff, n#390080, Fong
[ VBAUntested ]
SectionOwner => noelpwer
basic-source-classes-eventatt-cxx.diff, #no-upstream
Added: branches/ooo-build-2-4-1/patches/vba/vba-pagesetup-object.diff
==============================================================================
--- (empty file)
+++ branches/ooo-build-2-4-1/patches/vba/vba-pagesetup-object.diff Mon May 19 02:21:45 2008
@@ -0,0 +1,330 @@
+--- oovbaapi/org/openoffice/excel/XWorksheet.idl.orig 2008-05-15 10:55:34.000000000 +0800
++++ oovbaapi/org/openoffice/excel/XWorksheet.idl 2008-05-15 10:55:40.000000000 +0800
+@@ -56,6 +56,7 @@ module org { module openoffice { modul
+ interface XComments;
+ interface XRange;
+ interface XOutline;
++interface XPageSetup;
+ interface XWorksheet
+ {
+ interface ::org::openoffice::vba::XHelperInterface;
+@@ -88,6 +89,7 @@ interface XWorksheet
+ any PivotTables([in] any Index);
+ any Comments([in] any Index);
+ XOutline Outline();
++ XPageSetup PageSetup();
+ any OLEObjects([in] any Index);
+ void ShowDataForm();
+ any Shapes([in] any Index);
+--- oovbaapi/org/openoffice/excel/makefile.mk.orig 2008-05-15 10:55:34.000000000 +0800
++++ oovbaapi/org/openoffice/excel/makefile.mk 2008-05-15 10:55:40.000000000 +0800
+@@ -95,6 +95,7 @@ IDLFILES= XApplication.idl\
+ XNames.idl \
+ Workbook.idl \
+ Worksheet.idl \
++ XPageSetup.idl \
+
+
+ # ------------------------------------------------------------------
+--- /dev/null 2007-09-22 03:12:45.000000000 +0800
++++ oovbaapi/org/openoffice/excel/XPageSetup.idl 2008-05-15 10:55:40.000000000 +0800
+@@ -0,0 +1,64 @@
++/*************************************************************************
++ *
++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
++ *
++ * Copyright 2008 by Sun Microsystems, Inc.
++ *
++ * OpenOffice.org - a multi-platform office productivity suite
++ *
++ * $RCSfile: XPageSetup.idl,v $
++ * $Revision: 1.0 $
++ *
++ * 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.
++ *
++ ************************************************************************/
++#ifndef __org_openoffice_excel_XPageSetup_idl__
++#define __org_openoffice_excel_XPageSetup_idl__
++
++#ifndef __com_sun_star_uno_XInterface_idl__
++#include <com/sun/star/uno/XInterface.idl>
++#endif
++
++#ifndef __org_openoffice_vba_XHelperInterface_idl__
++#include <org/openoffice/vba/XHelperInterface.idl>
++#endif
++
++//=============================================================================
++
++module org { module openoffice { module excel {
++
++//=============================================================================
++
++
++interface XPageSetup
++{
++
++ interface ::org::openoffice::vba::XHelperInterface;
++
++ //Attributes
++ [attribute] string PrintArea;
++
++};
++
++//=============================================================================
++
++}; }; };
++
++#endif
++
++
+--- sc/source/ui/vba/vbaworksheet.hxx.orig 2008-05-15 10:55:34.000000000 +0800
++++ sc/source/ui/vba/vbaworksheet.hxx 2008-05-15 10:55:40.000000000 +0800
+@@ -47,6 +47,7 @@
+ #include <com/sun/star/uno/XComponentContext.hpp>
+ #include <com/sun/star/frame/XModel.hpp>
+ #include <org/openoffice/excel/XOutline.hpp>
++#include <org/openoffice/excel/XPageSetup.hpp>
+ #include <org/openoffice/excel/XChartObjects.hpp>
+
+ #include "vbahelperinterface.hxx"
+@@ -94,6 +95,7 @@ public:
+ virtual css::uno::Reference< oo::excel::XRange > SAL_CALL getUsedRange() throw (css::uno::RuntimeException) ;
+ virtual css::uno::Any SAL_CALL ChartObjects( const css::uno::Any& Index ) throw (css::uno::RuntimeException);
+ virtual css::uno::Reference< oo::excel::XOutline > SAL_CALL Outline( ) throw (css::uno::RuntimeException);
++ virtual css::uno::Reference< oo::excel::XPageSetup > SAL_CALL PageSetup( ) throw (css::uno::RuntimeException);
+ virtual css::uno::Reference< oo::excel::XWorksheet > SAL_CALL getNext() throw (css::uno::RuntimeException);
+ virtual css::uno::Reference< oo::excel::XWorksheet > SAL_CALL getPrevious() throw (css::uno::RuntimeException);
+
+--- sc/source/ui/vba/vbaworksheet.cxx.orig 2008-05-15 10:55:34.000000000 +0800
++++ sc/source/ui/vba/vbaworksheet.cxx 2008-05-15 20:44:11.000000000 +0800
+@@ -89,6 +89,7 @@
+ #include "vbaoleobject.hxx"
+ #include "vbaoleobjects.hxx"
+ #include "vbashapes.hxx"
++#include "vbapagesetup.hxx"
+
+ #define STANDARDWIDTH 2267
+ #define STANDARDHEIGHT 427
+@@ -271,6 +272,13 @@ ScVbaWorksheet::Outline( ) throw (uno::R
+ return new ScVbaOutline( this, mxContext, xOutline);
+ }
+
++uno::Reference< excel::XPageSetup >
++ScVbaWorksheet::PageSetup( ) throw (uno::RuntimeException)
++{
++ uno::Reference<sheet::XPrintAreas> xPrintAreas(getSheet(),uno::UNO_QUERY_THROW);
++ return new ScVbaPageSetup( this, mxContext, xPrintAreas, getModel());
++}
++
+ sal_Int32
+ ScVbaWorksheet::getStandardWidth() throw (uno::RuntimeException)
+ {
+--- sc/source/ui/vba/makefile.mk.orig 2008-05-15 10:55:34.000000000 +0800
++++ sc/source/ui/vba/makefile.mk 2008-05-15 10:55:40.000000000 +0800
+@@ -121,6 +121,7 @@ SLOFILES= \
+ $(SLO)$/vbacommandbarcontrols.obj \
+ $(SLO)$/vbacommandbar.obj \
+ $(SLO)$/vbacommandbars.obj \
++ $(SLO)$/vbapagesetup.obj \
+ $(SLO)$/service.obj \
+
+
+--- /dev/null 2007-09-22 03:12:45.000000000 +0800
++++ sc/source/ui/vba/vbapagesetup.hxx 2008-05-15 11:13:19.000000000 +0800
+@@ -0,0 +1,60 @@
++/*************************************************************************
++ *
++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
++ *
++ * Copyright 2008 by Sun Microsystems, Inc.
++ *
++ * OpenOffice.org - a multi-platform office productivity suite
++ *
++ * $RCSfile: vbapagesetup.hxx,v $
++ * $Revision: 1.4 $
++ *
++ * 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.
++ *
++ ************************************************************************/
++#ifndef SC_VBA_PAGESETUP_HXX
++#define SC_VBA_PAGESETUP_HXX
++
++#include <com/sun/star/sheet/XPrintAreas.hpp>
++#include <cppuhelper/implbase1.hxx>
++#include <org/openoffice/excel/XPageSetup.hpp>
++#include <com/sun/star/uno/XComponentContext.hpp>
++#include "vbahelperinterface.hxx"
++
++typedef InheritedHelperInterfaceImpl1< oo::excel::XPageSetup > ScVbaPageSetup_BASE;
++
++class ScVbaPageSetup : public ScVbaPageSetup_BASE
++{
++ css::uno::Reference< css::sheet::XPrintAreas > mxPrintAreas;
++ css::uno::Reference< css::frame::XModel > mxModel;
++public:
++ ScVbaPageSetup( const css::uno::Reference< oo::vba::XHelperInterface >& xParent,
++ const css::uno::Reference< css::uno::XComponentContext >& xContext,
++ const css::uno::Reference< css::sheet::XPrintAreas >& xPrintareas,
++ const css::uno::Reference< css::frame::XModel >& xModel) throw (css::uno::RuntimeException);
++ virtual ~ScVbaPageSetup(){}
++
++ // Attribute
++ virtual rtl::OUString SAL_CALL getPrintArea() throw (css::uno::RuntimeException);
++ virtual void SAL_CALL setPrintArea( const rtl::OUString& rAreas ) throw (css::uno::RuntimeException);
++
++ // XHelperInterface
++ virtual rtl::OUString& getServiceImplName();
++ virtual css::uno::Sequence<rtl::OUString> getServiceNames();
++};
++#endif
+--- /dev/null 2007-09-22 03:12:45.000000000 +0800
++++ sc/source/ui/vba/vbapagesetup.cxx 2008-05-15 20:44:11.000000000 +0800
+@@ -0,0 +1,117 @@
++/*************************************************************************
++ *
++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
++ *
++ * Copyright 2008 by Sun Microsystems, Inc.
++ *
++ * OpenOffice.org - a multi-platform office productivity suite
++ *
++ * $RCSfile: vbapagesetup.cxx,v $
++ * $Revision: 1.4 $
++ *
++ * 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.
++ *
++ ************************************************************************/
++#include "vbapagesetup.hxx"
++#include "cellsuno.hxx"
++#include "convuno.hxx"
++#include "rangelst.hxx"
++using namespace ::com::sun::star;
++using namespace ::org::openoffice;
++
++bool getScRangeListForAddress( const rtl::OUString& sName, ScDocShell* pDocSh, ScRange& refRange, ScRangeList& aCellRanges, ScAddress::Convention aConv = ScAddress::CONV_XL_A1 ) throw ( uno::RuntimeException );
++
++ScVbaPageSetup::ScVbaPageSetup(const uno::Reference< vba::XHelperInterface >& xParent,
++ const uno::Reference< uno::XComponentContext >& xContext,
++ const uno::Reference< sheet::XPrintAreas >& xPrintareas,
++ const uno::Reference< frame::XModel >& xModel) throw (uno::RuntimeException):
++ ScVbaPageSetup_BASE( xParent, xContext ),
++ mxPrintAreas( xPrintareas ), mxModel( xModel )
++{
++}
++
++rtl::OUString SAL_CALL ScVbaPageSetup::getPrintArea() throw (css::uno::RuntimeException)
++{
++ String aPrintArea;
++ uno::Sequence< table::CellRangeAddress > aSeq = mxPrintAreas->getPrintAreas();
++ sal_Int32 nCount = aSeq.getLength();
++ if( nCount )
++ {
++ ScAddress::Details aDetails( ScAddress::CONV_XL_A1, 0, 0 );
++ USHORT nFlags = SCA_VALID;
++ nFlags |= ( SCA_TAB_ABSOLUTE | SCA_COL_ABSOLUTE | SCA_ROW_ABSOLUTE | SCA_TAB2_ABSOLUTE | SCA_COL2_ABSOLUTE | SCA_ROW2_ABSOLUTE );
++ ScRangeList aRangeList;
++ for( sal_Int32 i=0; i<nCount; i++ )
++ {
++ ScRange aRange;
++ ScUnoConversion::FillScRange( aRange, aSeq[i] );
++ aRangeList.Append( aRange );
++ }
++ ScDocument* pDoc = getDocShell( mxModel )->GetDocument();
++ aRangeList.Format( aPrintArea, nFlags, pDoc, ScAddress::CONV_XL_A1, ',' );
++ }
++
++ return aPrintArea;
++}
++
++void SAL_CALL ScVbaPageSetup::setPrintArea( const rtl::OUString& rAreas ) throw (css::uno::RuntimeException)
++{
++ if( rAreas.getLength() == 0 ||
++ rAreas.equalsIgnoreAsciiCase ( rtl::OUString::createFromAscii("FALSE") ) )
++ {
++ // print the whole sheet
++ uno::Sequence< table::CellRangeAddress > aSeq;
++ mxPrintAreas->setPrintAreas( aSeq );
++ }
++ else
++ {
++ ScRangeList aCellRanges;
++ ScRange aRange;
++ if( getScRangeListForAddress( rAreas, getDocShell( mxModel ) , aRange, aCellRanges ) )
++ {
++ uno::Sequence< table::CellRangeAddress > aSeq( aCellRanges.Count() );
++ USHORT i=0;
++ for( ScRange* pRange = aCellRanges.First(); pRange; pRange = aCellRanges.Next() )
++ {
++ table::CellRangeAddress aRangeAddress;
++ ScUnoConversion::FillApiRange( aRangeAddress, *pRange );
++ aSeq[ i++ ] = aRangeAddress;
++ }
++ mxPrintAreas->setPrintAreas( aSeq );
++ }
++ }
++}
++
++rtl::OUString&
++ScVbaPageSetup::getServiceImplName()
++{
++ static rtl::OUString sImplName( RTL_CONSTASCII_USTRINGPARAM("ScVbaPageSetup") );
++ return sImplName;
++}
++
++uno::Sequence< rtl::OUString >
++ScVbaPageSetup::getServiceNames()
++{
++ static uno::Sequence< rtl::OUString > aServiceNames;
++ if ( aServiceNames.getLength() == 0 )
++ {
++ aServiceNames.realloc( 1 );
++ aServiceNames[ 0 ] = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("org.openoffice.excel.PageSetup" ) );
++ }
++ return aServiceNames;
++}
Added: branches/ooo-build-2-4-1/patches/vba/vba-worksheet-change-event.diff
==============================================================================
--- (empty file)
+++ branches/ooo-build-2-4-1/patches/vba/vba-worksheet-change-event.diff Mon May 19 02:21:45 2008
@@ -0,0 +1,263 @@
+--- sc/source/ui/docshell/docsh.cxx.orig 2008-05-15 15:34:26.000000000 +0800
++++ sc/source/ui/docshell/docsh.cxx 2008-05-16 13:07:38.000000000 +0800
+@@ -140,6 +140,7 @@
+ #include "compiler.hxx"
+ #include "cfgids.hxx"
+ #include "warnpassword.hxx"
++#include "cellsuno.hxx"
+
+ #include "docsh.hxx"
+ #include "docshimp.hxx"
+@@ -2490,6 +2491,70 @@ void ScDocShell::SetModified( BOOL bModi
+ }
+ }
+
++void ScDocShell::PostContentChanged( const ScRange& rRange )
++{
++ ScRangeList aList;
++ aList.Append(rRange);
++ PostContentChanged(aList);
++}
++uno::Any createRange( const uno::Any& aRange );
++uno::Any createWorkSheet( ScDocShell* pShell, SCTAB nTab );
++
++void ScDocShell::PostContentChanged( const ScRangeList& rList )
++{
++#if 0
++ String aStr;
++ rList.Format(aStr, SCR_ABS, &aDocument, ScAddress::CONV_XL_A1);
++ fprintf(stdout, "ScDocShell::PostContentChanged: range = '%s'\n",
++ rtl::OUStringToOString(aStr, RTL_TEXTENCODING_UTF8).getStr());
++#endif
++ ScCellRangesBase* pObj = NULL;
++ const ScRange& rRange = *(rList.GetObject(0));
++ SCTAB nTab = rRange.aStart.Tab();
++
++ if( rList.Count() == 1 )
++ pObj = new ScCellRangeObj( this, rRange );
++ else
++ pObj = new ScCellRangesObj( this, rList );
++
++ ScExtDocOptions* pExtOptions = aDocument.GetExtDocOptions();
++ String sSheetModuleName;
++ // Use code name if that exists, blank to force a full search otherwise
++ if ( pExtOptions )
++ sSheetModuleName = pExtOptions->GetCodeName( nTab );
++
++ String sSheetChangeScript( RTL_CONSTASCII_USTRINGPARAM("Worksheet_Change") );
++ String sWorkBookSheetChangeScript( RTL_CONSTASCII_USTRINGPARAM("Workbook_SheetChange") );
++ String sSheetChangeMacro = docMacroExists( this, sSheetModuleName, sSheetChangeScript );
++ String sWorkBookSheetChangeMacro = docMacroExists( this, String(), sWorkBookSheetChangeScript );
++ if( sSheetChangeMacro.Len() > 0 || sWorkBookSheetChangeMacro.Len() > 0 )
++ {
++ try
++ {
++ uno::Any aRet;
++ uno::Any aArg = uno::makeAny(uno::Reference<uno::XInterface>(static_cast<cppu::OWeakObject*>(pObj)));;
++ uno::Any aRange = createRange( aArg );
++ // Worksheet_Change
++ if( sSheetChangeMacro.Len() > 0 )
++ {
++ uno::Sequence< uno::Any > aArgs(1);
++ aArgs[0] = aRange;
++ executeWorkBookMacro( this, sSheetChangeMacro, aArgs, aRet );
++ }
++ // Workbook_SheetChanged
++ if( sWorkBookSheetChangeMacro.Len() > 0 )
++ {
++ uno::Sequence< uno::Any > aArgs(2);
++ aArgs[0] = createWorkSheet( this, nTab );
++ aArgs[1] = aRange;
++ executeWorkBookMacro( this, sWorkBookSheetChangeMacro, aArgs, aRet );
++ }
++ }
++ catch( uno::Exception& /*e*/ )
++ {
++ }
++ }
++}
+
+ void ScDocShell::SetDocumentModified( BOOL bIsModified /* = TRUE */ )
+ {
+--- sc/source/ui/inc/docsh.hxx.orig 2008-05-15 10:56:09.000000000 +0800
++++ sc/source/ui/inc/docsh.hxx 2008-05-15 10:56:17.000000000 +0800
+@@ -343,6 +343,8 @@ public:
+ void PostPaintExtras();
+
+ void PostDataChanged();
++ void PostContentChanged( const ScRange& rRange ); // for worsheet/workbook changed event
++ void PostContentChanged( const ScRangeList& rList );
+
+ void UpdatePaintExt( USHORT& rExtFlags, SCCOL nStartCol, SCROW nStartRow, SCTAB nStartTab,
+ SCCOL nEndCol, SCROW nEndRow, SCTAB nEndTab );
+--- sc/source/ui/undo/undoblk3.cxx.orig 2008-05-15 15:34:18.000000000 +0800
++++ sc/source/ui/undo/undoblk3.cxx 2008-05-16 12:37:05.000000000 +0800
+@@ -117,6 +117,15 @@ ScUndoDeleteContents::ScUndoDeleteConten
+ if ( !(aMarkData.IsMarked() || aMarkData.IsMultiMarked()) ) // keine Zelle markiert:
+ aMarkData.SetMarkArea( aRange ); // Zelle unter Cursor markieren
+
++ if (aMarkData.IsMarked() || aMarkData.IsMultiMarked())
++ {
++ ScRangeList aList;
++ aMarkData.FillRangeListWithMarks(&aList, false);
++ pDocShell->PostContentChanged(aList);
++ }
++ else
++ pDocShell->PostContentChanged( aRange );
++
+ SetChangeTrack();
+ }
+
+@@ -211,6 +220,15 @@ void ScUndoDeleteContents::DoChange( con
+ if (pViewShell)
+ pViewShell->CellContentChanged();
+
++ /*if (aMarkData.IsMarked() || aMarkData.IsMultiMarked())
++ {
++ ScRangeList aList;
++ aMarkData.FillRangeListWithMarks(&aList, false);
++ pDocShell->PostContentChanged(aList);
++ }
++ else
++ pDocShell->PostContentChanged( aRange );*/
++
+ ShowTable( aRange );
+ }
+
+--- sc/source/ui/undo/undoblk.cxx.orig 2008-05-15 15:34:18.000000000 +0800
++++ sc/source/ui/undo/undoblk.cxx 2008-05-16 12:38:58.000000000 +0800
+@@ -129,6 +129,7 @@ ScUndoInsertCells::ScUndoInsertCells( Sc
+ aEffRange.aEnd.SetRow(MAXROW);
+ }
+
++ pDocShell->PostContentChanged( aEffRange );
+ SetChangeTrack();
+ }
+
+@@ -264,6 +265,7 @@ void ScUndoInsertCells::DoChange( const
+ if (pViewShell)
+ pViewShell->CellContentChanged();
+
++ //pDocShell->PostContentChanged( aEffRange );
+ ShowTable( aEffRange.aStart.Tab() );
+ }
+
+@@ -337,6 +339,8 @@ ScUndoDeleteCells::ScUndoDeleteCells( Sc
+ aEffRange.aEnd.SetRow(MAXROW);
+ }
+
++ pDocShell->PostContentChanged( aEffRange );
++
+ SetChangeTrack();
+ }
+
+@@ -469,6 +473,7 @@ void ScUndoDeleteCells::DoChange( const
+
+ pDocShell->PostDataChanged();
+ // CellContentChanged kommt mit der Markierung
++ //pDocShell->PostContentChanged( aWorkRange );
+
+ ShowTable( aEffRange.aStart.Tab() );
+ }
+@@ -718,6 +723,7 @@ ScUndoCut::ScUndoCut( ScDocShell* pNewDo
+ pUndoDoc( pNewUndoDoc ),
+ aExtendedRange( aRange )
+ {
++ pDocShell->PostContentChanged( aExtendedRange );
+ SetChangeTrack();
+ }
+
+@@ -776,6 +782,7 @@ void ScUndoCut::DoChange( const BOOL bUn
+ pDocShell->PostDataChanged();
+ if (pViewShell)
+ pViewShell->CellContentChanged();
++ //pDocShell->PostContentChanged( aExtendedRange );
+ }
+
+ void __EXPORT ScUndoCut::Undo()
+@@ -842,6 +849,7 @@ ScUndoPaste::ScUndoPaste( ScDocShell* pN
+
+ if ( pOptions )
+ aPasteOptions = *pOptions; // used only for Repeat
++ pDocShell->PostContentChanged( aBlockRange );
+
+ SetChangeTrack();
+ }
+@@ -1017,6 +1025,7 @@ void ScUndoPaste::DoChange( const BOOL b
+ pDocShell->PostDataChanged();
+ if (pViewShell)
+ pViewShell->CellContentChanged();
++ //pDocShell->PostContentChanged( aDrawRange );
+ }
+
+ void __EXPORT ScUndoPaste::Undo()
+--- sc/source/ui/undo/undocell.cxx.orig 2008-05-15 15:34:18.000000000 +0800
++++ sc/source/ui/undo/undocell.cxx 2008-05-16 12:34:41.000000000 +0800
+@@ -218,6 +218,7 @@ ScUndoEnterData::ScUndoEnterData( ScDocS
+ nTab( nNewTab ),
+ nCount( nNewCount )
+ {
++ pDocShell->PostContentChanged( ScRange( ScAddress( nCol, nRow, nTab ) ) );
+ SetChangeTrack();
+ }
+
+@@ -254,6 +255,7 @@ void ScUndoEnterData::DoChange() const
+ pViewShell->MoveCursorAbs( nCol, nRow, SC_FOLLOW_JUMP, FALSE, FALSE );
+ }
+
++// pDocShell->PostContentChanged( ScRange( ScAddress( nCol, nRow, nTab ) ) );
+ pDocShell->PostDataChanged();
+ }
+
+@@ -375,6 +377,7 @@ ScUndoEnterValue::ScUndoEnterValue( ScDo
+ nValue ( nVal ),
+ bNeedHeight ( bHeight )
+ {
++ pDocShell->PostContentChanged( ScRange( aPos ) );
+ SetChangeTrack();
+ }
+
+@@ -425,6 +428,8 @@ void __EXPORT ScUndoEnterValue::Undo()
+
+ pDocShell->PostPaintCell( aPos.Col(), aPos.Row(), aPos.Tab() );
+
++ //pDocShell->PostContentChanged( ScRange( aPos ) );
++
+ ScChangeTrack* pChangeTrack = pDoc->GetChangeTrack();
+ if ( pChangeTrack )
+ pChangeTrack->Undo( nEndChangeAction, nEndChangeAction );
+@@ -440,6 +445,8 @@ void __EXPORT ScUndoEnterValue::Redo()
+ pDoc->SetValue( aPos.Col(), aPos.Row(), aPos.Tab(), nValue );
+ pDocShell->PostPaintCell( aPos.Col(), aPos.Row(), aPos.Tab() );
+
++ //pDocShell->PostContentChanged( ScRange( aPos ) );
++
+ SetChangeTrack();
+
+ EndRedo();
+@@ -469,6 +476,7 @@ ScUndoPutCell::ScUndoPutCell( ScDocShell
+ pEnteredCell( pRedoCell ),
+ bNeedHeight ( bHeight )
+ {
++ pDocShell->PostContentChanged( ScRange( aPos ) );
+ SetChangeTrack();
+ }
+
+@@ -521,6 +529,8 @@ void __EXPORT ScUndoPutCell::Undo()
+
+ pDocShell->PostPaintCell( aPos.Col(), aPos.Row(), aPos.Tab() );
+
++ //pDocShell->PostContentChanged( ScRange( aPos ) );
++
+ ScChangeTrack* pChangeTrack = pDoc->GetChangeTrack();
+ if ( pChangeTrack )
+ pChangeTrack->Undo( nEndChangeAction, nEndChangeAction );
+@@ -551,6 +561,8 @@ void __EXPORT ScUndoPutCell::Redo()
+
+ pDocShell->PostPaintCell( aPos.Col(), aPos.Row(), aPos.Tab() );
+
++ //pDocShell->PostContentChanged( ScRange( aPos ) );
++
+ SetChangeTrack();
+
+ EndRedo();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]