gpt4 book ai didi

jquery-ui - 设置 jquery ui 的对话框模式宽度?

转载 作者:行者123 更新时间:2023-12-02 19:55:44 32 4
gpt4 key购买 nike

你好

我正在使用this demo显示模式对话框

如果我将对话框用于谷歌街景,如何设置对话框的宽度:

var point = new GLatLng(svlat, svlon);
var panoClient = new GStreetviewClient();
panoClient.getNearestPanoramaLatLng(point, function (newPoint) {
if (newPoint == null) {
alert("no panorama found for this position!!");
return;
}
panoramaOptions = { latlng: newPoint };
myPano = new GStreetviewPanorama(document.getElementById("pano"), panoramaOptions);
$('#dialogStreetView').dialog("option", "maxWidth", 600);
$('#dialogStreetView').dialog('open');
GEvent.addListener(myPano, "error", handleNoFlash);
});

HTML:

<div id="dialogStreetView" title="Street View Provided by Google... "     style="width:300px;height:300px">
<a id="closestreet-view" name="closestreet-view" style="cursor:pointer; text- decoration:underline" >Close</a>
<div name="pano" id="pano" style="width: 300px; height: 300px"></div>
</div>

最佳答案

来自文档:

这应该有效:

$("#dialogStreetView").dialog( "option", "width", 460 );

关于jquery-ui - 设置 jquery ui 的对话框模式宽度?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4263358/

32 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com