: QComboBox( parent ),
myCleared( false )
{
- connect( this, SIGNAL( activated( int ) ), this, SLOT( onActivated( int ) ) );
connect( this, SIGNAL( currentIndexChanged( int ) ), this, SLOT( onCurrentChanged( int ) ) );
setModel( new Model( this ) );
}
lineEdit()->setText( "" );
}
-/*!
- \brief Called when any item is activated by the user.
- \param idx activated item index
-*/
-void QtxComboBox::onActivated( int idx )
-{
- resetClear();
- emit activatedId( id( idx ) );
-}
-
/*!
\brief Called when current item is chaned (by the user or programmatically).
\param idx item being set current
void QtxComboBox::onCurrentChanged( int idx )
{
if ( idx != -1 )
+ {
resetClear();
+ emit activatedId( id( idx ) );
+ }
}
/*!