コード例 #1
0
ScopedQtSignalsBlocker::ScopedQtSignalsBlocker( QObject& objectToBlock )
:
m_objectToBlock( objectToBlock ),
m_previousBlockState( objectToBlock.blockSignals( true ) )
{
}
コード例 #2
0
/*!
  \overload

  \post o.signalsBlocked() == true
*/
KDSignalBlocker::KDSignalBlocker( QObject & o )
    : blocked( o.signalsBlocked() ), object( &o )
{
    o.blockSignals( true );
}