diff options
author | Albert Thuswaldner <albert.thuswaldner@gmail.com> | 2012-08-24 19:10:01 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2012-08-24 21:13:03 +0000 |
commit | 06f611210cf487dcd32aa7ccfaae5ed80124e439 (patch) | |
tree | be1a535a9d4b0cc9fdb0eeaa72ddcb0d24629cc4 /sc/source/ui | |
parent | 1b7c88ab4d6aaa79c484bcb179e5b2f296654462 (diff) |
Translation of comments from german in sc/source/ui/undo
Change-Id: Ic7f2233ae55f8c5505c5b325aef973b0d0c65730
Reviewed-on: https://gerrit.libreoffice.org/479
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'sc/source/ui')
-rw-r--r-- | sc/source/ui/undo/refundo.cxx | 8 | ||||
-rw-r--r-- | sc/source/ui/undo/undobase.cxx | 40 | ||||
-rw-r--r-- | sc/source/ui/undo/undoblk.cxx | 197 | ||||
-rw-r--r-- | sc/source/ui/undo/undoblk2.cxx | 15 | ||||
-rw-r--r-- | sc/source/ui/undo/undoblk3.cxx | 194 | ||||
-rw-r--r-- | sc/source/ui/undo/undocell.cxx | 84 | ||||
-rw-r--r-- | sc/source/ui/undo/undodat.cxx | 197 | ||||
-rw-r--r-- | sc/source/ui/undo/undodraw.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/undo/undoolk.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/undo/undotab.cxx | 122 |
10 files changed, 257 insertions, 604 deletions
diff --git a/sc/source/ui/undo/refundo.cxx b/sc/source/ui/undo/refundo.cxx index 630f42540048..1ee75d5b8b4b 100644 --- a/sc/source/ui/undo/refundo.cxx +++ b/sc/source/ui/undo/refundo.cxx @@ -52,9 +52,9 @@ ScRefUndoData::ScRefUndoData( const ScDocument* pDoc ) : ScRangeName* pOldRanges = ((ScDocument*)pDoc)->GetRangeName(); //! const pRangeName = pOldRanges ? new ScRangeName(*pOldRanges) : NULL; - pPrintRanges = pDoc->CreatePrintRangeSaver(); // neu erzeugt + pPrintRanges = pDoc->CreatePrintRangeSaver(); // recreated - //! bei Pivot nur Bereiche merken ??? + //! for Pivot, just mark the range ??? ScDPCollection* pOldDP = ((ScDocument*)pDoc)->GetDPCollection(); //! const pDPCollection = pOldDP ? new ScDPCollection(*pOldDP) : NULL; @@ -166,7 +166,7 @@ void ScRefUndoData::DoUndo( ScDocument* pDoc, sal_Bool bUndoRefFirst ) if (pDetOpList) pDoc->SetDetOpList( new ScDetOpList(*pDetOpList) ); - // bUndoRefFirst ist bSetChartRangeLists + // bUndoRefFirst is bSetChartRangeLists if ( pChartListenerCollection ) pDoc->SetChartListenerCollection( new ScChartListenerCollection( *pChartListenerCollection ), bUndoRefFirst ); @@ -174,7 +174,7 @@ void ScRefUndoData::DoUndo( ScDocument* pDoc, sal_Bool bUndoRefFirst ) if (pDBCollection || pRangeName) { sal_Bool bOldAutoCalc = pDoc->GetAutoCalc(); - pDoc->SetAutoCalc( false ); // Mehrfachberechnungen vermeiden + pDoc->SetAutoCalc( false ); // Avoid multiple calculations pDoc->CompileAll(); pDoc->SetDirty(); pDoc->SetAutoCalc( bOldAutoCalc ); diff --git a/sc/source/ui/undo/undobase.cxx b/sc/source/ui/undo/undobase.cxx index aeb847de27d6..0ebd77f61c93 100644 --- a/sc/source/ui/undo/undobase.cxx +++ b/sc/source/ui/undo/undobase.cxx @@ -77,17 +77,17 @@ bool ScSimpleUndo::SetViewMarkData( const ScMarkData& rMarkData ) sal_Bool ScSimpleUndo::Merge( SfxUndoAction *pNextAction ) { - // Zu jeder Undo-Action kann eine SdrUndoGroup fuer das Aktualisieren - // der Detektiv-Pfeile gehoeren. - // DetectiveRefresh kommt immer hinterher, die SdrUndoGroup ist in - // eine ScUndoDraw Action verpackt. - // Nur beim automatischen Aktualisieren wird AddUndoAction mit - // bTryMerg=sal_True gerufen. + // A SdrUndoGroup for the updating of detective arrows can belong + // to each Undo-Action. + // DetectiveRefresh is always called next, + // the SdrUndoGroup is packaged in a ScUndoDraw action. + // AddUndoAction is only called with bTryMerg=sal_True + // for automatic update. if ( !pDetectiveUndo && pNextAction->ISA(ScUndoDraw) ) { - // SdrUndoAction aus der ScUndoDraw Action uebernehmen, - // ScUndoDraw wird dann vom UndoManager geloescht + // SdrUndoAction is aquired from ScUndoDraw Action, + // ScUndoDraw is then deleted by the UndoManager ScUndoDraw* pCalcUndo = (ScUndoDraw*)pNextAction; pDetectiveUndo = pCalcUndo->GetDrawUndo(); @@ -104,7 +104,7 @@ void ScSimpleUndo::BeginUndo() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) - pViewShell->HideAllCursors(); // z.B. wegen zusammengefassten Zellen + pViewShell->HideAllCursors(); // for example due to merged cells // detective updates happened last, must be undone first if (pDetectiveUndo) @@ -128,11 +128,11 @@ void ScSimpleUndo::EndUndo() void ScSimpleUndo::BeginRedo() { - pDocShell->SetInUndo( sal_True ); //! eigenes Flag fuer Redo? + pDocShell->SetInUndo( sal_True ); //! own Flag for Redo? ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) - pViewShell->HideAllCursors(); // z.B. wegen zusammengefassten Zellen + pViewShell->HideAllCursors(); // for example due to merged cells } void ScSimpleUndo::EndRedo() @@ -168,8 +168,8 @@ void ScSimpleUndo::ShowTable( const ScRange& rRange ) SCTAB nStart = rRange.aStart.Tab(); SCTAB nEnd = rRange.aEnd.Tab(); SCTAB nTab = pViewShell->GetViewData()->GetTabNo(); - if ( nTab < nStart || nTab > nEnd ) // wenn nicht im Bereich: - pViewShell->SetTabNo( nStart ); // auf erste des Bereiches + if ( nTab < nStart || nTab > nEnd ) // when not in range: + pViewShell->SetTabNo( nStart ); // at beginning of the range } } @@ -236,7 +236,7 @@ sal_Bool ScBlockUndo::AdjustHeight() } else { - // Zoom auf 100 lassen + // Leave zoom at 100 nPPTX = ScGlobal::nScreenPPTX; nPPTY = ScGlobal::nScreenPPTY; } @@ -261,7 +261,7 @@ void ScBlockUndo::ShowBlock() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) { - ShowTable( aBlockRange ); // bei mehreren Tabs im Range ist jede davon gut + ShowTable( aBlockRange ); // with multiple sheets in range each of them is good pViewShell->MoveCursorAbs( aBlockRange.aStart.Col(), aBlockRange.aStart.Row(), SC_FOLLOW_JUMP, false, false ); SCTAB nTab = pViewShell->GetViewData()->GetTabNo(); @@ -270,7 +270,7 @@ void ScBlockUndo::ShowBlock() aRange.aEnd.SetTab( nTab ); pViewShell->MarkRange( aRange ); - // nicht per SetMarkArea an MarkData, wegen evtl. fehlendem Paint + // not through SetMarkArea to Mark Data, due to possible lacking paint } } @@ -334,7 +334,7 @@ void ScMultiBlockUndo::AdjustHeight() } else { - // Zoom auf 100 lassen + // Leave zoom at 100 nPPTX = ScGlobal::nScreenPPTX; nPPTY = ScGlobal::nScreenPPTY; } @@ -413,9 +413,9 @@ void ScMoveUndo::UndoRef() pRefUndoDoc->CopyToDocument( aRange, IDF_FORMULA, false, pDoc, NULL, false ); if (pRefUndoData) pRefUndoData->DoUndo( pDoc, (eMode == SC_UNDO_REFFIRST) ); - // HACK: ScDragDropUndo ist der einzige mit REFFIRST. - // Falls nicht, resultiert daraus evtl. ein zu haeufiges Anpassen - // der ChartRefs, nicht schoen, aber auch nicht schlecht.. + // HACK: ScDragDropUndo is the only one with REFFIRST. + // If not, results possibly in a too frequent adjustment + // of ChartRefs not that pretty, but not too bad either.. } void ScMoveUndo::BeginUndo() diff --git a/sc/source/ui/undo/undoblk.cxx b/sc/source/ui/undo/undoblk.cxx index cbab521e7548..1b833d0cdc98 100644 --- a/sc/source/ui/undo/undoblk.cxx +++ b/sc/source/ui/undo/undoblk.cxx @@ -81,19 +81,12 @@ TYPEINIT1(ScUndoBorder, ScBlockUndo); // To Do: -/*A*/ // SetOptimalHeight auf Dokument, wenn keine View -/*B*/ // gelinkte Tabellen +/*A*/ // SetOptimalHeight on Document, when no View +/*B*/ // linked sheets /*C*/ // ScArea -//? // spaeter mal pruefen +//? // check later -// ----------------------------------------------------------------------- -// -// Zellen einfuegen -// Zeilen einfuegen -// einzeln oder Block -// - ScUndoInsertCells::ScUndoInsertCells( ScDocShell* pNewDocShell, const ScRange& rRange, SCTAB nNewCount, SCTAB* pNewTabs, SCTAB* pNewScenarios, InsCellCmd eNewCmd, ScDocument* pUndoDocument, ScRefUndoData* pRefData, @@ -107,13 +100,13 @@ ScUndoInsertCells::ScUndoInsertCells( ScDocShell* pNewDocShell, bPartOfPaste( bNewPartOfPaste ), pPasteUndo( NULL ) { - if (eCmd == INS_INSROWS) // ganze Zeilen? + if (eCmd == INS_INSROWS) // whole row? { aEffRange.aStart.SetCol(0); aEffRange.aEnd.SetCol(MAXCOL); } - if (eCmd == INS_INSCOLS) // ganze Spalten? + if (eCmd == INS_INSCOLS) // whole column? { aEffRange.aStart.SetRow(0); aEffRange.aEnd.SetRow(MAXROW); @@ -233,7 +226,7 @@ void ScUndoInsertCells::DoChange( const sal_Bool bUndo ) } } -//? Undo fuer herausgeschobene Attribute ? +//? Undo for deferred attributes? sal_uInt16 nPaint = PAINT_GRID; ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); @@ -256,14 +249,14 @@ void ScUndoInsertCells::DoChange( const sal_Bool bUndo ) } break; case INS_INSCOLS: - nPaint |= PAINT_TOP; // obere Leiste + nPaint |= PAINT_TOP; // top bar case INS_CELLSRIGHT: for( i=0; i<nCount; i++ ) { - aWorkRange.aEnd.SetCol(MAXCOL); // bis ganz nach rechts + aWorkRange.aEnd.SetCol(MAXCOL); // to the far right if ( pDocShell->AdjustRowHeight( aWorkRange.aStart.Row(), aWorkRange.aEnd.Row(), pTabs[i]) ) - { // AdjustDraw zeichnet PAINT_TOP nicht, - aWorkRange.aStart.SetCol(0); // daher so geloest + { // AdjustDraw does not paint PAINT_TOP, + aWorkRange.aStart.SetCol(0); // thus solved like this aWorkRange.aEnd.SetRow(MAXROW); nPaint |= PAINT_LEFT; } @@ -290,7 +283,7 @@ void ScUndoInsertCells::Undo() if ( pPasteUndo ) pPasteUndo->Undo(); // undo paste first - WaitObject aWait( pDocShell->GetActiveDialogParent() ); // wichtig wegen TrackFormulas bei UpdateReference + WaitObject aWait( pDocShell->GetActiveDialogParent() ); // important due to TrackFormulas in UpdateReference BeginUndo(); DoChange( sal_True ); EndUndo(); @@ -298,7 +291,7 @@ void ScUndoInsertCells::Undo() void ScUndoInsertCells::Redo() { - WaitObject aWait( pDocShell->GetActiveDialogParent() ); // wichtig wegen TrackFormulas bei UpdateReference + WaitObject aWait( pDocShell->GetActiveDialogParent() ); // important due to TrackFormulas in UpdateReference BeginRedo(); DoChange( false ); EndRedo(); @@ -329,13 +322,6 @@ sal_Bool ScUndoInsertCells::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Zellen loeschen -// Zeilen loeschen -// einzeln oder Block -// - ScUndoDeleteCells::ScUndoDeleteCells( ScDocShell* pNewDocShell, const ScRange& rRange, SCTAB nNewCount, SCTAB* pNewTabs, SCTAB* pNewScenarios, DelCellCmd eNewCmd, ScDocument* pUndoDocument, ScRefUndoData* pRefData ) : @@ -346,13 +332,13 @@ ScUndoDeleteCells::ScUndoDeleteCells( ScDocShell* pNewDocShell, pScenarios( pNewScenarios ), eCmd( eNewCmd ) { - if (eCmd == DEL_DELROWS) // gaze Zeilen? + if (eCmd == DEL_DELROWS) // whole row? { aEffRange.aStart.SetCol(0); aEffRange.aEnd.SetCol(MAXCOL); } - if (eCmd == DEL_DELCOLS) // ganze Spalten? + if (eCmd == DEL_DELCOLS) // whole column? { aEffRange.aStart.SetRow(0); aEffRange.aEnd.SetRow(MAXROW); @@ -369,7 +355,7 @@ ScUndoDeleteCells::~ScUndoDeleteCells() rtl::OUString ScUndoDeleteCells::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_DELETECELLS ); // "Loeschen" + return ScGlobal::GetRscString( STR_UNDO_DELETECELLS ); // "Delete" } void ScUndoDeleteCells::SetChangeTrack() @@ -396,7 +382,7 @@ void ScUndoDeleteCells::DoChange( const sal_Bool bUndo ) else SetChangeTrack(); - // Ausfuehren + // Perform it switch (eCmd) { case DEL_DELROWS: @@ -429,7 +415,7 @@ void ScUndoDeleteCells::DoChange( const sal_Bool bUndo ) } } - // bei Undo Referenzen wiederherstellen + // restore for Undo references for( i=0; i<nCount && bUndo; i++ ) { pRefUndoDoc->CopyToDocument( aEffRange.aStart.Col(), aEffRange.aStart.Row(), pTabs[i], aEffRange.aEnd.Col(), aEffRange.aEnd.Row(), pTabs[i]+pScenarios[i], @@ -490,11 +476,11 @@ void ScUndoDeleteCells::DoChange( const sal_Bool bUndo ) } break; case DEL_DELCOLS: - nPaint |= PAINT_TOP; // obere Leiste + nPaint |= PAINT_TOP; // top bar case DEL_CELLSLEFT: for( i=0; i<nCount; i++ ) { - aWorkRange.aEnd.SetCol(MAXCOL); // bis ganz nach rechts + aWorkRange.aEnd.SetCol(MAXCOL); // to the far right if ( pDocShell->AdjustRowHeight( aWorkRange.aStart.Row(), aWorkRange.aEnd.Row(), pTabs[i] ) ) { aWorkRange.aStart.SetCol(0); @@ -514,21 +500,21 @@ void ScUndoDeleteCells::DoChange( const sal_Bool bUndo ) pDocShell->PostPaint( aWorkRange.aStart.Col(), aWorkRange.aStart.Row(), pTabs[i], aWorkRange.aEnd.Col(), aWorkRange.aEnd.Row(), pTabs[i]+pScenarios[i], nPaint, SC_PF_LINES ); } - // Markierung erst nach EndUndo + // Selection only after EndUndo pDocShell->PostDataChanged(); - // CellContentChanged kommt mit der Markierung + // CellContentChanged comes with the selection } void ScUndoDeleteCells::Undo() { - WaitObject aWait( pDocShell->GetActiveDialogParent() ); // wichtig wegen TrackFormulas bei UpdateReference + WaitObject aWait( pDocShell->GetActiveDialogParent() ); // important due to TrackFormulas in UpdateReference BeginUndo(); DoChange( sal_True ); EndUndo(); SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); - // Markierung erst nach EndUndo + // Selection only after EndUndo ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) { @@ -541,7 +527,7 @@ void ScUndoDeleteCells::Undo() void ScUndoDeleteCells::Redo() { - WaitObject aWait( pDocShell->GetActiveDialogParent() ); // wichtig wegen TrackFormulas bei UpdateReference + WaitObject aWait( pDocShell->GetActiveDialogParent() ); // important due to TrackFormulas in UpdateReference BeginRedo(); DoChange( false); EndRedo(); @@ -549,7 +535,7 @@ void ScUndoDeleteCells::Redo() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) - pViewShell->DoneBlockMode(); // aktuelle weg + pViewShell->DoneBlockMode(); // current way } void ScUndoDeleteCells::Repeat(SfxRepeatTarget& rTarget) @@ -564,11 +550,6 @@ sal_Bool ScUndoDeleteCells::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Zellen loeschen auf Mehrfachselektion -// - ScUndoDeleteMulti::ScUndoDeleteMulti( ScDocShell* pNewDocShell, sal_Bool bNewRows, sal_Bool bNeedsRefresh, SCTAB nNewTab, const SCCOLROW* pRng, SCCOLROW nRngCnt, @@ -591,7 +572,7 @@ ScUndoDeleteMulti::~ScUndoDeleteMulti() rtl::OUString ScUndoDeleteMulti::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_DELETECELLS ); // wie DeleteCells + return ScGlobal::GetRscString( STR_UNDO_DELETECELLS ); // as DeleteCells } void ScUndoDeleteMulti::DoChange() const @@ -641,7 +622,7 @@ void ScUndoDeleteMulti::SetChangeTrack() aRange.aEnd.SetCol( MAXCOL ); else aRange.aEnd.SetRow( MAXROW ); - // rueckwaerts loeschen + // delete in reverse SCCOLROW* pOneRange = &pRanges[2*nRangeCnt]; for ( SCCOLROW nRangeNo=0; nRangeNo<nRangeCnt; nRangeNo++ ) { @@ -668,14 +649,14 @@ void ScUndoDeleteMulti::SetChangeTrack() void ScUndoDeleteMulti::Undo() { - WaitObject aWait( pDocShell->GetActiveDialogParent() ); // wichtig wegen TrackFormulas bei UpdateReference + WaitObject aWait( pDocShell->GetActiveDialogParent() ); // important due to TrackFormulas in UpdateReference BeginUndo(); ScDocument* pDoc = pDocShell->GetDocument(); SCCOLROW* pOneRange; SCCOLROW nRangeNo; - // rueckwaerts geloescht -> vorwaerts einfuegen + // reverse delete -> forward insert pOneRange = pRanges; for (nRangeNo=0; nRangeNo<nRangeCnt; nRangeNo++) { @@ -705,8 +686,8 @@ void ScUndoDeleteMulti::Undo() DoChange(); - //! Markierung wieder einzeichnen - //! geht im Moment nicht, da keine Daten fuer Markierung vorhanden! + //! redrawing the selection is not possible at the moment + //! since no data for selection exist EndUndo(); SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); @@ -714,12 +695,12 @@ void ScUndoDeleteMulti::Undo() void ScUndoDeleteMulti::Redo() { - WaitObject aWait( pDocShell->GetActiveDialogParent() ); // wichtig wegen TrackFormulas bei UpdateReference + WaitObject aWait( pDocShell->GetActiveDialogParent() ); // important due to TrackFormulas in UpdateReference BeginRedo(); ScDocument* pDoc = pDocShell->GetDocument(); - // rueckwaerts loeschen + // reverese delet SCCOLROW* pOneRange = &pRanges[2*nRangeCnt]; for (SCCOLROW nRangeNo=0; nRangeNo<nRangeCnt; nRangeNo++) { @@ -741,7 +722,7 @@ void ScUndoDeleteMulti::Redo() void ScUndoDeleteMulti::Repeat(SfxRepeatTarget& rTarget) { - // DeleteCells, falls einfache Selektion + // delete cell if single selection if (rTarget.ISA(ScTabViewTarget)) ((ScTabViewTarget&)rTarget).GetViewShell()->DeleteCells( DEL_DELROWS, sal_True ); } @@ -752,11 +733,6 @@ sal_Bool ScUndoDeleteMulti::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Ausschneiden (Cut) -// - ScUndoCut::ScUndoCut( ScDocShell* pNewDocShell, ScRange aRange, ScAddress aOldEnd, const ScMarkData& rMark, ScDocument* pNewUndoDoc ) : @@ -775,7 +751,7 @@ ScUndoCut::~ScUndoCut() rtl::OUString ScUndoCut::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_CUT ); // "Ausschneiden" + return ScGlobal::GetRscString( STR_UNDO_CUT ); // "cut" } void ScUndoCut::SetChangeTrack() @@ -796,7 +772,7 @@ void ScUndoCut::DoChange( const sal_Bool bUndo ) // do not undo/redo objects and note captions, they are handled via drawing undo sal_uInt16 nUndoFlags = (IDF_ALL & ~IDF_OBJECTS) | IDF_NOCAPTIONS; - if (bUndo) // nur bei Undo + if (bUndo) // nonly for Undo { // all sheets - CopyToDocument skips those that don't exist in pUndoDoc SCTAB nTabCount = pDoc->GetTableCount(); @@ -808,7 +784,7 @@ void ScUndoCut::DoChange( const sal_Bool bUndo ) if ( pChangeTrack ) pChangeTrack->Undo( nStartChangeAction, nEndChangeAction ); } - else // nur bei Redo + else // only for Redo { pDocShell->UpdatePaintExt( nExtFlags, aExtendedRange ); pDoc->DeleteArea( aBlockRange.aStart.Col(), aBlockRange.aStart.Row(), @@ -857,11 +833,6 @@ sal_Bool ScUndoCut::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Einfuegen (Paste) -// - ScUndoPaste::ScUndoPaste( ScDocShell* pNewDocShell, const ScRangeList& rRanges, const ScMarkData& rMark, ScDocument* pNewUndoDoc, ScDocument* pNewRedoDoc, @@ -896,7 +867,7 @@ ScUndoPaste::~ScUndoPaste() rtl::OUString ScUndoPaste::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_PASTE ); // "Einfuegen" + return ScGlobal::GetRscString( STR_UNDO_PASTE ); // "paste" } void ScUndoPaste::SetChangeTrack() @@ -926,7 +897,7 @@ void ScUndoPaste::DoChange(bool bUndo) ScRefUndoData* pWorkRefData = bUndo ? pRefUndoData : pRefRedoData; - // fuer Undo immer alle oder keine Inhalte sichern + // Always back-up all or none of the content for Undo sal_uInt16 nUndoFlags = IDF_NONE; if (nFlags & IDF_CONTENTS) nUndoFlags |= IDF_CONTENTS; @@ -1131,11 +1102,6 @@ sal_Bool ScUndoPaste::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Verschieben/Kopieren (Drag & Drop) -// - ScUndoDragDrop::ScUndoDragDrop( ScDocShell* pNewDocShell, const ScRange& rRange, ScAddress aNewDestPos, sal_Bool bNewCut, ScDocument* pUndoDocument, ScRefUndoData* pRefData, sal_Bool bScenario ) : @@ -1172,7 +1138,7 @@ ScUndoDragDrop::~ScUndoDragDrop() } rtl::OUString ScUndoDragDrop::GetComment() const -{ // "Verschieben" : "Kopieren" +{ // "Move" : "Copy" return bCut ? ScGlobal::GetRscString( STR_UNDO_MOVE ) : ScGlobal::GetRscString( STR_UNDO_COPY ); @@ -1223,7 +1189,7 @@ void ScUndoDragDrop::PaintArea( ScRange aRange, sal_uInt16 nExtFlags ) const if ( bKeepScenarioFlags ) { - // Szenarien mitkopiert -> auch Szenario-Rahmen painten + // Copy scenario -> also paint scenario file aRange.aStart.SetCol(0); aRange.aStart.SetRow(0); aRange.aEnd.SetCol(MAXCOL); @@ -1254,7 +1220,7 @@ void ScUndoDragDrop::DoUndo( ScRange aRange ) const if ( pChangeTrack ) pChangeTrack->Undo( nStartChangeAction, nEndChangeAction ); -//? DB-Areas vor Daten, damit bei ExtendMerge die Autofilter-Knoepfe stimmen +//? Database range before data, so that the Autofilter button match up in ExtendMerge ScRange aPaintRange = aRange; pDoc->ExtendMerge( aPaintRange ); // before deleting @@ -1376,16 +1342,12 @@ void ScUndoDragDrop::Repeat(SfxRepeatTarget& /* rTarget */) sal_Bool ScUndoDragDrop::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // geht nicht + return false; // not possible } -// ----------------------------------------------------------------------- -// -// Liste der Bereichsnamen einfuegen -// (Einfuegen|Name|Einfuegen =>[Liste]) -// - +// Insert list containing range names +// (Insert|Name|Insert =>[List]) ScUndoListNames::ScUndoListNames( ScDocShell* pNewDocShell, const ScRange& rRange, ScDocument* pNewUndoDoc, ScDocument* pNewRedoDoc ) : ScBlockUndo( pNewDocShell, rRange, SC_UNDO_AUTOHEIGHT ), @@ -1444,12 +1406,6 @@ sal_Bool ScUndoListNames::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Szenario anwenden -// (Extras|Szenarien) -// - ScUndoUseScenario::ScUndoUseScenario( ScDocShell* pNewDocShell, const ScMarkData& rMark, /*C*/ const ScArea& rDestArea, @@ -1493,7 +1449,7 @@ void ScUndoUseScenario::Undo() pDoc->DeleteSelection( IDF_ALL, aMarkData ); pUndoDoc->CopyToDocument( aRange, IDF_ALL, sal_True, pDoc, &aMarkData ); - // Szenario-Tabellen + // scenario table sal_Bool bFrame = false; SCTAB nTab = aRange.aStart.Tab(); SCTAB nEndTab = nTab; @@ -1501,7 +1457,7 @@ void ScUndoUseScenario::Undo() ++nEndTab; for (SCTAB i = nTab+1; i<=nEndTab; i++) { - // Flags immer + // Flags always rtl::OUString aComment; Color aColor; sal_uInt16 nScenFlags; @@ -1509,7 +1465,7 @@ void ScUndoUseScenario::Undo() pDoc->SetScenarioData( i, aComment, aColor, nScenFlags ); sal_Bool bActive = pUndoDoc->IsActiveScenario( i ); pDoc->SetActiveScenario( i, bActive ); - // Bei Zurueckkopier-Szenarios auch Inhalte + // For copy-back scenario also content if ( nScenFlags & SC_SCENARIO_TWOWAY ) { pDoc->DeleteAreaTab( 0,0, MAXCOL,MAXROW, i, IDF_ALL ); @@ -1519,7 +1475,7 @@ void ScUndoUseScenario::Undo() bFrame = sal_True; } - // Wenn sichtbare Rahmen, dann alles painten + // if visible borders, then paint all if (bFrame) pDocShell->PostPaint( 0,0,nTab, MAXCOL,MAXROW,nTab, PAINT_GRID | PAINT_EXTRAS ); else @@ -1571,12 +1527,6 @@ sal_Bool ScUndoUseScenario::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Vorlage anwenden -// (Format|Vorlagenkatalog) -// - ScUndoSelectionStyle::ScUndoSelectionStyle( ScDocShell* pNewDocShell, const ScMarkData& rMark, const ScRange& rRange, @@ -1608,13 +1558,13 @@ void ScUndoSelectionStyle::DoChange( const sal_Bool bUndo ) SetViewMarkData( aMarkData ); ScRange aWorkRange( aRange ); - if ( pDoc->HasAttrib( aWorkRange, HASATTR_MERGED ) ) // zusammengefasste Zellen? + if ( pDoc->HasAttrib( aWorkRange, HASATTR_MERGED ) ) // Merged cells? pDoc->ExtendMerge( aWorkRange, sal_True ); sal_uInt16 nExtFlags = 0; pDocShell->UpdatePaintExt( nExtFlags, aWorkRange ); - if (bUndo) // bei Undo alte Daten wieder reinschubsen + if (bUndo) // if Undo then push back all old data again { SCTAB nTabCount = pDoc->GetTableCount(); ScRange aCopyRange = aWorkRange; @@ -1622,7 +1572,7 @@ void ScUndoSelectionStyle::DoChange( const sal_Bool bUndo ) aCopyRange.aEnd.SetTab(nTabCount-1); pUndoDoc->CopyToDocument( aCopyRange, IDF_ATTRIB, sal_True, pDoc, &aMarkData ); } - else // bei Redo Style wieder zuweisen + else // if Redo, then reapply style { ScStyleSheetPool* pStlPool = pDoc->GetStyleSheetPool(); ScStyleSheet* pStyleSheet = @@ -1688,11 +1638,6 @@ sal_uInt16 ScUndoSelectionStyle::GetId() const } -// ----------------------------------------------------------------------- -// -// Matrix-Formel eingeben -// - ScUndoEnterMatrix::ScUndoEnterMatrix( ScDocShell* pNewDocShell, const ScRange& rArea, ScDocument* pNewUndoDoc, const String& rForm ) : ScBlockUndo( pNewDocShell, rArea, SC_UNDO_SIMPLE ), @@ -1757,7 +1702,7 @@ void ScUndoEnterMatrix::Redo() pDoc->InsertMatrixFormula( aBlockRange.aStart.Col(), aBlockRange.aStart.Row(), aBlockRange.aEnd.Col(), aBlockRange.aEnd.Row(), aDestMark, aFormula ); -// pDocShell->PostPaint( aBlockRange, PAINT_GRID ); // nicht noetig ??? +// pDocShell->PostPaint( aBlockRange, PAINT_GRID ); // not needed ??? SetChangeTrack(); @@ -1779,10 +1724,6 @@ sal_Bool ScUndoEnterMatrix::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// ----------------------------------------------------------------------- -// -// Einzug vermindern / erhoehen -// ScRange lcl_GetMultiMarkRange( const ScMarkData& rMark ) { @@ -1850,10 +1791,6 @@ sal_Bool ScUndoIndent::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// ----------------------------------------------------------------------- -// -// Transliteration for cells -// ScUndoTransliterate::ScUndoTransliterate( ScDocShell* pNewDocShell, const ScMarkData& rMark, ScDocument* pNewUndoDoc, sal_Int32 nType ) : @@ -1911,10 +1848,6 @@ sal_Bool ScUndoTransliterate::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// ----------------------------------------------------------------------- -// -// einzelne Items per Which-IDs aus Bereich loeschen -// ScUndoClearItems::ScUndoClearItems( ScDocShell* pNewDocShell, const ScMarkData& rMark, ScDocument* pNewUndoDoc, const sal_uInt16* pW ) : @@ -1980,10 +1913,6 @@ sal_Bool ScUndoClearItems::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// ----------------------------------------------------------------------- -// -// Alle Umbrueche einer Tabelle loeschen -// ScUndoRemoveBreaks::ScUndoRemoveBreaks( ScDocShell* pNewDocShell, SCTAB nNewTab, ScDocument* pNewUndoDoc ) : @@ -2048,10 +1977,6 @@ sal_Bool ScUndoRemoveBreaks::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// ----------------------------------------------------------------------- -// -// Zusammenfassung aufheben (fuer einen ganzen Bereich) -// ScUndoRemoveMerge::ScUndoRemoveMerge( ScDocShell* pNewDocShell, const ScCellMergeOption& rOption, ScDocument* pNewUndoDoc ) : @@ -2068,7 +1993,7 @@ ScUndoRemoveMerge::~ScUndoRemoveMerge() rtl::OUString ScUndoRemoveMerge::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_REMERGE ); // "Zusammenfassung aufheben" + return ScGlobal::GetRscString( STR_UNDO_REMERGE ); // "remove merge" } void ScUndoRemoveMerge::Undo() @@ -2122,7 +2047,7 @@ void ScUndoRemoveMerge::Redo() // There is no need to extend merge area because it's already been extended. ScRange aRange = maOption.getSingleRange(nTab); - // ausfuehren + // execute it const SfxPoolItem& rDefAttr = pDoc->GetPool()->GetDefaultItem( ATTR_MERGE ); ScPatternAttr aPattern( pDoc->GetPool() ); @@ -2170,11 +2095,7 @@ void ScUndoRemoveMerge::SetCurTab() aBlockRange.aEnd.SetTab(nCurTab); } -// ----------------------------------------------------------------------- -// -// nur Umrandung setzen, per ScRangeList (StarOne) -// - +/** set only border, for ScRangeList (StarOne) */ ScRange lcl_TotalRange( const ScRangeList& rRanges ) { ScRange aTotal; @@ -2236,7 +2157,7 @@ void ScUndoBorder::Redo() { BeginRedo(); - ScDocument* pDoc = pDocShell->GetDocument(); //! Funktion an docfunc aufrufen + ScDocument* pDoc = pDocShell->GetDocument(); //! Function to call docfunc size_t nCount = pRanges->size(); for (size_t i = 0; i < nCount; ++i ) { @@ -2257,12 +2178,12 @@ void ScUndoBorder::Redo() void ScUndoBorder::Repeat(SfxRepeatTarget& /* rTarget */) { - //! spaeter (wenn die Funktion aus cellsuno nach docfunc gewandert ist) + //! later (when the function has moved from cellsuno to docfunc) } sal_Bool ScUndoBorder::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // s.o. + return false; // See above } diff --git a/sc/source/ui/undo/undoblk2.cxx b/sc/source/ui/undo/undoblk2.cxx index 62978d3bcdfb..4473b2a90adc 100644 --- a/sc/source/ui/undo/undoblk2.cxx +++ b/sc/source/ui/undo/undoblk2.cxx @@ -37,7 +37,7 @@ #include "global.hxx" #include "target.hxx" -#include "undoolk.hxx" //! GetUndo ins Document verschieben! +#include "undoolk.hxx" //! shift GetUndo in the Document // STATIC DATA ----------------------------------------------------------- @@ -46,12 +46,7 @@ TYPEINIT1(ScUndoWidthOrHeight, SfxUndoAction); // ----------------------------------------------------------------------- - - -// -// Spaltenbreiten oder Zeilenhoehen aendern -// - +/** Change column widths or row heights */ ScUndoWidthOrHeight::ScUndoWidthOrHeight( ScDocShell* pNewDocShell, const ScMarkData& rMark, SCCOLROW nNewStart, SCTAB nNewStartTab, SCCOLROW nNewEnd, SCTAB nNewEndTab, @@ -86,7 +81,7 @@ ScUndoWidthOrHeight::~ScUndoWidthOrHeight() rtl::OUString ScUndoWidthOrHeight::GetComment() const { - // [ "optimale " ] "Spaltenbreite" | "Zeilenhoehe" + // [ "optimal " ] "Column width" | "row height" return ( bWidth ? ( ( eMode == SC_SIZE_OPTIMAL )? ScGlobal::GetRscString( STR_UNDO_OPTCOLWIDTH ) : @@ -113,7 +108,7 @@ void ScUndoWidthOrHeight::Undo() } //! outlines from all tables? - if (pUndoTab) // Outlines mit gespeichert? + if (pUndoTab) // Outlines are included when saving ? pDoc->SetOutlineTable( nStartTab, pUndoTab ); SCTAB nTabCount = pDoc->GetTableCount(); @@ -170,7 +165,7 @@ void ScUndoWidthOrHeight::Redo() if ( nTab < nStartTab || nTab > nEndTab ) pViewShell->SetTabNo( nStartTab ); - // SetWidthOrHeight aendert aktuelle Tabelle ! + // SetWidthOrHeigt changes current sheet ! pViewShell->SetWidthOrHeight( bWidth, nRangeCnt, pRanges, eMode, nNewSize, false, true, &aMarkData ); } diff --git a/sc/source/ui/undo/undoblk3.cxx b/sc/source/ui/undo/undoblk3.cxx index 13522ad62f15..87fa1f466475 100644 --- a/sc/source/ui/undo/undoblk3.cxx +++ b/sc/source/ui/undo/undoblk3.cxx @@ -78,16 +78,9 @@ TYPEINIT1(ScUndoUpdateAreaLink, SfxUndoAction); // To Do: -/*A*/ // SetOptimalHeight auf Dokument, wenn keine View +/*A*/ // SetOptimalHeight on Document, when no View -//============================================================================ -// class ScUndoDeleteContents -// -// Inhalte loeschen - -//---------------------------------------------------------------------------- - ScUndoDeleteContents::ScUndoDeleteContents( ScDocShell* pNewDocShell, const ScMarkData& rMark, const ScRange& rRange, @@ -101,13 +94,13 @@ ScUndoDeleteContents::ScUndoDeleteContents( pUndoDoc ( pNewUndoDoc ), pDrawUndo ( NULL ), nFlags ( nNewFlags ), - bMulti ( bNewMulti ) // ueberliquid + bMulti ( bNewMulti ) // over liquid { if (bObjects) pDrawUndo = GetSdrUndoAction( pDocShell->GetDocument() ); - if ( !(aMarkData.IsMarked() || aMarkData.IsMultiMarked()) ) // keine Zelle markiert: - aMarkData.SetMarkArea( aRange ); // Zelle unter Cursor markieren + if ( !(aMarkData.IsMarked() || aMarkData.IsMultiMarked()) ) // no cell selected: + aMarkData.SetMarkArea( aRange ); // cell under cursor is selected SetChangeTrack(); } @@ -126,7 +119,7 @@ ScUndoDeleteContents::~ScUndoDeleteContents() rtl::OUString ScUndoDeleteContents::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_DELETECONTENTS ); // "Loeschen" + return ScGlobal::GetRscString( STR_UNDO_DELETECONTENTS ); // "Delete" } @@ -151,15 +144,15 @@ void ScUndoDeleteContents::DoChange( const sal_Bool bUndo ) sal_uInt16 nExtFlags = 0; - if (bUndo) // nur Undo + if (bUndo) // only Undo { - sal_uInt16 nUndoFlags = IDF_NONE; // entweder alle oder keine Inhalte kopieren - if (nFlags & IDF_CONTENTS) // (es sind nur die richtigen ins UndoDoc kopiert worden) + sal_uInt16 nUndoFlags = IDF_NONE; // either copy all or none of the content + if (nFlags & IDF_CONTENTS) // (Only the correct ones have been copied into UndoDoc) nUndoFlags |= IDF_CONTENTS; if (nFlags & IDF_ATTRIB) nUndoFlags |= IDF_ATTRIB; - if (nFlags & IDF_EDITATTR) // Edit-Engine-Attribute - nUndoFlags |= IDF_STRING; // -> Zellen werden geaendert + if (nFlags & IDF_EDITATTR) // Edit-Engine attribute + nUndoFlags |= IDF_STRING; // -> Cells are being changed // do not create clones of note captions, they will be restored via drawing undo nUndoFlags |= IDF_NOCAPTIONS; @@ -178,7 +171,7 @@ void ScUndoDeleteContents::DoChange( const sal_Bool bUndo ) pDocShell->UpdatePaintExt( nExtFlags, aRange ); // content after the change } - else // nur Redo + else // only Redo { pDocShell->UpdatePaintExt( nExtFlags, aRange ); // content before the change @@ -260,14 +253,6 @@ sal_Bool ScUndoDeleteContents::CanRepeat(SfxRepeatTarget& rTarget) const } -//============================================================================ -// class ScUndoFillTable -// -// Tabellen ausfuellen -// (Bearbeiten|Ausfuellen|...) - -//---------------------------------------------------------------------------- - ScUndoFillTable::ScUndoFillTable( ScDocShell* pNewDocShell, const ScMarkData& rMark, SCCOL nStartX, SCROW nStartY, SCTAB nStartZ, @@ -343,7 +328,7 @@ void ScUndoFillTable::DoChange( const sal_Bool bUndo ) SetViewMarkData( aMarkData ); - if (bUndo) // nur Undo + if (bUndo) // only Undo { SCTAB nTabCount = pDoc->GetTableCount(); ScRange aWorkRange(aRange); @@ -364,7 +349,7 @@ void ScUndoFillTable::DoChange( const sal_Bool bUndo ) if ( pChangeTrack ) pChangeTrack->Undo( nStartChangeAction, nEndChangeAction ); } - else // nur Redo + else // only Redo { aMarkData.MarkToMulti(); pDoc->FillTabMarked( nSrcTab, aMarkData, nFlags, nFunction, bSkipEmpty, bAsLink ); @@ -375,7 +360,7 @@ void ScUndoFillTable::DoChange( const sal_Bool bUndo ) pDocShell->PostPaint(0,0,0,MAXCOL,MAXROW,MAXTAB, PAINT_GRID|PAINT_EXTRAS); pDocShell->PostDataChanged(); - // CellContentChanged kommt mit der Markierung + // CellContentChanged comes with the selection ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) @@ -384,7 +369,7 @@ void ScUndoFillTable::DoChange( const sal_Bool bUndo ) if ( !aMarkData.GetTableSelect(nTab) ) pViewShell->SetTabNo( nSrcTab ); - pViewShell->DoneBlockMode(); // gibt sonst Probleme, weil Markierung auf falscher Tabelle + pViewShell->DoneBlockMode(); // causes problems oterwise since selection is on the wrong sheet. } } @@ -426,13 +411,6 @@ sal_Bool ScUndoFillTable::CanRepeat(SfxRepeatTarget& rTarget) const } -//============================================================================ -// class ScUndoSelectionAttr -// -// Zellformat aendern - -//---------------------------------------------------------------------------- - ScUndoSelectionAttr::ScUndoSelectionAttr( ScDocShell* pNewDocShell, const ScMarkData& rMark, SCCOL nStartX, SCROW nStartY, SCTAB nStartZ, @@ -474,7 +452,7 @@ ScUndoSelectionAttr::~ScUndoSelectionAttr() rtl::OUString ScUndoSelectionAttr::GetComment() const { - //"Attribute" "/Linien" + //"Attribute" "/Lines" return ScGlobal::GetRscString( pLineOuter ? STR_UNDO_SELATTRLINES : STR_UNDO_SELATTR ); } @@ -494,7 +472,7 @@ void ScUndoSelectionAttr::DoChange( const sal_Bool bUndo ) SetViewMarkData( aMarkData ); ScRange aEffRange( aRange ); - if ( pDoc->HasAttrib( aEffRange, HASATTR_MERGED ) ) // zusammengefasste Zellen? + if ( pDoc->HasAttrib( aEffRange, HASATTR_MERGED ) ) // merged cells? pDoc->ExtendMerge( aEffRange ); sal_uInt16 nExtFlags = 0; @@ -502,7 +480,7 @@ void ScUndoSelectionAttr::DoChange( const sal_Bool bUndo ) ChangeEditData(bUndo); - if (bUndo) // nur bei Undo + if (bUndo) // only for Undo { ScRange aCopyRange = aRange; SCTAB nTabCount = pDoc->GetTableCount(); @@ -510,7 +488,7 @@ void ScUndoSelectionAttr::DoChange( const sal_Bool bUndo ) aCopyRange.aEnd.SetTab(nTabCount-1); pUndoDoc->CopyToDocument( aCopyRange, IDF_ATTRIB, bMulti, pDoc, &aMarkData ); } - else // nur bei Redo + else // only for Redo { aMarkData.MarkToMulti(); pDoc->ApplySelectionPattern( *pApplyPattern, aMarkData ); @@ -589,13 +567,6 @@ sal_Bool ScUndoSelectionAttr::CanRepeat(SfxRepeatTarget& rTarget) const } -//============================================================================ -// class ScUndoAutoFill -// -// Auto-Fill (nur einfache Bloecke) - -//---------------------------------------------------------------------------- - ScUndoAutoFill::ScUndoAutoFill( ScDocShell* pNewDocShell, const ScRange& rRange, const ScRange& rSourceArea, ScDocument* pNewUndoDoc, const ScMarkData& rMark, @@ -630,7 +601,7 @@ ScUndoAutoFill::~ScUndoAutoFill() rtl::OUString ScUndoAutoFill::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_AUTOFILL ); //"Ausfuellen" + return ScGlobal::GetRscString( STR_UNDO_AUTOFILL ); //"Fill" } @@ -685,7 +656,7 @@ void ScUndoAutoFill::Redo() { BeginRedo(); -//! Tabellen selektieren +//! Select sheet SCCOLROW nCount = 0; switch (eFillDir) @@ -763,13 +734,6 @@ sal_Bool ScUndoAutoFill::CanRepeat(SfxRepeatTarget& rTarget) const } -//============================================================================ -// class ScUndoMerge -// -// Zellen zusammenfassen / Zusammenfassung aufheben - -//---------------------------------------------------------------------------- - ScUndoMerge::ScUndoMerge( ScDocShell* pNewDocShell, const ScCellMergeOption& rOption, bool bMergeContents, ScDocument* pUndoDoc, SdrUndoAction* pDrawUndo ) // @@ -919,13 +883,6 @@ sal_Bool ScUndoMerge::CanRepeat(SfxRepeatTarget& rTarget) const } -//============================================================================ -// class ScUndoAutoFormat -// -// Auto-Format (nur einfache Bloecke) - -//---------------------------------------------------------------------------- - ScUndoAutoFormat::ScUndoAutoFormat( ScDocShell* pNewDocShell, const ScRange& rRange, ScDocument* pNewUndoDoc, const ScMarkData& rMark, sal_Bool bNewSize, sal_uInt16 nNewFormatNo ) @@ -977,7 +934,7 @@ void ScUndoAutoFormat::Undo() aCopyRange.aEnd.SetTab(nTabCount-1); pUndoDoc->CopyToDocument( aCopyRange, IDF_ATTRIB, false, pDoc, &aMarkData ); - // Zellhoehen und -breiten (IDF_NONE) + // cell heights and widths (IDF_NONE) if (bSize) { SCCOL nStartX = aBlockRange.aStart.Col(); @@ -1035,12 +992,12 @@ void ScUndoAutoFormat::Redo() } else { - // Zoom auf 100 lassen + // Keep zoom at 100 nPPTX = ScGlobal::nScreenPPTX; nPPTY = ScGlobal::nScreenPPTY; } - sal_Bool bFormula = false; //! merken + sal_Bool bFormula = false; //! set for (SCTAB nTab=nStartZ; nTab<=nEndZ; nTab++) { @@ -1049,7 +1006,7 @@ void ScUndoAutoFormat::Redo() aDestMark.SetMarkArea( ScRange( nStartX, nStartY, nTab, nEndX, nEndY, nTab ) ); aDestMark.MarkToMulti(); - // wie SC_SIZE_VISOPT + // as SC_SIZE_VISOPT for (SCROW nRow=nStartY; nRow<=nEndY; nRow++) { sal_uInt8 nOld = pDoc->GetRowFlags(nRow,nTab); @@ -1099,13 +1056,6 @@ sal_Bool ScUndoAutoFormat::CanRepeat(SfxRepeatTarget& rTarget) const } -//============================================================================ -// class ScUndoReplace -// -// Ersetzen - -//---------------------------------------------------------------------------- - ScUndoReplace::ScUndoReplace( ScDocShell* pNewDocShell, const ScMarkData& rMark, SCCOL nCurX, SCROW nCurY, SCTAB nCurZ, const String& rNewUndoStr, ScDocument* pNewUndoDoc, @@ -1141,8 +1091,8 @@ void ScUndoReplace::SetChangeTrack() if ( pChangeTrack ) { if ( pUndoDoc ) - { //! im UndoDoc stehen nur die geaenderten Zellen, - // deswegen per Iterator moeglich + { //! UndoDoc includes only teh changed cells, + // that is why an Iterator can be used pChangeTrack->AppendContentsIfInRefDoc( pUndoDoc, nStartChangeAction, nEndChangeAction ); } @@ -1165,7 +1115,7 @@ void ScUndoReplace::SetChangeTrack() rtl::OUString ScUndoReplace::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_REPLACE ); // "Ersetzen" + return ScGlobal::GetRscString( STR_UNDO_REPLACE ); // "Replace" } @@ -1180,29 +1130,29 @@ void ScUndoReplace::Undo() ShowTable( aCursorPos.Tab() ); - if (pUndoDoc) // nur bei ReplaceAll !! + if (pUndoDoc) // only for ReplaceAll !! { OSL_ENSURE(pSearchItem->GetCommand() == SVX_SEARCHCMD_REPLACE_ALL, - "ScUndoReplace:: Falscher Modus"); + "ScUndoReplace:: Wrong Mode"); SetViewMarkData( aMarkData ); -//! markierte Tabellen -//! Bereich merken ? +//! selected sheet +//! select range ? - // Undo-Dokument hat keine Zeilen-/Spalten-Infos, also mit bColRowFlags = FALSE - // kopieren, um Outline-Gruppen nicht kaputtzumachen. + // Undo document has now row/column information, thus copy with + // bColRowFlags = FALSE to not destroy Outline groups sal_uInt16 nUndoFlags = (pSearchItem->GetPattern()) ? IDF_ATTRIB : IDF_CONTENTS; pUndoDoc->CopyToDocument( 0, 0, 0, MAXCOL, MAXROW, MAXTAB, - nUndoFlags, false, pDoc, NULL, false ); // ohne Row-Flags + nUndoFlags, false, pDoc, NULL, false ); // without row flags pDocShell->PostPaintGridAll(); } else if (pSearchItem->GetPattern() && pSearchItem->GetCommand() == SVX_SEARCHCMD_REPLACE) { - String aTempStr = pSearchItem->GetSearchString(); // vertauschen + String aTempStr = pSearchItem->GetSearchString(); // replace pSearchItem->SetSearchString(pSearchItem->GetReplaceString()); pSearchItem->SetReplaceString(aTempStr); pDoc->ReplaceStyle( *pSearchItem, @@ -1301,14 +1251,6 @@ sal_Bool ScUndoReplace::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } - -//============================================================================ -// class ScUndoTabOp -// -// Mehrfachoperation (nur einfache Bloecke) - -//---------------------------------------------------------------------------- - ScUndoTabOp::ScUndoTabOp( ScDocShell* pNewDocShell, SCCOL nStartX, SCROW nStartY, SCTAB nStartZ, SCCOL nEndX, SCROW nEndY, SCTAB nEndZ, ScDocument* pNewUndoDoc, @@ -1343,7 +1285,7 @@ ScUndoTabOp::~ScUndoTabOp() rtl::OUString ScUndoTabOp::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_TABOP ); // "Mehrfachoperation" + return ScGlobal::GetRscString( STR_UNDO_TABOP ); // "Multiple operation" } @@ -1406,13 +1348,6 @@ sal_Bool ScUndoTabOp::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -//============================================================================ -// class ScUndoConversion -// -// Spelling - -//---------------------------------------------------------------------------- - ScUndoConversion::ScUndoConversion( ScDocShell* pNewDocShell, const ScMarkData& rMark, SCCOL nCurX, SCROW nCurY, SCTAB nCurZ, ScDocument* pNewUndoDoc, @@ -1452,7 +1387,7 @@ void ScUndoConversion::SetChangeTrack() nStartChangeAction, nEndChangeAction ); else { - OSL_FAIL( "ScUndoConversion::SetChangeTrack: kein UndoDoc" ); + OSL_FAIL( "ScUndoConversion::SetChangeTrack: no UndoDoc" ); nStartChangeAction = nEndChangeAction = 0; } } @@ -1498,7 +1433,7 @@ void ScUndoConversion::DoChange( ScDocument* pRefDoc, const ScAddress& rCursorPo } else { - OSL_FAIL("Kein Un-/RedoDoc bei Un-/RedoSpelling"); + OSL_FAIL("no Un-/RedoDoc for Un-/RedoSpelling"); } } @@ -1544,13 +1479,6 @@ sal_Bool ScUndoConversion::CanRepeat(SfxRepeatTarget& rTarget) const } -//============================================================================ -// class ScUndoRefConversion -// -// cell reference conversion - -//---------------------------------------------------------------------------- - ScUndoRefConversion::ScUndoRefConversion( ScDocShell* pNewDocShell, const ScRange& aMarkRange, const ScMarkData& rMark, ScDocument* pNewUndoDoc, ScDocument* pNewRedoDoc, sal_Bool bNewMulti, sal_uInt16 nNewFlag) : @@ -1573,7 +1501,7 @@ ScUndoRefConversion::~ScUndoRefConversion() rtl::OUString ScUndoRefConversion::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_ENTERDATA ); // "Eingabe" + return ScGlobal::GetRscString( STR_UNDO_ENTERDATA ); // "Input" } void ScUndoRefConversion::SetChangeTrack() @@ -1635,12 +1563,7 @@ sal_Bool ScUndoRefConversion::CanRepeat(SfxRepeatTarget& rTarget) const { return (rTarget.ISA(ScTabViewTarget)); } -//============================================================================ -// class ScUndoRefreshLink -// -// Link aktualisieren / aendern -//---------------------------------------------------------------------------- ScUndoRefreshLink::ScUndoRefreshLink( ScDocShell* pNewDocShell, ScDocument* pNewUndoDoc ) @@ -1722,7 +1645,7 @@ void ScUndoRefreshLink::Undo() void ScUndoRefreshLink::Redo() { - OSL_ENSURE(pRedoDoc, "Kein RedoDoc bei ScUndoRefreshLink::Redo"); + OSL_ENSURE(pRedoDoc, "No RedoDoc for ScUndoRefreshLink::Redo"); BeginUndo(); @@ -1754,7 +1677,7 @@ void ScUndoRefreshLink::Redo() void ScUndoRefreshLink::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // no such thing } @@ -1782,18 +1705,11 @@ ScAreaLink* lcl_FindAreaLink( sfx2::LinkManager* pLinkManager, const String& rDo return (ScAreaLink*)pBase; } - OSL_FAIL("ScAreaLink nicht gefunden"); + OSL_FAIL("ScAreaLink not found"); return NULL; } -//============================================================================ -// class ScUndoInsertAreaLink -// -// Bereichs-Verknuepfung einfuegen - -//---------------------------------------------------------------------------- - ScUndoInsertAreaLink::ScUndoInsertAreaLink( ScDocShell* pShell, const String& rDoc, const String& rFlt, const String& rOpt, @@ -1878,13 +1794,6 @@ sal_Bool ScUndoInsertAreaLink::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -//============================================================================ -// class ScUndoRemoveAreaLink -// -// Bereichs-Verknuepfung loeschen - -//---------------------------------------------------------------------------- - ScUndoRemoveAreaLink::ScUndoRemoveAreaLink( ScDocShell* pShell, const String& rDoc, const String& rFlt, const String& rOpt, const String& rArea, const ScRange& rDestRange, @@ -1956,7 +1865,7 @@ void ScUndoRemoveAreaLink::Redo() void ScUndoRemoveAreaLink::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // no such thing } @@ -1968,13 +1877,6 @@ sal_Bool ScUndoRemoveAreaLink::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -//============================================================================ -// class ScUndoUpdateAreaLink -// -// Bereichs-Verknuepfung aktualisieren - -//---------------------------------------------------------------------------- - ScUndoUpdateAreaLink::ScUndoUpdateAreaLink( ScDocShell* pShell, const String& rOldD, const String& rOldF, const String& rOldO, const String& rOldA, const ScRange& rOldR, sal_uLong nOldRD, @@ -2000,7 +1902,7 @@ ScUndoUpdateAreaLink::ScUndoUpdateAreaLink( ScDocShell* pShell, nNewRefresh ( nNewRD ), bWithInsert ( bDoInsert ) { - OSL_ENSURE( aOldRange.aStart == aNewRange.aStart, "AreaLink verschoben ?" ); + OSL_ENSURE( aOldRange.aStart == aNewRange.aStart, "AreaLink moved ?" ); } @@ -2017,7 +1919,7 @@ ScUndoUpdateAreaLink::~ScUndoUpdateAreaLink() rtl::OUString ScUndoUpdateAreaLink::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_UPDATELINK ); //! eigener Text ?? + return ScGlobal::GetRscString( STR_UNDO_UPDATELINK ); //! own text ?? } @@ -2092,7 +1994,7 @@ void ScUndoUpdateAreaLink::Undo() aNewArea, aNewRange ); if (pLink) { - pLink->SetSource( aOldDoc, aOldFlt, aOldOpt, aOldArea ); // alte Werte im Link + pLink->SetSource( aOldDoc, aOldFlt, aOldOpt, aOldArea ); // old data in Link pLink->SetDestArea( aOldRange ); pLink->SetRefreshDelay( nOldRefresh ); } @@ -2124,7 +2026,7 @@ void ScUndoUpdateAreaLink::Redo() void ScUndoUpdateAreaLink::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // no such thing } diff --git a/sc/source/ui/undo/undocell.cxx b/sc/source/ui/undo/undocell.cxx index 0e139dff5e59..b4a18140bfdb 100644 --- a/sc/source/ui/undo/undocell.cxx +++ b/sc/source/ui/undo/undocell.cxx @@ -69,12 +69,6 @@ TYPEINIT1(ScUndoShowHideNote, ScSimpleUndo); TYPEINIT1(ScUndoDetective, ScSimpleUndo); TYPEINIT1(ScUndoRangeNames, ScSimpleUndo); - -// ----------------------------------------------------------------------- -// -// Attribute auf Cursor anwenden -// - ScUndoCursorAttr::ScUndoCursorAttr( ScDocShell* pNewDocShell, SCCOL nNewCol, SCROW nNewRow, SCTAB nNewTab, const ScPatternAttr* pOldPat, const ScPatternAttr* pNewPat, @@ -103,7 +97,7 @@ ScUndoCursorAttr::~ScUndoCursorAttr() rtl::OUString ScUndoCursorAttr::GetComment() const { - //! eigener Text fuer automatische Attributierung + //! own text for automatic attribution sal_uInt16 nId = STR_UNDO_CURSORATTR; // "Attribute" return ScGlobal::GetRscString( nId ); @@ -153,8 +147,8 @@ void ScUndoCursorAttr::Undo() if ( bIsAutomatic ) { - // wenn automatische Formatierung rueckgaengig gemacht wird, - // soll auch nicht weiter automatisch formatiert werden: + // if automatic formatting is reversed, then + // automatic formatting should also not continue to be done ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) @@ -183,11 +177,6 @@ sal_Bool ScUndoCursorAttr::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Daten eingeben -// - ScUndoEnterData::ScUndoEnterData( ScDocShell* pNewDocShell, SCCOL nNewCol, SCROW nNewRow, SCTAB nNewTab, SCTAB nNewCount, SCTAB* pNewTabs, ScBaseCell** ppOldData, @@ -224,13 +213,13 @@ ScUndoEnterData::~ScUndoEnterData() rtl::OUString ScUndoEnterData::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_ENTERDATA ); // "Eingabe" + return ScGlobal::GetRscString( STR_UNDO_ENTERDATA ); // "Input" } void ScUndoEnterData::DoChange() const { - // Zeilenhoehe anpassen - //! nur wenn noetig (alte oder neue EditZelle, oder Attribute) ?? + // Adjust row height + //! only when needed (old or new Edit cell, or Attribute) ?? for (sal_uInt16 i=0; i<nCount; i++) pDocShell->AdjustRowHeight( nRow, nRow, pTabs[i] ); @@ -263,7 +252,7 @@ void ScUndoEnterData::SetChangeTrack() pChangeTrack->AppendContent( aPos, ppOldCells[i], nFormat ); } if ( nEndChangeAction > pChangeTrack->GetActionMax() ) - nEndChangeAction = 0; // nichts appended + nEndChangeAction = 0; // nothing is appended } else nEndChangeAction = 0; @@ -362,11 +351,6 @@ sal_Bool ScUndoEnterData::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Wert aendern -// - ScUndoEnterValue::ScUndoEnterValue( ScDocShell* pNewDocShell, const ScAddress& rNewPos, ScBaseCell* pUndoCell, double nVal, sal_Bool bHeight ) : ScSimpleUndo( pNewDocShell ), @@ -386,7 +370,7 @@ ScUndoEnterValue::~ScUndoEnterValue() rtl::OUString ScUndoEnterValue::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_ENTERDATA ); // "Eingabe" + return ScGlobal::GetRscString( STR_UNDO_ENTERDATA ); // "Input" } void ScUndoEnterValue::SetChangeTrack() @@ -398,7 +382,7 @@ void ScUndoEnterValue::SetChangeTrack() nEndChangeAction = pChangeTrack->GetActionMax() + 1; pChangeTrack->AppendContent( aPos, pOldCell ); if ( nEndChangeAction > pChangeTrack->GetActionMax() ) - nEndChangeAction = 0; // nichts appended + nEndChangeAction = 0; // nothing is appended } else nEndChangeAction = 0; @@ -437,7 +421,7 @@ void ScUndoEnterValue::Redo() void ScUndoEnterValue::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // makes no sense } sal_Bool ScUndoEnterValue::CanRepeat(SfxRepeatTarget& /* rTarget */) const @@ -446,11 +430,6 @@ sal_Bool ScUndoEnterValue::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -// ----------------------------------------------------------------------- -// -// Beliebige Zelle eingeben -// - ScUndoPutCell::ScUndoPutCell( ScDocShell* pNewDocShell, const ScAddress& rNewPos, ScBaseCell* pUndoCell, ScBaseCell* pRedoCell, sal_Bool bHeight ) : ScSimpleUndo( pNewDocShell ), @@ -472,7 +451,7 @@ ScUndoPutCell::~ScUndoPutCell() rtl::OUString ScUndoPutCell::GetComment() const { - return ScGlobal::GetRscString( STR_UNDO_ENTERDATA ); // "Eingabe" + return ScGlobal::GetRscString( STR_UNDO_ENTERDATA ); // "Input" } void ScUndoPutCell::SetChangeTrack() @@ -484,7 +463,7 @@ void ScUndoPutCell::SetChangeTrack() nEndChangeAction = pChangeTrack->GetActionMax() + 1; pChangeTrack->AppendContent( aPos, pOldCell ); if ( nEndChangeAction > pChangeTrack->GetActionMax() ) - nEndChangeAction = 0; // nichts appended + nEndChangeAction = 0; // Nothing is appended } else nEndChangeAction = 0; @@ -526,7 +505,7 @@ void ScUndoPutCell::Redo() void ScUndoPutCell::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // makes no sense } sal_Bool ScUndoPutCell::CanRepeat(SfxRepeatTarget& /* rTarget */) const @@ -535,11 +514,6 @@ sal_Bool ScUndoPutCell::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -// ----------------------------------------------------------------------- -// -// Seitenumbrueche -// - ScUndoPageBreak::ScUndoPageBreak( ScDocShell* pNewDocShell, SCCOL nNewCol, SCROW nNewRow, SCTAB nNewTab, sal_Bool bNewColumn, sal_Bool bNewInsert ) : @@ -558,7 +532,7 @@ ScUndoPageBreak::~ScUndoPageBreak() rtl::OUString ScUndoPageBreak::GetComment() const { - //"Spaltenumbruch" | "Zeilenumbruch" "einfuegen" | "loeschen" + //"Column break" | "Row break" "insert" | "delete" return String ( bColumn ? ( bInsert ? ScGlobal::GetRscString( STR_UNDO_INSCOLBREAK ) : @@ -620,10 +594,6 @@ sal_Bool ScUndoPageBreak::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// ----------------------------------------------------------------------- -// -// Druck-Skalierung -// ScUndoPrintZoom::ScUndoPrintZoom( ScDocShell* pNewDocShell, SCTAB nT, sal_uInt16 nOS, sal_uInt16 nOP, sal_uInt16 nNS, sal_uInt16 nNP ) : @@ -696,11 +666,6 @@ sal_Bool ScUndoPrintZoom::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Thesaurus -// - ScUndoThesaurus::ScUndoThesaurus( ScDocShell* pNewDocShell, SCCOL nNewCol, SCROW nNewRow, SCTAB nNewTab, const String& rNewUndoStr, const EditTextObject* pUndoTObj, @@ -743,7 +708,7 @@ void ScUndoThesaurus::SetChangeTrack( ScBaseCell* pOldCell ) nEndChangeAction = pChangeTrack->GetActionMax() + 1; pChangeTrack->AppendContent( ScAddress( nCol, nRow, nTab ), pOldCell ); if ( nEndChangeAction > pChangeTrack->GetActionMax() ) - nEndChangeAction = 0; // nichts appended + nEndChangeAction = 0; // nothing is appended } else nEndChangeAction = 0; @@ -776,7 +741,7 @@ void ScUndoThesaurus::DoChange( sal_Bool bUndo, const String& rStr, } else { - OSL_FAIL("Nicht CELLTYPE_EDIT bei Un/RedoThesaurus"); + OSL_FAIL("Not CELLTYPE_EDIT for Un/RedoThesaurus"); } } } @@ -965,11 +930,6 @@ rtl::OUString ScUndoShowHideNote::GetComment() const // ============================================================================ -// ----------------------------------------------------------------------- -// -// Detektiv -// - ScUndoDetective::ScUndoDetective( ScDocShell* pNewDocShell, SdrUndoAction* pDraw, const ScDetOpData* pOperation, ScDetOpList* pUndoList ) : @@ -1023,7 +983,7 @@ void ScUndoDetective::Undo() } else { - // Eintrag aus der Liste loeschen + // Delete entry from list ScDetOpList* pList = pDoc->GetDetOpList(); if (pList && pList->Count()) @@ -1034,7 +994,7 @@ void ScUndoDetective::Undo() rVec.erase( it); else { - OSL_FAIL("Detektiv-Eintrag in der Liste nicht gefunden"); + OSL_FAIL("Detective entry in the list, not found"); } } } @@ -1068,7 +1028,7 @@ void ScUndoDetective::Redo() void ScUndoDetective::Repeat(SfxRepeatTarget& /* rTarget */) { - // hammanich + // makes no sense } sal_Bool ScUndoDetective::CanRepeat(SfxRepeatTarget& /* rTarget */) const @@ -1076,10 +1036,6 @@ sal_Bool ScUndoDetective::CanRepeat(SfxRepeatTarget& /* rTarget */) const return false; } -// ----------------------------------------------------------------------- -// -// Benannte Bereiche -// ScUndoRangeNames::ScUndoRangeNames( ScDocShell* pNewDocShell, ScRangeName* pOld, ScRangeName* pNew, SCTAB nTab ) : @@ -1142,7 +1098,7 @@ void ScUndoRangeNames::Redo() void ScUndoRangeNames::Repeat(SfxRepeatTarget& /* rTarget */) { - // hammanich + // makes no sense } sal_Bool ScUndoRangeNames::CanRepeat(SfxRepeatTarget& /* rTarget */) const diff --git a/sc/source/ui/undo/undodat.cxx b/sc/source/ui/undo/undodat.cxx index 24116db895a6..8314d9a65e2f 100644 --- a/sc/source/ui/undo/undodat.cxx +++ b/sc/source/ui/undo/undodat.cxx @@ -74,11 +74,7 @@ TYPEINIT1(ScUndoChartData, ScSimpleUndo); TYPEINIT1(ScUndoDataForm, SfxUndoAction); // ----------------------------------------------------------------------- - - -// -// Outline-Gruppen ein- oder ausblenden -// +// Show or hide outline groups ScUndoDoOutline::ScUndoDoOutline( ScDocShell* pNewDocShell, SCCOLROW nNewStart, SCCOLROW nNewEnd, SCTAB nNewTab, @@ -102,7 +98,7 @@ ScUndoDoOutline::~ScUndoDoOutline() } rtl::OUString ScUndoDoOutline::GetComment() const -{ // Detail einblenden" "Detail ausblenden" +{ // Show outline" "Hide outline" return bShow ? ScGlobal::GetRscString( STR_UNDO_DOOUTLINE ) : ScGlobal::GetRscString( STR_UNDO_REDOOUTLINE ); @@ -115,20 +111,20 @@ void ScUndoDoOutline::Undo() ScDocument* pDoc = pDocShell->GetDocument(); ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); - // Tabelle muss vorher umgeschaltet sein (#46952#) !!! + // sheet has to be switched on or off before this (#46952#) !!! SCTAB nVisTab = pViewShell->GetViewData()->GetTabNo(); if ( nVisTab != nTab ) pViewShell->SetTabNo( nTab ); - // inverse Funktion ausfuehren + // perform the inverse function if (bShow) pViewShell->HideOutline( bColumns, nLevel, nEntry, false, false ); else pViewShell->ShowOutline( bColumns, nLevel, nEntry, false, false ); - // Original Spalten-/Zeilenstatus + // Original column/row status if (bColumns) pUndoDoc->CopyToDocument( static_cast<SCCOL>(nStart), 0, nTab, @@ -149,7 +145,7 @@ void ScUndoDoOutline::Redo() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); - // Tabelle muss vorher umgeschaltet sein (#46952#) !!! + // sheet has to be switched on or off before this (#46952#) !!! SCTAB nVisTab = pViewShell->GetViewData()->GetTabNo(); if ( nVisTab != nTab ) @@ -169,13 +165,10 @@ void ScUndoDoOutline::Repeat(SfxRepeatTarget& /* rTarget */) sal_Bool ScUndoDoOutline::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // geht nicht + return false; // is not possible } -// -// Outline-Gruppen erzeugen oder loeschen -// - +/** Make or delete outline groups */ ScUndoMakeOutline::ScUndoMakeOutline( ScDocShell* pNewDocShell, SCCOL nStartX, SCROW nStartY, SCTAB nStartZ, SCCOL nEndX, SCROW nEndY, SCTAB nEndZ, @@ -195,7 +188,7 @@ ScUndoMakeOutline::~ScUndoMakeOutline() } rtl::OUString ScUndoMakeOutline::GetComment() const -{ // "Gruppierung" "Gruppierung aufheben" +{ // "Grouping" "Undo grouping" return bMake ? ScGlobal::GetRscString( STR_UNDO_MAKEOUTLINE ) : ScGlobal::GetRscString( STR_UNDO_REMAKEOUTLINE ); @@ -258,9 +251,6 @@ sal_Bool ScUndoMakeOutline::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// -// Outline-Ebene auswaehlen -// ScUndoOutlineLevel::ScUndoOutlineLevel( ScDocShell* pNewDocShell, SCCOLROW nNewStart, SCCOLROW nNewEnd, SCTAB nNewTab, @@ -284,7 +274,7 @@ ScUndoOutlineLevel::~ScUndoOutlineLevel() } rtl::OUString ScUndoOutlineLevel::GetComment() const -{ // "Gliederungsebene auswaehlen"; +{ // "Select outline level" return ScGlobal::GetRscString( STR_UNDO_OUTLINELEVEL ); } @@ -295,11 +285,11 @@ void ScUndoOutlineLevel::Undo() ScDocument* pDoc = pDocShell->GetDocument(); ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); - // Original Outline-Table + // Original Outline table pDoc->SetOutlineTable( nTab, pUndoTable ); - // Original Spalten-/Zeilenstatus + // Original column/row status if (bColumns) pUndoDoc->CopyToDocument( static_cast<SCCOL>(nStart), 0, nTab, @@ -326,7 +316,7 @@ void ScUndoOutlineLevel::Redo() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); - // Tabelle muss vorher umgeschaltet sein (#46952#) !!! + // sheet has to be switched on or off before this (#46952#) !!! SCTAB nVisTab = pViewShell->GetViewData()->GetTabNo(); if ( nVisTab != nTab ) @@ -348,10 +338,8 @@ sal_Bool ScUndoOutlineLevel::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// -// Outline ueber Blockmarken ein- oder ausblenden -// +/** show/hide outline over block marks */ ScUndoOutlineBlock::ScUndoOutlineBlock( ScDocShell* pNewDocShell, SCCOL nStartX, SCROW nStartY, SCTAB nStartZ, SCCOL nEndX, SCROW nEndY, SCTAB nEndZ, @@ -372,7 +360,7 @@ ScUndoOutlineBlock::~ScUndoOutlineBlock() } rtl::OUString ScUndoOutlineBlock::GetComment() const -{ // "Detail einblenden" "Detail ausblenden" +{ // "Show outline" "Hide outline" return bShow ? ScGlobal::GetRscString( STR_UNDO_DOOUTLINEBLK ) : ScGlobal::GetRscString( STR_UNDO_REDOOUTLINEBLK ); @@ -386,11 +374,11 @@ void ScUndoOutlineBlock::Undo() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); SCTAB nTab = aBlockStart.Tab(); - // Original Outline-Table + // Original Outline table pDoc->SetOutlineTable( nTab, pUndoTable ); - // Original Spalten-/Zeilenstatus + // Original column/row status SCCOLROW nStartCol = aBlockStart.Col(); SCCOLROW nEndCol = aBlockEnd.Col(); @@ -398,7 +386,7 @@ void ScUndoOutlineBlock::Undo() SCCOLROW nEndRow = aBlockEnd.Row(); if (!bShow) - { // Groesse des ausgeblendeten Blocks + { // Size of the hidden blocks size_t nLevel; pUndoTable->GetColArray()->FindTouchedLevel( nStartCol, nEndCol, nLevel ); pUndoTable->GetColArray()->ExtendBlock( nLevel, nStartCol, nEndCol ); @@ -456,9 +444,6 @@ sal_Bool ScUndoOutlineBlock::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// -// alle Outlines loeschen -// ScUndoRemoveAllOutlines::ScUndoRemoveAllOutlines( ScDocShell* pNewDocShell, SCCOL nStartX, SCROW nStartY, SCTAB nStartZ, @@ -479,7 +464,7 @@ ScUndoRemoveAllOutlines::~ScUndoRemoveAllOutlines() } rtl::OUString ScUndoRemoveAllOutlines::GetComment() const -{ // "Gliederung entfernen" +{ // "Remove outlines" return ScGlobal::GetRscString( STR_UNDO_REMOVEALLOTLNS ); } @@ -491,11 +476,11 @@ void ScUndoRemoveAllOutlines::Undo() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); SCTAB nTab = aBlockStart.Tab(); - // Original Outline-Table + // Original Outline table pDoc->SetOutlineTable( nTab, pUndoTable ); - // Original Spalten-/Zeilenstatus + // Original column/row status SCCOL nStartCol = aBlockStart.Col(); SCCOL nEndCol = aBlockEnd.Col(); @@ -524,7 +509,7 @@ void ScUndoRemoveAllOutlines::Redo() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); - // Tabelle muss vorher umgeschaltet sein (#46952#) !!! + // sheet has to be switched on or off before this (#46952#) !!! SCTAB nTab = aBlockStart.Tab(); SCTAB nVisTab = pViewShell->GetViewData()->GetTabNo(); @@ -547,9 +532,6 @@ sal_Bool ScUndoRemoveAllOutlines::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// -// Auto-Outline -// ScUndoAutoOutline::ScUndoAutoOutline( ScDocShell* pNewDocShell, SCCOL nStartX, SCROW nStartY, SCTAB nStartZ, @@ -570,7 +552,7 @@ ScUndoAutoOutline::~ScUndoAutoOutline() } rtl::OUString ScUndoAutoOutline::GetComment() const -{ // "Auto-Gliederung" +{ return ScGlobal::GetRscString( STR_UNDO_AUTOOUTLINE ); } @@ -582,11 +564,11 @@ void ScUndoAutoOutline::Undo() ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); SCTAB nTab = aBlockStart.Tab(); - // Original Outline-Table + // Original outline table pDoc->SetOutlineTable( nTab, pUndoTable ); - // Original Spalten-/Zeilenstatus + // Original column/row status if (pUndoDoc && pUndoTable) { @@ -623,7 +605,7 @@ void ScUndoAutoOutline::Redo() SCTAB nTab = aBlockStart.Tab(); if (pViewShell) { - // Tabelle muss vorher umgeschaltet sein (#46952#) !!! + // sheet has to be switched on or off before this (#46952#) !!! SCTAB nVisTab = pViewShell->GetViewData()->GetTabNo(); if ( nVisTab != nTab ) @@ -635,9 +617,9 @@ void ScUndoAutoOutline::Redo() ScOutlineDocFunc aFunc( *pDocShell ); aFunc.AutoOutline( aRange, false, false ); - // auf der View markieren - // Wenn's beim Aufruf eine Mehrfachselektion war, ist es jetzt der - // umschliessende Bereich... + // Select in View + // If it was called with a multi selection, + // then this is now the enclosing range... if (pViewShell) pViewShell->MarkRange( aRange ); @@ -656,9 +638,6 @@ sal_Bool ScUndoAutoOutline::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// -// Zwischenergebnisse -// ScUndoSubTotals::ScUndoSubTotals( ScDocShell* pNewDocShell, SCTAB nNewTab, const ScSubTotalParam& rNewParam, SCROW nNewEndY, @@ -685,7 +664,7 @@ ScUndoSubTotals::~ScUndoSubTotals() } rtl::OUString ScUndoSubTotals::GetComment() const -{ // "Teilergebnisse" +{ // "Subtotals" return ScGlobal::GetRscString( STR_UNDO_SUBTOTALS ); } @@ -706,11 +685,11 @@ void ScUndoSubTotals::Undo() } - // Original Outline-Table + // Original Outline table pDoc->SetOutlineTable( nTab, pUndoTable ); - // Original Spalten-/Zeilenstatus + // Original column/row status if (pUndoDoc && pUndoTable) { @@ -729,7 +708,7 @@ void ScUndoSubTotals::Undo() pViewShell->UpdateScrollBars(); } - // Original-Daten & Referenzen + // Original data and references ScUndoUtil::MarkSimpleBlock( pDocShell, 0, aParam.nRow1+1, nTab, MAXCOL, aParam.nRow2, nTab ); @@ -782,12 +761,9 @@ void ScUndoSubTotals::Repeat(SfxRepeatTarget& /* rTarget */) sal_Bool ScUndoSubTotals::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // geht nicht wegen Spaltennummern + return false; // is not possible due to column numbers } -// -// Sortieren -// ScUndoSort::ScUndoSort( ScDocShell* pNewDocShell, SCTAB nNewTab, const ScSortParam& rParam, @@ -856,8 +832,8 @@ void ScUndoSort::Undo() pUndoDoc->CopyToDocument( aDestRange, IDF_ALL|IDF_NOCAPTIONS, false, pDoc ); } - // Zeilenhoehen immer (wegen automatischer Anpassung) - //! auf ScBlockUndo umstellen + // Always reset row heights to ScBlockUndo + // (due to automatic adjustment) // if (bRepeatQuery) pUndoDoc->CopyToDocument( 0, nStartRow, nSortTab, MAXCOL, nEndRow, nSortTab, IDF_NONE, false, pDoc ); @@ -890,7 +866,7 @@ void ScUndoSort::Redo() pViewShell->Sort( aSortParam, false ); - // Quellbereich painten wegen Markierung + // Paint source range due to selection if ( !aSortParam.bInplace ) pDocShell->PostPaint( aSortParam.nCol1, aSortParam.nRow1, nTab, aSortParam.nCol2, aSortParam.nRow2, nTab, PAINT_GRID ); @@ -904,13 +880,9 @@ void ScUndoSort::Repeat(SfxRepeatTarget& /* rTarget */) sal_Bool ScUndoSort::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // geht nicht wegen Spaltennummern + return false; // does not work due to column numbers } -// -// Filtern -// - ScUndoQuery::ScUndoQuery( ScDocShell* pNewDocShell, SCTAB nNewTab, const ScQueryParam& rParam, ScDocument* pNewUndoDoc, ScDBCollection* pNewUndoDB, const ScRange* pOld, sal_Bool bSize, const ScRange* pAdvSrc ) : @@ -947,7 +919,7 @@ ScUndoQuery::~ScUndoQuery() } rtl::OUString ScUndoQuery::GetComment() const -{ // "Filtern"; +{ // "Filter"; return ScGlobal::GetRscString( STR_UNDO_QUERY ); } @@ -978,7 +950,7 @@ void ScUndoQuery::Undo() if ( bDoSize && bDestArea ) { - // aDestRange ist der alte Bereich + // aDestRange is the old range pDoc->FitBlock( ScRange( aQueryParam.nDestCol, aQueryParam.nDestRow, aQueryParam.nDestTab, nDestEndCol, nDestEndRow, aQueryParam.nDestTab ), @@ -996,9 +968,9 @@ void ScUndoQuery::Undo() pUndoDoc->CopyToDocument( aQueryParam.nDestCol, aQueryParam.nDestRow, aQueryParam.nDestTab, nDestEndCol, nDestEndRow, aQueryParam.nDestTab, IDF_ALL, false, pDoc ); - // Attribute werden immer mitkopiert (#49287#) + // Attributes are always copied (#49287#) - // Rest von altem Bereich + // the rest of the old range if ( bDestArea && !bDoSize ) { pDoc->DeleteAreaTab( aOldDest, IDF_ALL ); @@ -1078,12 +1050,10 @@ void ScUndoQuery::Repeat(SfxRepeatTarget& /* rTarget */) sal_Bool ScUndoQuery::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // geht nicht wegen Spaltennummern + return false; // does not work due to column numbers } -// // Show or hide AutoFilter buttons (doesn't include filter settings) -// ScUndoAutoFilter::ScUndoAutoFilter( ScDocShell* pNewDocShell, const ScRange& rRange, const ::rtl::OUString& rName, bool bSet ) : @@ -1162,9 +1132,6 @@ sal_Bool ScUndoAutoFilter::CanRepeat(SfxRepeatTarget& /* rTarget */) const return false; } -// -// Datenbankbereiche aendern (Dialog) -// ScUndoDBData::ScUndoDBData( ScDocShell* pNewDocShell, ScDBCollection* pNewUndoColl, ScDBCollection* pNewRedoColl ) : @@ -1181,7 +1148,7 @@ ScUndoDBData::~ScUndoDBData() } rtl::OUString ScUndoDBData::GetComment() const -{ // "Datenbankbereiche aendern"; +{ // "Change Data base rage"; return ScGlobal::GetRscString( STR_UNDO_DBDATA ); } @@ -1192,7 +1159,7 @@ void ScUndoDBData::Undo() ScDocument* pDoc = pDocShell->GetDocument(); sal_Bool bOldAutoCalc = pDoc->GetAutoCalc(); - pDoc->SetAutoCalc( false ); // unnoetige Berechnungen vermeiden + pDoc->SetAutoCalc( false ); // Avoid unnecessary calculations pDoc->CompileDBFormula( sal_True ); // CreateFormulaString pDoc->SetDBCollection( new ScDBCollection(*pUndoColl), sal_True ); pDoc->CompileDBFormula( false ); // CompileFormulaString @@ -1210,7 +1177,7 @@ void ScUndoDBData::Redo() ScDocument* pDoc = pDocShell->GetDocument(); sal_Bool bOldAutoCalc = pDoc->GetAutoCalc(); - pDoc->SetAutoCalc( false ); // unnoetige Berechnungen vermeiden + pDoc->SetAutoCalc( false ); // Avoid unnecessary calculations pDoc->CompileDBFormula( sal_True ); // CreateFormulaString pDoc->SetDBCollection( new ScDBCollection(*pRedoColl), sal_True ); pDoc->CompileDBFormula( false ); // CompileFormulaString @@ -1227,12 +1194,9 @@ void ScUndoDBData::Repeat(SfxRepeatTarget& /* rTarget */) sal_Bool ScUndoDBData::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // geht nicht + return false; // is not possible } -// -// Import -// ScUndoImportData::ScUndoImportData( ScDocShell* pNewDocShell, SCTAB nNewTab, const ScImportParam& rParam, SCCOL nNewEndX, SCROW nNewEndY, @@ -1263,7 +1227,7 @@ ScUndoImportData::~ScUndoImportData() } rtl::OUString ScUndoImportData::GetComment() const -{ // "Importieren"; +{ return ScGlobal::GetRscString( STR_UNDO_IMPORTDATA ); } @@ -1307,10 +1271,10 @@ void ScUndoImportData::Undo() } } sal_Bool bMoveCells = pUndoDBData && pRedoDBData && - pRedoDBData->IsDoSize(); // in alt und neu gleich + pRedoDBData->IsDoSize(); // the same in old and new if (bMoveCells) { - // Undo: erst die neuen Daten loeschen, dann FitBlock rueckwaerts + // Undo: first delete the new data, then FitBlock backwards ScRange aOld, aNew; pUndoDBData->GetArea( aOld ); @@ -1319,9 +1283,9 @@ void ScUndoImportData::Undo() pDoc->DeleteAreaTab( aNew.aStart.Col(), aNew.aStart.Row(), aNew.aEnd.Col(), aNew.aEnd.Row(), nTab, IDF_ALL & ~IDF_NOTE ); - aOld.aEnd.SetCol( aOld.aEnd.Col() + nFormulaCols ); // FitBlock auch fuer Formeln + aOld.aEnd.SetCol( aOld.aEnd.Col() + nFormulaCols ); // FitBlock also for formulas aNew.aEnd.SetCol( aNew.aEnd.Col() + nFormulaCols ); - pDoc->FitBlock( aNew, aOld, false ); // rueckwaerts + pDoc->FitBlock( aNew, aOld, false ); // backwards } else pDoc->DeleteAreaTab( aImportParam.nCol1,aImportParam.nRow1, @@ -1377,23 +1341,23 @@ void ScUndoImportData::Redo() nCol1, nRow1, nCol2, nRow2 ); } sal_Bool bMoveCells = pUndoDBData && pRedoDBData && - pRedoDBData->IsDoSize(); // in alt und neu gleich + pRedoDBData->IsDoSize(); // // the same in old and new if (bMoveCells) { - // Redo: FitBlock, dann Daten loeschen (noetig fuer CopyToDocument) + // Redo: FitBlock, then delete data (needed for CopyToDocument) ScRange aOld, aNew; pUndoDBData->GetArea( aOld ); pRedoDBData->GetArea( aNew ); - aOld.aEnd.SetCol( aOld.aEnd.Col() + nFormulaCols ); // FitBlock auch fuer Formeln + aOld.aEnd.SetCol( aOld.aEnd.Col() + nFormulaCols ); // FitBlock also for formulas aNew.aEnd.SetCol( aNew.aEnd.Col() + nFormulaCols ); pDoc->FitBlock( aOld, aNew ); pDoc->DeleteAreaTab( aNew.aStart.Col(), aNew.aStart.Row(), aNew.aEnd.Col(), aNew.aEnd.Row(), nTab, IDF_ALL & ~IDF_NOTE ); - pRedoDoc->CopyToDocument( aNew, IDF_ALL & ~IDF_NOTE, false, pDoc ); // incl. Formeln + pRedoDoc->CopyToDocument( aNew, IDF_ALL & ~IDF_NOTE, false, pDoc ); // including formulas } else { @@ -1445,17 +1409,14 @@ void ScUndoImportData::Repeat(SfxRepeatTarget& rTarget) sal_Bool ScUndoImportData::CanRepeat(SfxRepeatTarget& rTarget) const { - // Repeat nur fuer Import per DB-Bereich, dann ist pUndoDBData gesetzt + // Repeat only for import for each Data base range, then pUndoDBData is set if (pUndoDBData) return (rTarget.ISA(ScTabViewTarget)); else - return false; // Adressbuch + return false; // Address book } -// -// Operationen wiederholen -// ScUndoRepeatDB::ScUndoRepeatDB( ScDocShell* pNewDocShell, SCTAB nNewTab, SCCOL nStartX, SCROW nStartY, SCCOL nEndX, SCROW nEndY, @@ -1491,7 +1452,7 @@ ScUndoRepeatDB::~ScUndoRepeatDB() } rtl::OUString ScUndoRepeatDB::GetComment() const -{ // "Wiederholen"; //! bessere Beschreibung! +{ return ScGlobal::GetRscString( STR_UNDO_REPEATDB ); } @@ -1511,7 +1472,7 @@ void ScUndoRepeatDB::Undo() { SCCOL nFormulaCols = 0; SCCOL nCol = aOldQuery.aEnd.Col() + 1; - SCROW nRow = aOldQuery.aStart.Row() + 1; //! Header testen + SCROW nRow = aOldQuery.aStart.Row() + 1; //! Test Header while ( nCol <= MAXCOL && pDoc->GetCellType(ScAddress( nCol, nRow, nTab )) == CELLTYPE_FORMULA ) ++nCol, ++nFormulaCols; @@ -1528,7 +1489,7 @@ void ScUndoRepeatDB::Undo() } } - //! Daten von Filter in anderen Bereich fehlen noch !!!!!!!!!!!!!!!!! + //! Data from Filter in other range are still missing !!!!!!!!!!!!!!!!! if (nNewEndRow > aBlockEnd.Row()) { @@ -1539,11 +1500,11 @@ void ScUndoRepeatDB::Undo() pDoc->InsertRow( 0,nTab, MAXCOL,nTab, nNewEndRow+1, static_cast<SCSIZE>(nNewEndRow-aBlockEnd.Row()) ); } - // Original Outline-Table + // Original Outline table pDoc->SetOutlineTable( nTab, pUndoTable ); - // Original Spalten-/Zeilenstatus + // Original column/row status if (pUndoDoc && pUndoTable) { @@ -1562,7 +1523,7 @@ void ScUndoRepeatDB::Undo() pViewShell->UpdateScrollBars(); } - // Original-Daten & Referenzen + // Original data and references ScUndoUtil::MarkSimpleBlock( pDocShell, 0, aBlockStart.Row(), nTab, MAXCOL, aBlockEnd.Row(), nTab ); @@ -1626,9 +1587,6 @@ sal_Bool ScUndoRepeatDB::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// -// data pilot -// ScUndoDataPilot::ScUndoDataPilot( ScDocShell* pNewDocShell, ScDocument* pOldDoc, ScDocument* pNewDoc, @@ -1791,10 +1749,6 @@ sal_Bool ScUndoDataPilot::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -// -// Konsolidieren -// - ScUndoConsolidate::ScUndoConsolidate( ScDocShell* pNewDocShell, const ScArea& rArea, const ScConsolidateParam& rPar, ScDocument* pNewUndoDoc, sal_Bool bReference, SCROW nInsCount, ScOutlineTable* pTab, @@ -1835,22 +1789,19 @@ void ScUndoConsolidate::Undo() if (bInsRef) { - // Zeilen loeschen pDoc->DeleteRow( 0,nTab, MAXCOL,nTab, aDestArea.nRowStart, nInsertCount ); - - // Outlines pDoc->SetOutlineTable( nTab, pUndoTab ); - // Zeilenstatus + // Row status pUndoDoc->CopyToDocument( 0,0,nTab, MAXCOL,MAXROW,nTab, IDF_NONE, false, pDoc ); - // Daten & Referenzen + // Data and references pDoc->DeleteAreaTab( 0,aDestArea.nRowStart, MAXCOL,aDestArea.nRowEnd, nTab, IDF_ALL ); pUndoDoc->UndoToDocument( 0, aDestArea.nRowStart, nTab, MAXCOL, aDestArea.nRowEnd, nTab, IDF_ALL, false, pDoc ); - // Original-Bereich + // Original range if (pUndoData) { pDoc->DeleteAreaTab(aOldRange, IDF_ALL); @@ -1868,7 +1819,7 @@ void ScUndoConsolidate::Undo() aDestArea.nColEnd, aDestArea.nRowEnd, nTab, IDF_ALL, false, pDoc ); - // Original-Bereich + // Original range if (pUndoData) { pDoc->DeleteAreaTab(aOldRange, IDF_ALL); @@ -1888,7 +1839,7 @@ void ScUndoConsolidate::Undo() nEndX, nEndY, nTab, PAINT_GRID ); } - // DB-Bereich wieder anpassen + // Adjust Database range again if (pUndoData) { ScDBCollection* pColl = pDoc->GetDBCollection(); @@ -1938,9 +1889,7 @@ sal_Bool ScUndoConsolidate::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -// -// Quell-Daten von Chart aendern -// +// Change source data of Chart void ScUndoChartData::Init() { @@ -2111,7 +2060,7 @@ void ScUndoDataForm::DoChange( const sal_Bool bUndo ) ScRefUndoData* pWorkRefData = bUndo ? pRefUndoData : pRefRedoData; - // fuer Undo immer alle oder keine Inhalte sichern + // Always back-up all or none of the content for Undo sal_uInt16 nUndoFlags = IDF_NONE; if (nFlags & IDF_CONTENTS) nUndoFlags |= IDF_CONTENTS; @@ -2186,12 +2135,12 @@ void ScUndoDataForm::DoChange( const sal_Bool bUndo ) } else { - if ( aBlockRange.aStart.Row() == 0 && aBlockRange.aEnd.Row() == MAXROW ) // ganze Spalte + if ( aBlockRange.aStart.Row() == 0 && aBlockRange.aEnd.Row() == MAXROW ) // whole column { nPaint |= PAINT_TOP; aDrawRange.aEnd.SetCol(MAXCOL); } - if ( aBlockRange.aStart.Col() == 0 && aBlockRange.aEnd.Col() == MAXCOL ) // ganze Zeile + if ( aBlockRange.aStart.Col() == 0 && aBlockRange.aEnd.Col() == MAXCOL ) // whole row { nPaint |= PAINT_LEFT; aDrawRange.aEnd.SetRow(MAXROW); diff --git a/sc/source/ui/undo/undodraw.cxx b/sc/source/ui/undo/undodraw.cxx index 3e2f2512c4ef..02b5138b94e3 100644 --- a/sc/source/ui/undo/undodraw.cxx +++ b/sc/source/ui/undo/undodraw.cxx @@ -52,7 +52,7 @@ ScUndoDraw::~ScUndoDraw() void ScUndoDraw::ForgetDrawUndo() { - pDrawUndo = NULL; // nicht loeschen (Draw-Undo muss dann von aussen gemerkt werden) + pDrawUndo = NULL; // do not delete (DrawUndo has to be set from outside) } rtl::OUString ScUndoDraw::GetComment() const diff --git a/sc/source/ui/undo/undoolk.cxx b/sc/source/ui/undo/undoolk.cxx index d9dd672af62f..91109c789fab 100644 --- a/sc/source/ui/undo/undoolk.cxx +++ b/sc/source/ui/undo/undoolk.cxx @@ -31,7 +31,7 @@ SdrUndoAction* GetSdrUndoAction( ScDocument* pDoc ) { ScDrawLayer* pLayer = pDoc->GetDrawLayer(); if (pLayer) - return pLayer->GetCalcUndo(); // muss vorhanden sein + return pLayer->GetCalcUndo(); // must exist else return NULL; } diff --git a/sc/source/ui/undo/undotab.cxx b/sc/source/ui/undo/undotab.cxx index ac86110ec067..d48366ab8614 100644 --- a/sc/source/ui/undo/undotab.cxx +++ b/sc/source/ui/undo/undotab.cxx @@ -59,7 +59,7 @@ #include <vector> -extern sal_Bool bDrawIsInUndo; //! irgendwo als Member !!! +extern sal_Bool bDrawIsInUndo; //! somewhere as Member !!! using namespace com::sun::star; using ::com::sun::star::uno::Sequence; @@ -87,11 +87,6 @@ TYPEINIT1(ScUndoLayoutRTL, SfxUndoAction); TYPEINIT1(ScUndoTabColor, SfxUndoAction); -// ----------------------------------------------------------------------- -// -// Tabelle einfuegen -// - ScUndoInsertTab::ScUndoInsertTab( ScDocShell* pNewDocShell, SCTAB nTabNum, sal_Bool bApp, @@ -186,10 +181,6 @@ sal_Bool ScUndoInsertTab::CanRepeat(SfxRepeatTarget& rTarget) const return (rTarget.ISA(ScTabViewTarget)); } -// ----------------------------------------------------------------------- -// -// Tabellen einfuegen -// ScUndoInsertTables::ScUndoInsertTables( ScDocShell* pNewDocShell, SCTAB nTabNum, @@ -288,11 +279,6 @@ sal_Bool ScUndoInsertTables::CanRepeat(SfxRepeatTarget& rTarget) const } -//---------------------------------------------------------------------------------- -// -// Tabelle loeschen -// - ScUndoDeleteTab::ScUndoDeleteTab( ScDocShell* pNewDocShell, const vector<SCTAB> &aTab, //SCTAB nNewTab, ScDocument* pUndoDocument, ScRefUndoData* pRefData ) : ScMoveUndo( pNewDocShell, pUndoDocument, pRefData, SC_UNDO_REFLAST ) @@ -393,10 +379,10 @@ void ScUndoDeleteTab::Undo() } if (bLink) { - pDocShell->UpdateLinks(); // Link-Manager updaten + pDocShell->UpdateLinks(); // Update Link manager updaten } - EndUndo(); // Draw-Undo muss vor dem Broadcast kommen! + EndUndo(); // Draw-Undo has to be called before Broadcast! ScChangeTrack* pChangeTrack = pDocShell->GetDocument()->GetChangeTrack(); if ( pChangeTrack ) @@ -411,9 +397,9 @@ void ScUndoDeleteTab::Undo() pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) ); pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); - pDocShell->PostPaint(0,0,0, MAXCOL,MAXROW,MAXTAB, PAINT_ALL ); // incl. Extras + pDocShell->PostPaint(0,0,0, MAXCOL,MAXROW,MAXTAB, PAINT_ALL ); // incl. extras - // nicht ShowTable wegen SetTabNo(..., sal_True): + // not ShowTable due to SetTabNo(..., sal_True): ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) pViewShell->SetTabNo( lcl_GetVisibleTabBefore( *pDoc, theTabs[0] ), true ); @@ -453,11 +439,6 @@ sal_Bool ScUndoDeleteTab::CanRepeat(SfxRepeatTarget& rTarget) const } -//--------------------------------------------------------------------------------- -// -// Tabelle umbenennen -// - ScUndoRenameTab::ScUndoRenameTab( ScDocShell* pNewDocShell, SCTAB nT, const String& rOldName, @@ -489,7 +470,7 @@ void ScUndoRenameTab::DoChange( SCTAB nTabP, const String& rName ) const pDocShell->PostPaintExtras(); pDocShell->PostDataChanged(); - // Der Tabellenname koennte in einer Formel vorkommen... + // The sheet name could be found in a formula ... ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) pViewShell->UpdateInputHandler(); @@ -507,7 +488,7 @@ void ScUndoRenameTab::Redo() void ScUndoRenameTab::Repeat(SfxRepeatTarget& /* rTarget */) { - // Repeat macht keinen Sinn + // Repeat makes no sense } sal_Bool ScUndoRenameTab::CanRepeat(SfxRepeatTarget& /* rTarget */) const @@ -516,11 +497,6 @@ sal_Bool ScUndoRenameTab::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -//---------------------------------------------------------------------------------- -// -// Tabelle verschieben -// - ScUndoMoveTab::ScUndoMoveTab( ScDocShell* pNewDocShell, vector<SCTAB>* pOldTabs, vector<SCTAB>* pNewTabs, vector<OUString>* pOldNames, vector<OUString>* pNewNames) : @@ -560,7 +536,7 @@ void ScUndoMoveTab::DoChange( sal_Bool bUndo ) const { SCTAB nDestTab = (*mpNewTabs)[i-1]; SCTAB nOldTab = (*mpOldTabs)[i-1]; - if (nDestTab > MAXTAB) // angehaengt ? + if (nDestTab > MAXTAB) // appended ? nDestTab = pDoc->GetTableCount() - 1; pDoc->MoveTab( nDestTab, nOldTab, pProgress ); @@ -584,7 +560,7 @@ void ScUndoMoveTab::DoChange( sal_Bool bUndo ) const SCTAB nDestTab = (*mpNewTabs)[i]; SCTAB nNewTab = nDestTab; SCTAB nOldTab = (*mpOldTabs)[i]; - if (nDestTab > MAXTAB) // angehaengt ? + if (nDestTab > MAXTAB) // appended ? nDestTab = pDoc->GetTableCount() - 1; pDoc->MoveTab( nOldTab, nNewTab, pProgress ); @@ -627,11 +603,6 @@ sal_Bool ScUndoMoveTab::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -//---------------------------------------------------------------------------------- -// -// Copy table -// - ScUndoCopyTab::ScUndoCopyTab( ScDocShell* pNewDocShell, vector<SCTAB>* pOldTabs, vector<SCTAB>* pNewTabs, @@ -717,7 +688,7 @@ void ScUndoCopyTab::Redo() nDestTab = (*mpNewTabs)[i]; SCTAB nNewTab = nDestTab; SCTAB nOldTab = (*mpOldTabs)[i]; - if (nDestTab > MAXTAB) // angehaengt ? + if (nDestTab > MAXTAB) // appended ? nDestTab = pDoc->GetTableCount() - 1; bDrawIsInUndo = sal_True; @@ -764,7 +735,7 @@ void ScUndoCopyTab::Redo() void ScUndoCopyTab::Repeat(SfxRepeatTarget& /* rTarget */) { - // kein Repeat ! ? ! + // no Repeat ! ? ! } sal_Bool ScUndoCopyTab::CanRepeat(SfxRepeatTarget& /* rTarget */) const @@ -772,10 +743,6 @@ sal_Bool ScUndoCopyTab::CanRepeat(SfxRepeatTarget& /* rTarget */) const return false; } -//--------------------------------------------------------------------------------- -// -// Tab Bg Color -// ScUndoTabColor::ScUndoTabColor( ScDocShell* pNewDocShell, SCTAB nT, const Color& aOTabBgColor, const Color& aNTabBgColor) : @@ -845,10 +812,6 @@ sal_Bool ScUndoTabColor::CanRepeat(SfxRepeatTarget& /* rTarget */) const return false; } -// ----------------------------------------------------------------------- -// -// Szenario anlegen -// ScUndoMakeScenario::ScUndoMakeScenario( ScDocShell* pNewDocShell, SCTAB nSrc, SCTAB nDest, @@ -938,11 +901,6 @@ sal_Bool ScUndoMakeScenario::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Tabelle einfuegen -// - ScUndoImportTab::ScUndoImportTab( ScDocShell* pShell, SCTAB nNewTab, SCTAB nNewCount, sal_Bool bNewLink ) : ScSimpleUndo( pShell ), @@ -990,7 +948,7 @@ void ScUndoImportTab::DoChange() const void ScUndoImportTab::Undo() { - //! eingefuegte Bereichsnamen etc. + //! Inserted range names, and so on. SCTAB i; ScDocument* pDoc = pDocShell->GetDocument(); @@ -1043,7 +1001,7 @@ void ScUndoImportTab::Redo() { if (!pRedoDoc) { - OSL_FAIL("wo ist mein Redo-Document?"); + OSL_FAIL("Where is my Redo Document?"); return; } @@ -1099,11 +1057,6 @@ sal_Bool ScUndoImportTab::CanRepeat(SfxRepeatTarget& rTarget) const } -// ----------------------------------------------------------------------- -// -// Tabellen-Verknuepfung aufheben -// - ScUndoRemoveLink::ScUndoRemoveLink( ScDocShell* pShell, const String& rDoc ) : ScSimpleUndo( pShell ), aDocName( rDoc ), @@ -1131,7 +1084,7 @@ ScUndoRemoveLink::ScUndoRemoveLink( ScDocShell* pShell, const String& rDoc ) : { OSL_ENSURE(rtl::OUString(aFltName) == pDoc->GetLinkFlt(i) && rtl::OUString(aOptions) == pDoc->GetLinkOpt(i), - "verschiedene Filter fuer ein Dokument?"); + "diffrent Filter for a Document?"); } pTabs[nCount] = i; pModes[nCount] = nMode; @@ -1177,7 +1130,7 @@ void ScUndoRemoveLink::Redo() void ScUndoRemoveLink::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // makes no sense } sal_Bool ScUndoRemoveLink::CanRepeat(SfxRepeatTarget& /* rTarget */) const @@ -1186,11 +1139,6 @@ sal_Bool ScUndoRemoveLink::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -// ----------------------------------------------------------------------- -// -// Tabellen ein-/ausblenden -// - ScUndoShowHideTab::ScUndoShowHideTab( ScDocShell* pShell, SCTAB nNewTab, sal_Bool bNewShow ) : ScSimpleUndo( pShell ), nTab( nNewTab ), @@ -1281,7 +1229,7 @@ void ScUndoDocProtect::DoProtect(bool bProtect) if (pViewShell) { pViewShell->UpdateLayerLocks(); - pViewShell->UpdateInputHandler(sal_True); // damit sofort wieder eingegeben werden kann + pViewShell->UpdateInputHandler(sal_True); // so that input can be immediately entered again } pDocShell->PostPaintGridAll(); @@ -1303,12 +1251,12 @@ void ScUndoDocProtect::Redo() void ScUndoDocProtect::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // makes no sense } sal_Bool ScUndoDocProtect::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // gippsnich + return false; // makes no sense } rtl::OUString ScUndoDocProtect::GetComment() const @@ -1355,7 +1303,7 @@ void ScUndoTabProtect::DoProtect(bool bProtect) if (pViewShell) { pViewShell->UpdateLayerLocks(); - pViewShell->UpdateInputHandler(sal_True); // damit sofort wieder eingegeben werden kann + pViewShell->UpdateInputHandler(sal_True); // so that input can be immediately entered again } pDocShell->PostPaintGridAll(); @@ -1377,12 +1325,12 @@ void ScUndoTabProtect::Redo() void ScUndoTabProtect::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // makes no sense } sal_Bool ScUndoTabProtect::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // gippsnich + return false; // makes no sense } rtl::OUString ScUndoTabProtect::GetComment() const @@ -1391,10 +1339,6 @@ rtl::OUString ScUndoTabProtect::GetComment() const return ScGlobal::GetRscString( nId ); } -// ----------------------------------------------------------------------- -// -// Druck-/Wiederholungsbereiche aendern -// ScUndoPrintRange::ScUndoPrintRange( ScDocShell* pShell, SCTAB nNewTab, ScPrintRangeSaver* pOld, ScPrintRangeSaver* pNew ) : @@ -1444,12 +1388,12 @@ void ScUndoPrintRange::Redo() void ScUndoPrintRange::Repeat(SfxRepeatTarget& /* rTarget */) { - // gippsnich + // makes no sense } sal_Bool ScUndoPrintRange::CanRepeat(SfxRepeatTarget& /* rTarget */) const { - return false; // gippsnich + return false; // makes no sense } rtl::OUString ScUndoPrintRange::GetComment() const @@ -1460,11 +1404,6 @@ rtl::OUString ScUndoPrintRange::GetComment() const //------------------------------------------------------------------------ -//--------------------------------------------------------------------------------- -// -// Szenario-Flags -// - ScUndoScenarioFlags::ScUndoScenarioFlags( ScDocShell* pNewDocShell, SCTAB nT, const String& rON, const String& rNN, const String& rOC, const String& rNC, const Color& rOCol, const Color& rNCol, sal_uInt16 nOF, sal_uInt16 nNF ) : @@ -1498,7 +1437,7 @@ void ScUndoScenarioFlags::Undo() pDoc->SetScenarioData( nTab, aOldComment, aOldColor, nOldFlags ); pDocShell->PostPaintGridAll(); - // Der Tabellenname koennte in einer Formel vorkommen... + // The sheet name could be found in a formula ... ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) pViewShell->UpdateInputHandler(); @@ -1515,7 +1454,7 @@ void ScUndoScenarioFlags::Redo() pDoc->SetScenarioData( nTab, aNewComment, aNewColor, nNewFlags ); pDocShell->PostPaintGridAll(); - // Der Tabellenname koennte in einer Formel vorkommen... + // The sheet name could be found in a formula ... ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell(); if (pViewShell) pViewShell->UpdateInputHandler(); @@ -1526,7 +1465,7 @@ void ScUndoScenarioFlags::Redo() void ScUndoScenarioFlags::Repeat(SfxRepeatTarget& /* rTarget */) { - // Repeat macht keinen Sinn + // Repeat makes no sense } sal_Bool ScUndoScenarioFlags::CanRepeat(SfxRepeatTarget& /* rTarget */) const @@ -1535,12 +1474,7 @@ sal_Bool ScUndoScenarioFlags::CanRepeat(SfxRepeatTarget& /* rTarget */) const } -//--------------------------------------------------------------------------------- -// -// rename object // (move to different file?) -// - ScUndoRenameObject::ScUndoRenameObject( ScDocShell* pNewDocShell, const String& rPN, const String& rON, const String& rNN ) : ScSimpleUndo( pNewDocShell ), @@ -1617,10 +1551,6 @@ sal_Bool ScUndoRenameObject::CanRepeat(SfxRepeatTarget& /* rTarget */) const return false; } -// ----------------------------------------------------------------------- -// -// Switch sheet between left-to-right and right-to-left -// ScUndoLayoutRTL::ScUndoLayoutRTL( ScDocShell* pShell, SCTAB nNewTab, sal_Bool bNewRTL ) : ScSimpleUndo( pShell ), |