KFileDnDDetailView Class Reference
This is a fileview inherited from KFileDetailView. "Drag and drop" aware KFileDetailView. More...
#include <kfilednddetailview.h>
Inheritance diagram for KFileDnDDetailView:

Signals | |
void | dropped (QDropEvent *) |
Emitted whenever an decodable item is dropped in the view. | |
void | dropped (KFileView *, QDropEvent *) |
Emitted whenever an decodable item is dropped in the view Note: The QDropEvent contains a KURLDrag object. | |
void | dropped (KFileView *, KURL::List &urls) |
Emitted whenever an decodable item is dropped in the view. | |
Public Member Functions | |
KFileDnDDetailView (QWidget *parent=0, const char *name=0) | |
virtual | ~KFileDnDDetailView () |
void | setDnDEnabled (bool) |
Set this to true if Drag'n drop should be enabled or not, default is enabled. | |
bool | isDnDEnabled () const |
void | setAutoOpenTime (const int &time) |
Sets the auto open time, which means the time that will elapse before a directory is automatically opened after entered by DnD. | |
void | useAutoOpenTimer (bool on=true) |
Set this to true if you want the view to use it's auto open functionallity otherwhise set it to false. | |
bool | isAutoOpening () const |
virtual void | readConfig (KConfig *, const QString &group=QString::null) |
virtual void | writeConfig (KConfig *, const QString &group=QString::null) |
Protected Slots | |
void | slotOpenFolder () |
Called when the auto timer times out. | |
Protected Member Functions | |
virtual void | contentsDragEnterEvent (QDragEnterEvent *e) |
virtual void | contentsDragMoveEvent (QDragMoveEvent *e) |
virtual void | contentsDragLeaveEvent (QDragLeaveEvent *e) |
virtual void | contentsDropEvent (QDropEvent *e) |
virtual void | startDrag () |
Create dragobject encoding the current selection and starts the drag. | |
virtual QDragObject * | dragObject () const |
virtual bool | acceptDrag (QDropEvent *event) const |
Protected Attributes | |
QTimer | m_autoOpenTimer |
int | m_autoOpenTime |
bool | m_useAutoOpenTimer |
QListViewItem * | m_dropItem |
KURLDrag * | m_dragObject |
bool | m_dndEnabled |
Detailed Description
This is a fileview inherited from KFileDetailView. "Drag and drop" aware KFileDetailView.It adds "drag and drop" handling to the view suitable for a KFileDetailView. No special setup is needed, just connect to the dropped signals and the view will take care of the rest.
- Author:
- Björn Sahlström
Definition at line 40 of file kfilednddetailview.h.
Constructor & Destructor Documentation
|
Definition at line 36 of file kfilednddetailview.cpp. References autoOpenTime, KFileDnDDetailView(), setDnDEnabled(), and useAutoOpenTimer(). Referenced by KFileDnDDetailView(). |
|
Definition at line 46 of file kfilednddetailview.cpp. |
Member Function Documentation
|
Reimplemented from KFileDetailView. Definition at line 179 of file kfilednddetailview.cpp. References acceptDrag(). Referenced by acceptDrag(), contentsDragEnterEvent(), contentsDragMoveEvent(), and contentsDropEvent(). |
|
Reimplemented from KFileDetailView. Definition at line 81 of file kfilednddetailview.cpp. References acceptDrag(), contentsDragEnterEvent(), endl(), kdDebug(), m_autoOpenTime, m_autoOpenTimer, m_dropItem, and m_useAutoOpenTimer. Referenced by contentsDragEnterEvent(). |
|
Reimplemented from KFileDetailView. Definition at line 120 of file kfilednddetailview.cpp. References contentsDragLeaveEvent(), endl(), kdDebug(), m_autoOpenTimer, m_dropItem, and m_useAutoOpenTimer. Referenced by contentsDragLeaveEvent(). |
|
Reimplemented from KFileDetailView. Definition at line 97 of file kfilednddetailview.cpp. References acceptDrag(), contentsDragMoveEvent(), endl(), kdDebug(), m_autoOpenTime, m_autoOpenTimer, m_dropItem, and m_useAutoOpenTimer. Referenced by contentsDragMoveEvent(). |
|
Reimplemented from KFileDetailView. Definition at line 130 of file kfilednddetailview.cpp. References acceptDrag(), contentsDropEvent(), dropped(), endl(), kdDebug(), m_autoOpenTimer, m_dropItem, and m_useAutoOpenTimer. Referenced by contentsDropEvent(). |
|
Definition at line 175 of file kfilednddetailview.cpp. References m_dragObject. |
|
Emitted whenever an decodable item is dropped in the view.
|
|
Emitted whenever an decodable item is dropped in the view Note: The QDropEvent contains a KURLDrag object.
|
|
Emitted whenever an decodable item is dropped in the view. Note: The QDropEvent contains a KURLDrag object. Referenced by contentsDropEvent(). |
|
Definition at line 72 of file kfilednddetailview.h. References m_useAutoOpenTimer. |
|
Definition at line 54 of file kfilednddetailview.h. References m_dndEnabled. |
|
Reimplemented from KFileDetailView. Definition at line 49 of file kfilednddetailview.cpp. References KConfigBase::readBoolEntry(), readConfig(), and setDnDEnabled(). Referenced by readConfig(). |
|
Sets the auto open time, which means the time that will elapse before a directory is automatically opened after entered by DnD. Only need to call this if you want to change the predefined time that is 750 ms. This also calls useAutoOpenTimer so no need to call this to. Definition at line 186 of file kfilednddetailview.cpp. References m_autoOpenTime, setAutoOpenTime(), and useAutoOpenTimer(). Referenced by setAutoOpenTime(). |
|
Set this to true if Drag'n drop should be enabled or not, default is enabled.
Definition at line 202 of file kfilednddetailview.cpp. References m_dndEnabled, and setDnDEnabled(). Referenced by KFileDnDDetailView(), readConfig(), and setDnDEnabled(). |
|
Called when the auto timer times out. Open the current folder. Definition at line 62 of file kfilednddetailview.cpp. References KFileViewSignaler::activate(), m_autoOpenTimer, m_dropItem, and m_useAutoOpenTimer. Referenced by useAutoOpenTimer(). |
|
Create dragobject encoding the current selection and starts the drag.
Reimplemented from KListView. Definition at line 151 of file kfilednddetailview.cpp. References KFileDetailView::currentFileItem(), endl(), kdDebug(), m_dragObject, KFileItem::pixmap(), and KFileDetailView::widget(). |
|
Set this to true if you want the view to use it's auto open functionallity otherwhise set it to false. By default this is turned ON. Definition at line 191 of file kfilednddetailview.cpp. References m_autoOpenTimer, m_dropItem, m_useAutoOpenTimer, slotOpenFolder(), and useAutoOpenTimer(). Referenced by KFileDnDDetailView(), setAutoOpenTime(), and useAutoOpenTimer(). |
|
Reimplemented from KFileDetailView. Definition at line 56 of file kfilednddetailview.cpp. References m_dndEnabled, writeConfig(), and KConfigBase::writeEntry(). Referenced by writeConfig(). |
Member Data Documentation
|
Definition at line 121 of file kfilednddetailview.h. Referenced by contentsDragEnterEvent(), contentsDragMoveEvent(), and setAutoOpenTime(). |
|
Definition at line 120 of file kfilednddetailview.h. Referenced by contentsDragEnterEvent(), contentsDragLeaveEvent(), contentsDragMoveEvent(), contentsDropEvent(), slotOpenFolder(), and useAutoOpenTimer(). |
|
Definition at line 125 of file kfilednddetailview.h. Referenced by isDnDEnabled(), setDnDEnabled(), and writeConfig(). |
|
Definition at line 124 of file kfilednddetailview.h. Referenced by dragObject(), and startDrag(). |
|
Definition at line 123 of file kfilednddetailview.h. Referenced by contentsDragEnterEvent(), contentsDragLeaveEvent(), contentsDragMoveEvent(), contentsDropEvent(), slotOpenFolder(), and useAutoOpenTimer(). |
|
Definition at line 122 of file kfilednddetailview.h. Referenced by contentsDragEnterEvent(), contentsDragLeaveEvent(), contentsDragMoveEvent(), contentsDropEvent(), isAutoOpening(), slotOpenFolder(), and useAutoOpenTimer(). |
The documentation for this class was generated from the following files:
- buildtools/autotools/kfilednddetailview.h
- buildtools/autotools/kfilednddetailview.cpp