QgsOSMDownloadDialog::QgsOSMDownloadDialog( QWidget* parent ) : QDialog( parent ) , mDownload( new QgsOSMDownload ) { setupUi( this ); editXMin->setValidator( new QDoubleValidator( -180.0, 180.0, 6, this ) ); editXMax->setValidator( new QDoubleValidator( -180.0, 180.0, 6, this ) ); editYMin->setValidator( new QDoubleValidator( -90.0, 90.0, 6, this ) ); editYMax->setValidator( new QDoubleValidator( -90.0, 90.0, 6, this ) ); populateLayers(); onExtentCanvas(); connect( radExtentCanvas, SIGNAL( clicked() ), this, SLOT( onExtentCanvas() ) ); connect( radExtentLayer, SIGNAL( clicked() ), this, SLOT( onExtentLayer() ) ); connect( radExtentManual, SIGNAL( clicked() ), this, SLOT( onExtentManual() ) ); connect( cboLayers, SIGNAL( currentIndexChanged( int ) ), this, SLOT( onCurrentLayerChanged( int ) ) ); connect( btnBrowse, SIGNAL( clicked() ), this, SLOT( onBrowseClicked() ) ); connect( buttonBox, SIGNAL( accepted() ), this, SLOT( onOK() ) ); connect( buttonBox, SIGNAL( rejected() ), this, SLOT( onClose() ) ); connect( mDownload, SIGNAL( finished() ), this, SLOT( onFinished() ) ); connect( mDownload, SIGNAL( downloadProgress( qint64, qint64 ) ), this, SLOT( onDownloadProgress( qint64, qint64 ) ) ); }
LayerSelectorDialog::LayerSelectorDialog( QWidget *parent ) : QDialog( parent ) { setupUi( this ); // additional buttons //~ QPushButton *pb; //~ pb = new QPushButton( tr( "Select all" ) ); //~ buttonBox->addButton( pb, QDialogButtonBox::ActionRole ); //~ connect( pb, SIGNAL( clicked() ), this, SLOT( selectAll() ) ); //~ //~ pb = new QPushButton( tr( "Clear selection" ) ); //~ buttonBox->addButton( pb, QDialogButtonBox::ActionRole ); //~ connect( pb, SIGNAL( clicked() ), this, SLOT( clearSelection() ) ); connect( treeLayers, SIGNAL( itemSelectionChanged() ), this, SLOT( updateSelectedLayers() ) ); populateLayers(); }