【发布时间】:2016-08-14 19:31:09
【问题描述】:
我厌倦了在首页打开拨号。
我在地图属性中添加标志position 设置为top 但不起作用。
primefaces 6.0
对话框在中心可见。
public void openWindowNotification() {
try {
System.err.println("openWindowNotification");
Map<String, Object> options = new HashMap<String, Object>();
options.put("draggable", false);
options.put("modal", true);
options.put("position", "top"); // <--- not work
options.put("width", "90%");
options.put("contentWidth", "90%");
options.put("height", "90%");
options.put("contentheight", "90%");
options.put("size", "auto");
options.put("widgetVar", "editarDialog");
RequestContext.getCurrentInstance().openDialog("window/WindowNotification", options, null);
} catch (Exception e) {
e.printStackTrace();
}
}
有什么想法吗?
编辑: 火虫显示代码:
> <div id="formFindPanel:bAdd_dlg" class="ui-dialog ui-widget
> ui-widget-content ui-corner-all ui-shadow ui-hidden-container
> ui-resizable ui-overlay-visible"
> data-widgetvar="formFindPanel_bAdd_dlgwidget"
> data-pfdlgcid="96e9d80e-f114-49a2-8699-1684bf9e3418" style="width:
> 90%; height: auto; left: 83px; top: 365.5px; visibility: visible;
> z-index: 1001; display: block;" role="dialog"
> aria-labelledby="formFindPanel:bAdd_dlg_title" aria-hidden="false"
> aria-live="polite">
在 css 中是 toppropertis 365.5px 是什么导致该对话框位于中心。
我需要设置在 ~15px 左右的顶部;
【问题讨论】:
-
@YagamiLight: 用咆哮代替 PF 对话框框架中的对话框???
-
请始终发布版本信息。但在这种情况下,它有点无关紧要。 5.3 和 6.0 中没有“位置”配置选项。也许您可以查看生成的 html 并在包含对话框页面的 iframe 上尝试一些 css
-
我不会咆哮,我的窗口是标准对话框/窗口有输入控件和按钮提交
-
是否可以将类似...
position:absolute; top: 80%;的内容设置为进一步的属性?
标签: jsf-2 primefaces