map组件中 bindregionchange 无限触发
wxml: [代码]<[代码][代码]map[代码] [代码]latitude[代码][代码]=[代码][代码]"{{latitude}}"[代码] [代码]longitude[代码][代码]=[代码][代码]"{{longitude}}"[代码] [代码]scale[代码][代码]=[代码][代码]"{{buildlData[isSelectedBuildType].scale+2}}"[代码] [代码]bindcontroltap[代码][代码]=[代码][代码]"controltap"[代码] [代码]markers[代码][代码]=[代码][代码]"{{buildlData[isSelectedBuildType].data}}"[代码] [代码]bindmarkertap[代码][代码]=[代码][代码]"markertap"[代码] [代码]bindregionchange[代码][代码]=[代码][代码]"regionchange"[代码] [代码]include-points[代码][代码]=[代码][代码]"{{buildlData[isSelectedBuildType].data}}"[代码] [代码]show-location[代码][代码]=[代码][代码]"{{islocation? 'true': 'false'}}"[代码] [代码]controls[代码][代码]=[代码][代码]"{{controls}}"[代码] [代码]style[代码][代码]=[代码][代码]"width: auto; height:{{fullscreen ? 89 : 48}}vh;background-color: #fff;"[代码][代码]>[代码][代码] [代码][代码]</[代码][代码]map[代码][代码]>[代码][代码]<!-- 地图 -->[代码] js: [代码]regionchange(e) {[代码][代码] [代码][代码]//console.log(e.type)[代码][代码] [代码][代码]//if (!this.data.fullscreen) {[代码][代码] [代码][代码]if[代码][代码](e.type == [代码][代码]"end"[代码][代码]){[代码][代码] [代码][代码]this[代码][代码].setData({ fullscreen: ![代码][代码]this[代码][代码].data.fullscreen })[代码][代码] [代码][代码]if[代码] [代码]([代码][代码]this[代码][代码].data.fullscreen) {[代码][代码] [代码][代码]this[代码][代码].setControls([代码][代码]this[代码][代码].data.windowWidth, [代码][代码]this[代码][代码].data.windowHeight - 54)[代码][代码] [代码][代码]this[代码][代码].setData({[代码][代码] [代码][代码]clickchar: [代码][代码]"⇑"[代码][代码] [代码][代码]})[代码][代码] [代码][代码]} [代码][代码]else[代码] [代码]{[代码][代码] [代码][代码]this[代码][代码].setControls([代码][代码]this[代码][代码].data.windowWidth, [代码][代码]this[代码][代码].data.windowHeight / 2)[代码][代码] [代码][代码]this[代码][代码].setData({[代码][代码] [代码][代码]clickchar: [代码][代码]"⇓"[代码][代码] [代码][代码]})[代码][代码] [代码][代码]} [代码][代码] [代码][代码]//移动地图事件[代码][代码] [代码][代码]// }*/ [代码][代码] [代码][代码]}[代码] 代码的大意是移动地图就改变是否全屏的状态 在电脑上测试没有问题 但是到手机上就循环触发事件 代码没有改变经纬度的值 不知道为什么