diff options
| author | Peter Penz <[email protected]> | 2009-08-30 18:39:03 +0000 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2009-08-30 18:39:03 +0000 |
| commit | 05762d42ea91ea034086c67099cf9208f86c00ff (patch) | |
| tree | c7cd12caf603595821cd44f9be2266c82a5a9c0f /src/dolphincontroller.cpp | |
| parent | 55704b419eb3ac864b2218cbeca2a8ae921ea1e1 (diff) | |
Move the VersionControlObserver from the DolphinView to the ViewExtensionsFactory. This automatically enables also the column view to be able handling version controlled files.
svn path=/trunk/KDE/kdebase/apps/; revision=1017482
Diffstat (limited to 'src/dolphincontroller.cpp')
| -rw-r--r-- | src/dolphincontroller.cpp | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/src/dolphincontroller.cpp b/src/dolphincontroller.cpp index b3801bda8..a7c91def5 100644 --- a/src/dolphincontroller.cpp +++ b/src/dolphincontroller.cpp @@ -34,7 +34,8 @@ DolphinController::DolphinController(DolphinView* dolphinView) : m_nameFilter(), m_url(), m_dolphinView(dolphinView), - m_itemView(0) + m_itemView(0), + m_versionControlActions() { } @@ -144,6 +145,20 @@ void DolphinController::setZoomLevel(int level) } } +void DolphinController::setVersionControlActions(QList<QAction*> actions) +{ + m_versionControlActions = actions; +} + +QList<QAction*> DolphinController::versionControlActions(const KFileItemList& items) +{ + emit requestVersionControlActions(items); + // All view implementations are connected with the signal requestVersionControlActions() + // (see ViewExtensionFactory) and will invoke DolphinController::setVersionControlActions(), + // so that the context dependent actions can be returned. + return m_versionControlActions; +} + void DolphinController::handleKeyPressEvent(QKeyEvent* event) { Q_ASSERT(m_itemView != 0); |
