Avoid errors in stock JS
This commit is contained in:
@ -602,3 +602,12 @@ window.clampLatLng = function(latlng) {
|
|||||||
window.clampLatLngBounds = function(bounds) {
|
window.clampLatLngBounds = function(bounds) {
|
||||||
return new L.LatLngBounds ( clampLatLng(bounds.getSouthWest()), clampLatLng(bounds.getNorthEast()) );
|
return new L.LatLngBounds ( clampLatLng(bounds.getSouthWest()), clampLatLng(bounds.getNorthEast()) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// avoid error in stock JS
|
||||||
|
if(goog && goog.style) {
|
||||||
|
goog.style.showElement = function(a, b) {
|
||||||
|
if(a && a.style)
|
||||||
|
a.style.display = b ? "" : "none"
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
4
main.js
4
main.js
@ -100,7 +100,9 @@ document.getElementsByTagName('body')[0].innerHTML = ''
|
|||||||
+ ' </div>'
|
+ ' </div>'
|
||||||
+ ' </div>'
|
+ ' </div>'
|
||||||
+ '</div>'
|
+ '</div>'
|
||||||
+ '<div id="updatestatus"><div id="innerstatus"></div></div>';
|
+ '<div id="updatestatus"><div id="innerstatus"></div></div>'
|
||||||
|
// avoid error by stock JS
|
||||||
|
+ '<div id="play_button"></div>';
|
||||||
|
|
||||||
// putting everything in a wrapper function that in turn is placed in a
|
// putting everything in a wrapper function that in turn is placed in a
|
||||||
// script tag on the website allows us to execute in the site’s context
|
// script tag on the website allows us to execute in the site’s context
|
||||||
|
Reference in New Issue
Block a user