[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdebase/apps/plasma/applets/folderview
From:       Aaron J. Seigo <aseigo () kde ! org>
Date:       2010-03-05 0:09:08
Message-ID: 1267747748.966789.2306.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 1099064 by aseigo:

if we are a containment and have no scrolling to do ... don't.
BUG:183599


 M  +4 -3      iconview.cpp  


--- trunk/KDE/kdebase/apps/plasma/applets/folderview/iconview.cpp #1099063:1099064
@@ -1846,8 +1846,6 @@
         m_pressedIndex = QModelIndex();
         m_buttonDownPos = pos;
 
-        const Plasma::Containment *parent = qobject_cast<Plasma::Containment*>(parentWidget());
-
         if (event->modifiers() & Qt::ControlModifier) {
             // Make the current selection persistent
             m_selectionModel->select(m_selectionModel->selection(), QItemSelectionModel::Select);
@@ -1982,7 +1980,10 @@
 
 void IconView::wheelEvent(QGraphicsSceneWheelEvent *event)
 {
-    if ((event->modifiers() & Qt::CTRL) || (event->orientation() == Qt::Horizontal)) {
+    Plasma::Containment *containment = qobject_cast<Plasma::Containment*>(parentWidget());
+    if ((containment && containment->isContainment() && !m_scrollBar->isVisible()) ||
+        (event->modifiers() & Qt::CTRL) ||
+        (event->orientation() == Qt::Horizontal)) {
         // Let the event propagate to the parent widget
         event->ignore();
         return;
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic