KDirOperator Class Reference
This widget works as a network transparent filebrowser. A widget for displaying files and browsing directories. More...
#include <kdiroperator.h>
Inheritance diagram for KDirOperator:

Public Types | |
enum | ActionTypes { SortActions = 1, ViewActions = 2, NavActions = 4, FileActions = 8, AllActions = 15 } |
The various action types. More... | |
Public Slots | |
void | back () |
Goes one step back in the history and opens that url. | |
void | forward () |
Goes one step forward in the history and opens that url. | |
void | home () |
Enters the home directory. | |
void | cdUp () |
Goes one directory up from the current url. | |
void | updateDir () |
to update the view after changing the settings | |
void | rereadDir () |
Re-reads the current url. | |
void | mkdir () |
Opens a dialog to create a new directory. | |
void | deleteSelected () |
Deletes the currently selected files/directories. | |
void | updateSelectionDependentActions () |
Enables/disables actions that are selection dependent. | |
QString | makeCompletion (const QString &) |
Tries to complete the given string (only completes files). | |
QString | makeDirCompletion (const QString &) |
Tries to complete the given string (only completes directores). | |
Signals | |
void | urlEntered (const KURL &) |
void | updateInformation (int files, int dirs) |
void | completion (const QString &) |
void | finishedLoading () |
void | viewChanged (KFileView *newView) |
Emitted whenever the current fileview is changed, either by an explicit call to setView() or by the user selecting a different view thru the GUI. | |
void | fileHighlighted (const KFileItem *item) |
Emitted when a file is highlighted or generally the selection changes in multiselection mode. | |
void | dirActivated (const KFileItem *item) |
void | fileSelected (const KFileItem *item) |
Public Member Functions | |
KDirOperator (const KURL &urlName=KURL(), QWidget *parent=0, const char *name=0) | |
Constructs the KDirOperator with no initial view. | |
virtual | ~KDirOperator () |
Destroys the KDirOperator. | |
void | setShowHiddenFiles (bool s) |
Enables/disables showing hidden files. | |
bool | showHiddenFiles () const |
void | close () |
Stops loading immediately. | |
void | setNameFilter (const QString &filter) |
Sets a filter like "*.cpp *.h *.o". | |
const QString & | nameFilter () const |
void | setMimeFilter (const QStringList &mimetypes) |
Sets a list of mimetypes as filter. | |
QStringList | mimeFilter () const |
void | clearFilter () |
Clears both the namefilter and mimetype filter, so that all files and directories will be shown. | |
KURL | url () const |
void | setURL (const KURL &url, bool clearforward) |
Sets a new url to list. | |
void | setCurrentItem (const QString &filename) |
Clears the current selection and attempts to set filename the current file. | |
void | setView (KFileView *view) |
Sets a new KFileView to be used for showing and browsing files. | |
KFileView * | view () const |
QWidget * | viewWidget () const |
Returns the widget of the current view. | |
void | setView (KFile::FileView view) |
Sets one of the predefined fileviews. | |
void | setSorting (QDir::SortSpec) |
Sets the way to sort files and directories. | |
QDir::SortSpec | sorting () const |
bool | isRoot () const |
KDirLister * | dirLister () const |
KProgress * | progressBar () const |
void | setMode (KFile::Mode m) |
Sets the listing/selection mode for the views, an OR'ed combination of
| |
KFile::Mode | mode () const |
void | setPreviewWidget (const QWidget *w) |
Sets a preview-widget to be shown next to the file-view. | |
const KFileItemList * | selectedItems () const |
bool | isSelected (const KFileItem *item) const |
int | numDirs () const |
int | numFiles () const |
KCompletion * | completionObject () const |
KCompletion * | dirCompletionObject () const |
KActionCollection * | actionCollection () const |
an accessor to a collection of all available Actions. | |
void | setViewConfig (KConfig *config, const QString &group) |
Sets the config object and the to be used group in KDirOperator. | |
KConfig * | viewConfig () |
Returns the KConfig object used for saving and restoring view's configuration. | |
QString | viewConfigGroup () const |
Returns the group name used for saving and restoring view's configuration. | |
virtual void | readConfig (KConfig *, const QString &group=QString::null) |
Reads the default settings for a view, i.e. | |
virtual void | writeConfig (KConfig *, const QString &group=QString::null) |
Saves the current settings like sorting, simple or detailed view. | |
void | setOnlyDoubleClickSelectsFiles (bool enable) |
This is a KFileDialog specific hack: we want to select directories with single click, but not files. | |
bool | onlyDoubleClickSelectsFiles () const |
bool | mkdir (const QString &directory, bool enterDirectory=true) |
Creates the given directory/url. | |
KIO::DeleteJob * | del (const KFileItemList &items, bool ask=true, bool showProgress=true) |
Starts and returns a KIO::DeleteJob to delete the given items . | |
KIO::DeleteJob * | del (const KFileItemList &items, QWidget *parent, bool ask=true, bool showProgress=true) |
Starts and returns a KIO::DeleteJob to delete the given items . | |
void | clearHistory () |
Clears the forward and backward history. | |
void | setEnableDirHighlighting (bool enable) |
When going up in the directory hierarchy, KDirOperator can highlight the directory that was just left. | |
bool | dirHighlighting () const |
bool | dirOnlyMode () const |
void | setupMenu (int whichActions) |
Sets up the action menu. | |
Static Public Member Functions | |
bool | dirOnlyMode (uint mode) |
Protected Slots | |
void | resetCursor () |
Restores the normal cursor after showing the busy-cursor. | |
void | pathChanged () |
Called after setURL() to load the directory, update the history, etc. | |
void | insertNewFiles (const KFileItemList &newone) |
Adds a new list of KFileItems to the view (coming from KDirLister). | |
void | itemDeleted (KFileItem *) |
Removes the given KFileItem item from the view (usually called from KDirLister). | |
void | selectDir (const KFileItem *item) |
Enters the directory specified by the given item . | |
void | selectFile (const KFileItem *item) |
Emits fileSelected( item ). | |
void | highlightFile (const KFileItem *i) |
Emits fileHighlighted( i ). | |
virtual void | activatedMenu (const KFileItem *, const QPoint &pos) |
Called upon right-click to activate the popupmenu. | |
void | sortByName () |
Changes sorting to sort by name. | |
void | sortBySize () |
Changes sorting to sort by size. | |
void | sortByDate () |
Changes sorting to sort by date. | |
void | sortReversed () |
Changes sorting to reverse sorting. | |
void | toggleDirsFirst () |
Toggles showing directories first / having them sorted like files. | |
void | toggleIgnoreCase () |
Toggles case sensitive / case insensitive sorting. | |
void | slotCompletionMatch (const QString &match) |
Tries to make the given match as current item in the view and emits completion( match ). | |
Protected Member Functions | |
virtual KFileView * | createView (QWidget *parent, KFile::FileView view) |
A view factory for creating predefined fileviews. | |
void | setDirLister (KDirLister *lister) |
Sets a custom KFileReader to list directories. | |
void | resizeEvent (QResizeEvent *) |
void | setupActions () |
Sets up all the actions. | |
void | updateSortActions () |
Updates the sorting-related actions to comply with the current sorting. | |
void | updateViewActions () |
Updates the view-related actions to comply with the current KFile::FileView. | |
void | setupMenu () |
Sets up the context-menu with all the necessary actions. | |
void | prepareCompletionObjects () |
Synchronizes the completion objects with the entries of the currently listed url. | |
bool | checkPreviewSupport () |
Checks if there support from KIO::PreviewJob for the currently shown files, taking mimeFilter() and nameFilter() into account Enables/disables the preview-action accordingly. | |
virtual void | virtual_hook (int id, void *data) |
Detailed Description
This widget works as a network transparent filebrowser. A widget for displaying files and browsing directories.You specify a URL to display and this url will be loaded via KDirLister. The user can browse through directories, highlight and select files, delete or rename files.
It supports different views, e.g. a detailed view (see KFileDetailView), a simple icon view (see KFileIconView), a combination of two views, separating directories and files (KCombiView).
Additionally, a preview view is available (see KFilePreview), which can show either a simple or detailed view and additionally a preview widget (see setPreviewWidget()). KImageFilePreview is one implementation of a preview widget, that displays previews for all supported filetypes utilizing KIO::PreviewJob.
Currently, those classes don't support Drag&Drop out of the box -- there you have to use your own view-classes. You can use some DnD-aware views from Björn Sahlström <bjorn@kbear.org> until they will be integrated into this library. See http://devel-home.kde.org/~pfeiffer/DnD-classes.tar.gz
This widget is the one used in the KFileDialog.
Basic usage is like this:
KDirOperator *op = new KDirOperator( KURL( "file:/home/gis" ), this ); // some signals you might be interested in connect(op, SIGNAL(urlEntered(const KURL&)), SLOT(urlEntered(const KURL&))); connect(op, SIGNAL(fileHighlighted(const KFileItem *)), SLOT(fileHighlighted(const KFileItem *))); connect(op, SIGNAL(fileSelected(const KFileItem *)), SLOT(fileSelected(const KFileItem *))); connect(op, SIGNAL(finishedLoading()), SLOT(slotLoadingFinished()));
op->readConfig( KGlobal::config(), "Your KDiroperator ConfigGroup" ); op->setView(KFile::Default);This will create a childwidget of 'this' showing the directory contents of /home/gis in the default-view. The view is determined by the readConfig() call, which will read the KDirOperator settings, the user left your program with (and which you saved with op->writeConfig()).
- Author:
- Stephan Kulow <coolo@kde.org>, Carsten Pfeiffer <pfeiffer@kde.org>
Definition at line 98 of file kdiroperator.h.
Member Enumeration Documentation
|
The various action types. These values can be or'd together
Definition at line 107 of file kdiroperator.h. |
Constructor & Destructor Documentation
|
Constructs the KDirOperator with no initial view. As the views are configurable, call readConfig() to load the user's configuration and then setView to explicitly set a view. This constructor doesn't start loading the url, setView will do it. Definition at line 93 of file kdiroperator.cpp. References KURL::addPath(), QString::append(), QDir::currentDirPath(), QString::fromLatin1(), QWidget::height(), QString::isEmpty(), KURL::isEmpty(), KURL::protocol(), QPtrStack< KURL >::setAutoDelete(), setDirLister(), QWidget::setFocusPolicy(), KURL::setPath(), KURL::setProtocol(), setupActions(), setupMenu(), and slotCompletionMatch(). |
|
Destroys the KDirOperator.
Definition at line 146 of file kdiroperator.cpp. References resetCursor(), and KFileView::writeConfig(). |
Member Function Documentation
|
Enables/disables showing hidden files.
Definition at line 129 of file kdiroperator.h. References KToggleAction::setChecked(). |
|
Definition at line 134 of file kdiroperator.h. References KToggleAction::isChecked(). |
|
Stops loading immediately. You don't need to call this, usually. Reimplemented from QWidget. Definition at line 470 of file kdiroperator.cpp. References KCompletion::clear(), QPtrList::clear(), resetCursor(), and KDirLister::stop(). |
|
Sets a filter like "*.cpp *.h *.o". Only files matching that filter will be shown. Call updateDir() to apply it.
Definition at line 683 of file kdiroperator.cpp. References checkPreviewSupport(), and KDirLister::setNameFilter(). Referenced by KFileDialog::setFilter(). |
|
Definition at line 154 of file kdiroperator.h. References KDirLister::nameFilter(). |
|
Sets a list of mimetypes as filter. Only files of those mimetypes will be shown. Example:
Definition at line 689 of file kdiroperator.cpp. References checkPreviewSupport(), and KDirLister::setMimeFilter(). Referenced by KFileDialog::setMimeFilter(). |
|
Definition at line 178 of file kdiroperator.h. References KDirLister::mimeFilters(). |
|
Clears both the namefilter and mimetype filter, so that all files and directories will be shown. Call updateDir() to apply it.
Definition at line 676 of file kdiroperator.cpp. References checkPreviewSupport(), KDirLister::clearMimeFilter(), and KDirLister::setNameFilter(). Referenced by KFileDialog::clearFilter(), KFileDialog::setFilter(), and KFileDialog::setMimeFilter(). |
|
Definition at line 659 of file kdiroperator.cpp. Referenced by KFileDialog::baseURL(), del(), isRoot(), mkdir(), KFileDialog::readConfig(), KFileDialog::setSelection(), setView(), and KFileDialog::tokenize(). |
|
Sets a new url to list.
Definition at line 533 of file kdiroperator.cpp. References KURL::cd(), QPtrStack< KURL >::clear(), KURL::cmp(), KMessageBox::error(), QString::fromLatin1(), QDir::homeDirPath(), QPtrStack< KURL >::isEmpty(), KURL::isMalformed(), isRoot(), KDirLister::openURL(), KURL::path(), pathChanged(), QPtrStack< KURL >::push(), resetCursor(), KAction::setEnabled(), KURL::setPath(), KURL::url(), and viewWidget(). Referenced by back(), cdUp(), forward(), home(), mkdir(), selectDir(), and KFileDialog::setURL(). |
|
Clears the current selection and attempts to set filename is just the name, no path or url. Definition at line 1049 of file kdiroperator.cpp. References KFileView::clearSelection(), KFileView::ensureItemVisible(), KDirLister::findByName(), QString::isNull(), KFileView::setCurrentItem(), and KFileView::setSelected(). Referenced by slotCompletionMatch(). |
|
Sets a new KFileView to be used for showing and browsing files. Note: this will read the current url() to fill the view.
Definition at line 964 of file kdiroperator.cpp. References QWidget::setFocusProxy(), KFileView::setOnlyDoubleClickSelectsFiles(), KFileView::setSorting(), viewChanged(), and KFileView::widget(). Referenced by setMode(), setPreviewWidget(), and setView(). |
|
Definition at line 223 of file kdiroperator.h. |
|
Returns the widget of the current view. 0L if there is no view/widget. (KFileView itself is not a widget.) Definition at line 229 of file kdiroperator.h. References KFileView::widget(). Referenced by mkdir(), pathChanged(), and setURL(). |
|
Sets one of the predefined fileviews.
Definition at line 815 of file kdiroperator.cpp. References KActionCollection::action(), createView(), KAction::isEnabled(), KFile::isPreviewInfo(), mode(), KToggleAction::setChecked(), KAction::setEnabled(), setView(), and url(). |
|
Sets the way to sort files and directories.
Definition at line 164 of file kdiroperator.cpp. References KFileView::setSorting(), and updateSortActions(). Referenced by readConfig(). |
|
Definition at line 245 of file kdiroperator.h. |
|
Definition at line 250 of file kdiroperator.h. References KURL::path(), and url(). Referenced by setURL(). |
|
Definition at line 255 of file kdiroperator.h. |
|
Definition at line 1471 of file kdiroperator.cpp. |
|
Sets the listing/selection mode for the views, an OR'ed combination of
You cannot mix File and Files of course, as the former means single-selection mode, the latter multi-selection. Definition at line 951 of file kdiroperator.cpp. References dirOnlyMode(), KDirLister::setDirOnlyMode(), and setView(). Referenced by KFileDialog::setMode(). |
|
Definition at line 946 of file kdiroperator.cpp. References KFile::Mode. Referenced by KFileDialog::init(), KFileDialog::mode(), KFileDialog::selectedFiles(), KFileDialog::selectedURLs(), and setView(). |
|
Sets a preview-widget to be shown next to the file-view.
The ownership of Definition at line 244 of file kdiroperator.cpp. References KActionCollection::action(), KToggleAction::setChecked(), KAction::setEnabled(), and setView(). Referenced by KFileDialog::setPreviewWidget(). |
|
Definition at line 291 of file kdiroperator.h. References KFileView::selectedItems(). Referenced by KFileDialog::multiSelectionChanged(). |
|
Definition at line 298 of file kdiroperator.h. References KFileView::isSelected(). |
|
Definition at line 260 of file kdiroperator.cpp. References KFileView::numDirs(). |
|
Definition at line 265 of file kdiroperator.cpp. References KFileView::numFiles(). |
|
Definition at line 322 of file kdiroperator.h. Referenced by KFileDialog::init(). |
|
Definition at line 334 of file kdiroperator.h. Referenced by KFileDialog::init(). |
|
an accessor to a collection of all available Actions. The actions are static, they will be there all the time (no need to connect to the signals KActionCollection::inserted() or removed(). There are the following actions:
You can e.g. use
Definition at line 381 of file kdiroperator.h. Referenced by KFileDialog::actionCollection(), KFileDialog::init(), and KFileDialog::toggleSpeedbar(). |
|
Sets the config object and the to be used group in KDirOperator. This will be used to store the view's configuration via KFileView::writeConfig() (and for KFileView::readConfig()). If you don't set this, the views cannot save and restore their configuration. Usually you call this right after KDirOperator creation so that the view instantiation can make use of it already. Note that KDirOperator does NOT take ownership of that object (typically it's KGlobal::config() anyway.
Definition at line 1569 of file kdiroperator.cpp. Referenced by KFileDialog::init(). |
|
Returns the KConfig object used for saving and restoring view's configuration.
Definition at line 1575 of file kdiroperator.cpp. |
|
Returns the group name used for saving and restoring view's configuration.
Definition at line 1580 of file kdiroperator.cpp. |
|
Reads the default settings for a view, i.e. the default KFile::FileView. Also reads the sorting and whether hidden files should be shown. Note: the default view will not be set - you have to call
Definition at line 1288 of file kdiroperator.cpp. References QString::fromLatin1(), KConfigBase::group(), QString::isEmpty(), KStdAccel::name(), KConfigBase::readBoolEntry(), KConfigBase::readEntry(), KToggleAction::setChecked(), KConfigBase::setGroup(), KDirLister::setShowingDotFiles(), and setSorting(). Referenced by KFileDialog::readConfig(). |
|
Saves the current settings like sorting, simple or detailed view.
Definition at line 1346 of file kdiroperator.cpp. References KActionCollection::action(), QString::fromLatin1(), KConfigBase::group(), KToggleAction::isChecked(), QString::isEmpty(), KAction::isEnabled(), KConfigBase::setGroup(), QWidget::style(), and KConfigBase::writeEntry(). Referenced by KFileDialog::writeConfig(). |
|
This is a KFileDialog specific hack: we want to select directories with single click, but not files. But as a generic class, we have to be able to select files on single click as well. This gives us the opportunity to do both. The default is false, set it to true if you don't want files selected with single click. Definition at line 1415 of file kdiroperator.cpp. References KFileView::setOnlyDoubleClickSelectsFiles(). Referenced by KFileDialog::init(). |
|
Definition at line 1422 of file kdiroperator.cpp. |
|
Creates the given directory/url. If it is a relative path, it will be completed with the current directory. If enterDirectory is true, the directory will be entered after a successful operation. If unsuccessful, a messagebox will be presented to the user.
Definition at line 376 of file kdiroperator.cpp. References KURL::addPath(), KURL::isLocalFile(), KIO::NetAccess::mkdir(), KURL::path(), setURL(), KMessageBox::sorry(), url(), and viewWidget(). |
|
Starts and returns a KIO::DeleteJob to delete the given
Definition at line 402 of file kdiroperator.cpp. Referenced by deleteSelected(). |
|
Starts and returns a KIO::DeleteJob to delete the given
Definition at line 408 of file kdiroperator.cpp. References QValueList< KURL >::append(), QPtrList::count(), QPtrListIterator::current(), KIO::del(), KMessageBox::information(), QPtrList::isEmpty(), KURL::isLocalFile(), KURL::path(), KURL::prettyURL(), KIO::Job::setAutoErrorHandlingEnabled(), KURL::url(), url(), KMessageBox::warningContinueCancel(), and KMessageBox::warningContinueCancelList(). |
|
Clears the forward and backward history.
Definition at line 1476 of file kdiroperator.cpp. References QPtrStack< KURL >::clear(), and KAction::setEnabled(). Referenced by KFileDialog::getExistingDirectory(), KFileDialog::getExistingURL(), KFileDialog::getOpenFileName(), KFileDialog::getOpenFileNames(), KFileDialog::getOpenURL(), KFileDialog::getOpenURLs(), and KFileDialog::setPreviewWidget(). |
|
When going up in the directory hierarchy, KDirOperator can highlight the directory that was just left. I.e. when you go from /home/gis/src to /home/gis, the item "src" will be made the current item. Default is off. Definition at line 1506 of file kdiroperator.cpp. |
|
Definition at line 1511 of file kdiroperator.cpp. |
|
Definition at line 521 of file kdiroperator.h. Referenced by KFileDialog::setMode(), and setMode(). |
|
Sets up the action menu.
Definition at line 1212 of file kdiroperator.cpp. References KActionCollection::action(), QPopupMenu::clear(), KActionMenu::insert(), and KActionMenu::popupMenu(). Referenced by KFileDialog::init(). |
|
A view factory for creating predefined fileviews. Called internally by setView , but you can also call it directly. Reimplement this if you depend on self defined fileviews.
Definition at line 769 of file kdiroperator.cpp. References KFile::isPreviewInfo(), KFileView::setOnlyDoubleClickSelectsFiles(), KCombiView::setRight(), and KFileView::setViewName(). Referenced by setView(). |
|
Sets a custom KFileReader to list directories.
Definition at line 978 of file kdiroperator.cpp. References insertNewFiles(), itemDeleted(), and KDirLister::setAutoUpdate(). Referenced by KDirOperator(). |
|
Sets up all the actions. Called from the constructor, you usually better not call this. Definition at line 1112 of file kdiroperator.cpp. References back(), KStdAction::back(), cdUp(), deleteSelected(), forward(), KStdAction::forward(), QString::fromLatin1(), home(), KStdAction::home(), mkdir(), KActionMenu::popupMenu(), KStdAction::redisplay(), rereadDir(), KToggleAction::setExclusiveGroup(), KAction::setIcon(), KAction::setShortcut(), KAction::setText(), and KStdAction::up(). Referenced by KDirOperator(). |
|
Updates the sorting-related actions to comply with the current sorting.
Definition at line 1260 of file kdiroperator.cpp. References KFileView::isReversed(), KToggleAction::setChecked(), and KAction::setEnabled(). Referenced by setSorting(). |
|
Updates the view-related actions to comply with the current KFile::FileView.
Definition at line 1277 of file kdiroperator.cpp. References KAction::isEnabled(), and KToggleAction::setChecked(). |
|
Sets up the context-menu with all the necessary actions. Called from the constructor, you usually don't need to call this.
Definition at line 1207 of file kdiroperator.cpp. Referenced by KDirOperator(). |
|
Synchronizes the completion objects with the entries of the currently listed url. Automatically called from makeCompletion() and makeDirCompletion() Definition at line 1088 of file kdiroperator.cpp. References KCompletion::addItem(), QPtrListIterator::current(), KFileItem::isDir(), KFileView::items(), and KFileItem::name(). Referenced by makeCompletion(), and makeDirCompletion(). |
|
Checks if there support from KIO::PreviewJob for the currently shown files, taking mimeFilter() and nameFilter() into account Enables/disables the preview-action accordingly.
Definition at line 695 of file kdiroperator.cpp. References KActionCollection::action(), KGlobal::config(), KConfigBase::readBoolEntry(), and KAction::setEnabled(). Referenced by clearFilter(), setMimeFilter(), and setNameFilter(). |
|
Goes one step back in the history and opens that url.
Definition at line 633 of file kdiroperator.cpp. References QPtrStack< KURL >::isEmpty(), QPtrStack< KURL >::pop(), QPtrStack< KURL >::push(), and setURL(). Referenced by pathChanged(), and setupActions(). |
|
Goes one step forward in the history and opens that url.
Definition at line 647 of file kdiroperator.cpp. References QPtrStack< KURL >::isEmpty(), QPtrStack< KURL >::pop(), QPtrStack< KURL >::push(), and setURL(). Referenced by setupActions(). |
|
Enters the home directory.
Definition at line 671 of file kdiroperator.cpp. References QDir::homeDirPath(), and setURL(). Referenced by pathChanged(), and setupActions(). |
|
Goes one directory up from the current url.
Definition at line 664 of file kdiroperator.cpp. References KURL::cd(), QString::fromLatin1(), and setURL(). Referenced by setupActions(). |
|
to update the view after changing the settings
Definition at line 581 of file kdiroperator.cpp. References KDirLister::emitChanges(), and KFileView::listingCompleted(). |
|
Re-reads the current url.
Definition at line 588 of file kdiroperator.cpp. References KDirLister::openURL(), and pathChanged(). Referenced by setupActions(). |
|
Opens a dialog to create a new directory.
Definition at line 365 of file kdiroperator.cpp. References QDialog::exec(), QString::fromLatin1(), KDialog::setCaption(), KLineEditDlg::text(), and url(). Referenced by setupActions(). |
|
Deletes the currently selected files/directories.
Definition at line 460 of file kdiroperator.cpp. References del(), and KFileView::selectedItems(). Referenced by setupActions(). |
|
Enables/disables actions that are selection dependent. Call this e.g. when you are about to show a popup menu using some of KDirOperators actions. Definition at line 236 of file kdiroperator.cpp. References KActionCollection::action(), QPtrList::isEmpty(), KFileView::selectedItems(), and KAction::setEnabled(). Referenced by activatedMenu(). |
|
Tries to complete the given string (only completes files).
Definition at line 1066 of file kdiroperator.cpp. References KFileView::clearSelection(), QString::isEmpty(), KCompletion::makeCompletion(), and prepareCompletionObjects(). |
|
Tries to complete the given string (only completes directores).
Definition at line 1077 of file kdiroperator.cpp. References KFileView::clearSelection(), QString::isEmpty(), KCompletion::makeCompletion(), and prepareCompletionObjects(). |
|
Restores the normal cursor after showing the busy-cursor. Also hides the progressbar. Definition at line 172 of file kdiroperator.cpp. References QApplication::restoreOverrideCursor(). Referenced by close(), insertNewFiles(), setURL(), and ~KDirOperator(). |
|
Called after setURL() to load the directory, update the history, etc.
Definition at line 595 of file kdiroperator.cpp. References back(), KCompletion::clear(), KFileView::clear(), QPtrList::clear(), KMessageBox::error(), home(), QPtrStack< KURL >::isEmpty(), QApplication::restoreOverrideCursor(), QApplication::setOverrideCursor(), and viewWidget(). Referenced by rereadDir(), and setURL(). |
|
Adds a new list of KFileItems to the view (coming from KDirLister).
Definition at line 1004 of file kdiroperator.cpp. References KFileView::addItemList(), QPtrListIterator::current(), KFileView::ensureItemVisible(), KFileItem::isDir(), QPtrList::isEmpty(), KFileView::numDirs(), KFileView::numFiles(), resetCursor(), KFileView::setCurrentItem(), QTimer::singleShot(), KURL::url(), and KFileItem::url(). Referenced by setDirLister(). |
|
Removes the given KFileItem item from the view (usually called from KDirLister).
Definition at line 1035 of file kdiroperator.cpp. References KFileView::numDirs(), KFileView::numFiles(), KFileView::removeItem(), and QPtrList::removeRef(). Referenced by setDirLister(). |
|
Enters the directory specified by the given
Definition at line 1030 of file kdiroperator.cpp. References setURL(), and KFileItem::url(). |
|
Emits fileSelected( item ).
Definition at line 1042 of file kdiroperator.cpp. References QApplication::restoreOverrideCursor(). |
|
Emits fileHighlighted( i ).
Definition at line 697 of file kdiroperator.h. References fileHighlighted(). |
|
Called upon right-click to activate the popupmenu.
Definition at line 229 of file kdiroperator.cpp. References KActionMenu::popup(), and updateSelectionDependentActions(). |
|
Changes sorting to sort by name.
Definition at line 707 of file kdiroperator.h. References KToggleAction::setChecked(). |
|
Changes sorting to sort by size.
Definition at line 712 of file kdiroperator.h. References KToggleAction::setChecked(). |
|
Changes sorting to sort by date.
Definition at line 717 of file kdiroperator.h. References KToggleAction::setChecked(). |
|
Changes sorting to reverse sorting.
Definition at line 722 of file kdiroperator.h. References KToggleAction::isChecked(), and KToggleAction::setChecked(). |
|
Toggles showing directories first / having them sorted like files.
Definition at line 727 of file kdiroperator.h. References KToggleAction::isChecked(), and KToggleAction::setChecked(). |
|
Toggles case sensitive / case insensitive sorting.
Definition at line 732 of file kdiroperator.h. References KToggleAction::isChecked(), and KToggleAction::setChecked(). |
|
Tries to make the given
Definition at line 1106 of file kdiroperator.cpp. References setCurrentItem(). Referenced by KDirOperator(). |
|
Emitted whenever the current fileview is changed, either by an explicit call to setView() or by the user selecting a different view thru the GUI.
Referenced by setView(). |
|
Emitted when a file is highlighted or generally the selection changes in multiselection mode.
In the latter case, Referenced by highlightFile(). |
The documentation for this class was generated from the following files: