summaryrefslogtreecommitdiff
path: root/formula/source
diff options
context:
space:
mode:
authorEike Rathke <erack@erack.de>2011-08-24 01:39:19 +0200
committerEike Rathke <erack@erack.de>2011-08-24 01:39:43 +0200
commitfcac4e3eb4df6dcd4d6f6955a5d369262bcd1ea4 (patch)
tree2b48f9ffe8469737fe4ee297c0ffe1c83f228881 /formula/source
parent326494b71ce56488760d42c245df745deb713b16 (diff)
replace ScNameToken with proper FormulaIndexToken
Diffstat (limited to 'formula/source')
-rw-r--r--formula/source/core/api/token.cxx21
1 files changed, 17 insertions, 4 deletions
diff --git a/formula/source/core/api/token.cxx b/formula/source/core/api/token.cxx
index 8703fd8ba5fc..57469d334d89 100644
--- a/formula/source/core/api/token.cxx
+++ b/formula/source/core/api/token.cxx
@@ -212,6 +212,17 @@ void FormulaToken::SetIndex( sal_uInt16 )
DBG_ERRORFILE( "FormulaToken::SetIndex: virtual dummy called" );
}
+bool FormulaToken::IsGlobal() const
+{
+ DBG_ERRORFILE( "FormulaToken::IsGlobal: virtual dummy called" );
+ return true;
+}
+
+void FormulaToken::SetGlobal( bool )
+{
+ DBG_ERRORFILE( "FormulaToken::SetGlobal: virtual dummy called" );
+}
+
short* FormulaToken::GetJump() const
{
DBG_ERRORFILE( "FormulaToken::GetJump: virtual dummy called" );
@@ -1346,12 +1357,14 @@ bool FormulaStringOpToken::operator==( const FormulaToken& r ) const
return FormulaByteToken::operator==( r ) && aString == r.GetString();
}
-sal_uInt16 FormulaIndexToken::GetIndex() const { return nIndex; }
-sal_uInt8 FormulaIndexToken::GetByte() const {return static_cast<sal_uInt8>(mbGlobal); }
-void FormulaIndexToken::SetIndex( sal_uInt16 n ) { nIndex = n; }
+sal_uInt16 FormulaIndexToken::GetIndex() const { return nIndex; }
+void FormulaIndexToken::SetIndex( sal_uInt16 n ) { nIndex = n; }
+bool FormulaIndexToken::IsGlobal() const { return mbGlobal; }
+void FormulaIndexToken::SetGlobal( bool b ) { mbGlobal = b; }
bool FormulaIndexToken::operator==( const FormulaToken& r ) const
{
- return FormulaToken::operator==( r ) && nIndex == r.GetIndex();
+ return FormulaToken::operator==( r ) && nIndex == r.GetIndex() &&
+ mbGlobal == r.IsGlobal();
}
const String& FormulaExternalToken::GetExternal() const { return aExternal; }
sal_uInt8 FormulaExternalToken::GetByte() const { return nByte; }