]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/selectionmode/topbar.cpp
Make touch tap to select items work in selection mode
[dolphin.git] / src / selectionmode / topbar.cpp
index d783c76caaa017754a05acbb1eeb7e70425b9fcb..0a5d3f2cf2b27af24031c4cd90fe0c4a9ce0e03d 100644 (file)
@@ -42,7 +42,7 @@ TopBar::TopBar(QWidget *parent) :
     fillParentLayout->setContentsMargins(0, 0, 0, 0);
 
     // Put the contents into a QScrollArea. This prevents increasing the view width
-    // in case that not enough width for the contents is available. (this trick is also used in selectionmodebottombar.cpp.)
+    // in case that not enough width for the contents is available. (this trick is also used in bottombar.cpp.)
     auto scrollArea = new QScrollArea(this);
     fillParentLayout->addWidget(scrollArea);
     scrollArea->setFrameShape(QFrame::NoFrame);
@@ -70,7 +70,7 @@ TopBar::TopBar(QWidget *parent) :
     m_closeButton->setAccessibleName(m_closeButton->toolTip());
     m_closeButton->setFlat(true);
     connect(m_closeButton, &QAbstractButton::pressed,
-            this, &TopBar::leaveSelectionModeRequested);
+            this, &TopBar::selectionModeLeavingRequested);
 
     QHBoxLayout *layout = new QHBoxLayout(contentsContainer);
     auto contentsMargins = layout->contentsMargins();
@@ -111,9 +111,10 @@ void TopBar::setVisible(bool visible, Animated animated)
     m_heightAnimation->start(QAbstractAnimation::DeleteWhenStopped);
 }
 
-void TopBar::resizeEvent(QResizeEvent */* resizeEvent */)
+void TopBar::resizeEvent(QResizeEvent *resizeEvent)
 {
     updateLabelString();
+    return QWidget::resizeEvent(resizeEvent);
 }
 
 void TopBar::updateLabelString()