| | |
| | | var longitude = 106.638135; |
| | | var latitude = 29.709625; |
| | | point = new BMap.Point(longitude, latitude); |
| | | } else if ("射阳县" == regoinNames[2]) { |
| | | var longitude = 120.332826; |
| | | var latitude = 33.772274; |
| | | point = new BMap.Point(longitude, latitude); |
| | | } |
| | | map.centerAndZoom(point, showZoom); |
| | | } else { |
| | |
| | | var timer = setTimeout(function () { |
| | | baiduMap.closeInfoWindow.apply(baiduMap, arguments); |
| | | moralMap["_closeInfoWinTimer"] = null; |
| | | }, 1200); |
| | | }, 500); |
| | | moralMap["_closeInfoWinTimer"] = timer; |
| | | } |
| | | moralMap.clearOverlays = function () { |
| | |
| | | } |
| | | var mouseOverHandle = option['mouseover']; |
| | | moralMarker.addEventListener("mouseover", function () { |
| | | /* var obj = {}; |
| | | obj['methodName'] = 'deliverMac'; |
| | | obj['mac'] = option['mac']; |
| | | var objStr = JSON.stringify(obj); |
| | | if (!!window['external'] && !!window['external']['callWin']) { |
| | | window['external'].callWin(objStr); |
| | | } else { |
| | | alert(objStr); |
| | | }*/ |
| | | |
| | | moralMap.showSensors = function (jsonData) { |
| | | var deviceSensors = jsonData; |
| | | var mac = deviceSensors["mac"]; |
| | | if (mac == option['mac']) { |
| | | if (!jsonData.hasOwnProperty('mac')) { |
| | | infoWindow.setContent(""); |
| | | infoWindow.redraw(); |
| | | } else { |
| | | if (!jsonData.hasOwnProperty('mac')) { |
| | | infoWindow.setContent(""); |
| | | infoWindow.redraw(); |
| | | } else { |
| | | if (mac == option['mac']) { |
| | | var adressOutHtml = '<div style="min-height:20px;overflow:auto;max-height:480px;font-size: 12px;" onmouseover="moralMap.clearCloseInfoWindow()" onmouseout="moralMap.closeInfoWindow()">'; |
| | | var y, m, d, h, mm, s; |
| | | var date = new Date($.now()); |
| | |
| | | } |
| | | } |
| | | } |
| | | // } |
| | | /* if (!$.isEmptyObject(sensorInfo)) { |
| | | moralMap.openInfoWindow(infoWindow, this._point); //开启信息窗口 |
| | | }*/ |
| | |
| | | }); |
| | | |
| | | moralMarker.addEventListener("mouseout", function () { |
| | | /* var obj = {}; |
| | | obj['methodName'] = 'stopDeliverMac'; |
| | | var objStr = JSON.stringify(obj); |
| | | if (!!window['external'] && !!window['external']['callWin']) { |
| | | window['external'].callWin(objStr); |
| | | } else { |
| | | alert(objStr); |
| | | }*/ |
| | | moralMap.closeInfoWindow(); |
| | | }); |
| | | |
| | |
| | | if (longitude < bounds.northeastLng && longitude > bounds.southwestLng && latitude < bounds.northeastLat && latitude > bounds.southwestLat) { |
| | | markers.push(oldmarker); |
| | | } |
| | | if ("国控站" === option["monitorPoint"]["description"]) { |
| | | var icon05 = new BMap.Icon("/img/ico05.png", new BMap.Size(50, 50)); |
| | | var mark05 = new BMap.Marker(new BMap.Point(option["monitorPoint"]["longitude"], option["monitorPoint"]["latitude"]), {icon: icon05}); |
| | | markers.push(mark05); |
| | | } else if ("省控站" === option["monitorPoint"]["description"]) { |
| | | var icon06 = new BMap.Icon("/img/ico06.png", new BMap.Size(50, 50)); |
| | | var mark06 = new BMap.Marker(new BMap.Point(option["monitorPoint"]["longitude"], option["monitorPoint"]["latitude"]), {icon: icon06}); |
| | | markers.push(mark06); |
| | | } else if ("县控站" === option["monitorPoint"]["description"]) { |
| | | var icon08 = new BMap.Icon("/img/ico08.png", new BMap.Size(50, 50)); |
| | | var mark08 = new BMap.Marker(new BMap.Point(option["monitorPoint"]["longitude"], option["monitorPoint"]["latitude"]), {icon: icon08}); |
| | | markers.push(mark08); |
| | | } |
| | | } |
| | | } |
| | | } |