diff options
| author | Fuwn <[email protected]> | 2021-05-03 16:38:41 -0700 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2021-05-03 16:38:41 -0700 |
| commit | e1e781bb2135ef78592226f1a3eaba4925702f1f (patch) | |
| tree | 8a5b590463ed413e1c6eabb719130e701b95ca63 /NET/worlds/console/ConfirmDialog.java | |
| download | worlds.jar-e1e781bb2135ef78592226f1a3eaba4925702f1f.tar.xz worlds.jar-e1e781bb2135ef78592226f1a3eaba4925702f1f.zip | |
Diffstat (limited to 'NET/worlds/console/ConfirmDialog.java')
| -rw-r--r-- | NET/worlds/console/ConfirmDialog.java | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/NET/worlds/console/ConfirmDialog.java b/NET/worlds/console/ConfirmDialog.java new file mode 100644 index 0000000..8b368e4 --- /dev/null +++ b/NET/worlds/console/ConfirmDialog.java @@ -0,0 +1,68 @@ +/* */ package NET.worlds.console; +/* */ +/* */ import java.awt.Button; +/* */ import java.awt.GridBagConstraints; +/* */ import java.awt.Label; +/* */ import java.awt.Window; +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ public class ConfirmDialog +/* */ extends OkCancelDialog +/* */ { +/* */ private static final long serialVersionUID = 2839131701328189735L; +/* */ private String prompt; +/* */ +/* */ public ConfirmDialog(Window parent, DialogReceiver target, String title, String prompt) +/* */ { +/* 29 */ super(parent, target, title, Console.message("No"), Console.message("Yes")); +/* 30 */ this.prompt = prompt; +/* 31 */ ready(); +/* */ } +/* */ +/* */ public ConfirmDialog(Window parent, String title, String prompt) { +/* 35 */ this(parent, (DialogReceiver)parent, title, prompt); +/* */ } +/* */ +/* */ protected void build() +/* */ { +/* 40 */ GridBagConstraints c = new GridBagConstraints(); +/* 41 */ c.weightx = 1.0D; +/* 42 */ c.weighty = 1.0D; +/* 43 */ c.gridwidth = 0; +/* 44 */ add(this.gbag, new Label(this.prompt), c); +/* 45 */ super.build(); +/* */ } +/* */ +/* */ protected boolean setValue() +/* */ { +/* 50 */ return true; +/* */ } +/* */ +/* */ +/* */ +/* */ public void setVisible(boolean visible) +/* */ { +/* 57 */ super.setVisible(visible); +/* 58 */ if (visible) { +/* 59 */ this.okButton.requestFocus(); +/* */ } +/* */ } +/* */ } + + +/* Location: C:\Program Files (x86)\Worlds Inc\WorldsPlayer - Win7\lib\worlds.jar!\NET\worlds\console\ConfirmDialog.class + * Java compiler version: 6 (50.0) + * JD-Core Version: 0.7.1 + */
\ No newline at end of file |