LibreOffice Module sfx2 (master) 1
|
The class SfxShell is the base class for all classes, which provide the functionality of the form <Slot>s. More...
#include <shell.hxx>
Public Member Functions | |
virtual | ~SfxShell () override |
The connection to a possible corresponding SbxObject is dissolved. More... | |
virtual SfxInterface * | GetInterface () const |
With this virtual method, which is automatically overridden by each subclass with its own slots through the macro <SFX_DECL_INTERFACE>, one can access each of the <SfxInterface> instance belonging to the subclass. More... | |
void | SetName (const OUString &rName) |
Sets the name of the Shell object. More... | |
const OUString & | GetName () const |
Returns the name of the Shell object. More... | |
SfxViewShell * | GetViewShell () const |
Returns the SfxViewShell in which they are located in the subshells. More... | |
const SfxPoolItem * | GetSlotState (sal_uInt16 nSlotId, const SfxInterface *pIF=nullptr, SfxItemSet *pStateSet=nullptr) |
This method returns the status of the slot with the specified slot ID on the specified interface. More... | |
const SfxPoolItem * | ExecuteSlot (SfxRequest &rReq, const SfxInterface *pIF=nullptr) |
This method allows you to forward a <SfxRequest> to the specified base <SfxShell>. More... | |
void | ExecuteSlot (SfxRequest &rReq, bool bAsync) |
Asynchronous ExecuteSlot for the RELOAD. More... | |
SfxItemPool & | GetPool () const |
Each Subclass of SfxShell must reference a pool. More... | |
void | SetPool (SfxItemPool *pNewPool) |
With this method, the subclasses register their special <SfxItemPool> in the SfxShell. More... | |
virtual SfxUndoManager * | GetUndoManager () |
Each Subclass of SfxShell can have a <SfxUndoManager>. More... | |
void | SetUndoManager (SfxUndoManager *pNewUndoMgr) |
Sets a <SfxUndoManager> for this <SfxShell> Instance. More... | |
SfxRepeatTarget * | GetRepeatTarget () const |
Returns a pointer to the <SfxRepeatTarget> instance that is used in SID_REPEAT as repeat target when it is addressed from the <SfxUndoManager> supplied by this SfxShell. More... | |
void | SetRepeatTarget (SfxRepeatTarget *pTarget) |
Sets the <SfxRepeatTarget> instance that is used in SID_REPEAT as RepeatTarget, when the current supplied by this <SfxUndoManager> is addressed. More... | |
virtual void | Invalidate (sal_uInt16 nId=0) |
With this method can the slots of the subclasses be invalidated through the slot Id or alternatively through the Which ID. More... | |
virtual bool | IsDesignMode () const |
bool | IsActive () const |
virtual void | Activate (bool bMDI) |
Virtual method that is called when enabling the SfxShell instance, in order to give the Subclasses the opportunity to respond to the to the enabling. More... | |
virtual void | Deactivate (bool bMDI) |
Virtual method that is called when disabling the SfxShell instance, to give the Subclasses the opportunity to respond to the disabling. More... | |
SfxDispatcher * | GetDispatcher () const |
This method returns a pointer to the <SfxDispatcher>, when the SfxShell is currently <UI-active> or a NULL-pointer if it is not UI-active. More... | |
SfxViewFrame * | GetFrame () const |
This method returns a pointer to the <SfxViewFrame> to which this SfxShell instance is associated or in which they currently is <UI-active>. More... | |
virtual bool | HasUIFeature (SfxShellFeature nFeature) const |
void | UIFeatureChanged () |
const SfxPoolItem * | GetItem (sal_uInt16 nSlotId) const |
With this method any objects of <SfxPoolItemu> subclasses can be accessed. More... | |
template<class T > | |
const T * | GetItem (TypedWhichId< T > nWhich) const |
void | PutItem (const SfxPoolItem &rItem) |
With this method, any objects of subclasses of <SfxPoolItem> can be made available. More... | |
void | SetVerbs (const css::uno::Sequence< css::embed::VerbDescriptor > &aVerbs) |
const css::uno::Sequence< css::embed::VerbDescriptor > & | GetVerbs () const |
void | VerbExec (SfxRequest &) |
SAL_DLLPRIVATE const SfxSlot * | GetVerbSlot_Impl (sal_uInt16 nId) const |
virtual SfxObjectShell * | GetObjectShell () |
void | SetDisableFlags (SfxDisableFlags nFlags) |
SfxDisableFlags | GetDisableFlags () const |
virtual std::optional< SfxItemSet > | CreateItemSet (sal_uInt16 nId) |
virtual void | ApplyItemSet (sal_uInt16 nId, const SfxItemSet &rSet) |
void | SetContextName (const OUString &rsContextName) |
Set the name of the sidebar context that is broadcast on calls to Activation(). More... | |
void | BroadcastContextForActivation (const bool bIsActivated) |
Broadcast a sidebar context change. More... | |
bool | SetContextBroadcasterEnabled (const bool bIsEnabled) |
Enabled or disable the context broadcaster. More... | |
SAL_DLLPRIVATE bool | CanExecuteSlot_Impl (const SfxSlot &rSlot) |
This method determines by calling the status function whether 'rSlot' can be executed currently. More... | |
virtual bool | IsConditionalFastCall (const SfxRequest &rReq) |
This method determines whether we need to execute without checking the disabled state of the slot. More... | |
SAL_DLLPRIVATE void | DoActivate_Impl (SfxViewFrame *pFrame, bool bMDI) |
This method controls the activation of SfxShell instance. More... | |
SAL_DLLPRIVATE void | DoDeactivate_Impl (SfxViewFrame const *pFrame, bool bMDI) |
This method controls the deactivation of the SfxShell instance. More... | |
Public Member Functions inherited from SfxBroadcaster | |
SfxBroadcaster () | |
SfxBroadcaster (const SfxBroadcaster &rBC) | |
virtual | ~SfxBroadcaster () COVERITY_NOEXCEPT_FALSE |
void | Broadcast (const SfxHint &rHint) |
bool | HasListeners () const |
size_t | GetListenerCount () const |
void | ForAllListeners (std::function< bool(SfxListener *)> f) const |
Static Public Member Functions | |
static SfxInterface * | GetStaticInterface () |
static void | EmptyExecStub (SfxShell *pShell, SfxRequest &) |
static void | EmptyStateStub (SfxShell *pShell, SfxItemSet &) |
static void | VerbState (SfxItemSet &) |
Protected Member Functions | |
SfxShell () | |
The constructor of the SfxShell class initializes only simple types, the corresponding SbxObject is only created on-demand. More... | |
SfxShell (SfxViewShell *pViewSh) | |
The constructor of the SfxShell class initializes only simple types, the corresponding SbxObject is only created on-demand. More... | |
void | SetViewShell_Impl (SfxViewShell *pView) |
SAL_DLLPRIVATE void | Invalidate_Impl (SfxBindings &rBindings, sal_uInt16 nId) |
Protected Member Functions inherited from SfxBroadcaster | |
void | Forward (SfxBroadcaster &rBC, const SfxHint &rHint) |
Static Protected Member Functions | |
static void | HandleOpenXmlFilterSettings (SfxRequest &) |
Private Member Functions | |
SfxShell (const SfxShell &)=delete | |
SfxShell & | operator= (const SfxShell &)=delete |
Private Attributes | |
std::unique_ptr< SfxShell_Impl > | pImpl |
SfxItemPool * | pPool |
SfxUndoManager * | pUndoMgr |
Friends | |
class | SfxObjectItem |
The class SfxShell is the base class for all classes, which provide the functionality of the form <Slot>s.
Each instance has a reference to an interface description, which is obtainable through <SfxShell::GetInterface()const>. This interface provides the connection to specific methods and contains some other descriptive data for controllers like menus and toolboxes, but also for the various APIs. The main part of the interface description is in the form of a <Type-Library>, which is generated from an IDL-file by the <SVIDL-Compiler>. For each SfxShell Subclass-File there is one such IDL-file to write.
|
privatedelete |
|
protected |
|
protected |
|
overridevirtual |
|
virtual |
Virtual method that is called when enabling the SfxShell instance, in order to give the Subclasses the opportunity to respond to the to the enabling.
[Cross-reference]
StarView SystemWindow::Activate(bool)
Reimplemented in SfxViewFrame, and SfxViewShell.
Definition at line 359 of file shell.cxx.
Referenced by DoActivate_Impl().
|
virtual |
void SfxShell::BroadcastContextForActivation | ( | const bool | bIsActivated | ) |
Broadcast a sidebar context change.
This method is typically called from Activate() or Deactivate().
bIsActivated | When <TRUE> then broadcast the context name that was defined with an earlier call to SetContextName(). When <FALSE> then broadcast the 'default' context. |
Definition at line 713 of file shell.cxx.
References GetFrame(), SfxViewFrame::GetFrame(), SfxFrame::GetFrameInterface(), comphelper::LibreOfficeKit::isDialogPainting(), and pImpl.
Referenced by Deactivate(), and SfxViewFrame::GetDispatcher().
bool SfxShell::CanExecuteSlot_Impl | ( | const SfxSlot & | rSlot | ) |
This method determines by calling the status function whether 'rSlot' can be executed currently.
Definition at line 393 of file shell.cxx.
References SfxItemSet::GetItemState(), GetPool(), SfxSlot::GetStateFnc(), SfxSlot::GetWhich(), and nId.
Referenced by SfxDispatcher::Call_Impl().
|
virtual |
|
virtual |
Virtual method that is called when disabling the SfxShell instance, to give the Subclasses the opportunity to respond to the disabling.
[Cross-reference]
StarView SystemWindow::Deactivate(bool)
Reimplemented in SfxViewFrame, and SfxViewShell.
Definition at line 376 of file shell.cxx.
References BroadcastContextForActivation().
Referenced by DoDeactivate_Impl().
void SfxShell::DoActivate_Impl | ( | SfxViewFrame * | pFrame, |
bool | bMDI | ||
) |
This method controls the activation of SfxShell instance.
First, by calling the virtual method <SfxShell::Activate(sal_Bool)> which gives the subclass the opportunity to respond to the event.
When bMDI == TRUE, the associated SbxObject is being 'armed', so that unqualified methods of the object (without the name of the object) from BASIC are found.
Definition at line 292 of file shell.cxx.
References Activate(), GetInterface(), GetObjectShell(), SfxObjectShell::GetTitle(), pImpl, SAL_INFO, and CrashReporter::setActiveSfxObjectName().
void SfxShell::DoDeactivate_Impl | ( | SfxViewFrame const * | pFrame, |
bool | bMDI | ||
) |
This method controls the deactivation of the SfxShell instance.
When bMDI == TRUE the SbxObject is first set to a status that only qualified BASIC methods can be called.
Then the subclass gets the opportunity in every case to respond to the event by calling the virtual method <SfxShell::Deactivate(sal_Bool)>.
Definition at line 329 of file shell.cxx.
References Deactivate(), GetInterface(), pImpl, and SAL_INFO.
Referenced by SfxDispatcher::RemoveShell_Impl().
|
static |
|
static |
void SfxShell::ExecuteSlot | ( | SfxRequest & | rReq, |
bool | bAsync | ||
) |
Asynchronous ExecuteSlot for the RELOAD.
Definition at line 424 of file shell.cxx.
References ExecuteSlot(), pImpl, and ShellCall_Impl().
const SfxPoolItem * SfxShell::ExecuteSlot | ( | SfxRequest & | rReq, |
const SfxInterface * | pIF = nullptr |
||
) |
This method allows you to forward a <SfxRequest> to the specified base <SfxShell>.
[Example]
In a derived class of SfxViewShell the SID_PRINTDOCDIRECT will be intercepted. Under certain circumstances a query should appear before you print, and the request will be aborted if necessary.
Also in the IDL of this subclass of the above slot is entered. The status method will contain in outline:
void SubViewShell::Exec( SfxRequest &rReq ) { if ( rReq.GetSlot() == SID_PRINTDOCDIRECT ) { 'dialog' if ( 'condition' ) ExecuteSlot( rReq, SfxViewShell::GetInterface() ); } }
It usually takes no rReq.Done() to be called as that is already completed in implementation of the SfxViewShell, for instance it has been canceled.
[Cross-reference]
<SfxShell::GetSlotState(sal_uInt16,const SfxInterface*,SfxItemSet*)>
Definition at line 437 of file shell.cxx.
References DBG_ASSERT, SfxSlot::GetExecFnc(), GetInterface(), SfxRequest::GetReturnValue(), SfxRequest::GetSlot(), SfxInterface::GetSlot(), and GetVerbSlot_Impl().
Referenced by SfxViewFrame::AddDispatchMacroToBasic_Impl(), SfxViewFrame::Exec_Impl(), SfxObjectShell::ExecFile_Impl(), SfxViewFrame::ExecHistory_Impl(), ExecuteSlot(), SfxApplication::NewDocDirectExec_Impl(), SfxApplication::OfaExec_Impl(), and SfxObjectShell::PrintExec_Impl().
SfxDisableFlags SfxShell::GetDisableFlags | ( | ) | const |
Definition at line 689 of file shell.cxx.
References pImpl.
Referenced by SfxDispatcher::FindServer_().
SfxDispatcher * SfxShell::GetDispatcher | ( | ) | const |
This method returns a pointer to the <SfxDispatcher>, when the SfxShell is currently <UI-active> or a NULL-pointer if it is not UI-active.
The returned pointer is only valid in the immediate context of the method call.
Definition at line 124 of file shell.cxx.
References pImpl.
Referenced by SfxApplication::MiscExec_Impl(), SfxApplication::MiscState_Impl(), SfxViewShell::PrepareClose(), PutItem(), SfxSecurityPage_Impl::Reset_Impl(), and SfxDispatcher::Update_Impl().
SfxViewFrame * SfxShell::GetFrame | ( | ) | const |
This method returns a pointer to the <SfxViewFrame> to which this SfxShell instance is associated or in which they currently is <UI-active>.
A NULL pointer is returned if this SfxShell instance is not UI-active at the moment and also no SfxViewFrame is permanently assigned.
The returned pointer is only valid in the immediate context of the method call.
[Note]
Only instances of a subclass of SfxApplication and SfxObjectShell should here provide a NULL-pointer. Otherwise, there is an error in the application program (wrong constructor was called from SfxShell).
[Cross-reference]
<SfxViewShell::GetViewFrame()const>
Definition at line 134 of file shell.cxx.
References pImpl.
Referenced by BroadcastContextForActivation(), SfxObjectShell::CancelCheckOut(), SfxObjectShell::CheckIn(), SfxObjectShell::CheckOut(), SfxObjectShell::ExecFile_Impl(), SfxObjectShell::GetCmisVersions(), SfxObjectShell::GetState_Impl(), SfxApplication::NewDocDirectExec_Impl(), SfxViewShell::OutplaceActivated(), SfxObjectShell::SignSignatureLine(), and UIFeatureChanged().
|
virtual |
With this virtual method, which is automatically overridden by each subclass with its own slots through the macro <SFX_DECL_INTERFACE>, one can access each of the <SfxInterface> instance belonging to the subclass.
The class SfxShell itself has no own SfxInterface (no slots), therefore a NULL-pointer is returned.
Definition at line 198 of file shell.cxx.
References GetStaticInterface().
Referenced by DoActivate_Impl(), DoDeactivate_Impl(), SfxViewShell::ExecPrint_Impl(), SfxDispatcher::ExecutePopup(), ExecuteSlot(), SfxDispatcher::FillState_(), SfxDispatcher::FindServer_(), GetSlotState(), Invalidate_Impl(), SfxApplication::OfaExec_Impl(), SfxApplication::OpenDocExec_Impl(), SfxDispatcher::Pop(), and SfxDispatcher::Update_Impl_().
const SfxPoolItem * SfxShell::GetItem | ( | sal_uInt16 | nSlotId | ) | const |
With this method any objects of <SfxPoolItemu> subclasses can be accessed.
This exchange method is needed if, for example special <SfxToolBoxControl> subclasses need access to certain data such as the <SfxObjectShell>.
The returned instance belongs to the particular SfxShell and may be used only in the immediate context of the method call.
[Cross-reference]
<SfxShell::PutItem(const SfxPoolItem&)> <SfxShell::RemoveItem(sal_uInt16)>
Definition at line 143 of file shell.cxx.
References pImpl.
Referenced by SfxModule::GetCurrentFieldUnit(), SfxModule::GetFieldUnit(), and SfxManageStyleSheetPage::SetDescriptionText_Impl().
|
inline |
const OUString & SfxShell::GetName | ( | ) | const |
Returns the name of the Shell object.
With this name, the SfxShell instance of BASIC can be expressed.
Definition at line 119 of file shell.cxx.
References pImpl.
Referenced by SfxObjectShell::CallBasic(), SfxObjectShell::CheckIsReadonly(), SfxEvents_Impl::ConvertToMacro(), SfxObjectShell::ExecFile_Impl(), SfxObjectShell::GetAPIName(), SfxObjectShell::GetDocumentSignatureInformation(), SfxObjectShell::GetState_Impl(), SfxEvents_Impl::NormalizeMacro(), SfxObjectShell::PrepareForSigning(), SfxRequest::Record_Impl(), SfxObjectShell::SignDocumentContentUsingCertificate(), and SfxObjectShell::UpdateFromTemplate_Impl().
|
virtual |
Reimplemented in SfxObjectShell, SfxViewFrame, and SfxViewShell.
Definition at line 649 of file shell.cxx.
References SfxViewFrame::GetObjectShell(), SfxViewShell::GetViewFrame(), and GetViewShell().
Referenced by DoActivate_Impl(), and SfxWorkWindow::SfxWorkWindow().
|
inline |
Each Subclass of SfxShell must reference a pool.
This is partly set by SFx's own set of subclasses (eg <SfxViewShell>). In particular however this must be set directly from one derived SfxShell class and ny derivatives of SfxObjectShell.
The SfxShell class itself does not have any SfxItemPool, therefore a null-pointer is returned.
Definition at line 511 of file shell.hxx.
References pPool.
Referenced by SfxViewFrame::AddDispatchMacroToBasic_Impl(), SfxBaseModel::attachResource(), CanExecuteSlot_Impl(), SfxModule::Construct_Impl(), SfxViewFrame::Construct_Impl(), SfxBindings::CreateSet_Impl(), SfxDispatchController_Impl::dispatch(), SfxViewFrame::Exec_Impl(), SfxObjectShell::ExecFile_Impl(), SfxViewFrame::ExecReload_Impl(), SfxDispatcher::Execute(), sfx2::FileDialogHelper_Impl::execute(), SfxBindings::Execute_Impl(), SfxDispatcher::ExecuteList(), GetSlotState(), SfxObjectShell::HandleFilter(), IMPL_LINK(), IMPL_LINK_NOARG(), SfxObjectShell::ImportFromGeneratedStream_Impl(), SfxApplication::MiscExec_Impl(), SfxApplication::NewDocDirectExec_Impl(), SfxApplication::OfaExec_Impl(), SfxObjectShell::PrepareForSigning(), SfxDispatcher::QueryState(), SfxRequest::SfxRequest(), SfxViewShell::SfxViewShell(), and SfxObjectShell::SignDocumentContentUsingCertificate().
SfxRepeatTarget * SfxShell::GetRepeatTarget | ( | ) | const |
Returns a pointer to the <SfxRepeatTarget> instance that is used in SID_REPEAT as repeat target when it is addressed from the <SfxUndoManager> supplied by this SfxShell.
The return value can be NULL.
[Note]
A derivation of <SfxShell> or one of its subclasses of <SfxRepeatTarget> is not recommended, as compiler errors are provoked. (due to Call-to-Pointer-to-Member-Function to the subclass).
Definition at line 224 of file shell.cxx.
References pImpl.
Referenced by SfxViewFrame::ExecHistory_Impl(), and SfxViewFrame::StateHistory_Impl().
const SfxPoolItem * SfxShell::GetSlotState | ( | sal_uInt16 | nSlotId, |
const SfxInterface * | pIF = nullptr , |
||
SfxItemSet * | pStateSet = nullptr |
||
) |
This method returns the status of the slot with the specified slot ID on the specified interface.
If the slot is disabled or in this SfxShell (and their parent shells) are not known, a Null-pointer is returned.
If the slot does not have a Status, a SfxVoidItem is returned.
The status is set directly in this Set when pStateSet != 0 , so that overridden Slots of the <SfxShell> Subclasses and also in the Status method of the base implementation can be called.
[Example]
In a derived class of SfxViewShell the SID_PRINTDOCDIRECT will be intercepted. Under certain circumstances a query should appear before you print, and the request will be aborted if necessary.
Also in the IDL of this subclass of the above slot is entered. The status method will contain in outline:
void SubViewShell::PrintState( SfxItemSet &rState ) { if ( rState.GetItemState( SID_PRINTDOCDIRECT ) != SfxItemState::UNKNOWN ) GetSlotState( SID_PRINTDOCDIRECT, SfxViewShell::GetInterface(), &rState ); ... }
[Cross-reference]
<SfxShell::ExecuteSlot(SfxRequest&)>
Definition at line 461 of file shell.cxx.
References SfxItemSet::ClearItem(), SfxPoolItem::Clone(), DeleteItemOnIdle(), SfxItemSet::DisableItem(), SfxItemSet::Get(), SfxItemPool::GetDefaultItem(), GetInterface(), SfxItemSet::GetItemState(), GetPool(), SfxInterface::GetSlot(), SfxSlot::GetStateFnc(), GetVerbSlot_Impl(), SfxSlot::GetWhich(), SfxItemPool::IsWhich(), SfxItemSet::Put(), and SfxPoolItem::Which().
Referenced by SfxObjectShell::ExecFile_Impl(), SfxDispatcher::QueryState(), and SfxViewFrame::StateHistory_Impl().
|
inlinestatic |
Definition at line 176 of file shell.hxx.
Referenced by GetInterface().
|
virtual |
Each Subclass of SfxShell can have a <SfxUndoManager>.
This can be set in the derived class with <SfxShell:SetUndoManager()>.
The class SfxShell itself does not have a SfxUndoManager, a NULL-pointer is therefore returned.
Definition at line 203 of file shell.cxx.
References pUndoMgr.
Referenced by SfxViewFrame::ExecHistory_Impl(), sfx2::DocumentUndoManager_Impl::getImplUndoManager(), SfxObjectShell::GetState_Impl(), sfx2::DocumentUndoManager_Impl::impl_retrieveUndoManager(), and SfxViewFrame::StateHistory_Impl().
const css::uno::Sequence< css::embed::VerbDescriptor > & SfxShell::GetVerbs | ( | ) | const |
Definition at line 597 of file shell.cxx.
References pImpl.
Referenced by SfxViewFrame::GetState_Impl(), and VerbExec().
const SfxSlot * SfxShell::GetVerbSlot_Impl | ( | sal_uInt16 | nId | ) | const |
Definition at line 635 of file shell.cxx.
References DBG_ASSERT, nId, nIndex, and pImpl.
Referenced by ExecuteSlot(), SfxDispatcher::FindServer_(), and GetSlotState().
SfxViewShell * SfxShell::GetViewShell | ( | ) | const |
Returns the SfxViewShell in which they are located in the subshells.
Otherwise, and if not specified by the App developer, this method returns NULL.
Definition at line 129 of file shell.cxx.
References pImpl.
Referenced by SfxViewFrame::Activate(), SfxWorkWindow::ArrangeChildren_Impl(), SfxViewFrame::Close(), SfxObjectShell::CreatePreview_Impl(), SfxViewShell::Current(), SfxViewFrame::Deactivate(), SfxBaseController::dispose(), sfx2::sidebar::SidebarController::disposeDecks(), SfxViewFrame::Enable(), SfxFrameWindow_Impl::EventNotify(), SfxViewFrame::Exec_Impl(), SfxViewFrame::ExecHistory_Impl(), SfxViewFrame::ExecReload_Impl(), SfxViewFrame::ExecView_Impl(), StyleList::FillTreeBox(), SfxViewFrame::Get(), GetObjectShell(), SfxPrintHelper::getPrinter(), SfxViewFrame::GetState_Impl(), SfxBaseModel::getViewData(), SfxFrame::GetViewData_Impl(), SfxFrame::GrabFocusOnComponent_Impl(), IMPL_LINK_NOARG(), SfxPrintHelper::impl_setPrinter(), SfxDockingWindow::Initialize_Impl(), InterceptLOKStateChangeEvent(), Invalidate(), SfxViewFrame::InvalidateBorderImpl(), SfxViewFrame::MakeActive_Impl(), SfxApplication::OfaExec_Impl(), SfxApplication::OpenDocExec_Impl(), SfxFrameWindow_Impl::PreNotify(), SfxFrame::PrepareClose_Impl(), SfxPrintHelper::print(), SfxObjectShell::PrintExec_Impl(), SfxObjectShell::PrintState_Impl(), SfxViewFrame::ReleaseObjectShell_Impl(), SfxFrame::Resize(), SfxViewFrame::Resize(), SfxViewFrame::SaveCurrentViewData_Impl(), SfxApplication::SetViewFrame_Impl(), SfxBaseModel::setVisualAreaSize(), SfxRecordingFloatWrapper_Impl::SfxRecordingFloatWrapper_Impl(), SfxViewFrame::StateHistory_Impl(), SfxViewFrame::StateReload_Impl(), SfxViewFrame::StateView_Impl(), sfx2::sidebar::SidebarController::SwitchToDeck(), SfxViewFrame::SwitchToViewShell_Impl(), sfx2::sidebar::SidebarController::UpdateDeckOpenState(), StyleList::UpdateStyles(), and VerbExec().
|
staticprotected |
Definition at line 279 of file shell.cxx.
References SfxRequest::Ignore().
|
virtual |
Definition at line 657 of file shell.cxx.
Referenced by SfxDispatcher::Update_Impl_().
|
virtual |
With this method can the slots of the subclasses be invalidated through the slot Id or alternatively through the Which ID.
Slot IDs, which are inherited by the subclass are also invalidated.
[Cross-reference]
<SfxBindings::Invalidate(sal_uInt16)> <SfxBindings::InvalidateAll(sal_Bool)>
Reimplemented in SfxApplication, SfxModule, and SfxObjectShell.
Definition at line 234 of file shell.cxx.
References GetBindings(), GetViewShell(), Invalidate_Impl(), and nId.
Referenced by SfxViewFrame::Exec_Impl().
|
protected |
Definition at line 251 of file shell.cxx.
References SfxInterface::GetGenoType(), GetInterface(), SfxInterface::GetSlot(), SfxSlot::GetSlotId(), SfxBindings::Invalidate(), SfxBindings::InvalidateShell(), nId, and SAL_INFO.
Referenced by Invalidate(), SfxApplication::Invalidate(), SfxModule::Invalidate(), and SfxObjectShell::Invalidate().
|
virtual |
This method determines whether we need to execute without checking the disabled state of the slot.
This is used for dynamic conditions while you can use SfxSlotMode::FASTCALL for a specific slotid in general.
Definition at line 404 of file shell.cxx.
References SfxRequest::GetArgs(), SfxRequest::GetSlot(), SfxItemSet::HasItem(), and nId.
Referenced by SfxDispatcher::Call_Impl().
|
inlinevirtual |
Definition at line 337 of file shell.hxx.
Referenced by SfxViewFrame::Notify(), and SfxViewFrame::StateReload_Impl().
void SfxShell::PutItem | ( | const SfxPoolItem & | rItem | ) |
With this method, any objects of subclasses of <SfxPoolItem> can be made available.
This exchange technology is needed if, for example, special <SfxToolBoxControl> Subclasses need access to certain data such as the <SfxObjectShell>
If a SfxPoolItem exists with the same slot ID, it is deleted automatically.
[Cross-reference]
<SfxShell::RemoveItem(sal_uInt16)> <SfxShell::GetItem(sal_uInt16)>
Definition at line 154 of file shell.cxx.
References SfxBroadcaster::Broadcast(), SfxPoolItem::Clone(), DBG_ASSERT, SfxDispatcher::GetBindings(), GetDispatcher(), SfxBindings::GetStateCache(), SfxItemPool::IsSlot(), pImpl, SfxStateCache::SetCachedState(), SfxStateCache::SetState(), and SfxPoolItem::Which().
bool SfxShell::SetContextBroadcasterEnabled | ( | const bool | bIsEnabled | ) |
Enabled or disable the context broadcaster.
Returns the old state.
Definition at line 731 of file shell.cxx.
References bIsEnabled, and pImpl.
void SfxShell::SetContextName | ( | const OUString & | rsContextName | ) |
void SfxShell::SetDisableFlags | ( | SfxDisableFlags | nFlags | ) |
Definition at line 684 of file shell.cxx.
References pImpl.
Referenced by SfxDispatcher::FlushImpl(), and SfxDispatcher::RemoveShell_Impl().
void SfxShell::SetName | ( | const OUString & | rName | ) |
Sets the name of the Shell object.
With this name, the SfxShell instance of BASIC can be expressed.
Definition at line 114 of file shell.cxx.
References pImpl.
Referenced by SfxObjectShell::DoLoad(), SfxObjectShell::InvalidateName(), SfxApplication::OfaExec_Impl(), SfxObjectShell::SetNamedVisibility_Impl(), SfxObjectShell::SetTitle(), SfxApplication::SfxApplication(), and SfxViewFrame::UpdateTitle().
|
inline |
With this method, the subclasses register their special <SfxItemPool> in the SfxShell.
Each SfxShell instance must have access to a SfxItemPool. Usually this is the SfxItemPool of the SfxDocumentShell. The SfxShell subclass does not take ownership of the orphaned pool. Before it is deleted it has to be deregistered with SetPool(0).
Definition at line 524 of file shell.hxx.
References pPool.
Referenced by SfxModule::Construct_Impl(), SfxViewFrame::Construct_Impl(), SfxApplication::Initialize_Impl(), and SfxViewShell::SfxViewShell().
void SfxShell::SetRepeatTarget | ( | SfxRepeatTarget * | pTarget | ) |
Sets the <SfxRepeatTarget> instance that is used in SID_REPEAT as RepeatTarget, when the current supplied by this <SfxUndoManager> is addressed.
By 'pTarget==0' the SID_REPEAT is disabled for this SfxShell. The instance '*pTarget' must live as long as it is registered.
[Note]
A derivation of <SfxShell> or one of its subclasses of <SfxRepeatTarget> is not recommended, as compiler errors are provoked. (due to Call-to-Pointer-to-Member-Function to the subclass).
Definition at line 229 of file shell.cxx.
References pImpl.
void SfxShell::SetUndoManager | ( | SfxUndoManager * | pNewUndoMgr | ) |
Sets a <SfxUndoManager> for this <SfxShell> Instance.
For the undo is only the undo-manager used for SfxShell at the top of the stack of each <SfxDispatcher>.
On the given <SfxUndoManager> is automatically the current Max-Undo-Action-Count setting set from the options.
'pNewUndoMgr' must exist until the Destructor of SfxShell instance is called or until the next 'SetUndoManager()'.
Definition at line 208 of file shell.cxx.
References utl::ConfigManager::IsFuzzing(), pUndoMgr, and SfxUndoManager::SetMaxUndoActionCount().
void SfxShell::SetVerbs | ( | const css::uno::Sequence< css::embed::VerbDescriptor > & | aVerbs | ) |
Definition at line 538 of file shell.cxx.
References ASYNCHRON, CONTAINER, DBG_ASSERT, SfxDispatcher::GetBindings(), SfxViewFrame::GetDispatcher(), SfxViewShell::GetViewFrame(), SfxBindings::Invalidate(), n, n1, nCount, nId, NONE, pImpl, SfxSlot::pNextSlot, SFX_STUB_PTR, VerbExec(), and VerbState().
|
protected |
Definition at line 708 of file shell.cxx.
References pImpl.
Referenced by SfxViewFrame::SetViewShell_Impl().
void SfxShell::UIFeatureChanged | ( | ) |
Definition at line 668 of file shell.cxx.
References DispatcherUpdate_Impl(), SfxViewFrame::GetDispatcher(), GetFrame(), SfxViewFrame::IsVisible(), and pImpl.
void SfxShell::VerbExec | ( | SfxRequest & | rReq | ) |
Definition at line 602 of file shell.cxx.
References bReadOnly, SfxRequest::Done(), SfxViewShell::DoVerb(), SfxViewShell::GetObjectShell(), SfxRequest::GetSlot(), GetVerbs(), GetViewShell(), SfxObjectShell::IsReadOnly(), and nId.
Referenced by SetVerbs().
|
static |
Definition at line 631 of file shell.cxx.
Referenced by SetVerbs().
|
friend |
Definition at line 129 of file shell.hxx.
Referenced by SfxViewFrame::Exec_Impl(), and SfxObjectShell::ExecView_Impl().
|
private |
Definition at line 131 of file shell.hxx.
Referenced by BroadcastContextForActivation(), DoActivate_Impl(), DoDeactivate_Impl(), ExecuteSlot(), GetDisableFlags(), GetDispatcher(), GetFrame(), GetItem(), GetName(), GetRepeatTarget(), GetVerbs(), GetVerbSlot_Impl(), GetViewShell(), IsActive(), PutItem(), SetContextBroadcasterEnabled(), SetContextName(), SetDisableFlags(), SetName(), SetRepeatTarget(), SetVerbs(), SetViewShell_Impl(), SfxShell(), and UIFeatureChanged().
|
private |
|
private |
Definition at line 133 of file shell.hxx.
Referenced by GetUndoManager(), and SetUndoManager().