LibreOffice Module vcl (master) 1
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
QtMimeData Class Referencefinal

A lazy loading QMimeData for XTransferable reads. More...

#include <QtTransferable.hxx>

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

Public Member Functions

 QtMimeData (const css::uno::Reference< css::datatransfer::XTransferable > &aContents)
 
bool hasFormat (const QString &mimeType) const override
 
QStringList formats () const override
 
bool deepCopy (QMimeData **const) const
 
css::datatransfer::XTransferable * xTransferable () const
 

Private Member Functions

QVariant retrieveData (const QString &mimeType, QMetaType type) const override
 

Private Attributes

const css::uno::Reference< css::datatransfer::XTransferable > m_aContents
 
bool m_bHaveNoCharset
 
bool m_bHaveUTF8
 
QStringList m_aMimeTypeList
 

Friends

class QtClipboardTransferable
 

Detailed Description

A lazy loading QMimeData for XTransferable reads.

This is an interface class to make a XTransferable read accessible as a QMimeData. The mime data is just stored inside the XTransferable, never in the QMimeData itself! It's objects are just used for QClipboard to read the XTransferable data.

Like XTransferable itself, this class should be considered an immutable container for mime data. There is no need to ever set any of its data.

LO will offer at least UTF-16, if there is a viable text representation. If LO misses to offer a UTF-8 or a locale encoded string, these objects will offer them themselves and convert from UTF-16 on demand.

It's the "mirror" interface of the QtTransferable.

Definition at line 102 of file qt5/QtTransferable.hxx.

Constructor & Destructor Documentation

◆ QtMimeData()

QtMimeData::QtMimeData ( const css::uno::Reference< css::datatransfer::XTransferable > &  aContents)
explicit

Member Function Documentation

◆ deepCopy()

bool QtMimeData::deepCopy ( QMimeData ** const  ) const

◆ formats()

QStringList QtMimeData::formats ( ) const
override

◆ hasFormat()

bool QtMimeData::hasFormat ( const QString &  mimeType) const
override

◆ retrieveData()

QVariant QtMimeData::retrieveData ( const QString &  mimeType,
QMetaType  type 
) const
overrideprivate

◆ xTransferable()

css::datatransfer::XTransferable * QtMimeData::xTransferable ( ) const
inline

Definition at line 125 of file qt5/QtTransferable.hxx.

References m_aContents.

Friends And Related Function Documentation

◆ QtClipboardTransferable

friend class QtClipboardTransferable
friend

Definition at line 104 of file qt5/QtTransferable.hxx.

Member Data Documentation

◆ m_aContents

const css::uno::Reference<css::datatransfer::XTransferable> QtMimeData::m_aContents
private

Definition at line 106 of file qt5/QtTransferable.hxx.

Referenced by xTransferable().

◆ m_aMimeTypeList

QStringList QtMimeData::m_aMimeTypeList
mutableprivate

Definition at line 109 of file qt5/QtTransferable.hxx.

◆ m_bHaveNoCharset

bool QtMimeData::m_bHaveNoCharset
mutableprivate

Definition at line 107 of file qt5/QtTransferable.hxx.

◆ m_bHaveUTF8

bool QtMimeData::m_bHaveUTF8
mutableprivate

Definition at line 108 of file qt5/QtTransferable.hxx.


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