1
mirror of https://invent.kde.org/network/falkon.git synced 2024-12-20 18:56:34 +01:00

[ComboTabBar] Middle click on left/right buttons now scrolls to current tab

This commit is contained in:
nowrep 2014-01-01 15:42:30 +01:00
parent cf5abaddb0
commit 48079096c2

View File

@ -1122,6 +1122,7 @@ TabBarScrollWidget::TabBarScrollWidget(QTabBar* tabBar, QWidget* parent)
connect(m_leftScrollButton, SIGNAL(pressed()), this, SLOT(scrollStart())); connect(m_leftScrollButton, SIGNAL(pressed()), this, SLOT(scrollStart()));
connect(m_leftScrollButton, SIGNAL(released()), this, SLOT(scrollStop())); connect(m_leftScrollButton, SIGNAL(released()), this, SLOT(scrollStop()));
connect(m_leftScrollButton, SIGNAL(doubleClicked()), this, SLOT(scrollToLeftEdge())); connect(m_leftScrollButton, SIGNAL(doubleClicked()), this, SLOT(scrollToLeftEdge()));
connect(m_leftScrollButton, SIGNAL(middleMouseClicked()), this, SLOT(ensureVisible()));
m_rightScrollButton = new ToolButton(this); m_rightScrollButton = new ToolButton(this);
m_rightScrollButton->setAutoRaise(true); m_rightScrollButton->setAutoRaise(true);
@ -1129,6 +1130,7 @@ TabBarScrollWidget::TabBarScrollWidget(QTabBar* tabBar, QWidget* parent)
connect(m_rightScrollButton, SIGNAL(pressed()), this, SLOT(scrollStart())); connect(m_rightScrollButton, SIGNAL(pressed()), this, SLOT(scrollStart()));
connect(m_rightScrollButton, SIGNAL(released()), this, SLOT(scrollStop())); connect(m_rightScrollButton, SIGNAL(released()), this, SLOT(scrollStop()));
connect(m_rightScrollButton, SIGNAL(doubleClicked()), this, SLOT(scrollToRightEdge())); connect(m_rightScrollButton, SIGNAL(doubleClicked()), this, SLOT(scrollToRightEdge()));
connect(m_rightScrollButton, SIGNAL(middleMouseClicked()), this, SLOT(ensureVisible()));
m_leftLayout = new QHBoxLayout; m_leftLayout = new QHBoxLayout;
m_leftLayout->setSpacing(0); m_leftLayout->setSpacing(0);