diff options
Diffstat (limited to 'sc/source/ui/dbgui/consdlg.cxx')
-rw-r--r-- | sc/source/ui/dbgui/consdlg.cxx | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/sc/source/ui/dbgui/consdlg.cxx b/sc/source/ui/dbgui/consdlg.cxx index db55aaa0c657..7f6252fe248a 100644 --- a/sc/source/ui/dbgui/consdlg.cxx +++ b/sc/source/ui/dbgui/consdlg.cxx @@ -232,26 +232,26 @@ void ScConsolidateDlg::FillAreaLists() void ScConsolidateDlg::SetReference( const ScRange& rRef, ScDocument& rDocP ) { - if ( m_pRefInputEdit ) - { - if ( rRef.aStart != rRef.aEnd ) - RefInputStart( m_pRefInputEdit ); + if ( !m_pRefInputEdit ) + return; - OUString aStr; - ScRefFlags nFmt = ScRefFlags::RANGE_ABS_3D; //!!! nCurTab is still missing - const formula::FormulaGrammar::AddressConvention eConv = rDocP.GetAddressConvention(); + if ( rRef.aStart != rRef.aEnd ) + RefInputStart( m_pRefInputEdit ); - if ( rRef.aStart.Tab() != rRef.aEnd.Tab() ) - nFmt |= ScRefFlags::TAB2_3D; + OUString aStr; + ScRefFlags nFmt = ScRefFlags::RANGE_ABS_3D; //!!! nCurTab is still missing + const formula::FormulaGrammar::AddressConvention eConv = rDocP.GetAddressConvention(); - if ( m_pRefInputEdit == m_xEdDataArea.get()) - aStr = rRef.Format(rDocP, nFmt, eConv); - else if ( m_pRefInputEdit == m_xEdDestArea.get() ) - aStr = rRef.aStart.Format(nFmt, &rDocP, eConv); + if ( rRef.aStart.Tab() != rRef.aEnd.Tab() ) + nFmt |= ScRefFlags::TAB2_3D; - m_pRefInputEdit->SetRefString( aStr ); - ModifyHdl( *m_pRefInputEdit ); - } + if ( m_pRefInputEdit == m_xEdDataArea.get()) + aStr = rRef.Format(rDocP, nFmt, eConv); + else if ( m_pRefInputEdit == m_xEdDestArea.get() ) + aStr = rRef.aStart.Format(nFmt, &rDocP, eConv); + + m_pRefInputEdit->SetRefString( aStr ); + ModifyHdl( *m_pRefInputEdit ); } void ScConsolidateDlg::Close() |