Clang: reduce warnings
This commit is contained in:
parent
2add7f6f86
commit
6a3aa01564
@ -39,6 +39,7 @@ static int s_defaultFontHeight = 0;
|
|||||||
QPixmap
|
QPixmap
|
||||||
defaultPixmap( ImageType type, ImageMode mode, const QSize& size )
|
defaultPixmap( ImageType type, ImageMode mode, const QSize& size )
|
||||||
{
|
{
|
||||||
|
Q_UNUSED( mode );
|
||||||
QPixmap pixmap;
|
QPixmap pixmap;
|
||||||
|
|
||||||
switch ( type )
|
switch ( type )
|
||||||
@ -106,9 +107,6 @@ defaultPixmap( ImageType type, ImageMode mode, const QSize& size )
|
|||||||
case Squid:
|
case Squid:
|
||||||
pixmap = ImageRegistry::instance()->pixmap( RESPATH "images/squid.svg", size );
|
pixmap = ImageRegistry::instance()->pixmap( RESPATH "images/squid.svg", size );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( pixmap.isNull() )
|
if ( pixmap.isNull() )
|
||||||
@ -142,7 +140,7 @@ createRoundedImage( const QPixmap& pixmap, const QSize& size, float frameWidthPc
|
|||||||
return QPixmap();
|
return QPixmap();
|
||||||
|
|
||||||
QPixmap scaledAvatar = pixmap.scaled( width, height, Qt::IgnoreAspectRatio, Qt::SmoothTransformation );
|
QPixmap scaledAvatar = pixmap.scaled( width, height, Qt::IgnoreAspectRatio, Qt::SmoothTransformation );
|
||||||
if ( frameWidthPct == 0.00 )
|
if ( frameWidthPct == 0.00f )
|
||||||
return scaledAvatar;
|
return scaledAvatar;
|
||||||
|
|
||||||
QPixmap frame( width, height );
|
QPixmap frame( width, height );
|
||||||
@ -159,7 +157,7 @@ createRoundedImage( const QPixmap& pixmap, const QSize& size, float frameWidthPc
|
|||||||
|
|
||||||
painter.setBrush( brush );
|
painter.setBrush( brush );
|
||||||
painter.setPen( pen );
|
painter.setPen( pen );
|
||||||
painter.drawRoundedRect( outerRect, frameWidthPct * 100.0, frameWidthPct * 100.0, Qt::RelativeSize );
|
painter.drawRoundedRect( outerRect, frameWidthPct * 100.0f, frameWidthPct * 100.0f, Qt::RelativeSize );
|
||||||
|
|
||||||
/* painter.setBrush( Qt::transparent );
|
/* painter.setBrush( Qt::transparent );
|
||||||
painter.setPen( Qt::white );
|
painter.setPen( Qt::white );
|
||||||
@ -225,7 +223,7 @@ setDefaultFontSize( int points )
|
|||||||
QSize
|
QSize
|
||||||
defaultIconSize()
|
defaultIconSize()
|
||||||
{
|
{
|
||||||
const int w = defaultFontHeight() * 1.6;
|
const int w = defaultFontHeight() * 1.6f;
|
||||||
return QSize( w, w );
|
return QSize( w, w );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user