LibreOffice Module sc (master)  1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
ScUndoTabProtect Class Reference

This class implements undo & redo of both protect and unprotect of sheet. More...

#include <undotab.hxx>

Inheritance diagram for ScUndoTabProtect:
[legend]
Collaboration diagram for ScUndoTabProtect:
[legend]

Public Member Functions

 ScUndoTabProtect (ScDocShell *pShell, SCTAB nTab, std::unique_ptr< ScTableProtection > &&pProtectSettings)
 
virtual ~ScUndoTabProtect () override
 
virtual void Undo () override
 
virtual void Redo () override
 
virtual void Repeat (SfxRepeatTarget &rTarget) override
 
virtual bool CanRepeat (SfxRepeatTarget &rTarget) const override
 
virtual OUString GetComment () const override
 
- Public Member Functions inherited from ScSimpleUndo
 ScSimpleUndo (ScDocShell *pDocSh)
 
virtual bool Merge (SfxUndoAction *pNextAction) override
 
ViewShellId GetViewShellId () const override
 See SfxUndoAction::GetViewShellId(). More...
 
- Public Member Functions inherited from SfxUndoAction
 SfxUndoAction ()
 
virtual ~SfxUndoAction () COVERITY_NOEXCEPT_FALSE
 
virtual void UndoWithContext (SfxUndoContext &i_context)
 
virtual void RedoWithContext (SfxUndoContext &i_context)
 
virtual OUString GetRepeatComment (SfxRepeatTarget &) const
 
const DateTimeGetDateTime () const
 
virtual void dumpAsXml (xmlTextWriterPtr pWriter) const
 

Private Member Functions

void DoProtect (bool bProtect)
 

Private Attributes

SCTAB mnTab
 
::std::unique_ptr< ScTableProtectionmpProtectSettings
 

Additional Inherited Members

- Public Types inherited from ScSimpleUndo
typedef std::map< SCTAB, std::unique_ptr< sc::ColumnSpanSet > > DataSpansType
 
- Protected Member Functions inherited from ScSimpleUndo
bool IsPaintLocked () const
 
bool SetViewMarkData (const ScMarkData &rMarkData)
 
void BeginUndo ()
 
void EndUndo ()
 
void BeginRedo ()
 
void EndRedo ()
 
void BroadcastChanges (const ScRange &rRange)
 
void BroadcastChanges (const DataSpansType &rSpans)
 Broadcast changes on specified spans. More...
 
- Static Protected Member Functions inherited from ScSimpleUndo
static void ShowTable (SCTAB nTab)
 
static void ShowTable (const ScRange &rRange)
 
- Protected Attributes inherited from ScSimpleUndo
ScDocShellpDocShell
 
std::unique_ptr< SfxUndoActionpDetectiveUndo
 
ViewShellId mnViewShellId
 

Detailed Description

This class implements undo & redo of both protect and unprotect of sheet.

Definition at line 353 of file undotab.hxx.

Constructor & Destructor Documentation

ScUndoTabProtect::ScUndoTabProtect ( ScDocShell pShell,
SCTAB  nTab,
std::unique_ptr< ScTableProtection > &&  pProtectSettings 
)

Definition at line 1219 of file undotab.cxx.

ScUndoTabProtect::~ScUndoTabProtect ( )
overridevirtual

Definition at line 1226 of file undotab.cxx.

Member Function Documentation

bool ScUndoTabProtect::CanRepeat ( SfxRepeatTarget rTarget) const
overridevirtual

Reimplemented from SfxUndoAction.

Definition at line 1278 of file undotab.cxx.

void ScUndoTabProtect::DoProtect ( bool  bProtect)
private
OUString ScUndoTabProtect::GetComment ( ) const
overridevirtual

Reimplemented from SfxUndoAction.

Definition at line 1283 of file undotab.cxx.

References mpProtectSettings, and ScResId().

void ScUndoTabProtect::Redo ( )
overridevirtual

Reimplemented from SfxUndoAction.

Definition at line 1266 of file undotab.cxx.

References ScSimpleUndo::BeginRedo(), DoProtect(), ScSimpleUndo::EndRedo(), and mpProtectSettings.

void ScUndoTabProtect::Repeat ( SfxRepeatTarget rTarget)
overridevirtual

Reimplemented from SfxUndoAction.

Definition at line 1273 of file undotab.cxx.

void ScUndoTabProtect::Undo ( )
overridevirtual

Reimplemented from SfxUndoAction.

Definition at line 1259 of file undotab.cxx.

References ScSimpleUndo::BeginUndo(), DoProtect(), ScSimpleUndo::EndUndo(), and mpProtectSettings.

Member Data Documentation

SCTAB ScUndoTabProtect::mnTab
private

Definition at line 368 of file undotab.hxx.

Referenced by DoProtect().

::std::unique_ptr<ScTableProtection> ScUndoTabProtect::mpProtectSettings
private

Definition at line 369 of file undotab.hxx.

Referenced by DoProtect(), GetComment(), Redo(), and Undo().


The documentation for this class was generated from the following files: