31#include <com/sun/star/frame/XUntitledNumbers.hpp>
32#include <com/sun/star/frame/XController.hpp>
33#include <com/sun/star/frame/XDesktop2.hpp>
34#include <com/sun/star/frame/XTerminateListener.hpp>
35#include <com/sun/star/frame/XTask.hpp>
36#include <com/sun/star/frame/XFramesSupplier.hpp>
37#include <com/sun/star/frame/XFrames.hpp>
38#include <com/sun/star/lang/XServiceInfo.hpp>
39#include <com/sun/star/frame/XDispatchProvider.hpp>
40#include <com/sun/star/frame/XTasksSupplier.hpp>
41#include <com/sun/star/container/XEnumerationAccess.hpp>
42#include <com/sun/star/frame/XDispatchResultListener.hpp>
43#include <com/sun/star/lang/XEventListener.hpp>
44#include <com/sun/star/lang/XComponent.hpp>
45#include <com/sun/star/task/XInteractionHandler.hpp>
46#include <com/sun/star/frame/XDispatchRecorderSupplier.hpp>
47#include <com/sun/star/uno/XComponentContext.hpp>
91typedef cppu::WeakComponentImplHelper<
92 css::lang::XServiceInfo ,
93 css::frame::XDesktop2 ,
94 css::frame::XTasksSupplier ,
95 css::frame::XDispatchResultListener ,
96 css::task::XInteractionHandler ,
113 Desktop( css::uno::Reference< css::uno::XComponentContext > xContext );
116 void constructorInit();
126 virtual void SAL_CALL
acquire() noexcept
override
127 { OWeakObject::acquire(); }
128 virtual void SAL_CALL
release() noexcept
override
129 { OWeakObject::release(); }
130 virtual css::uno::Any SAL_CALL
queryInterface(
const css::uno::Type& type)
override;
133 virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes( )
override;
163 virtual sal_Bool SAL_CALL terminate()
override;
184 virtual void SAL_CALL addTerminateListener(
const css::uno::Reference< css::frame::XTerminateListener >& xListener )
override;
204 virtual void SAL_CALL removeTerminateListener(
const css::uno::Reference< css::frame::XTerminateListener >& xListener )
override;
206 virtual css::uno::Reference< css::container::XEnumerationAccess > SAL_CALL getComponents ( )
override;
207 virtual css::uno::Reference< css::lang::XComponent > SAL_CALL getCurrentComponent ( )
override;
208 virtual css::uno::Reference< css::frame::XFrame > SAL_CALL getCurrentFrame ( )
override;
211 virtual css::uno::Reference< css::lang::XComponent > SAL_CALL loadComponentFromURL (
const OUString& sURL ,
212 const OUString& sTargetFrameName ,
213 sal_Int32 nSearchFlags ,
214 const css::uno::Sequence< css::beans::PropertyValue >& lArguments )
override;
217 virtual css::uno::Reference< css::container::XEnumerationAccess > SAL_CALL getTasks ( )
override;
218 virtual css::uno::Reference< css::frame::XTask > SAL_CALL getActiveTask ( )
override;
221 virtual css::uno::Reference< css::frame::XDispatch > SAL_CALL queryDispatch (
const css::util::URL& aURL ,
222 const OUString& sTargetFrameName ,
223 sal_Int32 nSearchFlags )
override;
224 virtual css::uno::Sequence< css::uno::Reference< css::frame::XDispatch > > SAL_CALL queryDispatches (
const css::uno::Sequence< css::frame::DispatchDescriptor >& lQueries )
override;
227 virtual void SAL_CALL registerDispatchProviderInterceptor(
const css::uno::Reference< css::frame::XDispatchProviderInterceptor >& xInterceptor)
override;
228 virtual void SAL_CALL releaseDispatchProviderInterceptor (
const css::uno::Reference< css::frame::XDispatchProviderInterceptor >& xInterceptor)
override;
231 virtual css::uno::Reference< css::frame::XFrames > SAL_CALL getFrames ( )
override;
232 virtual css::uno::Reference< css::frame::XFrame > SAL_CALL getActiveFrame ( )
override;
233 virtual void SAL_CALL setActiveFrame (
const css::uno::Reference< css::frame::XFrame >& xFrame )
override;
237 virtual css::uno::Reference< css::frame::XFrame > SAL_CALL findFrame (
const OUString& sTargetFrameName ,
238 sal_Int32 nSearchFlags )
override;
239 virtual void SAL_CALL initialize (
const css::uno::Reference< css::awt::XWindow >& xWindow )
override;
240 virtual css::uno::Reference< css::awt::XWindow > SAL_CALL getContainerWindow ( )
override;
241 virtual void SAL_CALL setCreator (
const css::uno::Reference< css::frame::XFramesSupplier >& xCreator )
override;
242 virtual css::uno::Reference< css::frame::XFramesSupplier > SAL_CALL getCreator ( )
override;
243 virtual OUString SAL_CALL getName ( )
override;
244 virtual void SAL_CALL setName (
const OUString& sName )
override;
245 virtual sal_Bool SAL_CALL isTop ( )
override;
246 virtual void SAL_CALL activate ( )
override;
247 virtual void SAL_CALL deactivate ( )
override;
249 virtual sal_Bool SAL_CALL setComponent (
const css::uno::Reference< css::awt::XWindow >& xComponentWindow ,
250 const css::uno::Reference< css::frame::XController >& xController )
override;
251 virtual css::uno::Reference< css::awt::XWindow > SAL_CALL getComponentWindow ( )
override;
252 virtual css::uno::Reference< css::frame::XController > SAL_CALL getController ( )
override;
253 virtual void SAL_CALL contextChanged ( )
override;
254 virtual void SAL_CALL addFrameActionListener (
const css::uno::Reference< css::frame::XFrameActionListener >& xListener )
override;
255 virtual void SAL_CALL removeFrameActionListener (
const css::uno::Reference< css::frame::XFrameActionListener >& xListener )
override;
258 virtual void SAL_CALL disposing()
override;
259 virtual void SAL_CALL addEventListener (
const css::uno::Reference< css::lang::XEventListener >& xListener )
override;
260 virtual void SAL_CALL removeEventListener (
const css::uno::Reference< css::lang::XEventListener >& xListener )
override;
263 virtual void SAL_CALL dispatchFinished (
const css::frame::DispatchResultEvent& aEvent )
override;
266 virtual void SAL_CALL disposing (
const css::lang::EventObject& aSource )
override;
269 virtual void SAL_CALL handle (
const css::uno::Reference< css::task::XInteractionRequest >& xRequest )
override;
272 virtual ::sal_Int32 SAL_CALL leaseNumber(
const css::uno::Reference< css::uno::XInterface >& xComponent )
override;
275 virtual void SAL_CALL releaseNumber( ::sal_Int32 nNumber )
override;
278 virtual void SAL_CALL releaseNumberForComponent(
const css::uno::Reference< css::uno::XInterface >& xComponent )
override;
281 virtual OUString SAL_CALL getUntitledPrefix()
override;
286 bool terminateQuickstarterToo();
292 virtual sal_Bool SAL_CALL convertFastPropertyValue ( css::uno::Any& aConvertedValue ,
293 css::uno::Any& aOldValue ,
295 const css::uno::Any& aValue )
override;
296 virtual void SAL_CALL setFastPropertyValue_NoBroadcast( sal_Int32 nHandle ,
297 const css::uno::Any& aValue )
override;
299 virtual void SAL_CALL getFastPropertyValue ( css::uno::Any& aValue ,
300 sal_Int32 nHandle )
const override;
301 virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper ( )
override;
302 virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo ( )
override;
304 css::uno::Reference< css::lang::XComponent > impl_getFrameComponent (
const css::uno::Reference< css::frame::XFrame >& xFrame )
const;
321 bool impl_sendQueryTerminationEvent(TTerminateListenerList& lCalledListener);
336 void impl_sendCancelTerminationEvent(
const TTerminateListenerList& lCalledListener);
345 void impl_sendTerminateToClipboard();
353 void impl_sendNotifyTerminationEvent();
370 bool impl_closeFrames(
bool bAllowUI);
396 css::uno::Reference< css::uno::XComponentContext >
m_xContext;
451 css::uno::Reference<css::uno::XComponentContext>
const & context);
virtual css::uno::Any SAL_CALL getFastPropertyValue(sal_Int32 nHandle) SAL_OVERRIDE
virtual void SAL_CALL acquire() noexcept override
comphelper::OMultiTypeInterfaceContainerHelper2 m_aListenerContainer
array of child tasks (children of desktop are tasks; and tasks are also frames - But pure frames are ...
bool m_bSession
when true, the call came from session manager the method is Desktop::terminateQuickstarterToo() this ...
OUString m_sName
ref counted class to support disabling commands defined by configuration file
FrameContainer m_aChildTaskContainer
reference to factory, which has create this instance
ELoadState m_eLoadState
helper to dispatch something for new tasks, created by "_blank"!
css::uno::Reference< css::frame::XTerminateListener > m_xSWThreadManager
special terminate listener which loads images asynchronous for current open documents.
bool m_bIsShutdown
check flag to protect us against dispose before terminate! see dispose() for further information!
std::vector< css::uno::Reference< css::frame::XTerminateListener > > m_xComponentDllListeners
css::uno::Reference< css::uno::XComponentContext > m_xContext
bool m_bSuspendQuickstartVeto
hold information about state of asynchron loading of component for loadComponentFromURL()!
css::uno::Reference< css::frame::XDispatchProvider > m_xDispatchHelper
helper for XFrames, XIndexAccess, XElementAccess and implementation of a childcontainer!
bool m_bIsTerminated
check flag to protect against multiple terminate runs
virtual void SAL_CALL release() noexcept override
css::uno::Reference< css::frame::XTerminateListener > m_xSfxTerminator
special terminate listener shutting down the SfxApplication.
css::uno::Reference< css::frame::XTerminateListener > m_xPipeTerminator
special terminate listener to close pipe and block external requests during/after termination process...
css::uno::Reference< css::frame::XTerminateListener > m_xQuickLauncher
special terminate listener shown inside system tray (quick starter) Will hinder the office on shutdow...
css::uno::Reference< css::frame::XFrames > m_xFramesHelper
container for ALL Listener
css::uno::Reference< css::frame::XDispatchRecorderSupplier > m_xDispatchRecorderSupplier
::std::vector< css::uno::Reference< css::frame::XTerminateListener > > TTerminateListenerList
used temporary to know which listener was already called or not.
css::uno::Reference< css::frame::XUntitledNumbers > m_xTitleNumberGenerator
TransactionManager m_aTransactionManager
std::unique_ptr< SvtCommandOptions > m_xCommandOptions
don't ask quickstart for a veto
css::uno::Sequence< OUString > getSupportedServiceNames()
OUString getImplementationName()
css::uno::Any SAL_CALL queryInterface(const css::uno::Type &rType, Interface1 *p1)
bool CPPUHELPER_DLLPUBLIC supportsService(css::lang::XServiceInfo *implementation, rtl::OUString const &name)
FWK_DLLPUBLIC const rtl::Reference< Desktop > & getDesktop(css::uno::Reference< css::uno::XComponentContext > const &context)
cppu::WeakComponentImplHelper< css::lang::XServiceInfo, css::frame::XDesktop2, css::frame::XTasksSupplier, css::frame::XDispatchResultListener, css::task::XInteractionHandler, css::frame::XUntitledNumbers > Desktop_BASE