[Libreoffice-commits] .: 2 commits - sc/source

Kohei Yoshida kohei at kemper.freedesktop.org
Mon Nov 15 10:50:01 PST 2010


 sc/source/filter/excel/excdoc.cxx |    2 +-
 sc/source/ui/inc/drawview.hxx     |   11 +++--------
 sc/source/ui/view/drawview.cxx    |   24 ++----------------------
 3 files changed, 6 insertions(+), 31 deletions(-)

New commits:
commit 0678229df4cccc00233dd21002cfa8417e98cbdd
Author: René Kjellerup <rk.katana.steel at gmail>
Date:   Mon Nov 15 17:04:23 2010 +0100

    Removing dead code in ScDrawView
    
    the method void DrawMarks(OutputDevice*) was unused in calc and actually
    the implementation there of was dead code, so removed completely.
    
    Commented references to unused code removed too, some (Hdl parts) I couldn't
    even find in any of the parent classes.

diff --git a/sc/source/ui/inc/drawview.hxx b/sc/source/ui/inc/drawview.hxx
index 1bcd560..d11979e 100644
--- a/sc/source/ui/inc/drawview.hxx
+++ b/sc/source/ui/inc/drawview.hxx
@@ -50,7 +50,6 @@ class ScDrawView: public FmFormView
     SdrDropMarkerOverlay*	pDropMarker;
     SdrObject*				pDropMarkObj;
     BOOL					bInConstruct;
-    //HMHBOOL					bDisableHdl;
 
     void			Construct();
     void			UpdateBrowser();
@@ -76,12 +75,8 @@ public:
 
     virtual void    DeleteMarked();
 
-    void			DrawMarks( OutputDevice* pOut ) const;
-
     void			MarkDropObj( SdrObject* pObj );
 
-    //HMHBOOL			IsDisableHdl() const 	{ return bDisableHdl; }
-
     void			SetMarkedToLayer( BYTE nLayerNo );
 
     void			InvalidateAttribs();
diff --git a/sc/source/ui/view/drawview.cxx b/sc/source/ui/view/drawview.cxx
index 35a835b..40b67f4 100644
--- a/sc/source/ui/view/drawview.cxx
+++ b/sc/source/ui/view/drawview.cxx
@@ -88,7 +88,6 @@ void ScDrawView::Construct()
     EnableExtendedCommandEventDispatcher(FALSE);
 
     SetFrameDragSingles(TRUE);
-//	SetSolidMarkHdl(TRUE);				// einstellbar -> UpdateUserViewOptions
 
     SetMinMoveDistancePixel( 2 );
     SetHitTolerancePixel( 2 );
@@ -248,20 +247,6 @@ void ScDrawView::InvalidateDrawTextAttrs()
     rBindings.Invalidate( SID_ALIGN_ANY_JUSTIFIED );
 }
 
-//void ScDrawView::DrawMarks( OutputDevice* pOut ) const
-//{
-//	DBG_ASSERT(pOut, "ScDrawView::DrawMarks: No OutputDevice (!)");
-//	SdrPaintWindow* pPaintWindow = FindPaintWindow(*pOut);
-//
-//	if(pPaintWindow)
-//	{
-//		if(pPaintWindow->isXorVisible())
-//		{
-//			ToggleShownXor(pOut, 0L);
-//		}
-//	}
-//}
-
 void ScDrawView::SetMarkedToLayer( BYTE nLayerNo )
 {
     if (AreObjectsMarked())
@@ -416,9 +401,7 @@ void ScDrawView::MarkListHasChanged()
     if ( pClient && pClient->IsObjectInPlaceActive() && !bUnoRefDialog )
     {
         //	#41730# beim ViewShell::Activate aus dem Reset2Open nicht die Handles anzeigen
-        //HMHbDisableHdl = TRUE;
         pClient->DeactivateObject();
-        //HMHbDisableHdl = FALSE;
         //	Image-Ole wieder durch Grafik ersetzen passiert jetzt in ScClient::UIActivate
     }
 
@@ -618,9 +601,6 @@ void __EXPORT ScDrawView::UpdateUserViewOptions()
         SetSnapEnabled( rGrid.GetUseGridSnap() );
         SetGridSnap( rGrid.GetUseGridSnap() );
 
-        //	Snap from grid options is no longer used
-//		SetSnapGrid( Size( rGrid.GetFldSnapX(), rGrid.GetFldSnapY() ) );
-
         Fraction aFractX( rGrid.GetFldDrawX(), rGrid.GetFldDivisionX() + 1 );
         Fraction aFractY( rGrid.GetFldDrawY(), rGrid.GetFldDivisionY() + 1 );
         SetSnapGridWidth( aFractX, aFractY );
commit 1ffd3b222b4de471e307e54eeb993141e1425954
Author: René Kjellerup <rk.katana.steel at gmail>
Date:   Mon Nov 15 16:50:03 2010 +0100

    Macro update and Comment translation
    
    just minor comment translations
    and a single ASSERT -> ENSURE convertion

diff --git a/sc/source/filter/excel/excdoc.cxx b/sc/source/filter/excel/excdoc.cxx
index 281b7cb..6d84808 100644
--- a/sc/source/filter/excel/excdoc.cxx
+++ b/sc/source/filter/excel/excdoc.cxx
@@ -760,7 +760,7 @@ void ExcDocument::Write( SvStream& rSvStrm )
 
         aHeader.Write( aXclStrm );
 
-        DBG_ASSERT( maTableList.GetSize() == maBoundsheetList.GetSize(),
+        OSL_ENSURE( maTableList.GetSize() == maBoundsheetList.GetSize(),
             "ExcDocument::Write - different number of sheets and BOUNDSHEET records" );
 
         for( size_t nTab = 0, nTabCount = maTableList.GetSize(); nTab < nTabCount; ++nTab )
diff --git a/sc/source/ui/inc/drawview.hxx b/sc/source/ui/inc/drawview.hxx
index 5a18bab..1bcd560 100644
--- a/sc/source/ui/inc/drawview.hxx
+++ b/sc/source/ui/inc/drawview.hxx
@@ -42,10 +42,10 @@ class ScDrawObjData;
 class ScDrawView: public FmFormView
 {
     ScViewData*				pViewData;
-    OutputDevice*			pDev;					//! noetig ?
+    OutputDevice*			pDev;					//! needed ?
     ScDocument*				pDoc;
     SCTAB					nTab;
-    Fraction				aScaleX;				// Faktor fuer Drawing-MapMode
+    Fraction				aScaleX;				// Factor for Drawing-MapMode
     Fraction				aScaleY;
     SdrDropMarkerOverlay*	pDropMarker;
     SdrObject*				pDropMarkObj;
@@ -139,7 +139,7 @@ public:
     /** Unlocks the internal layer that contains caption objects of cell notes. */
     inline void     UnlockInternalLayer() { LockInternalLayer( false ); }
 
-    SdrEndTextEditKind	ScEndTextEdit();	// ruft SetDrawTextUndo(0)
+    SdrEndTextEditKind	ScEndTextEdit();	// calls SetDrawTextUndo(0)
     ::com::sun::star::uno::Reference< ::com::sun::star::datatransfer::XTransferable > CopyToTransferable();
 };
 
diff --git a/sc/source/ui/view/drawview.cxx b/sc/source/ui/view/drawview.cxx
index 8a82114..35a835b 100644
--- a/sc/source/ui/view/drawview.cxx
+++ b/sc/source/ui/view/drawview.cxx
@@ -114,7 +114,7 @@ void ScDrawView::Construct()
         if (pLayer)
         {
             SetLayerLocked( pLayer->GetName(), bProt );
-            SetActiveLayer( pLayer->GetName() );		// FRONT als aktiven Layer setzen
+            SetActiveLayer( pLayer->GetName() );		// set active layer to FRONT
         }
         pLayer = rAdmin.GetLayerPerID(SC_LAYER_CONTROLS);
         if (pLayer)
@@ -205,7 +205,7 @@ void ScDrawView::InvalidateAttribs()
     if (!pViewData) return;
     SfxBindings& rBindings = pViewData->GetBindings();
 
-        // echte Statuswerte:
+        // true status values:
     rBindings.InvalidateAll( TRUE );
 }
 


More information about the Libreoffice-commits mailing list