Q3StoredDrag Class

The Q3StoredDrag class provides a simple stored-value drag object for arbitrary MIME data. 更多...

頭: #include <Q3StoredDrag>
繼承: Q3DragObject
繼承者: Q3ColorDrag and Q3UriDrag

公共函數

Q3StoredDrag (const char * mimeType , QWidget * dragSource = 0, const char * name = 0)
~Q3StoredDrag ()
virtual void setEncodedData (const QByteArray & data )

重實現公共函數

virtual QByteArray encodedData (const char * format ) const
virtual const char * format (int i ) const

額外繼承成員

詳細描述

The Q3StoredDrag class provides a simple stored-value drag object for arbitrary MIME data.

When a block of data has only one representation, you can use a Q3StoredDrag to hold it.

For more information about drag and drop, see the Q3DragObject 類和 drag and drop documentation .

成員函數文檔編製

Q3StoredDrag:: Q3StoredDrag (const char * mimeType , QWidget * dragSource = 0, const char * name = 0)

構造 Q3StoredDrag dragSource and name 被傳遞給 Q3DragObject constructor, and the format is set to mimeType .

The data will be unset. Use setEncodedData () to set it.

Q3StoredDrag:: ~Q3StoredDrag ()

銷毀拖拽對象。

[虛擬] QByteArray Q3StoredDrag:: encodedData (const char * format ) const

重實現自 QMimeSource::encodedData ().

Returns the stored data in the format 給定。

另請參閱 setEncodedData ().

[虛擬] const char * Q3StoredDrag:: format ( int i ) const

重實現自 QMimeSource::format ().

[虛擬] void Q3StoredDrag:: setEncodedData (const QByteArray & data )

Sets the encoded data of this drag object. The encoded data is delivered to drop sites; it must be in a strictly defined and portable format.

The drag object can't be dropped (by the user) until this function has been called.

另請參閱 encodedData ().