(Bug fix) JS: can not click upon the overlay menu on the map
MODIFY
plugin.xml
plugin.xml
<?xml version='1.0' encoding='utf-8'?>
-<plugin id="cordova-plugin-googlemaps" version="2.1.0-beta-20171026-1638" 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.0-beta-20171027-0054" 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/Common.js
www/Common.js
@@ -307,23 +307,12 @@ function getZIndex(dom) {
return z;
}
-
-function getDomDepth(dom, idx, parentZIndex, parentDepth, floorLevel) {
+function getDomDepth(dom, idx, parentDepth, floorLevel) {
if (dom.nodeType !== Node.ELEMENT_NODE) {
return 0;
}
- var orgDom = dom;
- var zIndex = parentZIndex + getZIndex(dom);
-/*
- var depth = 0;
- while (dom.parentNode !== null && dom.parentNode != document) {
- dom = dom.parentNode;
- depth++;
- }
-*/
- //var result = ((zIndex + 1) << (depth + 1)) + idx;
- var result = (parentDepth + ((zIndex + 1) / (floorLevel + 1)) + idx) - 0.01 ;
- //orgDom.setAttribute("_depth", result); // for debugging
+ var result = parentDepth + (getZIndex(dom) + 1 + idx) / (1 << floorLevel);
+ //dom.setAttribute("_depth", result); // for debugging
return result;
}

MODIFY
www/googlemaps-cdv-plugin.js
www/googlemaps-cdv-plugin.js
@@ -245,7 +245,7 @@ if (!cordova) {
prevDomPositions[elemId].zIndex === zIndex) {
depth = cacheDepth[elemId];
} else {
- depth = common.getDomDepth(element, domIdx, parentZIndex, parentDepth, floorLevel);
+ depth = common.getDomDepth(element, domIdx, parentDepth, floorLevel);
cacheDepth[elemId] = depth;
}

(Bug fix) JS: can not click upon the overlay menu on the map