思うが、一応。。。
最初に必要な画面スクリーンサイズを取得、
リクエストサイクルセッティング
org.apache.wicket.settings.IRequestCycleSettings
WebApplication の init() で getRequestCycleSettings() で取得して
setGatherExtendedBrowserInfo(true) ブラウザ情報取得の拡張モードをtrue に
セットして Page クラスで、クライアントBrowser の情報取得する。
WebApplication で setGatherExtendedBrowserInfo(true) にしないと
通常の getRequestCycle().getClientInfo() では、画面スクリーンサイズまでは取り出せない。
------ WebApplication init() の中で、 -------
getRequestCycleSettings().setGatherExtendedBrowserInfo(true);
------ WebPage コンストラクタの中で、-------
ClientProperties properties = *1.getProperties();
int screenHeight = properties.getScreenHeight();
int screenWidth = properties.getScreenWidth();
// ポップアップウィンドウのセッティング
PopupSettings popupSettings = new PopupSettings(PageMap.forName("popupPagemap"))
.setHeight(screenHeight - 60).setWidth(screenWidth - 10)
.setTop(0).setLeft(0);
// Popup.class =ポップアップPageクラス を上のセッティングでリンクを作る
add(new BookmarkablePageLink<String>("start",Popup.class).setPopupSettings(popupSettings));
PopupSettings の 上記のように、setHeight , setWidth を調整しないと
画面からはみ出してしまった。
*1:WebClientInfo)getRequestCycle().getClientInfo(