X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/f42d1d2c02eb7e608564f137ce97f9424d9c49f6..b5cc2a6924cfd8f59611d3cec2edbb00a08b4ff1:/src/dolphinview.h diff --git a/src/dolphinview.h b/src/dolphinview.h index 875b6b114..5cfd7904d 100644 --- a/src/dolphinview.h +++ b/src/dolphinview.h @@ -327,11 +327,6 @@ public: /** Reloads the current directory. */ void reload(); - /** - * Declare this View as the activeview of the mainWindow() - */ - void declareViewActive(); - public slots: /** * Popups the filter bar above the status bar if \a show is true. @@ -351,6 +346,9 @@ public slots: */ void requestActivation(); + /** Applies an item effect to all cut items of the clipboard. */ + void updateCutItems(); + signals: /** Is emitted if URL of the view has been changed to \a url. */ void urlChanged(const KUrl& url); @@ -409,6 +407,19 @@ private slots: */ void updateItemCount(); + /** + * Generates a preview image for each file item in \a items. + * The current preview settings (maximum size, 'Show Preview' menu) + * are respected. + */ + void generatePreviews(const KFileItemList& items); + + /** + * Replaces the icon of the item \a item by the preview pixmap + * \a pixmap. + */ + void showPreview(const KFileItem* item, const QPixmap& pixmap); + /** * Restores the x- and y-position of the contents if the * current view is part of the history. @@ -430,8 +441,27 @@ private slots: */ void changeNameFilter(const QString& nameFilter); - void openContextMenu(const QPoint& pos, const QPoint& globalPos); + /** + * Opens the context menu on position \a pos. The position + * is used to check whether the context menu is related to an + * item or to the viewport. + */ + void openContextMenu(const QPoint& pos); + + /** + * Drops the URLs \a urls at the position \a pos. + * The position is used to check whether the dropping + * is done above an item or above the viewport. + */ + void dropUrls(const KUrl::List& urls, + const QPoint& pos); + /** + * Drops the URLs \a urls at the + * destination \a destination. + */ + void dropUrls(const KUrl::List& urls, + const KUrl& destination); /** * Updates the view properties of the current URL to the * sorting given by \a sorting. @@ -444,6 +474,18 @@ private slots: */ void updateSortOrder(Qt::SortOrder order); + /** + * Emits the signal contentsMoved with the current coordinates + * of the viewport as parameters. + */ + void emitContentsMoved(); + + /** + * Updates the activation state of the view by checking whether + * the currently active view is this view. + */ + void updateActivationState(); + private: void startDirLister(const KUrl& url, bool reload = false); @@ -465,11 +507,6 @@ private: */ void createView(); - /** - * Returns the column index used in the KDirModel depending on \a sorting. - */ - int columnIndex(Sorting sorting) const; - /** * Selects all items by using the selection flags \a flags. This is a helper * method for the slots DolphinView::selectAll() and DolphinView::invertSelection(). @@ -482,6 +519,18 @@ private: */ QAbstractItemView* itemView() const; + /** + * Returns true if the index is valid and represents + * the column KDirModel::Name. + */ + bool isValidNameIndex(const QModelIndex& index) const; + + /** + * Returns true, if the item \a item has been cut into + * the clipboard. + */ + bool isCutItem(const KFileItem& item) const; + private: bool m_showProgress; Mode m_mode;