kabc
Functions | |
bool | canDecode (const QMimeData *md) |
bool | fromMimeData (const QMimeData *md, KABC::Addressee::List &contacts) |
bool | fromMimeData (const QMimeData *md, QByteArray &content) |
bool | populateMimeData (QMimeData *md, const KABC::Addressee::List &contacts) |
bool | populateMimeData (QMimeData *md, const QByteArray &content) |
Detailed Description
Utility function for implementing drag&drop for vCards.
See the Qt drag'n'drop documentation.
- Since
- 4.5
Function Documentation
◆ canDecode()
bool KABC::VCardDrag::canDecode | ( | const QMimeData * | md | ) |
Returns if drag&drop object can be decoded to vCard.
- Parameters
-
md the object to check for vCard data
- Returns
true
if the given data object contains a vCard MIME type, otherwisefalse
Definition at line 69 of file vcarddrag.cpp.
◆ fromMimeData() [1/2]
bool KABC::VCardDrag::fromMimeData | ( | const QMimeData * | md, |
KABC::Addressee::List & | contacts ) |
Decodes the MIME data md
and puts the resulting vCard into contactss
.
- Parameters
-
md the object to check for vCard data contacts where to put the parsed vCards from md
- Returns
true
if there was data for the vCard MIME type and it could be parsed successfully, otherwisefalse
- See also
- canDecode()
Definition at line 84 of file vcarddrag.cpp.
◆ fromMimeData() [2/2]
bool KABC::VCardDrag::fromMimeData | ( | const QMimeData * | md, |
QByteArray & | content ) |
Decodes the drag&drop object to vCard component content
.
- Parameters
-
md the object to check for vCard data content where to put the vCard data from md
- Returns
true
if there was data for the vCard MIME type, otherwisefalse
- See also
- canDecode()
Definition at line 74 of file vcarddrag.cpp.
◆ populateMimeData() [1/2]
bool KABC::VCardDrag::populateMimeData | ( | QMimeData * | md, |
const KABC::Addressee::List & | contacts ) |
Adds the vCard representation as data of the drag object.
- Parameters
-
md the object to set the data on contacts list of Addressee objects to serialize to vCard
- Returns
true
if serializing of the given list worked, otherwisefalse
- See also
- VCardConverter::createVCards()
Definition at line 58 of file vcarddrag.cpp.
◆ populateMimeData() [2/2]
bool KABC::VCardDrag::populateMimeData | ( | QMimeData * | md, |
const QByteArray & | content ) |
Adds the vCard representation as data of the drag object.
- Parameters
-
md the object to set the data on content the vCard data to set
- Returns
- Always
true
Definition at line 52 of file vcarddrag.cpp.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Wed Jan 24 2024 00:00:00 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.