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)
 
- 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)
 

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 Public Member Functions inherited from TransferableHelper
static void ClearPrimarySelection ()
 

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
 
rtl::Reference< ScCellRangesBase > 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 40 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(), 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 85 of file transobj.hxx.

Referenced by ScGridWindow::AcceptPrivateDrop().

◆ GetDragHandleY()

SCROW ScTransferObj::GetDragHandleY ( ) const
inline

Definition at line 86 of file transobj.hxx.

Referenced by ScGridWindow::AcceptPrivateDrop().

◆ GetDragSourceFlags()

ScDragSrc ScTransferObj::GetDragSourceFlags ( ) const
inline

◆ GetNonFilteredRows()

SCROW ScTransferObj::GetNonFilteredRows ( ) const
inline

Definition at line 84 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

◆ GetSourceCursorX()

SCCOL ScTransferObj::GetSourceCursorX ( ) const
inline

Definition at line 88 of file transobj.hxx.

Referenced by ScGridWindow::DropTransferObj().

◆ GetSourceCursorY()

SCROW ScTransferObj::GetSourceCursorY ( ) const
inline

Definition at line 89 of file transobj.hxx.

Referenced by ScGridWindow::DropTransferObj().

◆ GetSourceDocShell()

ScDocShell * ScTransferObj::GetSourceDocShell ( )

Definition at line 636 of file transobj.cxx.

References m_xDragSourceRanges.

Referenced by DragFinished(), ScGridWindow::DropTransferObj(), and GetSourceDocument().

◆ GetSourceDocument()

ScDocument * ScTransferObj::GetSourceDocument ( )

◆ GetSourceMarkData()

ScMarkData ScTransferObj::GetSourceMarkData ( ) const

◆ GetUseInApi()

bool ScTransferObj::GetUseInApi ( ) const
inline

Definition at line 93 of file transobj.hxx.

Referenced by ScVbaRange::Insert().

◆ GetVisibleTab()

SCTAB ScTransferObj::GetVisibleTab ( ) const
inline

◆ HasFilteredRows()

bool ScTransferObj::HasFilteredRows ( ) const
inline

Definition at line 92 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 47 of file transobj.hxx.

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

◆ m_aDrawPersistRef

SfxObjectShellRef ScTransferObj::m_aDrawPersistRef
private

Definition at line 48 of file transobj.hxx.

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

◆ m_aObjDesc

TransferableObjectDescriptor ScTransferObj::m_aObjDesc
private

Definition at line 46 of file transobj.hxx.

Referenced by GetData(), and ScTransferObj().

◆ m_bDragWasInternal

bool ScTransferObj::m_bDragWasInternal
private

Definition at line 56 of file transobj.hxx.

Referenced by DragFinished(), and SetDragWasInternal().

◆ m_bHasFiltered

bool ScTransferObj::m_bHasFiltered
private

Definition at line 58 of file transobj.hxx.

Referenced by ScTransferObj().

◆ m_bUsedForLink

bool ScTransferObj::m_bUsedForLink
private

Definition at line 57 of file transobj.hxx.

Referenced by GetData().

◆ m_bUseInApi

bool ScTransferObj::m_bUseInApi
private

Definition at line 59 of file transobj.hxx.

Referenced by SetUseInApi().

◆ m_nDragHandleX

SCCOL ScTransferObj::m_nDragHandleX
private

Definition at line 50 of file transobj.hxx.

Referenced by SetDragHandlePos().

◆ m_nDragHandleY

SCROW ScTransferObj::m_nDragHandleY
private

Definition at line 51 of file transobj.hxx.

Referenced by SetDragHandlePos().

◆ m_nDragSourceFlags

ScDragSrc ScTransferObj::m_nDragSourceFlags
private

Definition at line 55 of file transobj.hxx.

Referenced by DragFinished(), and SetDragSourceFlags().

◆ m_nNonFiltered

SCROW ScTransferObj::m_nNonFiltered
private

Definition at line 45 of file transobj.hxx.

Referenced by ScTransferObj().

◆ m_nSourceCursorX

SCCOL ScTransferObj::m_nSourceCursorX
private

Definition at line 52 of file transobj.hxx.

Referenced by SetSourceCursorPos(), and WasSourceCursorInSelection().

◆ m_nSourceCursorY

SCROW ScTransferObj::m_nSourceCursorY
private

Definition at line 53 of file transobj.hxx.

Referenced by SetSourceCursorPos(), and WasSourceCursorInSelection().

◆ m_nVisibleTab

SCTAB ScTransferObj::m_nVisibleTab
private

Definition at line 54 of file transobj.hxx.

Referenced by ScTransferObj(), and SetVisibleTab().

◆ m_pDoc

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

◆ m_xDragSourceRanges

rtl::Reference<ScCellRangesBase> ScTransferObj::m_xDragSourceRanges
private

Definition at line 49 of file transobj.hxx.

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


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