2 * SPDX-FileCopyrightText: 2006-2009 Peter Penz <peter.penz19@gmail.com>
3 * SPDX-FileCopyrightText: 2006 Gregor Kališnik <gregor@podnapisi.net>
5 * SPDX-License-Identifier: GPL-2.0-or-later
11 #include "dolphintabwidget.h"
12 #include "dolphin_export.h"
13 #include "tooltips/tooltipmanager.h"
17 #include "config-dolphin.h"
18 #include <kio/fileundomanager.h>
19 #include <kparts/part.h>
28 typedef KIO::FileUndoManager::CommandType CommandType
;
30 class DolphinItemListView
;
32 class KItemListContainer
;
36 class VersionControlObserver
;
39 class QGraphicsSceneDragDropEvent
;
42 class QRegularExpression
;
45 * @short Represents a view for the directory content.
47 * View modes for icons, compact and details are supported. It's
55 class DOLPHIN_EXPORT DolphinView
: public QWidget
61 * Defines the view mode for a directory. The
62 * view mode is automatically updated if the directory itself
63 * defines a view mode (see class ViewProperties for details).
68 * The items are shown as icons with a name-label below.
73 * The icon, the name and the size of the items are
74 * shown per default as a table.
79 * The items are shown as icons with the name-label aligned
86 * @param url Specifies the content which should be shown.
87 * @param parent Parent widget of the view.
89 DolphinView(const QUrl
& url
, QWidget
* parent
);
91 ~DolphinView() override
;
94 * Returns the current active URL, where all actions are applied.
95 * The URL navigator is synchronized with this URL.
100 * If \a active is true, the view will marked as active. The active
101 * view is defined as view where all actions are applied to.
103 void setActive(bool active
);
104 bool isActive() const;
107 * Changes the view mode for the current directory to \a mode.
108 * If the view properties should be remembered for each directory
109 * (GeneralSettings::globalViewProps() returns false), then the
110 * changed view mode will be stored automatically.
112 void setViewMode(Mode mode
);
113 Mode
viewMode() const;
115 void setSelectionMode(bool enabled
);
116 bool selectionMode() const;
119 * Turns on the file preview for the all files of the current directory,
120 * if \a show is true.
121 * If the view properties should be remembered for each directory
122 * (GeneralSettings::globalViewProps() returns false), then the
123 * preview setting will be stored automatically.
125 void setPreviewsShown(bool show
);
126 bool previewsShown() const;
129 * Shows all hidden files of the current directory,
130 * if \a show is true.
131 * If the view properties should be remembered for each directory
132 * (GeneralSettings::globalViewProps() returns false), then the
133 * show hidden file setting will be stored automatically.
135 void setHiddenFilesShown(bool show
);
136 bool hiddenFilesShown() const;
139 * Turns on sorting by groups if \a enable is true.
141 void setGroupedSorting(bool grouped
);
142 bool groupedSorting() const;
145 * Returns the items of the view.
147 KFileItemList
items() const;
150 * @return The number of items. itemsCount() is faster in comparison
151 * to items().count().
153 int itemsCount() const;
156 * Returns the selected items. The list is empty if no item has been
159 KFileItemList
selectedItems() const;
162 * Returns the number of selected items (this is faster than
163 * invoking selectedItems().count()).
165 int selectedItemsCount() const;
168 * Marks the items indicated by \p urls to get selected after the
169 * directory DolphinView::url() has been loaded. Note that nothing
170 * gets selected if no loading of a directory has been triggered
171 * by DolphinView::setUrl() or DolphinView::reload().
173 void markUrlsAsSelected(const QList
<QUrl
> &urls
);
176 * Marks the item indicated by \p url to be scrolled to and as the
177 * current item after directory DolphinView::url() has been loaded.
179 void markUrlAsCurrent(const QUrl
& url
);
182 * All items that match the regular expression \a regexp will get selected
183 * if \a enabled is true and deselected if \a enabled is false.
185 * Note that to match the whole string the pattern should be anchored:
186 * - you can anchor the pattern with QRegularExpression::anchoredPattern()
187 * - if you use QRegularExpresssion::wildcardToRegularExpression(), don't use
188 * QRegularExpression::anchoredPattern() as the former already returns an
191 void selectItems(const QRegularExpression
®exp
, bool enabled
);
194 * Sets the zoom level to \a level. It is assured that the used
195 * level is adjusted to be inside the range ZoomLevelInfo::minimumLevel() and
196 * ZoomLevelInfo::maximumLevel().
198 void setZoomLevel(int level
);
199 int zoomLevel() const;
202 * Resets the view's icon size to the default value
204 void resetZoomLevel();
206 void setSortRole(const QByteArray
& role
);
207 QByteArray
sortRole() const;
209 void setSortOrder(Qt::SortOrder order
);
210 Qt::SortOrder
sortOrder() const;
212 /** Sets a separate sorting with folders first (true) or a mixed sorting of files and folders (false). */
213 void setSortFoldersFirst(bool foldersFirst
);
214 bool sortFoldersFirst() const;
216 /** Sets a separate sorting with hidden files and folders last (true) or not (false). */
217 void setSortHiddenLast(bool hiddenLast
);
218 bool sortHiddenLast() const;
220 /** Sets the additional information which should be shown for the items. */
221 void setVisibleRoles(const QList
<QByteArray
>& roles
);
223 /** Returns the additional information which should be shown for the items. */
224 QList
<QByteArray
> visibleRoles() const;
229 * Refreshes the view to get synchronized with the settings (e.g. icons size,
235 * Saves the current settings (e.g. icons size, font, ..).
237 void writeSettings();
240 * Filters the currently shown items by \a nameFilter. All items
241 * which contain the given filter string will be shown.
243 void setNameFilter(const QString
& nameFilter
);
244 QString
nameFilter() const;
247 * Filters the currently shown items by \a filters. All items
248 * whose content-type matches those given by the list of filters
251 void setMimeTypeFilters(const QStringList
& filters
);
252 QStringList
mimeTypeFilters() const;
255 * Tells the view to generate an updated status bar text. The result
256 * is returned through the statusBarTextChanged(QString statusBarText) signal.
257 * It will carry a textual representation of the state of the current
258 * folder or selected items, suitable for use in the status bar.
259 * Any pending requests of status bar text are killed.
261 void requestStatusBarText();
264 * Returns the version control actions that are provided for the items \p items.
265 * Usually the actions are presented in the context menu.
267 QList
<QAction
*> versionControlActions(const KFileItemList
& items
) const;
270 * Returns the state of the paste action:
271 * first is whether the action should be enabled
272 * second is the text for the action
274 QPair
<bool, QString
> pasteInfo() const;
277 * If \a tabsForFiles is true, the signal tabRequested() will also
278 * emitted also for files. Per default tabs for files is disabled
279 * and hence the signal tabRequested() will only be emitted for
282 void setTabsForFilesEnabled(bool tabsForFiles
);
283 bool isTabsForFilesEnabled() const;
286 * Returns true if the current view allows folders to be expanded,
287 * i.e. presents a hierarchical view to the user.
289 bool itemsExpandable() const;
292 * Restores the view state (current item, contents position, details view expansion state)
294 void restoreState(QDataStream
& stream
);
297 * Saves the view state (current item, contents position, details view expansion state)
299 void saveState(QDataStream
& stream
);
302 * Returns the root item which represents the current URL.
304 KFileItem
rootItem() const;
307 * Sets a context that is used for remembering the view-properties.
308 * Per default the context is empty and the path of the currently set URL
309 * is used for remembering the view-properties. Setting a custom context
310 * makes sense if specific types of URLs (e.g. search-URLs) should
311 * share common view-properties.
313 void setViewPropertiesContext(const QString
& context
);
314 QString
viewPropertiesContext() const;
317 * Checks if the given \a item can be opened as folder (e.g. archives).
318 * This function will also adjust the \a url (e.g. change the protocol).
319 * @return a valid and adjusted url if the item can be opened as folder,
320 * otherwise return an empty url.
322 static QUrl
openItemAsFolderUrl(const KFileItem
& item
, const bool browseThroughArchives
= true);
325 * Hides tooltip displayed over element.
327 void hideToolTip(const ToolTipManager::HideBehavior behavior
= ToolTipManager::HideBehavior::Later
);
331 * Changes the directory to \a url. If the current directory is equal to
332 * \a url, nothing will be done (use DolphinView::reload() instead).
334 void setUrl(const QUrl
& url
);
338 * @see DolphinView::selectedItems()
343 * Inverts the current selection: selected items get unselected,
344 * unselected items get selected.
345 * @see DolphinView::selectedItems()
347 void invertSelection();
349 void clearSelection();
352 * Triggers the renaming of the currently selected items, where
353 * the user must input a new name for the items.
355 void renameSelectedItems();
358 * Moves all selected items to the trash.
360 void trashSelectedItems();
363 * Deletes all selected items.
365 void deleteSelectedItems();
368 * Copies all selected items to the clipboard and marks
371 void cutSelectedItemsToClipboard();
373 /** Copies all selected items to the clipboard. */
374 void copySelectedItemsToClipboard();
377 * Copies all selected items to @p destinationUrl.
379 void copySelectedItems(const KFileItemList
&selection
, const QUrl
&destinationUrl
);
382 * Moves all selected items to @p destinationUrl.
384 void moveSelectedItems(const KFileItemList
&selection
, const QUrl
&destinationUrl
);
386 /** Pastes the clipboard data to this view. */
390 * Pastes the clipboard data into the currently selected
391 * folder. If the current selection is not exactly one folder, no
392 * paste operation is done.
394 void pasteIntoFolder();
397 * Copies the path of the first selected KFileItem into Clipboard.
399 void copyPathToClipboard();
402 * Creates duplicates of selected items, appending "copy"
405 void duplicateSelectedItems();
408 * Handles a drop of @p dropEvent onto widget @p dropWidget and destination @p destUrl
410 void dropUrls(const QUrl
&destUrl
, QDropEvent
*dropEvent
, QWidget
*dropWidget
);
415 * Applies the state that has been restored by restoreViewState()
418 void updateViewState();
420 /** Activates the view if the item list container gets focus. */
421 bool eventFilter(QObject
* watched
, QEvent
* event
) override
;
425 * Is emitted if the view has been activated by e. g. a mouse click.
429 /** Is emitted if the URL of the view has been changed to \a url. */
430 void urlChanged(const QUrl
& url
);
433 * Is emitted when clicking on an item with the left mouse button.
435 void itemActivated(const KFileItem
&item
);
438 * Is emitted when multiple items have been activated by e. g.
439 * context menu open with.
441 void itemsActivated(const KFileItemList
&items
);
444 * Is emitted if items have been added or deleted.
446 void itemCountChanged();
449 * Is emitted if a new tab should be opened for the URL \a url.
451 void tabRequested(const QUrl
& url
);
454 * Is emitted if a new tab should be opened for the URL \a url and set as active.
456 void activeTabRequested(const QUrl
&url
);
459 * Is emitted if a new window should be opened for the URL \a url.
461 void windowRequested(const QUrl
&url
);
464 * Is emitted if the view mode (IconsView, DetailsView,
465 * PreviewsView) has been changed.
467 void modeChanged(DolphinView::Mode current
, DolphinView::Mode previous
);
469 /** Is emitted if the 'show preview' property has been changed. */
470 void previewsShownChanged(bool shown
);
472 /** Is emitted if the 'show hidden files' property has been changed. */
473 void hiddenFilesShownChanged(bool shown
);
475 /** Is emitted if the 'grouped sorting' property has been changed. */
476 void groupedSortingChanged(bool groupedSorting
);
478 /** Is emitted in reaction to a requestStatusBarText() call.
479 * @see requestStatusBarText() */
480 void statusBarTextChanged(QString statusBarText
);
482 /** Is emitted if the sorting by name, size or date has been changed. */
483 void sortRoleChanged(const QByteArray
& role
);
485 /** Is emitted if the sort order (ascending or descending) has been changed. */
486 void sortOrderChanged(Qt::SortOrder order
);
489 * Is emitted if the sorting of files and folders (separate with folders
490 * first or mixed) has been changed.
492 void sortFoldersFirstChanged(bool foldersFirst
);
495 * Is emitted if the sorting of hidden files has been changed.
497 void sortHiddenLastChanged(bool hiddenLast
);
499 /** Is emitted if the additional information shown for this view has been changed. */
500 void visibleRolesChanged(const QList
<QByteArray
>& current
,
501 const QList
<QByteArray
>& previous
);
503 /** Is emitted if the zoom level has been changed by zooming in or out. */
504 void zoomLevelChanged(int current
, int previous
);
507 * Is emitted if information of an item is requested to be shown e. g. in the panel.
508 * If item is null, no item information request is pending.
510 void requestItemInfo(const KFileItem
& item
);
513 * Is emitted whenever the selection has been changed.
515 void selectionChanged(const KFileItemList
& selection
);
518 * Is emitted if a context menu is requested for the item \a item,
519 * which is part of \a url. If the item is null, the context menu
520 * for the URL should be shown.
522 void requestContextMenu(const QPoint
& pos
,
523 const KFileItem
& item
,
524 const KFileItemList
&selectedItems
,
528 * Is emitted if an information message with the content \a msg
531 void infoMessage(const QString
& msg
);
534 * Is emitted if an error message with the content \a msg
537 void errorMessage(const QString
& msg
);
540 * Is emitted if an "operation completed" message with the content \a msg
543 void operationCompletedMessage(const QString
& msg
);
546 * Is emitted after DolphinView::setUrl() has been invoked and
547 * the current directory is loaded. If this signal is emitted,
548 * it is assured that the view contains already the correct root
549 * URL and property settings.
551 void directoryLoadingStarted();
554 * Is emitted after the directory triggered by DolphinView::setUrl()
557 void directoryLoadingCompleted();
560 * Is emitted after the directory loading triggered by DolphinView::setUrl()
563 void directoryLoadingCanceled();
566 * Is emitted after DolphinView::setUrl() has been invoked and provides
567 * the information how much percent of the current directory have been loaded.
569 void directoryLoadingProgress(int percent
);
572 * Is emitted if the sorting is done asynchronously and provides the
573 * progress information of the sorting.
575 void directorySortingProgress(int percent
);
578 * Emitted when the file-item-model emits redirection.
579 * Testcase: fish://localhost
581 void redirection(const QUrl
& oldUrl
, const QUrl
& newUrl
);
584 * Is emitted when the URL set by DolphinView::setUrl() represents a file.
585 * In this case no signal errorMessage() will be emitted.
587 void urlIsFileError(const QUrl
& url
);
590 * Is emitted when the write state of the folder has been changed. The application
591 * should disable all actions like "Create New..." that depend on the write
594 void writeStateChanged(bool isFolderWritable
);
597 * Is emitted if the URL should be changed to the previous URL of the
598 * history (e.g. because the "back"-mousebutton has been pressed).
600 void goBackRequested();
603 * Is emitted if the URL should be changed to the next URL of the
604 * history (e.g. because the "next"-mousebutton has been pressed).
606 void goForwardRequested();
609 * Is emitted when the selection mode is requested for the current view.
610 * This typically happens on press and hold.
611 * @see KItemListController::longPress()
613 void selectionModeRequested();
616 * Is emitted when the user wants to move the focus to another view.
618 void toggleActiveViewRequested();
621 * Is emitted when the user clicks a tag or a link
622 * in the metadata widget of a tooltip.
624 void urlActivated(const QUrl
& url
);
626 void goUpRequested();
628 void fileItemsChanged(const KFileItemList
&changedFileItems
);
631 /** Changes the zoom level if Control is pressed during a wheel event. */
632 void wheelEvent(QWheelEvent
* event
) override
;
634 void hideEvent(QHideEvent
* event
) override
;
635 bool event(QEvent
* event
) override
;
639 * Marks the view as active (DolphinView:isActive() will return true)
640 * and emits the 'activated' signal if it is not already active.
644 void slotItemActivated(int index
);
645 void slotItemsActivated(const KItemSet
&indexes
);
646 void slotItemMiddleClicked(int index
);
647 void slotItemContextMenuRequested(int index
, const QPointF
& pos
);
648 void slotViewContextMenuRequested(const QPointF
& pos
);
649 void slotHeaderContextMenuRequested(const QPointF
& pos
);
650 void slotHeaderColumnWidthChangeFinished(const QByteArray
& role
, qreal current
);
651 void slotSidePaddingWidthChanged(qreal width
);
652 void slotItemHovered(int index
);
653 void slotItemUnhovered(int index
);
654 void slotItemDropEvent(int index
, QGraphicsSceneDragDropEvent
* event
);
655 void slotModelChanged(KItemModelBase
* current
, KItemModelBase
* previous
);
656 void slotMouseButtonPressed(int itemIndex
, Qt::MouseButtons buttons
);
657 void slotRenameDialogRenamingFinished(const QList
<QUrl
>& urls
);
658 void slotSelectedItemTextPressed(int index
);
659 void slotCopyingDone(KIO::Job
*, const QUrl
&, const QUrl
&to
);
660 void slotIncreaseZoom();
661 void slotDecreaseZoom();
665 * Is called when new items get pasted or dropped.
667 void slotItemCreated(const QUrl
&url
);
669 * Is called after all pasted or dropped items have been copied to destination.
671 void slotJobResult(KJob
*job
);
674 * Emits the signal \a selectionChanged() with a small delay. This is
675 * because getting all file items for the selection can be an expensive
676 * operation. Fast selection changes are collected in this case and
677 * the signal is emitted only after no selection change has been done
678 * within a small delay.
680 void slotSelectionChanged(const KItemSet
& current
, const KItemSet
& previous
);
683 * Is called by emitDelayedSelectionChangedSignal() and emits the
684 * signal \a selectionChanged() with all selected file items as parameter.
686 void emitSelectionChangedSignal();
689 * Helper method for DolphinView::requestStatusBarText().
690 * Calculates the amount of folders and files and their total size in
691 * response to a KStatJob::result(), then calls emitStatusBarText().
692 * @see requestStatusBarText()
693 * @see emitStatusBarText()
695 void slotStatJobResult(KJob
*job
);
698 * Updates the view properties of the current URL to the
699 * sorting given by \a role.
701 void updateSortRole(const QByteArray
& role
);
704 * Updates the view properties of the current URL to the
705 * sort order given by \a order.
707 void updateSortOrder(Qt::SortOrder order
);
710 * Updates the view properties of the current URL to the
711 * sorting of files and folders (separate with folders first or mixed) given by \a foldersFirst.
713 void updateSortFoldersFirst(bool foldersFirst
);
716 * Updates the view properties of the current URL to the
717 * sorting of hidden files given by \a hiddenLast.
719 void updateSortHiddenLast(bool hiddenLast
);
722 * Indicates in the status bar that the delete operation
723 * of the job \a job has been finished.
725 void slotDeleteFileFinished(KJob
* job
);
728 * Indicates in the status bar that the trash operation
729 * of the job \a job has been finished.
731 void slotTrashFileFinished(KJob
* job
);
734 * Invoked when the rename job is done, for error handling.
736 void slotRenamingResult(KJob
* job
);
739 * Invoked when the file item model has started the loading
740 * of the directory specified by DolphinView::url().
742 void slotDirectoryLoadingStarted();
745 * Invoked when the file item model indicates that the loading of a directory has
746 * been completed. Assures that pasted items and renamed items get selected.
748 void slotDirectoryLoadingCompleted();
751 * Invoked when the file item model indicates that the loading of a directory has
754 void slotDirectoryLoadingCanceled();
757 * Is invoked when items of KFileItemModel have been changed.
759 void slotItemsChanged();
762 * Is invoked when the sort order has been changed by the user by clicking
763 * on a header item. The view properties of the directory will get updated.
765 void slotSortOrderChangedByHeader(Qt::SortOrder current
, Qt::SortOrder previous
);
768 * Is invoked when the sort role has been changed by the user by clicking
769 * on a header item. The view properties of the directory will get updated.
771 void slotSortRoleChangedByHeader(const QByteArray
& current
, const QByteArray
& previous
);
774 * Is invoked when the visible roles have been changed by the user by dragging
775 * a header item. The view properties of the directory will get updated.
777 void slotVisibleRolesChangedByHeader(const QList
<QByteArray
>& current
,
778 const QList
<QByteArray
>& previous
);
780 void slotRoleEditingCanceled();
781 void slotRoleEditingFinished(int index
, const QByteArray
& role
, const QVariant
& value
);
784 * Observes the item with the URL \a url. As soon as the directory
785 * model indicates that the item is available, the item will
786 * get selected and it is assured that the item stays visible.
788 void observeCreatedItem(const QUrl
&url
);
791 * Called when a redirection happens.
792 * Testcase: fish://localhost
794 void slotDirectoryRedirection(const QUrl
& oldUrl
, const QUrl
& newUrl
);
796 void slotTwoClicksRenamingTimerTimeout();
799 void loadDirectory(const QUrl
& url
, bool reload
= false);
802 * Applies the view properties which are defined by the current URL
803 * to the DolphinView properties. The view properties are read from a
804 * .directory file either in the current directory, or in the
805 * share/apps/dolphin/view_properties/ subfolder of the user's .kde folder.
807 void applyViewProperties();
810 * Applies the given view properties to the DolphinView.
812 void applyViewProperties(const ViewProperties
& props
);
815 * Applies the m_mode property to the corresponding
816 * itemlayout-property of the KItemListView.
818 void applyModeToView();
825 * Helper method for DolphinView::requestStatusBarText().
826 * Generates the status bar text from the parameters and
827 * then emits statusBarTextChanged().
828 * @param totalFileSize the sum of the sizes of the files
829 * @param selection if HasSelection is passed, the emitted status bar text will say
830 * that the folders and files which are counted here are selected.
832 void emitStatusBarText(const int folderCount
, const int fileCount
,
833 KIO::filesize_t totalFileSize
, const Selection selection
);
836 * Helper method for DolphinView::paste() and DolphinView::pasteIntoFolder().
837 * Pastes the clipboard data into the URL \a url.
839 void pasteToUrl(const QUrl
& url
);
842 * Returns a list of URLs for all selected items. The list is
843 * simplified, so that when the URLs are part of different tree
844 * levels, only the parent is returned.
846 QList
<QUrl
> simplifiedSelectedUrls() const;
849 * Returns the MIME data for all selected items.
851 QMimeData
* selectionMimeData() const;
854 * Updates m_isFolderWritable dependent on whether the folder represented by
855 * the current URL is writable. If the state has changed, the signal
856 * writeableStateChanged() will be emitted.
858 void updateWritableState();
861 * @return The current URL if no viewproperties-context is given (see
862 * DolphinView::viewPropertiesContext(), otherwise the context
865 QUrl
viewPropertiesUrl() const;
868 * Clears the selection and updates current item and selection according to the parameters
870 * @param current URL to be set as current
871 * @param selected list of selected items
873 void forceUrlsSelection(const QUrl
& current
, const QList
<QUrl
>& selected
);
875 void abortTwoClicksRenaming();
877 void updatePlaceholderLabel();
879 void tryShowNameToolTip(QHelpEvent
* event
);
882 void updatePalette();
883 void showLoadingPlaceholder();
887 bool m_assureVisibleCurrentIndex
;
888 bool m_isFolderWritable
;
889 bool m_dragging
; // True if a dragging is done. Required to be able to decide whether a
890 // tooltip may be shown when hovering an item.
892 enum class LoadingState
{
898 LoadingState m_loadingState
= LoadingState::Idle
;
901 QString m_viewPropertiesContext
;
903 QList
<QByteArray
> m_visibleRoles
;
905 QPointer
<KIO::StatJob
> m_statJobForStatusBarText
;
907 QVBoxLayout
* m_topLayout
;
909 KFileItemModel
* m_model
;
910 DolphinItemListView
* m_view
;
911 KItemListContainer
* m_container
;
913 ToolTipManager
* m_toolTipManager
;
915 QTimer
* m_selectionChangedTimer
;
917 QUrl m_currentItemUrl
; // Used for making the view to remember the current URL after F5
918 bool m_scrollToCurrentItem
; // Used for marking we need to scroll to current item or not
919 QPoint m_restoredContentsPosition
;
921 QList
<QUrl
> m_selectedUrls
; // Used for making the view to remember selections after F5
922 bool m_clearSelectionBeforeSelectingNewItems
;
923 bool m_markFirstNewlySelectedItemAsCurrent
;
925 VersionControlObserver
* m_versionControlObserver
;
927 QTimer
* m_twoClicksRenamingTimer
;
928 QUrl m_twoClicksRenamingItemUrl
;
929 QLabel
* m_placeholderLabel
;
930 QTimer
* m_showLoadingPlaceholderTimer
;
932 /// Used for selection mode. @see setSelectionMode()
933 std::unique_ptr
<QProxyStyle
> m_proxyStyle
;
936 friend class TestBase
;
937 friend class DolphinDetailsViewTest
;
938 friend class DolphinMainWindowTest
;
939 friend class DolphinPart
; // Accesses m_model
942 /// Allow using DolphinView::Mode in QVariant
943 Q_DECLARE_METATYPE(DolphinView::Mode
)
945 #endif // DOLPHINVIEW_H