6#ifndef QSK_SKIN_STATE_CHANGER_H
7#define QSK_SKIN_STATE_CHANGER_H
10#include "QskSkinnable.h"
18 void setStates( QskAspect::States,
int sampleIndex = -1 );
23 const QskAspect::States m_oldStates;
26inline QskSkinStateChanger::QskSkinStateChanger(
const QskSkinnable* skinnable )
27 : m_skinnable( const_cast<
QskSkinnable* >( skinnable ) )
28 , m_oldStates( skinnable->skinStates() )
32inline QskSkinStateChanger::~QskSkinStateChanger()
37inline void QskSkinStateChanger::setStates(
38 QskAspect::States states,
int sampleIndex )
40 m_skinnable->replaceSkinStates( states, sampleIndex );
43inline void QskSkinStateChanger::resetStates()
45 m_skinnable->replaceSkinStates( m_oldStates, -1 );