LibreOffice Module sd (master) 1
Public Member Functions | Private Attributes | List of all members
sd::framework::ViewShellWrapper Class Referencefinal

This class wraps ViewShell objects and makes them look like an XView. More...

#include <ViewShellWrapper.hxx>

Inheritance diagram for sd::framework::ViewShellWrapper:
[legend]
Collaboration diagram for sd::framework::ViewShellWrapper:
[legend]

Public Member Functions

 ViewShellWrapper (const ::std::shared_ptr< ViewShell > &pViewShell, const css::uno::Reference< css::drawing::framework::XResourceId > &rxViewId, const css::uno::Reference< css::awt::XWindow > &rxWindow)
 Create a new ViewShellWrapper object that wraps the given ViewShell object. More...
 
virtual ~ViewShellWrapper () override
 
virtual void disposing (std::unique_lock< std::mutex > &) override
 
virtual css::uno::Any SAL_CALL queryInterface (const css::uno::Type &rType) override
 
const ::std::shared_ptr< ViewShell > & GetViewShell () const
 This method is typically used to obtain a pointer to the wrapped ViewShell object for a given XView object. More...
 
virtual css::uno::Reference< css::drawing::framework::XResourceId > SAL_CALL getResourceId () override
 
virtual sal_Bool SAL_CALL isAnchorOnly () override
 
virtual sal_Bool SAL_CALL select (const css::uno::Any &aSelection) override
 
virtual css::uno::Any SAL_CALL getSelection () override
 
virtual void SAL_CALL addSelectionChangeListener (const css::uno::Reference< css::view::XSelectionChangeListener > &xListener) override
 
virtual void SAL_CALL removeSelectionChangeListener (const css::uno::Reference< css::view::XSelectionChangeListener > &xListener) override
 
virtual sal_Bool SAL_CALL relocateToAnchor (const css::uno::Reference< css::drawing::framework::XResource > &xResource) override
 
virtual void SAL_CALL windowResized (const css::awt::WindowEvent &rEvent) override
 
virtual void SAL_CALL windowMoved (const css::awt::WindowEvent &rEvent) override
 
virtual void SAL_CALL windowShown (const css::lang::EventObject &rEvent) override
 
virtual void SAL_CALL windowHidden (const css::lang::EventObject &rEvent) override
 
virtual void SAL_CALL disposing (const css::lang::EventObject &rEvent) override
 
- Public Member Functions inherited from comphelper::WeakComponentImplHelper< typename... Ifc >
virtual void SAL_CALL acquire () noexcept override
 
virtual void SAL_CALL release () noexcept override
 
virtual void SAL_CALL dispose () noexcept final override
 
virtual void SAL_CALL addEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) final override
 
virtual void SAL_CALL removeEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) final override
 
virtual css::uno::Any SAL_CALL queryInterface (css::uno::Type const &rType) override
 
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes () override
 
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId () override
 
- Public Member Functions inherited from comphelper::WeakComponentImplHelperBase
virtual ~WeakComponentImplHelperBase () override
 
virtual void SAL_CALL dispose () override
 
virtual void SAL_CALL addEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) override
 
virtual void SAL_CALL removeEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) override
 
virtual css::uno::Any SAL_CALL queryInterface (css::uno::Type const &rType) override
 
virtual void disposing (std::unique_lock< std::mutex > &)
 
- Public Member Functions inherited from comphelper::UnoImplBase
virtual ~UnoImplBase ()
 

Private Attributes

::std::shared_ptr< ViewShellmpViewShell
 
::std::shared_ptr< ::sd::slidesorter::SlideSorterViewShellmpSlideSorterViewShell
 
const css::uno::Reference< css::drawing::framework::XResourceId > mxViewId
 
css::uno::Reference< css::awt::XWindow > mxWindow
 

Additional Inherited Members

- Protected Member Functions inherited from comphelper::WeakComponentImplHelperBase
void throwIfDisposed (std::unique_lock< std::mutex > &)
 
- Protected Attributes inherited from comphelper::WeakComponentImplHelperBase
comphelper::OInterfaceContainerHelper4< css::lang::XEventListener > maEventListeners
 
- Protected Attributes inherited from comphelper::UnoImplBase
std::mutex m_aMutex
 
bool m_bDisposed
 

Detailed Description

This class wraps ViewShell objects and makes them look like an XView.

Most importantly it provides access to the ViewShell implementation. Then it forwards size changes of the pane window to the view shell.

Definition at line 46 of file ViewShellWrapper.hxx.

Constructor & Destructor Documentation

◆ ViewShellWrapper()

sd::framework::ViewShellWrapper::ViewShellWrapper ( const ::std::shared_ptr< ViewShell > &  pViewShell,
const css::uno::Reference< css::drawing::framework::XResourceId > &  rxViewId,
const css::uno::Reference< css::awt::XWindow > &  rxWindow 
)

Create a new ViewShellWrapper object that wraps the given ViewShell object.

Parameters
pViewShellThe ViewShell object to wrap.
rsViewURLURL of the view type of the wrapped view shell.
rxWindowThis window reference is optional. When a valid reference is given then size changes of the referenced window are forwarded to the ViewShell object.

Definition at line 46 of file ViewShellWrapper.cxx.

◆ ~ViewShellWrapper()

sd::framework::ViewShellWrapper::~ViewShellWrapper ( )
overridevirtual

Definition at line 58 of file ViewShellWrapper.cxx.

Member Function Documentation

◆ addSelectionChangeListener()

void SAL_CALL sd::framework::ViewShellWrapper::addSelectionChangeListener ( const css::uno::Reference< css::view::XSelectionChangeListener > &  xListener)
overridevirtual

Definition at line 164 of file ViewShellWrapper.cxx.

◆ disposing() [1/2]

virtual void SAL_CALL sd::framework::ViewShellWrapper::disposing ( const css::lang::EventObject &  rEvent)
overridevirtual

◆ disposing() [2/2]

void sd::framework::ViewShellWrapper::disposing ( std::unique_lock< std::mutex > &  )
overridevirtual

Reimplemented from comphelper::WeakComponentImplHelperBase.

Definition at line 62 of file ViewShellWrapper.cxx.

References mpSlideSorterViewShell, mpViewShell, mxWindow, and SAL_INFO.

◆ getResourceId()

Reference< XResourceId > SAL_CALL sd::framework::ViewShellWrapper::getResourceId ( )
overridevirtual

Definition at line 93 of file ViewShellWrapper.cxx.

References mxViewId.

◆ getSelection()

uno::Any SAL_CALL sd::framework::ViewShellWrapper::getSelection ( )
overridevirtual

◆ GetViewShell()

const ::std::shared_ptr< ViewShell > & sd::framework::ViewShellWrapper::GetViewShell ( ) const
inline

This method is typically used to obtain a pointer to the wrapped ViewShell object for a given XView object.

Definition at line 73 of file ViewShellWrapper.hxx.

References mpViewShell.

Referenced by sd::framework::CenterViewFocusModule::HandleNewView().

◆ isAnchorOnly()

sal_Bool SAL_CALL sd::framework::ViewShellWrapper::isAnchorOnly ( )
overridevirtual

Definition at line 98 of file ViewShellWrapper.cxx.

◆ queryInterface()

uno::Any SAL_CALL sd::framework::ViewShellWrapper::queryInterface ( const css::uno::Type &  rType)
overridevirtual

◆ relocateToAnchor()

sal_Bool SAL_CALL sd::framework::ViewShellWrapper::relocateToAnchor ( const css::uno::Reference< css::drawing::framework::XResource > &  xResource)
overridevirtual

Definition at line 174 of file ViewShellWrapper.cxx.

References VCLUnoHelper::GetWindow(), mpViewShell, and mxWindow.

◆ removeSelectionChangeListener()

void SAL_CALL sd::framework::ViewShellWrapper::removeSelectionChangeListener ( const css::uno::Reference< css::view::XSelectionChangeListener > &  xListener)
overridevirtual

Definition at line 168 of file ViewShellWrapper.cxx.

◆ select()

sal_Bool SAL_CALL sd::framework::ViewShellWrapper::select ( const css::uno::Any &  aSelection)
overridevirtual

◆ windowHidden()

void SAL_CALL sd::framework::ViewShellWrapper::windowHidden ( const css::lang::EventObject &  rEvent)
overridevirtual

Definition at line 227 of file ViewShellWrapper.cxx.

◆ windowMoved()

void SAL_CALL sd::framework::ViewShellWrapper::windowMoved ( const css::awt::WindowEvent &  rEvent)
overridevirtual

Definition at line 218 of file ViewShellWrapper.cxx.

◆ windowResized()

void SAL_CALL sd::framework::ViewShellWrapper::windowResized ( const css::awt::WindowEvent &  rEvent)
overridevirtual

Definition at line 211 of file ViewShellWrapper.cxx.

References mpViewShell, and sd::ViewShell::Resize().

◆ windowShown()

void SAL_CALL sd::framework::ViewShellWrapper::windowShown ( const css::lang::EventObject &  rEvent)
overridevirtual

Definition at line 220 of file ViewShellWrapper.cxx.

References mpViewShell, and sd::ViewShell::Resize().

Member Data Documentation

◆ mpSlideSorterViewShell

::std::shared_ptr< ::sd::slidesorter::SlideSorterViewShell > sd::framework::ViewShellWrapper::mpSlideSorterViewShell
private

Definition at line 116 of file ViewShellWrapper.hxx.

Referenced by disposing(), getSelection(), queryInterface(), and select().

◆ mpViewShell

::std::shared_ptr< ViewShell > sd::framework::ViewShellWrapper::mpViewShell
private

◆ mxViewId

const css::uno::Reference< css::drawing::framework::XResourceId > sd::framework::ViewShellWrapper::mxViewId
private

Definition at line 117 of file ViewShellWrapper.hxx.

Referenced by getResourceId().

◆ mxWindow

css::uno::Reference<css::awt::XWindow > sd::framework::ViewShellWrapper::mxWindow
private

Definition at line 118 of file ViewShellWrapper.hxx.

Referenced by disposing(), and relocateToAnchor().


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