Navigation Menu

Skip to content

Commit

Permalink
updates from the review
Browse files Browse the repository at this point in the history
  • Loading branch information
Samweli authored and nyalldawson committed Apr 1, 2020
1 parent 88f039e commit 55ef7fd
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/gui/raster/qgsrasterlayerproperties.cpp
Expand Up @@ -1281,8 +1281,8 @@ void QgsRasterLayerProperties::setSourceStaticTimeState()
mFetchModeComboBox->addItem( tr( "Use Whole Temporal Range" ), QgsRasterDataProviderTemporalCapabilities::MatchUsingWholeRange );
mFetchModeComboBox->addItem( tr( "Match to Start of Range" ), QgsRasterDataProviderTemporalCapabilities::MatchExactUsingStartOfRange );
mFetchModeComboBox->addItem( tr( "Match to End of Range" ), QgsRasterDataProviderTemporalCapabilities::MatchExactUsingEndOfRange );
mFetchModeComboBox->addItem( tr( "Previous Closest to Start of Range" ), QgsRasterDataProviderTemporalCapabilities::FindClosestMatchToStartOfRange );
mFetchModeComboBox->addItem( tr( "Previous Closest to End of Range" ), QgsRasterDataProviderTemporalCapabilities::FindClosestMatchToEndOfRange );
mFetchModeComboBox->addItem( tr( "Closest Match to Start of Range" ), QgsRasterDataProviderTemporalCapabilities::FindClosestMatchToStartOfRange );
mFetchModeComboBox->addItem( tr( "Closest Match to End of Range" ), QgsRasterDataProviderTemporalCapabilities::FindClosestMatchToEndOfRange );
mFetchModeComboBox->setCurrentIndex( mFetchModeComboBox->findData( mRasterLayer->temporalProperties()->intervalHandlingMethod() ) );

const QString temporalSource = uri.param( QStringLiteral( "temporalSource" ) );
Expand Down
4 changes: 2 additions & 2 deletions src/providers/wms/qgswmscapabilities.cpp
Expand Up @@ -335,10 +335,10 @@ QDateTime QgsWmsSettings::addTime( QDateTime dateTime, QgsWmstResolution resolut
return resultDateTime;
}

QDateTime QgsWmsSettings::findLeastClosestDateTime( QDateTime dateTime )
QDateTime QgsWmsSettings::findLeastClosestDateTime( QDateTime dateTime ) const
{
QDateTime closest = dateTime;
long long min = LLONG_MAX;
long long min = std::numeric_limits<long long>::max();

if ( !dateTime.isValid() || mDateTimes.contains( dateTime ) )
return closest;
Expand Down
2 changes: 1 addition & 1 deletion src/providers/wms/qgswmscapabilities.h
Expand Up @@ -791,7 +791,7 @@ class QgsWmsSettings
*
* Returns the passed \a dateTime if it is found in the available datetimes.
*/
QDateTime findLeastClosestDateTime( QDateTime dateTime );
QDateTime findLeastClosestDateTime( QDateTime dateTime ) const;

protected:
QgsWmsParserSettings mParserSettings;
Expand Down

0 comments on commit 55ef7fd

Please sign in to comment.