szgeoinfo.ModelInfoWindow

Class: szgeoinfo.ModelInfoWindow


new ModelInfoWindow(position, name, con)

三维模型提示窗口

Parameters:
Name Type Description
position szgeoinfo.Point

位置

name string

窗口名称

con string

窗口内容

Example
var  infoWin = new szgeoinfo.ModelInfoWindow(point, "弹出窗口", "<a><img src=\'Pag.png\' style=\'width:30px;height:30px;\'/></a>");
map.add3dModelInfo(infoWin);
infoWin.setVisible(false);//隐藏
infoWin.setContent("<h2>修改窗口内容</h2>");

Methods


destroy()

销毁三维模型提示窗口对象


hide()

三维模型提示窗口的隐藏


setContent(content)

三维模型提示窗口设置内容

Parameters:
Name Type Description
content string

内容


setPosition(lat, lng, hei)

三维模型提示窗口设置位置

Parameters:
Name Type Description
lat double

纬度

lng double

经度

hei double

高度


setSceneAndContain(map, contain)

将ModelInfoWindow添加到指定div,仅在三维模式下

Parameters:
Name Type Description
map map

map的对象

contain element

div对象

Example
var dd=document.getElementById("map1");
infoWin.setSceneAndContain(map.get3DScene(),dd);

setVisible(visible)

三维模型提示窗口显示隐藏

Parameters:
Name Type Description
visible boolean

显示隐藏


updateAll(position, title, content)

更新三维模型提示窗口的信息

Parameters:
Name Type Description
position szgeoinfo.Point

点位置

title string

窗口名称

content string

窗口内容

Example
infoWin.updateAll(point1,"更新","更新后的内容");