1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-19 04:11:46 +02:00

* StyleHelper doesn't exist anymore.

This commit is contained in:
Christian Muehlhaeuser
2013-04-29 18:15:12 +02:00
parent 55fd82bfd4
commit 4a221a79a4
10 changed files with 29 additions and 30 deletions

View File

@@ -106,7 +106,7 @@ set( libGuiSources
utils/ShortenedLinkParser.cpp
utils/SoundcloudParser.cpp
utils/ExfmParser.cpp
utils/StyleHelper.cpp
utils/TomahawkStyle.cpp
utils/DropJobNotifier.cpp
utils/ProxyStyle.cpp
utils/TomahawkUtilsGui.cpp

View File

@@ -21,7 +21,7 @@
#include <QGraphicsLinearLayout>
#include "PlaylistInterface.h"
#include "utils/StyleHelper.h"
#include "utils/TomahawkStyle.h"
#include "utils/TomahawkUtilsGui.h"
using namespace Tomahawk;
@@ -33,8 +33,8 @@ ContextProxyPage::paint( QPainter* painter, const QStyleOptionGraphicsItem* opti
painter->save();
painter->setRenderHint( QPainter::Antialiasing, true );
painter->setPen( StyleHelper::headerHighlightColor() );
painter->setBrush( StyleHelper::headerHighlightColor() );
painter->setPen( TomahawkStyle::headerHighlightColor() );
painter->setBrush( TomahawkStyle::headerHighlightColor() );
painter->drawRoundedRect( option->rect, 4.0, 4.0 );
QFont f( font() );

View File

@@ -31,7 +31,7 @@
#include "Source.h"
#include "utils/StyleHelper.h"
#include "utils/TomahawkStyle.h"
#include "utils/TomahawkUtilsGui.h"
#define ANIMATION_TIME 450

View File

@@ -19,9 +19,9 @@
#include "Breadcrumb.h"
#include "BreadcrumbButton.h"
#include "utils/StyleHelper.h"
#include "utils/Logger.h"
#include "utils/TomahawkStyle.h"
#include "utils/TomahawkUtilsGui.h"
#include "utils/Logger.h"
#include <QStylePainter>
#include <QPushButton>
@@ -83,7 +83,7 @@ void
Breadcrumb::paintEvent( QPaintEvent* )
{
QStylePainter p( this );
StyleHelper::horizontalHeader( &p, rect() );
TomahawkStyle::horizontalHeader( &p, rect() );
}

View File

@@ -21,7 +21,7 @@
#include "Breadcrumb.h"
#include "ComboBox.h"
#include "utils/StyleHelper.h"
#include "utils/TomahawkStyle.h"
#include "utils/TomahawkUtilsGui.h"
#include "utils/Logger.h"
@@ -107,7 +107,7 @@ BreadcrumbButton::paintEvent( QPaintEvent* )
{
QPainter p( this );
StyleHelper::horizontalHeader( &p, rect() ); // draw the background
TomahawkStyle::horizontalHeader( &p, rect() ); // draw the background
m_arrow->setVisible( hasChildren() );
}

View File

@@ -18,7 +18,7 @@
#include "ComboBox.h"
#include "utils/StyleHelper.h"
#include "utils/TomahawkStyle.h"
#include "utils/TomahawkUtilsGui.h"
#include "utils/Logger.h"
@@ -56,7 +56,7 @@ ComboBox::paintEvent( QPaintEvent* )
QRect r = cb.rect;
r.setHeight( TomahawkUtils::defaultFontHeight() + 8 );
StyleHelper::horizontalHeader( &p, r );
TomahawkStyle::horizontalHeader( &p, r );
if ( cb.state & QStyle::State_MouseOver )
{
@@ -68,7 +68,7 @@ ComboBox::paintEvent( QPaintEvent* )
highlightRect.setSize( hS );
highlightRect.translate( 0, 2 );
p.setRenderHint( QPainter::Antialiasing );
p.setBrush( StyleHelper::headerHighlightColor() );
p.setBrush( TomahawkStyle::headerHighlightColor() );
p.drawRoundedRect( highlightRect, 10.0, 10.0 );
p.restore();
}
@@ -77,7 +77,7 @@ ComboBox::paintEvent( QPaintEvent* )
QTextOption to( Qt::AlignVCenter );
r.adjust( 8, 0, -8, 0 );
p.setPen( Qt::white );
p.setBrush( StyleHelper::headerTextColor() );
p.setBrush( TomahawkStyle::headerTextColor() );
p.drawText( r, cb.currentText, to );
bool reverse = cb.direction == Qt::RightToLeft;
@@ -88,6 +88,6 @@ ComboBox::paintEvent( QPaintEvent* )
QStyleOption arrowOpt = cb;
arrowOpt.rect = arrowRect;
StyleHelper::drawArrow( QStyle::PE_IndicatorArrowDown, &p, &arrowOpt );
TomahawkStyle::drawArrow( QStyle::PE_IndicatorArrowDown, &p, &arrowOpt );
p.restore();
}

View File

@@ -23,7 +23,7 @@
#include <QMouseEvent>
#include "utils/Logger.h"
#include "utils/StyleHelper.h"
#include "utils/TomahawkStyle.h"
#include "utils/TomahawkUtilsGui.h"
@@ -59,11 +59,11 @@ void
HeaderLabel::mousePressEvent( QMouseEvent* event )
{
QFrame::mousePressEvent( event );
if ( !m_moved )
{
m_time.start();
m_pressed = true;
m_dragPoint = event->pos();
}
@@ -103,10 +103,10 @@ HeaderLabel::paintEvent( QPaintEvent* /* event */ )
{
QPainter p( this );
QRect r = contentsRect();
StyleHelper::horizontalHeader( &p, r );
TomahawkStyle::horizontalHeader( &p, r );
QTextOption to( alignment() | Qt::AlignVCenter );
r.adjust( 8, 0, -8, 0 );
p.setPen( StyleHelper::headerTextColor() );
p.setPen( TomahawkStyle::headerTextColor() );
p.drawText( r, text(), to );
}

View File

@@ -18,7 +18,7 @@
#include "HeaderWidget.h"
#include "utils/StyleHelper.h"
#include "utils/TomahawkStyle.h"
#include <QStyle>
#include <QStylePainter>
@@ -42,5 +42,5 @@ HeaderWidget::paintEvent( QPaintEvent* /* event */ )
QStylePainter p( this );
QRect r = rect();
StyleHelper::horizontalHeader( &p, r );
TomahawkStyle::horizontalHeader( &p, r );
}

View File

@@ -20,7 +20,7 @@
#include "ToggleButton.h"
#include "widgets/HeaderLabel.h"
#include "utils/StyleHelper.h"
#include "utils/TomahawkStyle.h"
#include "utils/TomahawkUtilsGui.h"
#include <QStylePainter>
@@ -71,12 +71,12 @@ void
ToggleButton::paintEvent( QPaintEvent* event )
{
Q_UNUSED( event );
QPainter p( this );
p.save();
QRect r = contentsRect();
StyleHelper::horizontalHeader( &p, r );
TomahawkStyle::horizontalHeader( &p, r );
p.restore();
p.save();
@@ -89,15 +89,15 @@ ToggleButton::paintEvent( QPaintEvent* event )
if ( isChecked() )
{
p.setBrush( StyleHelper::headerHighlightColor() );
p.setBrush( TomahawkStyle::headerHighlightColor() );
}
else if ( false )
{
p.setBrush( StyleHelper::headerLowerColor() );
p.setBrush( TomahawkStyle::headerLowerColor() );
}
else
{
p.setBrush( StyleHelper::headerUpperColor() );
p.setBrush( TomahawkStyle::headerUpperColor() );
}
p.drawRoundedRect( highlightRect, 4.0, 4.0 );
@@ -105,7 +105,7 @@ ToggleButton::paintEvent( QPaintEvent* event )
QTextOption to( Qt::AlignCenter );
r.adjust( 8, 0, -8, 0 );
p.setBrush( StyleHelper::headerTextColor() );
p.setBrush( TomahawkStyle::headerTextColor() );
p.drawText( r, text(), to );
p.restore();

View File

@@ -37,7 +37,6 @@
#include "GlobalActionManager.h"
#include "Pipeline.h"
#include "MetaPlaylistInterface.h"
#include "utils/StyleHelper.h"
#include "utils/TomahawkUtilsGui.h"
#include "utils/Logger.h"