Fix button order

wilder-work
Montel Laurent 13 years ago
parent 328a7d987c
commit 0b9d0ebd21
  1. 23
      simplestringlisteditor.cpp

@ -84,17 +84,6 @@ SimpleStringListEditor::SimpleStringListEditor( QWidget * parent,
this, SLOT(slotAdd()) );
}
if ( buttons & Remove ) {
if ( removeLabel.isEmpty() )
mRemoveButton = new QPushButton( i18n("&Remove"), this );
else
mRemoveButton = new QPushButton( removeLabel, this );
mRemoveButton->setAutoDefault( false );
mRemoveButton->setEnabled( false ); // no selection yet
vlay->addWidget( mRemoveButton );
connect( mRemoveButton, SIGNAL(clicked()),
this, SLOT(slotRemove()) );
}
if ( buttons & Modify ) {
if ( modifyLabel.isEmpty() )
@ -110,6 +99,18 @@ SimpleStringListEditor::SimpleStringListEditor( QWidget * parent,
this, SLOT(slotModify()) );
}
if ( buttons & Remove ) {
if ( removeLabel.isEmpty() )
mRemoveButton = new QPushButton( i18n("&Remove"), this );
else
mRemoveButton = new QPushButton( removeLabel, this );
mRemoveButton->setAutoDefault( false );
mRemoveButton->setEnabled( false ); // no selection yet
vlay->addWidget( mRemoveButton );
connect( mRemoveButton, SIGNAL(clicked()),
this, SLOT(slotRemove()) );
}
if ( buttons & Up ) {
if ( !(buttons & Down) ) {
kDebug() << "Are you sure you want to use an Up button"

Loading…
Cancel
Save