mirror of
https://github.com/qgis/QGIS.git
synced 2025-10-15 00:02:52 -04:00
new temporal map settings dialog
This commit is contained in:
parent
d446c0a223
commit
3e06d0a696
@ -829,6 +829,7 @@
|
||||
<file>themes/default/temporal_navigation/next.svg</file>
|
||||
<file>themes/default/temporal_navigation/stop.svg</file>
|
||||
<file>themes/default/temporal_navigation/previous.svg</file>
|
||||
<file>themes/default/temporal_navigation/vcr_settings.svg</file>
|
||||
</qresource>
|
||||
<qresource prefix="/images/tips">
|
||||
<file alias="symbol_levels.png">qgis_tips/symbol_levels.png</file>
|
||||
|
79
images/themes/default/temporal_navigation/vcr_settings.svg
Normal file
79
images/themes/default/temporal_navigation/vcr_settings.svg
Normal file
@ -0,0 +1,79 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
height="48"
|
||||
width="48"
|
||||
version="1.1"
|
||||
id="svg13"
|
||||
sodipodi:docname="temporalVcrSettings2.svg"
|
||||
inkscape:version="0.92.4 (unknown)">
|
||||
<metadata
|
||||
id="metadata19">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title />
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<defs
|
||||
id="defs17" />
|
||||
<sodipodi:namedview
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1"
|
||||
objecttolerance="10"
|
||||
gridtolerance="10"
|
||||
guidetolerance="10"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:window-width="1299"
|
||||
inkscape:window-height="713"
|
||||
id="namedview15"
|
||||
showgrid="false"
|
||||
inkscape:zoom="9.8333333"
|
||||
inkscape:cx="12.152543"
|
||||
inkscape:cy="24.20339"
|
||||
inkscape:window-x="67"
|
||||
inkscape:window-y="27"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:current-layer="svg13" />
|
||||
<linearGradient
|
||||
id="a"
|
||||
gradientUnits="userSpaceOnUse"
|
||||
x1="9.5"
|
||||
x2="15.5"
|
||||
y1="15.5"
|
||||
y2="23.5">
|
||||
<stop
|
||||
offset="0"
|
||||
stop-color="#fef5af"
|
||||
id="stop2" />
|
||||
<stop
|
||||
offset=".1986319"
|
||||
stop-color="#fbe741"
|
||||
id="stop4" />
|
||||
<stop
|
||||
offset=".71306628"
|
||||
stop-color="#fbe21e"
|
||||
id="stop6" />
|
||||
<stop
|
||||
offset="1"
|
||||
stop-color="#e3ca04"
|
||||
id="stop8" />
|
||||
</linearGradient>
|
||||
<path
|
||||
d="m 19.509474,3.1570395 v 7.8692355 c -0.41701,0.148573 -0.835395,0.318124 -1.233315,0.505364 L 12.689967,5.9726373 6.0881036,12.542367 11.674297,18.101371 c -0.186562,0.394619 -0.358956,0.812057 -0.507837,1.22731 H 3.2587339 v 9.240942 H 11.16646 c 0.147582,0.413347 0.322688,0.833591 0.507837,1.22731 l -5.5861934,5.559004 6.6018634,6.56973 5.586192,-5.559001 c 0.398255,0.186945 0.816471,0.356876 1.233315,0.505363 v 7.869236 h 9.286138 v -7.869236 c 0.416844,-0.148473 0.835059,-0.318431 1.233313,-0.505363 l 5.586193,5.559001 6.601864,-6.56973 -5.586193,-5.559004 c 0.185141,-0.393719 0.360247,-0.813963 0.507836,-1.22731 h 7.907726 v -9.240942 h -7.907726 c -0.149201,-0.414814 -0.319988,-0.830997 -0.507836,-1.22731 l 5.586193,-5.559004 -6.601864,-6.5697297 -5.586193,5.5590017 c -0.395647,-0.18424 -0.817942,-0.358493 -1.233313,-0.505364 V 3.1570395 Z M 24.152543,18.39015 c 3.081903,0 5.586193,2.492098 5.586193,5.559004 0,3.066902 -2.50429,5.559001 -5.586193,5.559001 -3.081904,0 -5.586192,-2.492099 -5.586192,-5.559001 0,-3.066906 2.504288,-5.559004 5.586192,-5.559004 z"
|
||||
style="overflow:visible;opacity:1;fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.99299085;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:1"
|
||||
id="path11"
|
||||
inkscape:connector-curvature="0" />
|
||||
</svg>
|
After Width: | Height: | Size: 3.2 KiB |
@ -13,7 +13,8 @@
|
||||
class QgsTemporalController : QObject
|
||||
{
|
||||
%Docstring
|
||||
|
||||
A controller base class for temporal objects, contains a signal for notifying
|
||||
updates of the objects temporal range.
|
||||
|
||||
.. versionadded:: 3.14
|
||||
%End
|
||||
@ -31,7 +32,12 @@ Constructor for QgsTemporalController.
|
||||
virtual ~QgsTemporalController();
|
||||
|
||||
signals:
|
||||
|
||||
void updateTemporalRange( const QgsDateTimeRange &range );
|
||||
%Docstring
|
||||
Signals that a temporal ``range`` has changed and need to be updated to
|
||||
the related objects.
|
||||
%End
|
||||
|
||||
};
|
||||
|
||||
|
@ -0,0 +1,46 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/gui/qgstemporalmapsettingsdialog.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
class QgsTemporalMapSettingsDialog : QDialog
|
||||
{
|
||||
%Docstring
|
||||
The QgsTemporalMapSettingsDialog class
|
||||
|
||||
.. versionadded:: 3.14
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgstemporalmapsettingsdialog.h"
|
||||
%End
|
||||
public:
|
||||
|
||||
QgsTemporalMapSettingsDialog( QWidget *parent = 0, Qt::WindowFlags flags = Qt::WindowFlags() );
|
||||
%Docstring
|
||||
Constructor for QgsTemporalMapSettingsDialog
|
||||
%End
|
||||
|
||||
~QgsTemporalMapSettingsDialog();
|
||||
|
||||
double frameRateValue();
|
||||
%Docstring
|
||||
Returns the value of frame rate from widget.
|
||||
%End
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/gui/qgstemporalmapsettingsdialog.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -0,0 +1,52 @@
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/gui/qgstemporalmapsettingswidget.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
class QgsTemporalMapSettingsWidget : QWidget
|
||||
{
|
||||
%Docstring
|
||||
The QgsTemporalMapSettingsWidget class
|
||||
|
||||
.. versionadded:: 3.14
|
||||
%End
|
||||
|
||||
%TypeHeaderCode
|
||||
#include "qgstemporalmapsettingswidget.h"
|
||||
%End
|
||||
public:
|
||||
|
||||
QgsTemporalMapSettingsWidget( QWidget *parent = 0 );
|
||||
%Docstring
|
||||
Constructor for QgsTemporalMapSettingsWidget
|
||||
%End
|
||||
|
||||
~QgsTemporalMapSettingsWidget();
|
||||
|
||||
double frameRateValue();
|
||||
%Docstring
|
||||
Returns the value of frame rate from widget input
|
||||
%End
|
||||
|
||||
void setFrameRateValue( double value );
|
||||
%Docstring
|
||||
Sets the value of frame rate from the vcr widget.
|
||||
%End
|
||||
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* This file has been generated automatically from *
|
||||
* *
|
||||
* src/gui/qgstemporalmapsettingswidget.h *
|
||||
* *
|
||||
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
||||
************************************************************************/
|
@ -196,6 +196,8 @@
|
||||
%Include auto_generated/qgstablewidgetitem.sip
|
||||
%Include auto_generated/qgstabwidget.sip
|
||||
%Include auto_generated/qgstaskmanagerwidget.sip
|
||||
%Include auto_generated/qgstemporalmapsettingsdialog.sip
|
||||
%Include auto_generated/qgstemporalmapsettingswidget.sip
|
||||
%Include auto_generated/qgstemporalvcrdockwidget.sip
|
||||
%Include auto_generated/qgstextformatwidget.sip
|
||||
%Include auto_generated/qgstextpreview.sip
|
||||
|
@ -504,6 +504,8 @@ SET(QGIS_GUI_SRCS
|
||||
qgstabwidget.cpp
|
||||
qgstablewidgetitem.cpp
|
||||
qgstaskmanagerwidget.cpp
|
||||
qgstemporalmapsettingsdialog.cpp
|
||||
qgstemporalmapsettingswidget.cpp
|
||||
qgstemporalvcrdockwidget.cpp
|
||||
qgstextformatwidget.cpp
|
||||
qgstextpreview.cpp
|
||||
@ -725,6 +727,8 @@ SET(QGIS_GUI_HDRS
|
||||
qgstablewidgetitem.h
|
||||
qgstabwidget.h
|
||||
qgstaskmanagerwidget.h
|
||||
qgstemporalmapsettingsdialog.h
|
||||
qgstemporalmapsettingswidget.h
|
||||
qgstemporalvcrdockwidget.h
|
||||
qgstextformatwidget.h
|
||||
qgstextpreview.h
|
||||
|
56
src/gui/qgstemporalmapsettingsdialog.cpp
Normal file
56
src/gui/qgstemporalmapsettingsdialog.cpp
Normal file
@ -0,0 +1,56 @@
|
||||
/***************************************************************************
|
||||
qgstemporalmapsettingsdialog.cpp
|
||||
---------------
|
||||
begin : March 2020
|
||||
copyright : (C) 2020 by Samweli Mwakisambwe
|
||||
email : samweli at kartoza dot com
|
||||
***************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#include "qgstemporalmapsettingsdialog.h"
|
||||
#include "qgsgui.h"
|
||||
#include "qgstemporalmapsettingswidget.h"
|
||||
|
||||
QgsTemporalMapSettingsDialog::QgsTemporalMapSettingsDialog( QWidget *parent, Qt::WindowFlags flags )
|
||||
: QDialog( parent, flags )
|
||||
{
|
||||
setupUi( this );
|
||||
|
||||
connect( this, &QDialog::accepted, this, &QgsTemporalMapSettingsDialog::apply );
|
||||
connect( this, &QDialog::rejected, this, &QgsTemporalMapSettingsDialog::onCancel );
|
||||
|
||||
QVBoxLayout *layout = new QVBoxLayout();
|
||||
mTemporalMapSettingsWidget = new QgsTemporalMapSettingsWidget( this );
|
||||
layout->addWidget( mTemporalMapSettingsWidget );
|
||||
setLayout( layout );
|
||||
setWindowTitle( tr( "Temporal Map Settings" ) );
|
||||
|
||||
mTemporalMapSettingsWidget->setFrameRateValue( 1 );
|
||||
|
||||
hide();
|
||||
}
|
||||
|
||||
QgsTemporalMapSettingsDialog::~QgsTemporalMapSettingsDialog()
|
||||
{
|
||||
}
|
||||
|
||||
void QgsTemporalMapSettingsDialog::apply()
|
||||
{
|
||||
}
|
||||
|
||||
void QgsTemporalMapSettingsDialog::onCancel()
|
||||
{
|
||||
|
||||
}
|
||||
double QgsTemporalMapSettingsDialog::frameRateValue()
|
||||
{
|
||||
return mTemporalMapSettingsWidget->frameRateValue();
|
||||
}
|
63
src/gui/qgstemporalmapsettingsdialog.h
Normal file
63
src/gui/qgstemporalmapsettingsdialog.h
Normal file
@ -0,0 +1,63 @@
|
||||
/***************************************************************************
|
||||
qgstemporalmapsettingsdialog.h
|
||||
---------------
|
||||
begin : March 2020
|
||||
copyright : (C) 2020 by Samweli Mwakisambwe
|
||||
email : samweli at kartoza dot com
|
||||
***************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef QGSTEMPORALMAPSETTINGSDIALOG_H
|
||||
#define QGSTEMPORALMAPSETTINGSDIALOG_H
|
||||
|
||||
#include "ui_qgstemporalmapsettingsdialogbase.h"
|
||||
#include "qgis_gui.h"
|
||||
|
||||
class QgsTemporalMapSettingsWidget;
|
||||
|
||||
/**
|
||||
* \ingroup gui
|
||||
* The QgsTemporalMapSettingsDialog class
|
||||
*
|
||||
* \since QGIS 3.14
|
||||
*/
|
||||
class GUI_EXPORT QgsTemporalMapSettingsDialog : public QDialog, private Ui::QgsTemporalMapSettingsDialogBase
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
|
||||
/**
|
||||
* Constructor for QgsTemporalMapSettingsDialog
|
||||
*
|
||||
*/
|
||||
QgsTemporalMapSettingsDialog( QWidget *parent = nullptr, Qt::WindowFlags flags = Qt::WindowFlags() );
|
||||
|
||||
~QgsTemporalMapSettingsDialog() override;
|
||||
|
||||
/**
|
||||
* Returns the value of frame rate from widget.
|
||||
*/
|
||||
double frameRateValue();
|
||||
|
||||
private slots:
|
||||
|
||||
//! \brief Applies the settings made in the dialog.
|
||||
void apply();
|
||||
//! \brief Called when cancel button is pressed
|
||||
void onCancel();
|
||||
|
||||
private:
|
||||
|
||||
//! Widget for handling temporal map settings
|
||||
QgsTemporalMapSettingsWidget *mTemporalMapSettingsWidget = nullptr;
|
||||
};
|
||||
|
||||
#endif // QGSTEMPORALMAPSETTINGSDIALOG_H
|
39
src/gui/qgstemporalmapsettingswidget.cpp
Normal file
39
src/gui/qgstemporalmapsettingswidget.cpp
Normal file
@ -0,0 +1,39 @@
|
||||
/***************************************************************************
|
||||
qgstemporalmapsettingswidget.cpp
|
||||
---------------
|
||||
begin : March 2020
|
||||
copyright : (C) 2020 by Samweli Mwakisambwe
|
||||
email : samweli at kartoza dot com
|
||||
***************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#include "qgstemporalmapsettingswidget.h"
|
||||
#include "qgsgui.h"
|
||||
|
||||
QgsTemporalMapSettingsWidget::QgsTemporalMapSettingsWidget( QWidget *parent )
|
||||
: QWidget( parent )
|
||||
{
|
||||
setupUi( this );
|
||||
}
|
||||
|
||||
QgsTemporalMapSettingsWidget::~QgsTemporalMapSettingsWidget()
|
||||
{
|
||||
}
|
||||
|
||||
double QgsTemporalMapSettingsWidget::frameRateValue()
|
||||
{
|
||||
return mFrameSpinBox->value();
|
||||
}
|
||||
|
||||
void QgsTemporalMapSettingsWidget::setFrameRateValue( double value )
|
||||
{
|
||||
mFrameSpinBox->setValue( value );
|
||||
}
|
57
src/gui/qgstemporalmapsettingswidget.h
Normal file
57
src/gui/qgstemporalmapsettingswidget.h
Normal file
@ -0,0 +1,57 @@
|
||||
/***************************************************************************
|
||||
qgstemporalmapsettingswidget.h
|
||||
---------------
|
||||
begin : March 2020
|
||||
copyright : (C) 2020 by Samweli Mwakisambwe
|
||||
email : samweli at kartoza dot com
|
||||
***************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef QGSTEMPORALMAPSETTINGSWIDGET_H
|
||||
#define QGSTEMPORALMAPSETTINGSWIDGET_H
|
||||
|
||||
#include "ui_qgstemporalmapsettingswidgetbase.h"
|
||||
|
||||
#include "qgis_gui.h"
|
||||
|
||||
|
||||
/**
|
||||
* \ingroup gui
|
||||
* The QgsTemporalMapSettingsWidget class
|
||||
*
|
||||
* \since QGIS 3.14
|
||||
*/
|
||||
class GUI_EXPORT QgsTemporalMapSettingsWidget : public QWidget, private Ui::QgsTemporalMapSettingsWidgetBase
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
|
||||
/**
|
||||
* Constructor for QgsTemporalMapSettingsWidget
|
||||
*
|
||||
*/
|
||||
QgsTemporalMapSettingsWidget( QWidget *parent = nullptr );
|
||||
|
||||
~QgsTemporalMapSettingsWidget() override;
|
||||
|
||||
/**
|
||||
* Returns the value of frame rate from widget input
|
||||
*/
|
||||
double frameRateValue();
|
||||
|
||||
/**
|
||||
* Sets the value of frame rate from the vcr widget.
|
||||
*/
|
||||
void setFrameRateValue( double value );
|
||||
|
||||
};
|
||||
|
||||
#endif // QGSTEMPORALMAPSETTINGSWIDGET_H
|
@ -22,6 +22,9 @@
|
||||
#include "qgsmaplayer.h"
|
||||
#include "qgsrasterlayer.h"
|
||||
#include "qgstemporalnavigationobject.h"
|
||||
#include "qgstemporalmapsettingswidget.h"
|
||||
|
||||
#include "qgstemporalmapsettingsdialog.h"
|
||||
|
||||
QgsTemporalVcrDockWidget::QgsTemporalVcrDockWidget( const QString &name, QWidget *parent )
|
||||
: QgsDockWidget( parent )
|
||||
@ -30,6 +33,7 @@ QgsTemporalVcrDockWidget::QgsTemporalVcrDockWidget( const QString &name, QWidget
|
||||
setWindowTitle( name );
|
||||
|
||||
mNavigationObject = new QgsTemporalNavigationObject();
|
||||
settingsDialog();
|
||||
|
||||
connect( mForwardButton, &QPushButton::clicked, this, &QgsTemporalVcrDockWidget::forwardButton_clicked );
|
||||
connect( mBackButton, &QPushButton::clicked, this, &QgsTemporalVcrDockWidget::backButton_clicked );
|
||||
@ -40,6 +44,7 @@ QgsTemporalVcrDockWidget::QgsTemporalVcrDockWidget( const QString &name, QWidget
|
||||
connect( mTimeStepsComboBox, qgis::overload<int>::of( &QComboBox::currentIndexChanged ), this, &QgsTemporalVcrDockWidget::timeStepsComboBox_currentIndexChanged );
|
||||
connect( mModeComboBox, qgis::overload<int>::of( &QComboBox::currentIndexChanged ), this, &QgsTemporalVcrDockWidget::modeComboBox_currentIndexChanged );
|
||||
connect( mTimeSlider, &QSlider::valueChanged, this, &QgsTemporalVcrDockWidget::timeSlider_valueChanged );
|
||||
connect( mSettings, &QPushButton::clicked, this, &QgsTemporalVcrDockWidget::settings_clicked );
|
||||
|
||||
connect( mStartDateTime, &QDateTimeEdit::dateTimeChanged, this, &QgsTemporalVcrDockWidget::startDateTime_changed );
|
||||
connect( mEndDateTime, &QDateTimeEdit::dateTimeChanged, this, &QgsTemporalVcrDockWidget::endDateTime_changed );
|
||||
@ -56,6 +61,7 @@ QgsTemporalVcrDockWidget::~QgsTemporalVcrDockWidget()
|
||||
{
|
||||
mTimer->stop();
|
||||
delete mNavigationObject;
|
||||
delete mSettingsDialog;
|
||||
}
|
||||
|
||||
void QgsTemporalVcrDockWidget::init()
|
||||
@ -92,6 +98,17 @@ void QgsTemporalVcrDockWidget::init()
|
||||
setSliderRange();
|
||||
}
|
||||
|
||||
void QgsTemporalVcrDockWidget::settingsDialog()
|
||||
{
|
||||
mSettingsDialog = new QgsTemporalMapSettingsDialog( this );
|
||||
|
||||
}
|
||||
|
||||
void QgsTemporalVcrDockWidget::settings_clicked()
|
||||
{
|
||||
mSettingsDialog->setVisible( !mSettingsDialog->isVisible() );
|
||||
}
|
||||
|
||||
void QgsTemporalVcrDockWidget::timerTimeout()
|
||||
{
|
||||
if ( mNavigationObject->navigationStatus() ==
|
||||
@ -227,7 +244,7 @@ void QgsTemporalVcrDockWidget::forwardButton_clicked()
|
||||
if ( ( mTimeSlider->value() + 1 ) < mNavigationObject->dateTimes().size() )
|
||||
{
|
||||
mTimeSlider->setValue( mTimeSlider->value() + 1 );
|
||||
mTimer->start( 1000 );
|
||||
mTimer->start( mSettingsDialog->frameRateValue() );
|
||||
}
|
||||
updateButtonsEnable( true );
|
||||
setDateInputsEnable( true );
|
||||
|
@ -26,6 +26,8 @@
|
||||
|
||||
class QgsMapLayer;
|
||||
class QgsTemporalNavigationObject;
|
||||
class QgsTemporalMapSettingsWidget;
|
||||
class QgsTemporalMapSettingsDialog;
|
||||
|
||||
/**
|
||||
* \ingroup gui
|
||||
@ -74,11 +76,20 @@ class GUI_EXPORT QgsTemporalVcrDockWidget : public QgsDockWidget, private Ui::Qg
|
||||
**/
|
||||
void setDateInputsEnable( bool enabled );
|
||||
|
||||
/**
|
||||
* Sets the VCR settings dialog
|
||||
**/
|
||||
void settingsDialog();
|
||||
|
||||
//! Timer to set navigation time interval
|
||||
QTimer *mTimer = nullptr;
|
||||
|
||||
//! Handles all non ui navigation logic
|
||||
QgsTemporalNavigationObject *mNavigationObject = nullptr;
|
||||
|
||||
//! Dialog for temporal map settings
|
||||
QgsTemporalMapSettingsDialog *mSettingsDialog = nullptr;
|
||||
|
||||
private slots:
|
||||
|
||||
/**
|
||||
@ -146,10 +157,15 @@ class GUI_EXPORT QgsTemporalVcrDockWidget : public QgsDockWidget, private Ui::Qg
|
||||
void startDateTime_changed( const QDateTime &datetime );
|
||||
|
||||
/**
|
||||
*Handles the input change on the end date time input.
|
||||
* Handles the input change on the end date time input.
|
||||
**/
|
||||
void endDateTime_changed( const QDateTime &datetime );
|
||||
|
||||
/**
|
||||
* Loads a temporal map settings dialog
|
||||
**/
|
||||
void settings_clicked();
|
||||
|
||||
};
|
||||
|
||||
#endif // QGSTEMPORALVCRDOCKWIDGET_H
|
||||
|
77
src/ui/qgstemporalmapsettingsdialogbase.ui
Normal file
77
src/ui/qgstemporalmapsettingsdialogbase.ui
Normal file
@ -0,0 +1,77 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>QgsTemporalMapSettingsDialogBase</class>
|
||||
<widget class="QDialog" name="QgsTemporalMapSettingsDialogBase">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>216</width>
|
||||
<height>210</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Dialog</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QDialogButtonBox" name="buttonBox">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="standardButtons">
|
||||
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<resources/>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>accepted()</signal>
|
||||
<receiver>QgsTemporalMapSettingsDialogBase</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>248</x>
|
||||
<y>254</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>157</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>rejected()</signal>
|
||||
<receiver>QgsTemporalMapSettingsDialogBase</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>316</x>
|
||||
<y>260</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>286</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
</ui>
|
74
src/ui/qgstemporalmapsettingswidgetbase.ui
Normal file
74
src/ui/qgstemporalmapsettingswidgetbase.ui
Normal file
@ -0,0 +1,74 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>QgsTemporalMapSettingsWidgetBase</class>
|
||||
<widget class="QWidget" name="QgsTemporalMapSettingsWidgetBase">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>231</width>
|
||||
<height>134</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Form</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Frame rate</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QDoubleSpinBox" name="mFrameSpinBox"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<resources/>
|
||||
<connections/>
|
||||
</ui>
|
@ -6,8 +6,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1076</width>
|
||||
<height>128</height>
|
||||
<width>1133</width>
|
||||
<height>134</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
@ -17,6 +17,17 @@
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="mSettings">
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../../images/images.qrc">
|
||||
<normaloff>:/images/themes/default/temporal_navigation/vcr_settings.svg</normaloff>:/images/themes/default/temporal_navigation/vcr_settings.svg</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
|
Loading…
x
Reference in New Issue
Block a user