[Libreoffice-commits] .: sc/source

Kohei Yoshida kohei at kemper.freedesktop.org
Sat Oct 23 09:32:26 PDT 2010


 sc/source/ui/formdlg/formula.cxx |    1 +
 1 file changed, 1 insertion(+)

New commits:
commit 57b695a2a5f69190f54e33f610e2a4a9fcca19b1
Author: Kohei Yoshida <kyoshida at novell.com>
Date:   Sat Oct 23 18:26:22 2010 +0200

    When launching the ref input window, we need to select the initial string.
    
    Launching the reference input window from the formula wizard dialog did not
    set initial selection over the whole reference string.  For instance, type
    =ABS(A1) in a cell, open up the formula wizard dialog, then click the
    reference button to launch the reference input which has 'A1' inside, this
    string.  Because 'A1' was not selected, when you click on another cell it
    would not overwrite the old reference string.
    
    This commit fixes it.

diff --git a/sc/source/ui/formdlg/formula.cxx b/sc/source/ui/formdlg/formula.cxx
index f295384..ed9a268 100644
--- a/sc/source/ui/formdlg/formula.cxx
+++ b/sc/source/ui/formdlg/formula.cxx
@@ -406,6 +406,7 @@ bool ScFormulaDlg::calculateValue( const String& rStrExp, String& rStrResult )
 //	virtuelle Methoden von ScAnyRefDlg:
 void ScFormulaDlg::RefInputStart( formula::RefEdit* pEdit, formula::RefButton* pButton )
 {
+    pEdit->SetSelection(Selection(0, SELECTION_MAX));
     ::std::pair<formula::RefButton*,formula::RefEdit*> aPair = RefInputStartBefore( pEdit, pButton );
     m_aHelper.RefInputStart( aPair.second, aPair.first);
     RefInputStartAfter( aPair.second, aPair.first );


More information about the Libreoffice-commits mailing list