这是我的代码
Info.newInfoPopUp = function (obj) {
var table = createInfo(obj);
popup = new OpenLayers.Popup.FramedCloud(
obj.name,
obj.lonlat,
new OpenLayers.Size(),
'<table class="info-table popup">' + table.html() + '</table>',
null,
true,
obj.closeCallback
);
popup.minSize =new OpenLayers.Size(300,155);
popup.maxSize = new OpenLayers.Size(800,200);
return popup;
};
弹出窗口有时会出现垂直滚动条
任何想法?
答案 0 :(得分:0)
OpenLayers.Size类构造函数应该具有参数width和height。 试试这个:
var popup = new OpenLayers.Popup.FramedCloud(
obj.name,
obj.lonlat,
new OpenLayers.Size(100,100),
tablHtml,
null,
true,
obj.closeCallback
);