[Qt] setStyleURL and setStyleJSON name review
Qt uses URL as Url and JSON as Json.
This commit is contained in:
@@ -59,7 +59,7 @@ void MapWindow::changeStyle()
|
||||
|
||||
auto& styles = QMapbox::defaultStyles();
|
||||
|
||||
m_map.setStyleURL(styles[currentStyleIndex].first);
|
||||
m_map.setStyleUrl(styles[currentStyleIndex].first);
|
||||
setWindowTitle(QString("Mapbox GL: ") + styles[currentStyleIndex].second);
|
||||
|
||||
if (++currentStyleIndex == styles.size()) {
|
||||
|
||||
@@ -119,11 +119,11 @@ public:
|
||||
|
||||
void cycleDebugOptions();
|
||||
|
||||
QString styleJSON() const;
|
||||
QString styleURL() const;
|
||||
QString styleJson() const;
|
||||
QString styleUrl() const;
|
||||
|
||||
void setStyleJSON(const QString &);
|
||||
void setStyleURL(const QString &);
|
||||
void setStyleJson(const QString &);
|
||||
void setStyleUrl(const QString &);
|
||||
|
||||
double latitude() const;
|
||||
void setLatitude(double latitude);
|
||||
|
||||
@@ -231,22 +231,22 @@ void QMapboxGL::cycleDebugOptions()
|
||||
d_ptr->mapObj->cycleDebugOptions();
|
||||
}
|
||||
|
||||
QString QMapboxGL::styleJSON() const
|
||||
QString QMapboxGL::styleJson() const
|
||||
{
|
||||
return QString::fromStdString(d_ptr->mapObj->getStyleJSON());
|
||||
}
|
||||
|
||||
QString QMapboxGL::styleURL() const
|
||||
QString QMapboxGL::styleUrl() const
|
||||
{
|
||||
return QString::fromStdString(d_ptr->mapObj->getStyleURL());
|
||||
}
|
||||
|
||||
void QMapboxGL::setStyleJSON(const QString &style)
|
||||
void QMapboxGL::setStyleJson(const QString &style)
|
||||
{
|
||||
d_ptr->mapObj->setStyleJSON(style.toStdString());
|
||||
}
|
||||
|
||||
void QMapboxGL::setStyleURL(const QString &url)
|
||||
void QMapboxGL::setStyleUrl(const QString &url)
|
||||
{
|
||||
d_ptr->mapObj->setStyleURL(url.toStdString());
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@ void QQuickMapboxGLRenderer::synchronize(QQuickFramebufferObject *item)
|
||||
}
|
||||
|
||||
if (syncStatus & QQuickMapboxGL::StyleNeedsSync && quickMap->style()) {
|
||||
m_map->setStyleURL(quickMap->style()->url());
|
||||
m_map->setStyleUrl(quickMap->style()->url());
|
||||
m_styleLoaded = false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user