Skip to content
Snippets Groups Projects
Commit a49753ff authored by Piotr Gawron's avatar Piotr Gawron
Browse files

Merge branch '451-no-need-for-the-google-agreement-for-openlayers' into 'master'

Resolve "no need for the google agreement for openlayers"

Closes #451

See merge request !339
parents 829eedc1 9f176d6d
No related branches found
No related tags found
1 merge request!339Resolve "no need for the google agreement for openlayers"
Pipeline #
......@@ -299,15 +299,17 @@ OverlayPanel.prototype.overlayToDataRow = function (overlay, checked, disabled)
result[1] = overlay.getName();
if (overlay.getInputDataAvailable()) {
var checkedString = "";
if (checked) {
checkedString = " checked ";
}
var disabledString = "";
if (disabled) {
disabledString = " disabled "
result[2] = "<div title='You did not consent to terms of the license of Google Maps Platform. Click the \"Edit\" button to do so.'>" +
"<i class='fa fa-exclamation-triangle' style='font-size:18px; font-weight:400; padding-right:10px;color:orange'></i></div>";
} else {
var checkedString = "";
if (checked) {
checkedString = " checked ";
}
result[2] = "<input type='checkbox' " + checkedString + " data='" + overlay.getId() + "' name='overlayToggle'/>";
}
result[2] = "<input type='checkbox' " + checkedString + disabledString + " data='" + overlay.getId() + "' name='overlayToggle'/>";
result[3] = "<button data='" + overlay.getId() + "' name='download-overlay'><span class='ui-icon ui-icon-arrowthickstop-1-s'></span></button>";
} else {
result[2] = "<a href='#' data='" + overlay.getId() + "' name='overlayLink'><img src='" + GuiConnector.getImgPrefix() + "icons/search.png' style='float: left' hspace='5'/></a>";
......@@ -494,8 +496,9 @@ OverlayPanel.prototype.refresh = function (showDefault) {
if (showDefault && overlay.isDefaultOverlay()) {
selectedOverlay[overlay.getId()] = true;
}
data.push(self.overlayToDataRow(overlay, selectedOverlay[overlay.getId()], !overlay.isGoogleLicenseConsent()));
if (!overlay.isGoogleLicenseConsent()) {
var disabled = !overlay.isGoogleLicenseConsent() && self.getMap().getProject().getMapCanvasType() === "GOOGLE_MAPS_API";
data.push(self.overlayToDataRow(overlay, selectedOverlay[overlay.getId()], disabled));
if (disabled) {
self.setGoogleLicenseConsentRequired(true);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment