(JS) update: iOS: Scrolling lags within HTML element on map
MODIFY
plugin.xml
plugin.xml
<?xml version='1.0' encoding='utf-8'?>
-<plugin id="cordova-plugin-googlemaps" version="2.1.2-beta-20171120-1917" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
+<plugin id="cordova-plugin-googlemaps" version="2.1.2-beta-20171120-1931" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
<name>cordova-plugin-googlemaps</name>
<js-module name="BaseClass" src="www/BaseClass.js">
<runs />

MODIFY
www/googlemaps-cdv-plugin.js
www/googlemaps-cdv-plugin.js
@@ -118,6 +118,7 @@ if (!cordova) {
var prevDomPositions = {};
var idlingCnt = -1;
var longIdlingCnt = -1;
+ var MIN_MAP_DEPTH = 0;
var isChecking = false;
var cacheDepth = {};
@@ -163,6 +164,13 @@ if (!cordova) {
document.body.addEventListener("followMapDivPositionOnly",followMapDivPositionOnly, true);
document.body.addEventListener("transitionend",followMapDivPositionOnly, true);
document.body.addEventListener("scroll", function(e) {
+ if (e.target.hasAttribute("__pluginDomId")) {
+ var elemId = e.target.getAttribute("__pluginDomId");
+ var depth = cacheDepth[elemId];
+ if (depth > MIN_MAP_DEPTH) {
+ return;
+ }
+ }
if (scrollEndTimer) {
clearTimeout(scrollEndTimer);
}
@@ -431,6 +439,7 @@ if (!cordova) {
});
return;
}
+ MIN_MAP_DEPTH = minMapDepth;
//-----------------------------------------------------------------
// Ignore the elements that their z-index is smaller than map div

(JS) update: iOS: Scrolling lags within HTML element on map #1756