diff options
| author | Peter Penz <[email protected]> | 2008-01-11 11:37:28 +0000 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2008-01-11 11:37:28 +0000 |
| commit | 87dc8352d448126f4d7f1e93c574277845cf4bef (patch) | |
| tree | c35f6293a7142e872c456923f1526ffdb5c5c7b0 /src/dolphincolumnwidget.h | |
| parent | 09c62f7c6a4f13659fb87cf2e4e8f23ca4125710 (diff) | |
Up to now DolphinView and ColumnWidget contained a lot of code duplication regarding generating previews and the dimming of cut items. This has been refactored by introducing an IconManager which takes care itself about generating a preview and dimming cut items. This also allows improving the speed of previews in (near) future (at the moment showing previews from the cache is a lot slower than in KDE 3...).
svn path=/trunk/KDE/kdebase/apps/; revision=759864
Diffstat (limited to 'src/dolphincolumnwidget.h')
| -rw-r--r-- | src/dolphincolumnwidget.h | 33 |
1 files changed, 2 insertions, 31 deletions
diff --git a/src/dolphincolumnwidget.h b/src/dolphincolumnwidget.h index 870246269..de14576e7 100644 --- a/src/dolphincolumnwidget.h +++ b/src/dolphincolumnwidget.h @@ -30,15 +30,12 @@ class DolphinColumnView; class DolphinModel; class DolphinSortFilterProxyModel; +class IconManager; class KDirLister; class KJob; class KFileItem; class KFileItemList; class QPixmap; -namespace KIO -{ - class PreviewJob; -} /** * Represents one column inside the DolphinColumnView and has been @@ -118,27 +115,8 @@ private slots: */ void triggerItem(const QModelIndex& index); - /** - * 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 replaceIcon(const KFileItem& item, const QPixmap& pixmap); - void slotEntered(const QModelIndex& index); - /** - * Is invoked when the preview job has been finished and - * set m_previewJob to 0. - */ - void slotPreviewJobFinished(KJob* job); - private: /** Used by DolphinColumnWidget::setActive(). */ void activate(); @@ -146,17 +124,10 @@ private: /** Used by DolphinColumnWidget::setActive(). */ void deactivate(); - /** - * Returns true, if the item \a item has been cut into - * the clipboard. - */ - bool isCutItem(const KFileItem& item) const; - KFileItem itemForIndex(const QModelIndex& index) const; private: bool m_active; - bool m_showPreview; DolphinColumnView* m_view; KUrl m_url; // URL of the directory that is shown KUrl m_childUrl; // URL of the next column that is shown @@ -168,7 +139,7 @@ private: DolphinModel* m_dolphinModel; DolphinSortFilterProxyModel* m_proxyModel; - KIO::PreviewJob* m_previewJob; + IconManager* m_iconManager; bool m_dragging; // TODO: remove this property when the issue #160611 is solved in Qt 4.4 QRect m_dropRect; // TODO: remove this property when the issue #160611 is solved in Qt 4.4 |
