Public Member Functions | Public Attributes

nsIClipboard Interface Reference

import "nsIClipboard.idl";

List of all members.

Public Member Functions

void setData (in nsITransferable aTransferable, in nsIClipboardOwner anOwner, in long aWhichClipboard)
 Given a transferable, set the data on the native clipboard.
void getData (in nsITransferable aTransferable, in long aWhichClipboard)
 Given a transferable, get the clipboard data.
void emptyClipboard (in long aWhichClipboard)
 This empties the clipboard and notifies the clipboard owner.
boolean hasDataMatchingFlavors ([array, size_is(aLength)] in string aFlavorList, in unsigned long aLength, in long aWhichClipboard)
 This provides a way to give correct UI feedback about, for instance, a paste should be allowed.
boolean supportsSelectionClipboard ()
 Allows clients to determine if the implementation supports the concept of a separate clipboard for selection.

Public Attributes

const long kSelectionClipboard = 0
const long kGlobalClipboard = 1

Member Function Documentation

void nsIClipboard::emptyClipboard ( in long  aWhichClipboard  ) 

This empties the clipboard and notifies the clipboard owner.

This empties the "logical" clipboard. It does not clear the native clipboard.

Parameters:
aWhichClipboard Specifies the clipboard to which this operation applies.
Returns:
NS_OK if successful.
void nsIClipboard::getData ( in nsITransferable  aTransferable,
in long  aWhichClipboard 
)

Given a transferable, get the clipboard data.

Parameters:
aTransferable The transferable
aWhichClipboard Specifies the clipboard to which this operation applies.
Returns:
NS_Ok if no errors
boolean nsIClipboard::hasDataMatchingFlavors ( [array, size_is(aLength)] in string  aFlavorList,
in unsigned long  aLength,
in long  aWhichClipboard 
)

This provides a way to give correct UI feedback about, for instance, a paste should be allowed.

It does _NOT_ actually retreive the data and should be a very inexpensive call. All it does is check if there is data on the clipboard matching any of the flavors in the given list.

Parameters:
aFlavorList An array of ASCII strings.
aLength The length of the aFlavorList.
aWhichClipboard Specifies the clipboard to which this operation applies. - if data is present matching one of
Returns:
NS_OK if successful.
void nsIClipboard::setData ( in nsITransferable  aTransferable,
in nsIClipboardOwner  anOwner,
in long  aWhichClipboard 
)

Given a transferable, set the data on the native clipboard.

Parameters:
aTransferable The transferable
anOwner The owner of the transferable
aWhichClipboard Specifies the clipboard to which this operation applies.
Returns:
NS_Ok if no errors
boolean nsIClipboard::supportsSelectionClipboard (  ) 

Allows clients to determine if the implementation supports the concept of a separate clipboard for selection.

- true if

Returns:
NS_OK if successful.

Member Data Documentation


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