making cppcheck happier

This commit is contained in:
Uwe Rathmann 2019-05-16 08:14:32 +02:00
parent 4f5c919706
commit 896772c9b4
5 changed files with 9 additions and 7 deletions

View File

@ -25,6 +25,7 @@ QskFlickAnimator::QskFlickAnimator()
, m_degrees( 0.0 )
, m_cos( 1.0 )
, m_sin( 0.0 )
, m_elapsed( 0 )
{
setDuration( 1000 );
setEasingCurve( QEasingCurve::OutCubic );
@ -83,7 +84,7 @@ void QskFlickAnimator::accelerate( qreal degrees, qreal velocity )
void QskFlickAnimator::done()
{
m_velocity[ 1 ] = 0.0;
m_elapsed = 0.0;
m_elapsed = 0;
}
void QskFlickAnimator::setAngle( qreal degrees )

View File

@ -125,13 +125,13 @@ namespace
}
private:
int m_pos;
int m_pos = 0;
enum { Count = 3 };
struct
{
int elapsed;
qreal velocity;
int elapsed = 0;
qreal velocity = 0.0;
} m_values[ Count ];
};
}

View File

@ -367,7 +367,7 @@ class QskScrollArea::PrivateData
}
}
QskScrollAreaClipItem* clipItem;
QskScrollAreaClipItem* clipItem = nullptr;
bool isItemResizable : 1;
bool autoScrollFocusItem : 1;

View File

@ -100,6 +100,7 @@ QskLayoutItem* QskStackBoxAnimator::layoutItemAt( int index ) const
QskStackBoxAnimator1::QskStackBoxAnimator1( QskStackBox* parent )
: QskStackBoxAnimator( parent )
, m_orientation( Qt::Horizontal )
, m_hasClip( false )
{
}

View File

@ -55,8 +55,8 @@ namespace
void initialize() override;
private:
int m_matrixId;
int m_opacityId;
int m_matrixId = -1;
int m_opacityId = -1;
const bool m_isOpaque : 1;
};