我有一個要求,當點擊一個按鈕,用戶應該被提示彈出/對話框輸入一些額外的細節,如姓氏,出生等,我試圖玩window.confirm()
,但我認爲這樣做不符合我的目的。有人可以幫助我如何通過UIBinder在GWT中實現這一點嗎?GWT Popup和UIBinder:Panel或DialogBox?
我嘗試一些像這樣的事情在我的UI binder.xml
<g:HTMLPanel visible="false" >
<g:DialogBox ui:field="dialogPanel"
animationEnabled="true" modal="false" glassEnabled="false">
<g:caption>More Details</g:caption>
<table>
<tr>
<td colspan="2" align="center">
<g:Datepicker ui:field="DOB">DOB:</g:Datepicker>
</td>
</tr>
<tr>
<td>UserName:</td>
<td>
<g:TextBox ui:field="usernameTextBox" />
</td>
</tr>
<tr>
<td></td>
<td align="right">
<g:Button ui:field="loginButton">OK</g:Button>
</td>
</tr>
</table>
</g:DialogBox>
</g:HTMLPanel>
我不知道有去其中一個:彈出窗口或對話框!
謝謝。
嗨,感謝您的答覆。我能夠得到這個只需稍作改動。我仍然將Html包裹在dialogBox標籤中。我必須在我的UiHandler方法中調用dialogBox.center()。 – user874722