Skip to content
Permalink
Browse files

Dock widget ui fixes

  • Loading branch information
nyalldawson committed Mar 12, 2020
1 parent e6f285b commit 835f928b3f70b07d6364ee2a68dc61f7b1a4fcbe
Showing with 13 additions and 9 deletions.
  1. +3 −3 src/gui/qgstemporalcontrollerdockwidget.cpp
  2. +10 −6 src/gui/qgstemporalmapsettingsdialog.cpp
@@ -123,9 +123,9 @@ void QgsTemporalControllerDockWidget::updateSlider( const QgsDateTimeRange &rang
void QgsTemporalControllerDockWidget::updateRangeLabel( const QgsDateTimeRange &range )
{
QLocale locale;
mCurrentRangeLabel->setText( tr( "Current temporal range is from %1 to %2" ).arg(
range.begin().toString( locale.dateTimeFormat() ),
range.end().toString( locale.dateTimeFormat() ) ) );
mCurrentRangeLabel->setText( tr( "%1 to %2" ).arg(
range.begin().toString( locale.dateTimeFormat( QLocale::NarrowFormat ) ),
range.end().toString( locale.dateTimeFormat( QLocale::NarrowFormat ) ) ) );
}

QgsTemporalController *QgsTemporalControllerDockWidget::temporalController()
@@ -24,14 +24,18 @@
QgsTemporalMapSettingsDialog::QgsTemporalMapSettingsDialog( QWidget *parent, Qt::WindowFlags flags )
: QDialog( parent, flags )
{
setupUi( this );

connect( this, &QDialog::accepted, this, &QgsTemporalMapSettingsDialog::accept );
connect( this, &QDialog::rejected, this, &QgsTemporalMapSettingsDialog::reject );
QVBoxLayout *vl = new QVBoxLayout( );

mTemporalMapSettingsWidget = new QgsTemporalMapSettingsWidget( this );
QVBoxLayout *layout = new QVBoxLayout( frame );
layout->addWidget( mTemporalMapSettingsWidget );

vl->addWidget( mTemporalMapSettingsWidget, 1 );

QDialogButtonBox *box = new QDialogButtonBox( QDialogButtonBox::Ok | QDialogButtonBox::Cancel );
vl->addWidget( box );
setLayout( vl );

connect( box, &QDialogButtonBox::accepted, this, &QgsTemporalMapSettingsDialog::accept );
connect( box, &QDialogButtonBox::rejected, this, &QgsTemporalMapSettingsDialog::reject );

setWindowTitle( tr( "Temporal Map Settings" ) );
}

0 comments on commit 835f928

Please sign in to comment.
You can’t perform that action at this time.