Reputation: 103
Test it with primefaces demo page, just scroll bottom our window, then press view , it will show a dialog on middle center window, but try resize it, dialog position will float to top.
please show me how to fix it :(.
Sorry about my English skill;
Upvotes: 3
Views: 2082
Reputation: 989
I don´t sure what you want but if you want change first position you can do it different ways:
By default dialog is positioned at center of the viewport and position option is used to change the location of the dialog. Possible values are;
• Single string value like ‘center’, ‘left’, ‘right’, ‘top’, ‘bottom’ representing the position within viewport.
• Comma separated x and y coordinate values like 200, 500
• Comma separated position values like ‘top’,‘right’. (Use single quotes when using a combination)
This you must write in your configuration map that you send:
Map<String,Object> configurationMap= new HashMap<String, Object>();
configurationMap.put("position", "top");
RequestContext.getCurrentInstance().openDialog("nameDialog", configurationMap, null);
Upvotes: 1