VCF::Clipboard Class Reference
The Clipboard represents a common place to put shared data between objects and/or between applications. More...
#include <vcf/ApplicationKit/Clipboard.h>
Inheritance diagram for VCF::Clipboard:

Public Member Functions | |
| Clipboard () | |
| virtual | ~Clipboard () |
| ClipboardItemPasted bool | hasDataType (const String &dataType) |
| does the Clipboard have a DataObject that matches the requested dataType | |
| void | copyTo (DataObject *dataObject) |
| copies the specified dataObject into the clipboard. | |
| DataObject * | pasteFrom (const String &dataType) |
| pastes the data, specified in dataType, from the Clipboard and returns it. | |
| void | internal_deleteDataObject (DataObject *dataObject) |
| internal VCF use only | |
Public Attributes | |
| VCF::Delegate | ClipboardDelegate |
| ClipboardContentsChanged VCF::Delegate | ClipboardDelegate |
| ClipboardItemCopied VCF::Delegate | ClipboardDelegate |
Detailed Description
The Clipboard represents a common place to put shared data between objects and/or between applications.The Clipboard maintains one or more ClipboardDataObjects that actually hold the data, according to their DataType.
The clipboard is never created directly - this is taken care of by the UIToolkit. To access the clipboard you call the UIToolkit::getSystemClipboard() method which will return a reference to the Clipboard singleton.
In Win32 the Clipboard is implemented with full support for COM's IDataObject for actual data transfer, so objects that put data into the Clipboard in the VCF can easily share the data with other Win32 programs.
- See also:
- DataObject
DataType
- Event Delegates for this class:
- Clipboard::ClipboardContentsChanged
- Clipboard::ClipboardItemCopied
- Clipboard::ClipboardItemPasted
Constructor & Destructor Documentation
|
|
|
|
|
|
Member Function Documentation
|
|
copies the specified dataObject into the clipboard. The Clipboard takes ownership of the dataObject object passed in which must be created on the heap.
Clipboard* clipboard = UIToolkit::getDefaultUIToolkit()->getSystemClipboard(); String selectedText = "Hello World - here's some clipboard text"; DataObject* textDataObj = new TextDataObject( selectedText ); clipboard->copyTo( textDataObj );
|
|
|
does the Clipboard have a DataObject that matches the requested dataType
|
|
|
internal VCF use only
|
|
|
pastes the data, specified in dataType, from the Clipboard and returns it.
|
Member Data Documentation
|
|
|
|
|
|
|
|
|
The documentation for this class was generated from the following file:
- vcf/ApplicationKit/Clipboard.h
