diff options
Diffstat (limited to 'sc/source/ui/miscdlgs/solvrdlg.cxx')
-rw-r--r-- | sc/source/ui/miscdlgs/solvrdlg.cxx | 66 |
1 files changed, 33 insertions, 33 deletions
diff --git a/sc/source/ui/miscdlgs/solvrdlg.cxx b/sc/source/ui/miscdlgs/solvrdlg.cxx index 524fcb8420ed..e718ba7be498 100644 --- a/sc/source/ui/miscdlgs/solvrdlg.cxx +++ b/sc/source/ui/miscdlgs/solvrdlg.cxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -50,42 +50,42 @@ #undef _SOLVERDLG_CXX -#define ERRORBOX(s) ErrorBox( this, WinBits( WB_OK | WB_DEF_OK), s ).Execute() +#define ERRORBOX(s) ErrorBox( this, WinBits( WB_OK | WB_DEF_OK), s ).Execute() //============================================================================ -// class ScSolverDlg +// class ScSolverDlg //---------------------------------------------------------------------------- ScSolverDlg::ScSolverDlg( SfxBindings* pB, SfxChildWindow* pCW, Window* pParent, ScDocument* pDocument, - ScAddress aCursorPos ) + ScAddress aCursorPos ) - : ScAnyRefDlg ( pB, pCW, pParent, RID_SCDLG_SOLVER ), + : ScAnyRefDlg ( pB, pCW, pParent, RID_SCDLG_SOLVER ), // aFlVariables ( this, ScResId( FL_VARIABLES ) ), - aFtFormulaCell ( this, ScResId( FT_FORMULACELL ) ), + aFtFormulaCell ( this, ScResId( FT_FORMULACELL ) ), aEdFormulaCell ( this, this, ScResId( ED_FORMULACELL ) ), - aRBFormulaCell ( this, ScResId( RB_FORMULACELL ), &aEdFormulaCell, this ), - aFtTargetVal ( this, ScResId( FT_TARGETVAL ) ), - aEdTargetVal ( this, ScResId( ED_TARGETVAL ) ), - aFtVariableCell ( this, ScResId( FT_VARCELL ) ), + aRBFormulaCell ( this, ScResId( RB_FORMULACELL ), &aEdFormulaCell, this ), + aFtTargetVal ( this, ScResId( FT_TARGETVAL ) ), + aEdTargetVal ( this, ScResId( ED_TARGETVAL ) ), + aFtVariableCell ( this, ScResId( FT_VARCELL ) ), aEdVariableCell ( this, this, ScResId( ED_VARCELL ) ), - aRBVariableCell ( this, ScResId( RB_VARCELL ), &aEdVariableCell, this ), - aBtnOk ( this, ScResId( BTN_OK ) ), - aBtnCancel ( this, ScResId( BTN_CANCEL ) ), - aBtnHelp ( this, ScResId( BTN_HELP ) ), + aRBVariableCell ( this, ScResId( RB_VARCELL ), &aEdVariableCell, this ), + aBtnOk ( this, ScResId( BTN_OK ) ), + aBtnCancel ( this, ScResId( BTN_CANCEL ) ), + aBtnHelp ( this, ScResId( BTN_HELP ) ), // - theFormulaCell ( aCursorPos ), - theVariableCell ( aCursorPos ), - pDoc ( pDocument ), - nCurTab ( aCursorPos.Tab() ), - pEdActive ( NULL ), - bDlgLostFocus ( FALSE ), - errMsgInvalidVar ( ScResId( STR_INVALIDVAR ) ), - errMsgInvalidForm ( ScResId( STR_INVALIDFORM ) ), - errMsgNoFormula ( ScResId( STR_NOFORMULA ) ), - errMsgInvalidVal ( ScResId( STR_INVALIDVAL ) ) + theFormulaCell ( aCursorPos ), + theVariableCell ( aCursorPos ), + pDoc ( pDocument ), + nCurTab ( aCursorPos.Tab() ), + pEdActive ( NULL ), + bDlgLostFocus ( FALSE ), + errMsgInvalidVar ( ScResId( STR_INVALIDVAR ) ), + errMsgInvalidForm ( ScResId( STR_INVALIDFORM ) ), + errMsgNoFormula ( ScResId( STR_NOFORMULA ) ), + errMsgInvalidVal ( ScResId( STR_INVALIDVAL ) ) { Init(); FreeResource(); @@ -101,10 +101,10 @@ __EXPORT ScSolverDlg::~ScSolverDlg() void __EXPORT ScSolverDlg::Init() { - String aStr; + String aStr; - aBtnOk. SetClickHdl ( LINK( this, ScSolverDlg, BtnHdl ) ); - aBtnCancel. SetClickHdl ( LINK( this, ScSolverDlg, BtnHdl ) ); + aBtnOk. SetClickHdl ( LINK( this, ScSolverDlg, BtnHdl ) ); + aBtnCancel. SetClickHdl ( LINK( this, ScSolverDlg, BtnHdl ) ); Link aLink = LINK( this, ScSolverDlg, GetFocusHdl ); aEdFormulaCell. SetGetFocusHdl ( aLink ); @@ -159,9 +159,9 @@ void ScSolverDlg::SetReference( const ScRange& rRef, ScDocument* pDocP ) if ( rRef.aStart != rRef.aEnd ) RefInputStart(pEdActive); - String aStr; - ScAddress aAdr = rRef.aStart; - USHORT nFmt = ( aAdr.Tab() == nCurTab ) + String aStr; + ScAddress aAdr = rRef.aStart; + USHORT nFmt = ( aAdr.Tab() == nCurTab ) ? SCA_ABS : SCA_ABS_3D; @@ -235,8 +235,8 @@ IMPL_LINK( ScSolverDlg, BtnHdl, PushButton*, pBtn ) // 3. wurde ein korrekter Zielwert eingegeben const formula::FormulaGrammar::AddressConvention eConv = pDoc->GetAddressConvention(); - USHORT nRes1 = theFormulaCell .Parse( aEdFormulaCell.GetText(), pDoc, eConv ); - USHORT nRes2 = theVariableCell.Parse( aEdVariableCell.GetText(), pDoc, eConv ); + USHORT nRes1 = theFormulaCell .Parse( aEdFormulaCell.GetText(), pDoc, eConv ); + USHORT nRes2 = theVariableCell.Parse( aEdVariableCell.GetText(), pDoc, eConv ); if ( SCA_VALID == ( nRes1 & SCA_VALID ) ) { @@ -255,7 +255,7 @@ IMPL_LINK( ScSolverDlg, BtnHdl, PushButton*, pBtn ) ScSolveParam aOutParam( theFormulaCell, theVariableCell, theTargetValStr ); - ScSolveItem aOutItem( SCITEM_SOLVEDATA, &aOutParam ); + ScSolveItem aOutItem( SCITEM_SOLVEDATA, &aOutParam ); SetDispatcherLock( FALSE ); |