[Libreoffice-commits] core.git: basctl/source

tagezi lera.goncharuk at gmail.com
Fri May 26 07:48:23 UTC 2017


 basctl/source/basicide/baside2.cxx |   12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

New commits:
commit d0c0ebbcabb67b8dfd130cf4e9e666bba229f846
Author: tagezi <lera.goncharuk at gmail.com>
Date:   Fri May 26 08:33:18 2017 +0300

    deleted variable bAdd because it does not make sense
    
    Change-Id: Ib65c38c7e99ff4667c021240a1412c8f57f53cbe
    Reviewed-on: https://gerrit.libreoffice.org/38050
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Mike Kaganski <mike.kaganski at collabora.com>

diff --git a/basctl/source/basicide/baside2.cxx b/basctl/source/basicide/baside2.cxx
index f0070aa5fe01..c85863afdd2f 100644
--- a/basctl/source/basicide/baside2.cxx
+++ b/basctl/source/basicide/baside2.cxx
@@ -669,7 +669,6 @@ BasicDebugFlags ModulWindow::BasicBreakHdl( StarBASIC* pBasic )
 void ModulWindow::BasicAddWatch()
 {
     AssertValidEditEngine();
-    bool bAdd = true;
     if ( !GetEditView()->HasSelection() )
     {
         TextPaM aWordStart;
@@ -679,15 +678,12 @@ void ModulWindow::BasicAddWatch()
             TextSelection aSel( aWordStart );
             aSel.GetEnd().GetIndex() += aWord.getLength();
             GetEditView()->SetSelection( aSel );
-            bAdd = true;
         }
     }
-    if ( bAdd )
-    {
-        TextSelection aSel = GetEditView()->GetSelection();
-        if ( aSel.GetStart().GetPara() == aSel.GetEnd().GetPara() ) // single line selection
-            m_rLayout.BasicAddWatch(GetEditView()->GetSelected());
-    }
+
+    TextSelection aSel = GetEditView()->GetSelection();
+    if ( aSel.GetStart().GetPara() == aSel.GetEnd().GetPara() ) // single line selection
+        m_rLayout.BasicAddWatch(GetEditView()->GetSelected());
 }
 
 


More information about the Libreoffice-commits mailing list