|
|
This is nothing but a QPushButton with drag-support. You have to call setDragEnabled( true ) and override the virtual method dragObject() to specify the QDragObject to be used.
KPushButton ( QWidget *parent, const char *name=0 )
| KPushButton |
Default constructor.
KPushButton ( const QString &text, QWidget *parent, const char *name=0)
| KPushButton |
Constructor, that sets the button-text to text
KPushButton ( const QIconSet &icon, const QString &text,
QWidget *parent, const char *name=0 )
| KPushButton |
Constructor, that sets an icon and the button-text to text
~KPushButton ()
| ~KPushButton |
Destroys the button
void setDragEnabled ( bool enable )
| setDragEnabled |
Enables/disables drag-support. Default is enabled.
bool isDragEnabled ()
| isDragEnabled |
[const]
Returns: if drag support is enabled or not.
QDragObject * dragObject ()
| dragObject |
[protected virtual]
Reimplement this and return the QDragObject that should be used for the drag. Default implementation returns 0L, so that no drag is initiated.
void mousePressEvent ( QMouseEvent * )
| mousePressEvent |
[protected virtual]
Reimplemented to add drag-support
void mouseMoveEvent ( QMouseEvent * )
| mouseMoveEvent |
[protected virtual]
Reimplemented to add drag-support
void startDrag ()
| startDrag |
[protected virtual]
Starts a drag (dragCopy() by default) using dragObject()