QgsMapUnitScaleDialog::QgsMapUnitScaleDialog( QWidget* parent )
    : QDialog( parent )
{
  setupUi( this );
  mComboBoxMinScale->setScale( 0.0000001 );
  mComboBoxMaxScale->setScale( 1 );
  connect( mCheckBoxMinScale, SIGNAL( toggled( bool ) ), this, SLOT( configureMinComboBox() ) );
  connect( mCheckBoxMaxScale, SIGNAL( toggled( bool ) ), this, SLOT( configureMaxComboBox() ) );
  connect( mComboBoxMinScale, SIGNAL( scaleChanged() ), this, SLOT( configureMaxComboBox() ) );
  connect( mComboBoxMaxScale, SIGNAL( scaleChanged() ), this, SLOT( configureMinComboBox() ) );
}
QgsMapUnitScaleDialog::QgsMapUnitScaleDialog( QWidget* parent )
    : QDialog( parent )
{
  setupUi( this );
  mComboBoxMinScale->setScale( 0.0000001 );
  mComboBoxMaxScale->setScale( 1 );
  mSpinBoxMinSize->setShowClearButton( false );
  mSpinBoxMaxSize->setShowClearButton( false );
  connect( mCheckBoxMinScale, SIGNAL( toggled( bool ) ), this, SLOT( configureMinComboBox() ) );
  connect( mCheckBoxMaxScale, SIGNAL( toggled( bool ) ), this, SLOT( configureMaxComboBox() ) );
  connect( mComboBoxMinScale, SIGNAL( scaleChanged() ), this, SLOT( configureMaxComboBox() ) );
  connect( mComboBoxMaxScale, SIGNAL( scaleChanged() ), this, SLOT( configureMinComboBox() ) );

  connect( mCheckBoxMinSize, SIGNAL( toggled( bool ) ), mSpinBoxMinSize, SLOT( setEnabled( bool ) ) );
  connect( mCheckBoxMaxSize, SIGNAL( toggled( bool ) ), mSpinBoxMaxSize, SLOT( setEnabled( bool ) ) );
}