[Libreoffice-commits] core.git: 3 commits - sc/source
Eike Rathke
erack at redhat.com
Tue May 10 11:22:16 UTC 2016
sc/source/core/tool/compiler.cxx | 12 ++++++------
sc/source/core/tool/tokenstringcontext.cxx | 6 ++++++
2 files changed, 12 insertions(+), 6 deletions(-)
New commits:
commit 8898a2359504c0c1e80c39468b8be10065597182
Author: Eike Rathke <erack at redhat.com>
Date: Tue May 10 13:15:09 2016 +0200
assert OpCodeMap and fallback-init maErrRef
Change-Id: I1e289c6891f3d0273104a909428a4aa0daeb738f
diff --git a/sc/source/core/tool/tokenstringcontext.cxx b/sc/source/core/tool/tokenstringcontext.cxx
index 46f6a8e..1e40afe 100644
--- a/sc/source/core/tool/tokenstringcontext.cxx
+++ b/sc/source/core/tool/tokenstringcontext.cxx
@@ -12,6 +12,7 @@
#include "document.hxx"
#include "dbdata.hxx"
#include "externalrefmgr.hxx"
+#include "globstr.hrc"
using namespace com::sun::star;
@@ -39,6 +40,11 @@ TokenStringContext::TokenStringContext( const ScDocument* pDoc, formula::Formula
mxOpCodeMap = aComp.GetOpCodeMap(formula::FormulaGrammar::extractFormulaLanguage(eGram));
if (mxOpCodeMap)
maErrRef = mxOpCodeMap->getSymbol(ocErrRef);
+ else
+ {
+ assert(!"TokenStringContext - no OpCodeMap?!?");
+ maErrRef = ScGlobal::GetRscString(STR_NO_REF_TABLE);
+ }
if (!pDoc)
return;
commit f92a6153ad9d8469fd8d6ae03e31fac993da091a
Author: Eike Rathke <erack at redhat.com>
Date: Tue May 10 13:06:40 2016 +0200
use passed rErrRef instead of obtaining resource string
Change-Id: I96ae74d8d82468bebcc79cebebf86731685c446f
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index 1a9cd57..c7014ac 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -1260,7 +1260,7 @@ struct ConventionXL_A1 : public Convention_A1, public ConventionXL
virtual void makeRefStr( OUStringBuffer& rBuf,
formula::FormulaGrammar::Grammar /*eGram*/,
const ScAddress& rPos,
- const OUString& /*rErrRef*/, const std::vector<OUString>& rTabNames,
+ const OUString& rErrRef, const std::vector<OUString>& rTabNames,
const ScComplexRefData& rRef,
bool bSingleRef,
bool /*bFromRangeName*/ ) const override
@@ -1275,7 +1275,7 @@ struct ConventionXL_A1 : public Convention_A1, public ConventionXL
if (!ValidAddress(aAbs1))
{
- rBuf.append(ScGlobal::GetRscString(STR_NO_REF_TABLE));
+ rBuf.append(rErrRef);
return;
}
@@ -1284,7 +1284,7 @@ struct ConventionXL_A1 : public Convention_A1, public ConventionXL
aAbs2 = aRef.Ref2.toAbs(rPos);
if (!ValidAddress(aAbs2))
{
- rBuf.append(ScGlobal::GetRscString(STR_NO_REF_TABLE));
+ rBuf.append(rErrRef);
return;
}
commit e17b76954cac42d9dec214eb7efb4d2c3d0274b7
Author: Eike Rathke <erack at redhat.com>
Date: Tue May 10 13:02:21 2016 +0200
use passed rErrRef instead of obtaining resource string
Change-Id: I3041b0a4f4427bbcbaf07e7a0694e9cfe5d10014
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index 10ec0ca..1a9cd57 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -1541,7 +1541,7 @@ struct ConventionXL_R1C1 : public ScCompiler::Convention, public ConventionXL
virtual void makeRefStr( OUStringBuffer& rBuf,
formula::FormulaGrammar::Grammar /*eGram*/,
const ScAddress& rPos,
- const OUString& /*rErrRef*/, const std::vector<OUString>& rTabNames,
+ const OUString& rErrRef, const std::vector<OUString>& rTabNames,
const ScComplexRefData& rRef,
bool bSingleRef,
bool /*bFromRangeName*/ ) const override
@@ -1555,7 +1555,7 @@ struct ConventionXL_R1C1 : public ScCompiler::Convention, public ConventionXL
// Foo!A1:#REF! versus #REF! at this point
if (!ValidCol(aAbsRef.aStart.Col()) || !ValidRow(aAbsRef.aStart.Row()))
{
- rBuf.append(ScGlobal::GetRscString(STR_NO_REF_TABLE));
+ rBuf.append(rErrRef);
return;
}
@@ -1563,7 +1563,7 @@ struct ConventionXL_R1C1 : public ScCompiler::Convention, public ConventionXL
{
if (!ValidCol(aAbsRef.aEnd.Col()) || !ValidRow(aAbsRef.aEnd.Row()))
{
- rBuf.append(ScGlobal::GetRscString(STR_NO_REF_TABLE));
+ rBuf.append(rErrRef);
return;
}
More information about the Libreoffice-commits
mailing list