ooo-build r14149 - in branches/ooo-build-3-0: . patches/dev300



Author: kyoshida
Date: Tue Sep 30 03:24:51 2008
New Revision: 14149
URL: http://svn.gnome.org/viewvc/ooo-build?rev=14149&view=rev

Log:
2008-09-29  Kohei Yoshida  <kyoshida novell com>

	* patches/dev300/calc-status-bar-func.diff: show calculation results 
	for COUNT and COUNTA even if current range contains errors (n#430655).

	* patches/dev300/apply: apply the new patch.


Added:
   branches/ooo-build-3-0/patches/dev300/calc-status-bar-func.diff
Modified:
   branches/ooo-build-3-0/ChangeLog
   branches/ooo-build-3-0/patches/dev300/apply

Modified: branches/ooo-build-3-0/patches/dev300/apply
==============================================================================
--- branches/ooo-build-3-0/patches/dev300/apply	(original)
+++ branches/ooo-build-3-0/patches/dev300/apply	Tue Sep 30 03:24:51 2008
@@ -775,6 +775,9 @@
 # fix regression that prevents data pilot from being created on a filtered range.
 calc-dp-filtered-range-fix.diff, i#94281, kohei
 
+# show COUNT and COUNTA results even if current range contains an error.
+calc-status-bar-func.diff, n#430655, kohei
+
 [ CalcFixes < ooo300-m3 ]
 # Fix a regression on filtering by page field.
 calc-fix-datapilot-date-filter.diff, i#90022, kohei

Added: branches/ooo-build-3-0/patches/dev300/calc-status-bar-func.diff
==============================================================================
--- (empty file)
+++ branches/ooo-build-3-0/patches/dev300/calc-status-bar-func.diff	Tue Sep 30 03:24:51 2008
@@ -0,0 +1,63 @@
+diff --git sc/source/ui/inc/tabvwsh.hxx sc/source/ui/inc/tabvwsh.hxx
+index 6074c60..e7fa0ec 100644
+--- sc/source/ui/inc/tabvwsh.hxx
++++ sc/source/ui/inc/tabvwsh.hxx
+@@ -406,7 +406,7 @@ public:
+ 
+ 	void	ExecuteCellFormatDlg	( SfxRequest& rReq, USHORT nTabPage = 0xffff );
+ 
+-	BOOL	GetFunction( String& rFuncStr );
++	BOOL	GetFunction( String& rFuncStr, sal_uInt16 nErrCode = 0 );
+ 
+ 	void	StartSimpleRefDialog( const String& rTitle, const String& rInitVal,
+                                     BOOL bCloseOnButtonUp, BOOL bSingleCell, BOOL bMultiSelection );
+diff --git sc/source/ui/view/cellsh.cxx sc/source/ui/view/cellsh.cxx
+index bda4829..28e88df 100644
+--- sc/source/ui/view/cellsh.cxx
++++ sc/source/ui/view/cellsh.cxx
+@@ -691,15 +691,9 @@ void ScCellShell::GetState(SfxItemSet &rSet)
+ 								nErrCode = pFCell->GetErrCode();
+ 						}
+ 
+-						if ( nErrCode > 0 )
+-							rSet.Put( SfxStringItem( nWhich,
+-								ScGlobal::GetLongErrorString( nErrCode ) ) );
+-						else
+-						{
+-							String aFuncStr;
+-							if ( pTabViewShell->GetFunction( aFuncStr ) )
+-								rSet.Put( SfxStringItem( nWhich, aFuncStr ) );
+-						}
++                        String aFuncStr;
++                        if ( pTabViewShell->GetFunction( aFuncStr, nErrCode ) )
++                            rSet.Put( SfxStringItem( nWhich, aFuncStr ) );
+ 					}
+ 				}
+ 				break;
+diff --git sc/source/ui/view/tabvwsha.cxx sc/source/ui/view/tabvwsha.cxx
+index ab3c2e7..0b83147 100644
+--- sc/source/ui/view/tabvwsha.cxx
++++ sc/source/ui/view/tabvwsha.cxx
+@@ -71,12 +71,21 @@
+ #include "compiler.hxx"
+ 
+ 
+-BOOL ScTabViewShell::GetFunction( String& rFuncStr )
++BOOL ScTabViewShell::GetFunction( String& rFuncStr, sal_uInt16 nErrCode )
+ {
+ 	String aStr;
+ 
+ 	ScSubTotalFunc eFunc = (ScSubTotalFunc) SC_MOD()->GetAppOptions().GetStatusFunc();
+ 
++    if (eFunc == SUBTOTAL_FUNC_CNT || eFunc == SUBTOTAL_FUNC_CNT2)
++        nErrCode = 0;
++
++    if (nErrCode)
++    {
++        rFuncStr = ScGlobal::GetLongErrorString(nErrCode);
++        return true;
++    }
++
+ 	USHORT nGlobStrId = 0;
+ 	switch (eFunc)
+ 	{



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]