]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Fixed issue that Ctrl+A sometimes did not result in an update of the Information...
authorPeter Penz <peter.penz19@gmail.com>
Wed, 6 Jan 2010 16:56:01 +0000 (16:56 +0000)
committerPeter Penz <peter.penz19@gmail.com>
Wed, 6 Jan 2010 16:56:01 +0000 (16:56 +0000)
svn path=/trunk/KDE/kdebase/apps/; revision=1070740

src/dolphincontroller.cpp
src/dolphincontroller.h
src/dolphinview.cpp
src/panels/information/informationpanel.cpp
src/viewextensionsfactory.cpp

index 89d6509ca42c0e9edc62af903649bd6af0b0d171..408abd501ad72a86bf1ff6af745d90fdb595ec9c 100644 (file)
@@ -255,11 +255,6 @@ void DolphinController::emitViewportEntered()
     emit viewportEntered();
 }
 
-void DolphinController::emitSelectionChanged()
-{
-    emit selectionChanged();
-}
-
 void DolphinController::updateMouseButtonState()
 {
     m_mouseButtons = QApplication::mouseButtons();
index 8aebdcac47338396b22b57132d0e36b4db6d18b1..d1eba97a1dadea557b4eff6c4066b047c087b6a4 100644 (file)
@@ -62,7 +62,6 @@ class QPoint;
  * - handleKeyPressEvent()
  * - emitItemEntered()
  * - emitViewportEntered()
- * - emitSelectionChanged()
  * - replaceUrlByClipboard()
  * - hideToolTip()
  * - setVersionControlActions()
@@ -293,12 +292,6 @@ public slots:
      */
     void emitViewportEntered();
 
-    /**
-     * Emits the signal selectionChanged(). The method should be invoked by
-     * the view implementation whenever the selection has been changed.
-     */
-    void emitSelectionChanged();
-
 signals:
     /**
      * Is emitted if the URL for the Dolphin controller has been changed
@@ -407,13 +400,6 @@ signals:
      */
     void viewportEntered();
 
-    /**
-     * Is emitted whenever the selection of the view implementation
-     * has been changed (see emitSelectionChanged()). The abstract
-     * Dolphin view connects to this signal.
-     */
-    void selectionChanged();
-
     /**
      * Is emitted if the view should respect the name filter \a nameFilter. The view
      * implementation must connect to this signal if it supports name filters.
index c0d700eb5999b33526685b8a16053aa1f3506521..e70cd446b18740366a85e676db217e40a9613af5 100644 (file)
@@ -1357,8 +1357,6 @@ void DolphinView::createView()
     view->viewport()->installEventFilter(this);
 
     m_controller->setItemView(view);
-    connect(m_controller, SIGNAL(selectionChanged()),
-            this, SLOT(emitDelayedSelectionChangedSignal()));
 
     // When changing the view mode, the selection is lost due to reinstantiating
     // a new item view with a custom selection model. Pass the ownership of the
@@ -1369,6 +1367,8 @@ void DolphinView::createView()
         m_selectionModel = view->selectionModel();
     }
     m_selectionModel->setParent(this);
+    connect(view->selectionModel(), SIGNAL(selectionChanged(const QItemSelection&, const QItemSelection&)),
+            this, SLOT(emitDelayedSelectionChangedSignal()));
 
     connect(view->verticalScrollBar(), SIGNAL(valueChanged(int)),
             this, SLOT(emitContentsMoved()));
index 05b1f89de9dce6914aeff692bb44758371dfca28..3d2163baaa32bc0e193adc695a53245964f3227d 100644 (file)
@@ -171,9 +171,8 @@ void InformationPanel::showItemInfo()
         } else {
             // no item is hovered and no selection has been done: provide
             // an item for the directory represented by m_shownUrl
-            m_fileItem = KFileItem(KFileItem::Unknown, KFileItem::Unknown, m_shownUrl);
-            m_fileItem.refresh();
-            item = m_fileItem;
+            item = KFileItem(KFileItem::Unknown, KFileItem::Unknown, m_shownUrl);
+            item.refresh();
         }
 
         m_content->showItem(item);
index 86311e28d745a057597f416764ef0d885aa98501..ce997bf8b5d87f73d00bc5c5e7497a637b07ecdf 100644 (file)
@@ -112,10 +112,6 @@ ViewExtensionsFactory::ViewExtensionsFactory(QAbstractItemView* view,
     connect(dolphinView, SIGNAL(sortFoldersFirstChanged(bool)),
             this, SLOT(slotSortFoldersFirstChanged(bool)));
 
-    // inform the controller about selection changes
-    connect(view->selectionModel(), SIGNAL(selectionChanged(const QItemSelection&, const QItemSelection&)),
-            controller, SLOT(emitSelectionChanged()));
-
     // Give the view the ability to auto-expand its directories on hovering
     // (the column view takes care about this itself). If the details view
     // uses expandable folders, the auto-expanding should be used always.