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

#include <transobj.hxx>

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

Public Member Functions

 ScTransferObj (const std::shared_ptr< ScDocument > &pClipDoc, TransferableObjectDescriptor aDesc)
 
virtual ~ScTransferObj () override
 
virtual void AddSupportedFormats () override
 
virtual bool GetData (const css::datatransfer::DataFlavor &rFlavor, const OUString &rDestDoc) override
 
virtual bool WriteObject (tools::SvRef< SotTempStream > &rxOStm, void *pUserObject, sal_uInt32 nUserObjectId, const css::datatransfer::DataFlavor &rFlavor) override
 
virtual void DragFinished (sal_Int8 nDropAction) override
 
virtual sal_Bool SAL_CALL isComplex () override
 
ScDocumentGetDocument () const
 
const ScRangeGetRange () const
 
SCROW GetNonFilteredRows () const
 
SCCOL GetDragHandleX () const
 
SCROW GetDragHandleY () const
 
bool WasSourceCursorInSelection () const
 
SCCOL GetSourceCursorX () const
 
SCROW GetSourceCursorY () const
 
SCTAB GetVisibleTab () const
 
ScDragSrc GetDragSourceFlags () const
 
bool HasFilteredRows () const
 
bool GetUseInApi () const
 
ScDocShellGetSourceDocShell ()
 
ScDocumentGetSourceDocument ()
 
ScMarkData GetSourceMarkData () const
 
void SetDrawPersist (const SfxObjectShellRef &rRef)
 
void SetDragHandlePos (SCCOL nX, SCROW nY)
 
void SetSourceCursorPos (SCCOL nX, SCROW nY)
 
void SetVisibleTab (SCTAB nNew)
 
void SetDragSource (ScDocShell *pSourceShell, const ScMarkData &rMark)
 
void SetDragSourceFlags (ScDragSrc nFlags)
 
void SetDragWasInternal ()
 
SC_DLLPUBLIC void SetUseInApi (bool bSet)
 
virtual sal_Int64 SAL_CALL getSomething (const com::sun::star::uno::Sequence< sal_Int8 > &rId) override
 
- Public Member Functions inherited from TransferDataContainer
 TransferDataContainer ()
 
virtual ~TransferDataContainer () override
 
void CopyINetBookmark (const INetBookmark &rBkmk)
 
void CopyString (const OUString &rStr)
 
void CopyString (SotClipboardFormatId nFmt, const OUString &rStr)
 
void CopyByteString (SotClipboardFormatId nFormatId, const OString &rStr)
 
void CopyAnyData (SotClipboardFormatId nFormatId, const char *pData, sal_uLong nLen)
 
bool HasAnyData () const
 
void StartDrag (vcl::Window *pWindow, sal_Int8 nDragSourceActions, const Link< sal_Int8, void > &rCallback)
 
virtual void DragFinished (sal_Int8 nDropAction) override
 
void StartDrag (vcl::Window *pWindow, sal_Int8 nDragSourceActions)
 
- Public Member Functions inherited from TransferableHelper
virtual css::uno::Any SAL_CALL getTransferData (const css::datatransfer::DataFlavor &rFlavor) override
 
virtual css::uno::Sequence< css::datatransfer::DataFlavor > SAL_CALL getTransferDataFlavors () override
 
virtual sal_Bool SAL_CALL isDataFlavorSupported (const css::datatransfer::DataFlavor &rFlavor) override
 
virtual css::uno::Any SAL_CALL getTransferData2 (const css::datatransfer::DataFlavor &rFlavor, const OUString &rDestDoc) override
 
virtual sal_Bool SAL_CALL isComplex () override
 
void PrepareOLE (const TransferableObjectDescriptor &rObjDesc)
 
void CopyToClipboard (const css::uno::Reference< css::datatransfer::clipboard::XClipboard > &rClipboard) const
 
void CopyToClipboard (vcl::Window *pWindow) const
 
void CopyToPrimarySelection () const
 
void StartDrag (vcl::Window *pWindow, sal_Int8 nDragSourceActions)
 
virtual sal_Int64 SAL_CALL getSomething (const css::uno::Sequence< sal_Int8 > &rId) override
 

Static Public Member Functions

static SC_DLLPUBLIC ScTransferObjGetOwnClipboard (const css::uno::Reference< css::datatransfer::XTransferable2 > &)
 
static SfxObjectShellSetDrawClipDoc (bool bAnyOle, const std::shared_ptr< ScDocument > &={})
 
static const com::sun::star::uno::Sequence< sal_Int8 > & getUnoTunnelId ()
 
- Static Public Member Functions inherited from TransferableHelper
static void ClearPrimarySelection ()
 
static const css::uno::Sequence< sal_Int8 > & getUnoTunnelId ()
 

Private Member Functions

void InitDocShell (bool bLimitToPageSize)
 

Static Private Member Functions

static void StripRefs (ScDocument &rDoc, SCCOL nStartX, SCROW nStartY, SCCOL nEndX, SCROW nEndY, ScDocument &rDestDoc)
 
static void PaintToDev (OutputDevice *pDev, ScDocument &rDoc, double nPrintFactor, const ScRange &rBlock)
 
static void GetAreaSize (const ScDocument &rDoc, SCTAB nTab1, SCTAB nTab2, SCROW &nRow, SCCOL &nCol)
 

Private Attributes

std::shared_ptr< ScDocumentm_pDoc
 
ScRange m_aBlock
 
SCROW m_nNonFiltered
 
TransferableObjectDescriptor m_aObjDesc
 
SfxObjectShellRef m_aDocShellRef
 
SfxObjectShellRef m_aDrawPersistRef
 
css::uno::Reference< css::sheet::XSheetCellRanges > m_xDragSourceRanges
 
SCCOL m_nDragHandleX
 
SCROW m_nDragHandleY
 
SCCOL m_nSourceCursorX
 
SCROW m_nSourceCursorY
 
SCTAB m_nVisibleTab
 
ScDragSrc m_nDragSourceFlags
 
bool m_bDragWasInternal
 
bool m_bUsedForLink
 
bool m_bHasFiltered
 
bool m_bUseInApi
 

Additional Inherited Members

- Protected Member Functions inherited from TransferableHelper
 ~TransferableHelper ()
 
const css::uno::Reference< css::datatransfer::clipboard::XClipboard > & getOwnClipboard () const
 
void implCallOwnLostOwnership (const css::uno::Reference< css::datatransfer::clipboard::XClipboard > &_rxClipboard, const css::uno::Reference< css::datatransfer::XTransferable > &_rxTrans)
 
void AddFormat (SotClipboardFormatId nFormat)
 
void AddFormat (const css::datatransfer::DataFlavor &rFlavor)
 
void RemoveFormat (SotClipboardFormatId nFormat)
 
void RemoveFormat (const css::datatransfer::DataFlavor &rFlavor)
 
bool HasFormat (SotClipboardFormatId nFormat)
 
void ClearFormats ()
 
bool SetAny (const css::uno::Any &rAny)
 
bool SetString (const OUString &rString)
 
bool SetBitmapEx (const BitmapEx &rBitmap, const css::datatransfer::DataFlavor &rFlavor)
 
bool SetGDIMetaFile (const GDIMetaFile &rMtf)
 
bool SetGraphic (const Graphic &rGraphic)
 
bool SetImageMap (const ImageMap &rIMap)
 
bool SetTransferableObjectDescriptor (const TransferableObjectDescriptor &rDesc)
 
bool SetINetBookmark (const INetBookmark &rBmk, const css::datatransfer::DataFlavor &rFlavor)
 
bool SetINetImage (const INetImage &rINtImg, const css::datatransfer::DataFlavor &rFlavor)
 
bool SetObject (void *pUserObject, sal_uInt32 nUserObjectId, const css::datatransfer::DataFlavor &rFlavor)
 
virtual void AddSupportedFormats ()=0
 
virtual bool GetData (const css::datatransfer::DataFlavor &rFlavor, const OUString &rDestDoc)=0
 
virtual bool WriteObject (tools::SvRef< SotTempStream > &rxOStm, void *pUserObject, sal_uInt32 nUserObjectId, const css::datatransfer::DataFlavor &rFlavor)
 
virtual void DragFinished (sal_Int8 nDropAction)
 
virtual void ObjectReleased ()
 
void CopyToSelection (const css::uno::Reference< css::datatransfer::clipboard::XClipboard > &rClipboard) const
 

Detailed Description

Definition at line 38 of file transobj.hxx.

Constructor & Destructor Documentation

◆ ScTransferObj()

ScTransferObj::ScTransferObj ( const std::shared_ptr< ScDocument > &  pClipDoc,
TransferableObjectDescriptor  aDesc 
)

◆ ~ScTransferObj()

ScTransferObj::~ScTransferObj ( )
overridevirtual

Member Function Documentation

◆ AddSupportedFormats()

void ScTransferObj::AddSupportedFormats ( )
overridevirtual

Reimplemented from TransferDataContainer.

Definition at line 204 of file transobj.cxx.

References TransferableHelper::AddFormat(), ScRange::aEnd, ScRange::aStart, and m_aBlock.

◆ DragFinished()

void ScTransferObj::DragFinished ( sal_Int8  nDropAction)
overridevirtual

◆ GetAreaSize()

void ScTransferObj::GetAreaSize ( const ScDocument rDoc,
SCTAB  nTab1,
SCTAB  nTab2,
SCROW nRow,
SCCOL nCol 
)
staticprivate

Definition at line 79 of file transobj.cxx.

References ScDocument::GetPrintArea().

Referenced by ScTransferObj().

◆ GetData()

bool ScTransferObj::GetData ( const css::datatransfer::DataFlavor &  rFlavor,
const OUString &  rDestDoc 
)
overridevirtual

Reimplemented from TransferDataContainer.

Definition at line 278 of file transobj.cxx.

References ScRange::aEnd, ASPECT_CONTENT, ScRange::aStart, CELLTYPE_EDIT, ScAddress::Col(), SfxObjectShell::DoDraw(), ScImportExport::ExportString(), tools::SvRef< typename T >::get(), ScRefCellValue::getEditText(), SotExchange::GetFormat(), SfxObjectShell::GetMapUnit(), ScPatternAttr::GetNumberFormat(), tools::Rectangle::GetSize(), ScCellFormat::GetString(), ScRefCellValue::getType(), SfxObjectShell::GetVisArea(), TransferableHelper::HasFormat(), InitDocShell(), ScImportExport::IsFormatSupported(), lcl_reduceBlock(), m_aBlock, m_aDocShellRef, m_aObjDesc, m_bUsedForLink, m_pDoc, ScExportTextOptions::mbAddQuotes, ScExportTextOptions::mcSeparatorConvertTo, ScExportTextOptions::meNewlineConversion, ScExportTextOptions::None, PaintToDev(), Point, GDIMetaFile::Record(), ScAddress::Row(), SCTRANS_TYPE_EDIT_BIN, SCTRANS_TYPE_EDIT_ODF_TEXT_FLAT, SCTRANS_TYPE_EDIT_RTF, SCTRANS_TYPE_EMBOBJ, SCTRANS_TYPE_IMPEX, TransferableHelper::SetBitmapEx(), ScImportExport::SetExportTextOptions(), ScImportExport::SetFormulas(), TransferableHelper::SetGDIMetaFile(), ScImportExport::SetIncludeFiltered(), TransferableHelper::SetObject(), GDIMetaFile::SetPrefMapMode(), GDIMetaFile::SetPrefSize(), TransferableHelper::SetString(), ScEditEngineDefaulter::SetTextCurrentDefaults(), TransferableHelper::SetTransferableObjectDescriptor(), GDIMetaFile::Stop(), ScAddress::Tab(), ScExportTextOptions::ToSpace, VOPT_FORMULAS, and GDIMetaFile::WindStart().

◆ GetDocument()

ScDocument * ScTransferObj::GetDocument ( ) const
inline

◆ GetDragHandleX()

SCCOL ScTransferObj::GetDragHandleX ( ) const
inline

Definition at line 83 of file transobj.hxx.

Referenced by ScGridWindow::AcceptPrivateDrop().

◆ GetDragHandleY()

SCROW ScTransferObj::GetDragHandleY ( ) const
inline

Definition at line 84 of file transobj.hxx.

Referenced by ScGridWindow::AcceptPrivateDrop().

◆ GetDragSourceFlags()

ScDragSrc ScTransferObj::GetDragSourceFlags ( ) const
inline

◆ GetNonFilteredRows()

SCROW ScTransferObj::GetNonFilteredRows ( ) const
inline

Definition at line 82 of file transobj.hxx.

Referenced by ScGridWindow::AcceptPrivateDrop(), and ScGridWindow::DropTransferObj().

◆ GetOwnClipboard()

ScTransferObj * ScTransferObj::GetOwnClipboard ( const css::uno::Reference< css::datatransfer::XTransferable2 > &  )
static

◆ GetRange()

const ScRange & ScTransferObj::GetRange ( ) const
inline

◆ getSomething()

sal_Int64 SAL_CALL ScTransferObj::getSomething ( const com::sun::star::uno::Sequence< sal_Int8 > &  rId)
overridevirtual

Definition at line 912 of file transobj.cxx.

References comphelper::getSomethingImpl().

◆ GetSourceCursorX()

SCCOL ScTransferObj::GetSourceCursorX ( ) const
inline

Definition at line 86 of file transobj.hxx.

Referenced by ScGridWindow::DropTransferObj().

◆ GetSourceCursorY()

SCROW ScTransferObj::GetSourceCursorY ( ) const
inline

Definition at line 87 of file transobj.hxx.

Referenced by ScGridWindow::DropTransferObj().

◆ GetSourceDocShell()

ScDocShell * ScTransferObj::GetSourceDocShell ( )

◆ GetSourceDocument()

ScDocument * ScTransferObj::GetSourceDocument ( )

◆ GetSourceMarkData()

ScMarkData ScTransferObj::GetSourceMarkData ( ) const

◆ getUnoTunnelId()

const css::uno::Sequence< sal_Int8 > & ScTransferObj::getUnoTunnelId ( )
static

Definition at line 906 of file transobj.cxx.

References comphelper::UnoIdInit::getSeq().

◆ GetUseInApi()

bool ScTransferObj::GetUseInApi ( ) const
inline

Definition at line 91 of file transobj.hxx.

Referenced by ScVbaRange::Insert().

◆ GetVisibleTab()

SCTAB ScTransferObj::GetVisibleTab ( ) const
inline

◆ HasFilteredRows()

bool ScTransferObj::HasFilteredRows ( ) const
inline

Definition at line 90 of file transobj.hxx.

Referenced by ScGridWindow::AcceptPrivateDrop(), and ScGridWindow::DropTransferObj().

◆ InitDocShell()

void ScTransferObj::InitDocShell ( bool  bLimitToPageSize)
private

◆ isComplex()

sal_Bool SAL_CALL ScTransferObj::isComplex ( )
overridevirtual

◆ PaintToDev()

void ScTransferObj::PaintToDev ( OutputDevice pDev,
ScDocument rDoc,
double  nPrintFactor,
const ScRange rBlock 
)
staticprivate

◆ SetDragHandlePos()

void ScTransferObj::SetDragHandlePos ( SCCOL  nX,
SCROW  nY 
)

Definition at line 577 of file transobj.cxx.

References m_nDragHandleX, and m_nDragHandleY.

◆ SetDragSource()

void ScTransferObj::SetDragSource ( ScDocShell pSourceShell,
const ScMarkData rMark 
)

Definition at line 606 of file transobj.cxx.

References ScMarkData::FillRangeListWithMarks(), and m_xDragSourceRanges.

◆ SetDragSourceFlags()

void ScTransferObj::SetDragSourceFlags ( ScDragSrc  nFlags)

Definition at line 613 of file transobj.cxx.

References m_nDragSourceFlags.

◆ SetDragWasInternal()

void ScTransferObj::SetDragWasInternal ( )

Definition at line 618 of file transobj.cxx.

References m_bDragWasInternal.

Referenced by ScGridWindow::DropTransferObj(), and ScTabControl::ExecuteDrop().

◆ SetDrawClipDoc()

SfxObjectShell * ScTransferObj::SetDrawClipDoc ( bool  bAnyOle,
const std::shared_ptr< ScDocument > &  pDoc = {} 
)
static

◆ SetDrawPersist()

void ScTransferObj::SetDrawPersist ( const SfxObjectShellRef rRef)

Definition at line 601 of file transobj.cxx.

References m_aDrawPersistRef.

◆ SetSourceCursorPos()

void ScTransferObj::SetSourceCursorPos ( SCCOL  nX,
SCROW  nY 
)

Definition at line 583 of file transobj.cxx.

References m_nSourceCursorX, and m_nSourceCursorY.

◆ SetUseInApi()

void ScTransferObj::SetUseInApi ( bool  bSet)

Definition at line 623 of file transobj.cxx.

References m_bUseInApi.

Referenced by ooo::vba::excel::implnCopy(), and ooo::vba::excel::implnCut().

◆ SetVisibleTab()

void ScTransferObj::SetVisibleTab ( SCTAB  nNew)

Definition at line 596 of file transobj.cxx.

References m_nVisibleTab.

◆ StripRefs()

void ScTransferObj::StripRefs ( ScDocument rDoc,
SCCOL  nStartX,
SCROW  nStartY,
SCCOL  nEndX,
SCROW  nEndY,
ScDocument rDestDoc 
)
staticprivate

◆ WasSourceCursorInSelection()

bool ScTransferObj::WasSourceCursorInSelection ( ) const

◆ WriteObject()

bool ScTransferObj::WriteObject ( tools::SvRef< SotTempStream > &  rxOStm,
void *  pUserObject,
sal_uInt32  nUserObjectId,
const css::datatransfer::DataFlavor &  rFlavor 
)
overridevirtual

Member Data Documentation

◆ m_aBlock

ScRange ScTransferObj::m_aBlock
private

◆ m_aDocShellRef

SfxObjectShellRef ScTransferObj::m_aDocShellRef
private

Definition at line 45 of file transobj.hxx.

Referenced by GetData(), InitDocShell(), and ~ScTransferObj().

◆ m_aDrawPersistRef

SfxObjectShellRef ScTransferObj::m_aDrawPersistRef
private

Definition at line 46 of file transobj.hxx.

Referenced by SetDrawPersist(), and ~ScTransferObj().

◆ m_aObjDesc

TransferableObjectDescriptor ScTransferObj::m_aObjDesc
private

Definition at line 44 of file transobj.hxx.

Referenced by GetData(), and ScTransferObj().

◆ m_bDragWasInternal

bool ScTransferObj::m_bDragWasInternal
private

Definition at line 54 of file transobj.hxx.

Referenced by DragFinished(), and SetDragWasInternal().

◆ m_bHasFiltered

bool ScTransferObj::m_bHasFiltered
private

Definition at line 56 of file transobj.hxx.

Referenced by ScTransferObj().

◆ m_bUsedForLink

bool ScTransferObj::m_bUsedForLink
private

Definition at line 55 of file transobj.hxx.

Referenced by GetData().

◆ m_bUseInApi

bool ScTransferObj::m_bUseInApi
private

Definition at line 57 of file transobj.hxx.

Referenced by SetUseInApi().

◆ m_nDragHandleX

SCCOL ScTransferObj::m_nDragHandleX
private

Definition at line 48 of file transobj.hxx.

Referenced by SetDragHandlePos().

◆ m_nDragHandleY

SCROW ScTransferObj::m_nDragHandleY
private

Definition at line 49 of file transobj.hxx.

Referenced by SetDragHandlePos().

◆ m_nDragSourceFlags

ScDragSrc ScTransferObj::m_nDragSourceFlags
private

Definition at line 53 of file transobj.hxx.

Referenced by DragFinished(), and SetDragSourceFlags().

◆ m_nNonFiltered

SCROW ScTransferObj::m_nNonFiltered
private

Definition at line 43 of file transobj.hxx.

Referenced by ScTransferObj().

◆ m_nSourceCursorX

SCCOL ScTransferObj::m_nSourceCursorX
private

Definition at line 50 of file transobj.hxx.

Referenced by SetSourceCursorPos(), and WasSourceCursorInSelection().

◆ m_nSourceCursorY

SCROW ScTransferObj::m_nSourceCursorY
private

Definition at line 51 of file transobj.hxx.

Referenced by SetSourceCursorPos(), and WasSourceCursorInSelection().

◆ m_nVisibleTab

SCTAB ScTransferObj::m_nVisibleTab
private

Definition at line 52 of file transobj.hxx.

Referenced by ScTransferObj(), and SetVisibleTab().

◆ m_pDoc

std::shared_ptr<ScDocument> ScTransferObj::m_pDoc
private

◆ m_xDragSourceRanges

css::uno::Reference<css::sheet::XSheetCellRanges> ScTransferObj::m_xDragSourceRanges
private

Definition at line 47 of file transobj.hxx.

Referenced by DragFinished(), GetSourceDocShell(), GetSourceMarkData(), and SetDragSource().


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