summaryrefslogtreecommitdiff
path: root/sc/source/ui/formdlg
diff options
context:
space:
mode:
authorEike Rathke <er@openoffice.org>2002-09-27 16:19:11 +0000
committerEike Rathke <er@openoffice.org>2002-09-27 16:19:11 +0000
commit22b27661a1991f77f0524ed62f0221f4dbda0519 (patch)
tree2f9d1c4586577f670fac7622688e3fb1a0488550 /sc/source/ui/formdlg
parent4ab8e3923197983eabb82a7b82b288e8faabd7a9 (diff)
#92320# new ScFAPToken
Diffstat (limited to 'sc/source/ui/formdlg')
-rw-r--r--sc/source/ui/formdlg/formula.cxx17
1 files changed, 10 insertions, 7 deletions
diff --git a/sc/source/ui/formdlg/formula.cxx b/sc/source/ui/formdlg/formula.cxx
index 73499864ee38..4983f183610e 100644
--- a/sc/source/ui/formdlg/formula.cxx
+++ b/sc/source/ui/formdlg/formula.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: formula.cxx,v $
*
- * $Revision: 1.6 $
+ * $Revision: 1.7 $
*
- * last change: $Author: nn $ $Date: 2002-04-23 14:22:31 $
+ * last change: $Author: er $ $Date: 2002-09-27 17:19:11 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -1828,17 +1828,20 @@ IMPL_LINK( ScFormulaDlg, StructSelHdl, ScStructPage*, pStruP )
if(pScStructPage==pStruP)
{
- ScToken* pSelToken=pScStructPage->GetSelectedToken();
+ ScToken* pSelToken = pScStructPage->GetSelectedToken();
+ ScToken* pOrigToken = ((pSelToken && pSelToken->GetType() == svFAP) ?
+ pSelToken->GetFAPOrigToken() : pSelToken);
xub_StrLen nTokPos=1;
if(pScTokA!=NULL)
{
- ScToken* pToken=pScTokA->First();
+ ScToken* pToken = pScTokA->First();
while(pToken!=NULL)
{
String aString;
- if(pToken==pSelToken) break;
+ if ( pToken == pOrigToken )
+ break;
pComp->CreateStringFromToken( aString,pToken);
nTokPos+=aString.Len();
pToken=pScTokA->Next();
@@ -1846,10 +1849,10 @@ IMPL_LINK( ScFormulaDlg, StructSelHdl, ScStructPage*, pStruP )
EditThisFunc(nTokPos);
}
- if(pSelToken!=NULL)
+ if( pOrigToken )
{
String aStr;
- pComp->CreateStringFromToken( aStr,pSelToken);
+ pComp->CreateStringFromToken( aStr, pOrigToken );
String aEntryTxt=pScStructPage->GetSelectedEntryText();
if(aEntryTxt!=aStr)