は、誰かが私は他のすべての前に現在の場所に置く助けることができますか?私はMAX_ZINDEXとsetZindex()について読みましたが、私はそれを理解することはできません。これは私のコードです:他のすべての前でGoogleマップV3からマーカー入れ
var latlng = new google.maps.LatLng(lat,lng);
var image = "";
var currentplace = "Ohla Hotel";
var zInd = "";
if(name == currentplace) {
image = "../img/hotel_icon.png";
}
else {
image = "../img/home_icon.png";
}
//alert();
var maxZindex = google.maps.Marker.MAX_ZINDEX;
if(name == currentplace) {
zInd = (maxZindex + 1);
}
var locationDescription = this.locationDescription;
var marker = new google.maps.Marker({
map: map,
position: latlng,
title:'pk:'+name,
MAX_ZINDEX: zInd,
icon: image
});
bounds.extend(latlng);
setMarker(map, marker, name, locationDescription);
私はすでに、'zIndexそれを試しています、999 "を与えると、それがすべてでは動作していないが、エラーの場所私ですが、私は'google.maps.event.addListener(マーカー、行う場合は「{)(マウスオーバー」、機能を \t \t marker.setZIndex(9999); ib.close(); //ib.setContent($infoWindowContent[0]); ib.open(マップ、マーカー); 'それは私が必要なものだけホバーで働きます緯度とLNG – outman
あなたは 'MarkerOptions.zIndex'プロパティを使用しようとすると、あなたが得るエラーは何ですか? –
あなたはマーカーが配置されていない意味しますかマップ?LAT&LNGの? – outman