aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/coreplugin/fancyactionbar.cpp
diff options
context:
space:
mode:
authorOrgad Shaneh <orgad.shaneh@audiocodes.com>2015-02-03 23:48:19 +0200
committerhjk <hjk@theqtcompany.com>2015-02-06 09:06:18 +0000
commit428565cb028a72d7ee82a6c3dd859c08c34b56a7 (patch)
tree4f9fcca395af5aa719d1c5fda04f991c6d024500 /src/plugins/coreplugin/fancyactionbar.cpp
parentf7835eb5f2ab8e5d7dc40a58740956b4b1b6a08c (diff)
Core: Remove unneeded qualifications
Mostly done using the following ruby script: Dir.glob('**/*.cpp').each { |file| next if file =~ %r{src/shared/qbs|/qmljs/} s = File.read(file) s.scan(/^using namespace (.*);$/) { ns = $1 t = s.gsub(/^(.*)\b#{ns}::((?!Const)[A-Z])/) { |m| before = $1 char = $2 if before =~ /"|\/\/|\\|using|SIGNAL|SLOT|Q_/ m else before + char end } if t != s puts file File.open(file, 'w').write(t) end } } Change-Id: I5c6690f51488bf8ca3610ba9fb11e6e5fd814aaa Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com> Reviewed-by: hjk <hjk@theqtcompany.com>
Diffstat (limited to 'src/plugins/coreplugin/fancyactionbar.cpp')
-rw-r--r--src/plugins/coreplugin/fancyactionbar.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/plugins/coreplugin/fancyactionbar.cpp b/src/plugins/coreplugin/fancyactionbar.cpp
index 2c9acba5ac..4b9a6ccd2f 100644
--- a/src/plugins/coreplugin/fancyactionbar.cpp
+++ b/src/plugins/coreplugin/fancyactionbar.cpp
@@ -142,7 +142,7 @@ void FancyToolButton::paintEvent(QPaintEvent *event)
bool isTitledAction = defaultAction()->property("titledAction").toBool();
- if (!Utils::HostOsInfo::isMacHost() // Mac UIs usually don't hover
+ if (!HostOsInfo::isMacHost() // Mac UIs usually don't hover
&& m_fader > 0 && isEnabled() && !isDown() && !isChecked()) {
painter.save();
const QColor hoverColor = creatorTheme()->color(Theme::FancyToolButtonHoverColor);
@@ -189,7 +189,7 @@ void FancyToolButton::paintEvent(QPaintEvent *event)
QFont normalFont(painter.font());
QRect centerRect = rect();
- normalFont.setPointSizeF(Utils::StyleHelper::sidebarFontSize());
+ normalFont.setPointSizeF(StyleHelper::sidebarFontSize());
QFont boldFont(normalFont);
boldFont.setBold(true);
QFontMetrics fm(normalFont);
@@ -204,7 +204,7 @@ void FancyToolButton::paintEvent(QPaintEvent *event)
centerRect.adjust(0, 0, 0, -lineHeight*2 - 4);
iconRect.moveCenter(centerRect.center());
- Utils::StyleHelper::drawIconWithShadow(icon(), iconRect, &painter, isEnabled() ? QIcon::Normal : QIcon::Disabled);
+ StyleHelper::drawIconWithShadow(icon(), iconRect, &painter, isEnabled() ? QIcon::Normal : QIcon::Disabled);
painter.setFont(normalFont);
QPoint textOffset = centerRect.center() - QPoint(iconRect.width()/2, iconRect.height()/2);
@@ -261,11 +261,11 @@ void FancyToolButton::paintEvent(QPaintEvent *event)
QStyleOption opt;
opt.initFrom(this);
opt.rect = rect().adjusted(rect().width() - 16, 0, -8, 0);
- Utils::StyleHelper::drawArrow(QStyle::PE_IndicatorArrowRight, &painter, &opt);
+ StyleHelper::drawArrow(QStyle::PE_IndicatorArrowRight, &painter, &opt);
}
} else {
iconRect.moveCenter(rect().center());
- Utils::StyleHelper::drawIconWithShadow(icon(), iconRect, &painter, isEnabled() ? QIcon::Normal : QIcon::Disabled);
+ StyleHelper::drawIconWithShadow(icon(), iconRect, &painter, isEnabled() ? QIcon::Normal : QIcon::Disabled);
}
}
@@ -279,8 +279,8 @@ void FancyActionBar::paintEvent(QPaintEvent *event)
painter.fillRect(event->rect(), creatorTheme()->color(Theme::FancyTabBarBackgroundColor));
}
- QColor light = Utils::StyleHelper::sidebarHighlight();
- QColor dark = Utils::StyleHelper::sidebarShadow();
+ QColor light = StyleHelper::sidebarHighlight();
+ QColor dark = StyleHelper::sidebarShadow();
painter.setPen(dark);
painter.drawLine(rect().topLeft(), rect().topRight());
painter.setPen(light);
@@ -292,7 +292,7 @@ QSize FancyToolButton::sizeHint() const
QSizeF buttonSize = iconSize().expandedTo(QSize(64, 38));
if (defaultAction()->property("titledAction").toBool()) {
QFont boldFont(font());
- boldFont.setPointSizeF(Utils::StyleHelper::sidebarFontSize());
+ boldFont.setPointSizeF(StyleHelper::sidebarFontSize());
boldFont.setBold(true);
QFontMetrics fm(boldFont);
qreal lineHeight = fm.height();