Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


Hi,

This is an easy hack against calc.

Cheers,
-- Takeshi Abe
From de04998fb7efeacd0fda5a929b7a737e73154dd0 Mon Sep 17 00:00:00 2001
From: Takeshi Abe <tabe@fixedpoint.jp>
Date: Thu, 10 Feb 2011 23:55:12 +0900
Subject: [PATCH] remove unused variables and indistinguishable branching

---
 sc/source/ui/view/tabview2.cxx |   18 +++---------------
 1 files changed, 3 insertions(+), 15 deletions(-)

diff --git a/sc/source/ui/view/tabview2.cxx b/sc/source/ui/view/tabview2.cxx
index df01968..70fec8f 100644
--- a/sc/source/ui/view/tabview2.cxx
+++ b/sc/source/ui/view/tabview2.cxx
@@ -854,7 +854,6 @@ void ScTabView::UpdateAllOverlays()
 
 void ScTabView::PaintBlock( BOOL bReset )
 {
-    ScDocument* pDoc = aViewData.GetDocument();
     ScMarkData& rMark = aViewData.GetMarkData();
     SCTAB nTab = aViewData.GetTabNo();
     BOOL bMark = rMark.IsMarked();
@@ -873,7 +872,6 @@ void ScTabView::PaintBlock( BOOL bReset )
             rMark.SetMarking(bFlag);
 
             bMark = rMark.IsMarked();
-            bMulti = rMark.IsMultiMarked();
         }
         else
             rMark.GetMarkArea(aMarkRange);
@@ -894,19 +892,9 @@ void ScTabView::PaintBlock( BOOL bReset )
                 // Invertieren beim Loeschen nur auf aktiver View
                 if ( aViewData.IsActive() )
                 {
-                    USHORT i;
-                    if ( bMulti )
-                    {
-                        rMark.ResetMark();
-                        UpdateSelectionOverlay();
-                        bDidReset = TRUE;
-                    }
-                    else
-                    {
-                        rMark.ResetMark();
-                        UpdateSelectionOverlay();
-                        bDidReset = TRUE;
-                    }
+                    rMark.ResetMark();
+                    UpdateSelectionOverlay();
+                    bDidReset = TRUE;
                 }
             }
             else
-- 
1.7.2.3


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.