From 34feb19dab19cfcc9943ddcea5d951a4c15a59f7 Mon Sep 17 00:00:00 2001 From: David Rosca Date: Fri, 2 May 2014 22:16:48 +0200 Subject: [PATCH] [Code] TabHelper: Rename m_pinnedTabBar to m_isPinnedTabBar [ci skip] --- src/lib/tabwidget/combotabbar.cpp | 12 ++++++------ src/lib/tabwidget/combotabbar.h | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/lib/tabwidget/combotabbar.cpp b/src/lib/tabwidget/combotabbar.cpp index 9cd18b4a6..f07a90884 100644 --- a/src/lib/tabwidget/combotabbar.cpp +++ b/src/lib/tabwidget/combotabbar.cpp @@ -49,8 +49,8 @@ ComboTabBar::ComboTabBar(QWidget* parent) { QObject::setObjectName(QSL("tabbarwidget")); - m_mainTabBar = new TabBarHelper(/*pinnedTabBar*/ false, this); - m_pinnedTabBar = new TabBarHelper(/*pinnedTabBar*/ true, this); + m_mainTabBar = new TabBarHelper(/*isPinnedTabBar*/ false, this); + m_pinnedTabBar = new TabBarHelper(/*isPinnedTabBar*/ true, this); m_mainTabBarWidget = new TabBarScrollWidget(m_mainTabBar, this); m_pinnedTabBarWidget = new TabBarScrollWidget(m_pinnedTabBar, this); @@ -918,7 +918,7 @@ void ComboTabBar::leaveEvent(QEvent* event) } -TabBarHelper::TabBarHelper(bool pinnedTabBar, ComboTabBar* comboTabBar) +TabBarHelper::TabBarHelper(bool isPinnedTabBar, ComboTabBar* comboTabBar) : QTabBar(comboTabBar) , m_comboTabBar(comboTabBar) , m_scrollArea(0) @@ -926,7 +926,7 @@ TabBarHelper::TabBarHelper(bool pinnedTabBar, ComboTabBar* comboTabBar) , m_pressedGlobalX(-1) , m_dragInProgress(false) , m_activeTabBar(false) - , m_pinnedTabBar(pinnedTabBar) + , m_isPinnedTabBar(isPinnedTabBar) , m_useFastTabSizeHint(false) , m_bluredBackground(false) { @@ -966,7 +966,7 @@ void TabBarHelper::setActiveTabBar(bool activate) if (!m_activeTabBar) { m_comboTabBar->m_blockCurrentChangedSignal = true; - setCurrentIndex(m_pinnedTabBar ? count() - 1 : 0); + setCurrentIndex(m_isPinnedTabBar ? count() - 1 : 0); m_comboTabBar->m_blockCurrentChangedSignal = false; } @@ -1211,7 +1211,7 @@ void TabBarHelper::initStyleOption(QStyleOptionTab* option, int tabIndex) const { QTabBar::initStyleOption(option, tabIndex); - int index = m_pinnedTabBar ? tabIndex : m_comboTabBar->pinnedTabsCount() + tabIndex; + int index = m_isPinnedTabBar ? tabIndex : m_comboTabBar->pinnedTabsCount() + tabIndex; if (m_comboTabBar->count() > 1) { if (index == 0) diff --git a/src/lib/tabwidget/combotabbar.h b/src/lib/tabwidget/combotabbar.h index b0b78a425..2379e8540 100644 --- a/src/lib/tabwidget/combotabbar.h +++ b/src/lib/tabwidget/combotabbar.h @@ -212,7 +212,7 @@ class QUPZILLA_EXPORT TabBarHelper : public QTabBar Q_OBJECT public: - explicit TabBarHelper(bool pinnedTabBar, ComboTabBar* comboTabBar); + explicit TabBarHelper(bool isPinnedTabBar, ComboTabBar* comboTabBar); void setTabButton(int index, QTabBar::ButtonPosition position, QWidget* widget); @@ -254,7 +254,7 @@ private: int m_pressedGlobalX; bool m_dragInProgress; bool m_activeTabBar; - bool m_pinnedTabBar; + bool m_isPinnedTabBar; bool m_useFastTabSizeHint; bool m_bluredBackground; };