Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes
nsBaseClipboard Class Reference

Native Win32 BaseClipboard wrapper. More...

#include <nsBaseClipboard.h>

Inheritance diagram for nsBaseClipboard:
Inheritance graph
[legend]
Collaboration diagram for nsBaseClipboard:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 nsBaseClipboard ()
virtual ~nsBaseClipboard ()
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 (in nsISupportsArray aFlavorList, 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

Protected Member Functions

NS_IMETHOD SetNativeClipboardData (PRInt32 aWhichClipboard)=0
NS_IMETHOD GetNativeClipboardData (nsITransferable *aTransferable, PRInt32 aWhichClipboard)=0

Protected Attributes

PRBool mIgnoreEmptyNotification
nsIClipboardOwnermClipboardOwner
nsITransferablemTransferable

Detailed Description

Native Win32 BaseClipboard wrapper.

Definition at line 53 of file nsBaseClipboard.h.


Constructor & Destructor Documentation

Definition at line 73 of file nsBaseClipboard.cpp.

{
  EmptyClipboard(kSelectionClipboard);
  EmptyClipboard(kGlobalClipboard);
}

Member Function Documentation

void nsIClipboard::emptyClipboard ( in long  aWhichClipboard) [inherited]

This empties the clipboard and notifies the clipboard owner.

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

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

Given a transferable, get the clipboard data.

Parameters:
aTransferableThe transferable
aWhichClipboardSpecifies the clipboard to which this operation applies.
Returns:
NS_Ok if no errors
NS_IMETHOD nsBaseClipboard::GetNativeClipboardData ( nsITransferable aTransferable,
PRInt32  aWhichClipboard 
) [protected, pure virtual]
boolean nsIClipboard::hasDataMatchingFlavors ( in nsISupportsArray  aFlavorList,
in long  aWhichClipboard 
) [inherited]

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.

- nsISupportsCString's in a nsISupportsArray (for JavaScript).

Parameters:
aWhichClipboardSpecifies 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 
) [inherited]

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

Parameters:
aTransferableThe transferable
anOwnerThe owner of the transferable
aWhichClipboardSpecifies the clipboard to which this operation applies.
Returns:
NS_Ok if no errors
NS_IMETHOD nsBaseClipboard::SetNativeClipboardData ( PRInt32  aWhichClipboard) [protected, pure virtual]

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

Definition at line 51 of file nsIClipboard.idl.

Definition at line 50 of file nsIClipboard.idl.

Definition at line 72 of file nsBaseClipboard.h.

Reimplemented in nsClipboard.

Definition at line 71 of file nsBaseClipboard.h.

Reimplemented in nsClipboard.

Definition at line 73 of file nsBaseClipboard.h.


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