369 |
inputValue = UNINITIALIZED_VALUE; |
inputValue = UNINITIALIZED_VALUE; |
370 |
value = UNINITIALIZED_VALUE; |
value = UNINITIALIZED_VALUE; |
371 |
|
|
|
// FIXME: This dialog should be centered on the parent |
|
|
// or at the center of the screen (if the parent is null) |
|
|
// Need getGraphicsConfiguration to return non-null in |
|
|
// order for that to work so we know how large the |
|
|
// screen is. |
|
372 |
dialog.getContentPane().add(this); |
dialog.getContentPane().add(this); |
373 |
dialog.setModal(true); |
dialog.setModal(true); |
374 |
dialog.setResizable(false); |
dialog.setResizable(false); |
375 |
|
dialog.pack(); |
376 |
|
dialog.setLocationRelativeTo(parentComponent); |
377 |
|
|
378 |
return dialog; |
return dialog; |
379 |
} |
} |
380 |
|
|
857 |
{ |
{ |
858 |
JOptionPane pane = new JOptionPane(message, QUESTION_MESSAGE); |
JOptionPane pane = new JOptionPane(message, QUESTION_MESSAGE); |
859 |
JDialog dialog = pane.createDialog(parentComponent, "Select an Option"); |
JDialog dialog = pane.createDialog(parentComponent, "Select an Option"); |
|
|
|
|
dialog.pack(); |
|
860 |
dialog.show(); |
dialog.show(); |
861 |
|
|
862 |
if (pane.getValue() instanceof Integer) |
if (pane.getValue() instanceof Integer) |
883 |
{ |
{ |
884 |
JOptionPane pane = new JOptionPane(message, PLAIN_MESSAGE, optionType); |
JOptionPane pane = new JOptionPane(message, PLAIN_MESSAGE, optionType); |
885 |
JDialog dialog = pane.createDialog(parentComponent, title); |
JDialog dialog = pane.createDialog(parentComponent, title); |
|
dialog.pack(); |
|
886 |
dialog.show(); |
dialog.show(); |
887 |
|
|
888 |
if (pane.getValue() instanceof Integer) |
if (pane.getValue() instanceof Integer) |
910 |
{ |
{ |
911 |
JOptionPane pane = new JOptionPane(message, messageType, optionType); |
JOptionPane pane = new JOptionPane(message, messageType, optionType); |
912 |
JDialog dialog = pane.createDialog(parentComponent, title); |
JDialog dialog = pane.createDialog(parentComponent, title); |
|
dialog.pack(); |
|
913 |
dialog.show(); |
dialog.show(); |
914 |
|
|
915 |
if (pane.getValue() instanceof Integer) |
if (pane.getValue() instanceof Integer) |
939 |
{ |
{ |
940 |
JOptionPane pane = new JOptionPane(message, messageType, optionType, icon); |
JOptionPane pane = new JOptionPane(message, messageType, optionType, icon); |
941 |
JDialog dialog = pane.createDialog(parentComponent, title); |
JDialog dialog = pane.createDialog(parentComponent, title); |
|
dialog.pack(); |
|
942 |
dialog.show(); |
dialog.show(); |
943 |
|
|
944 |
if (pane.getValue() instanceof Integer) |
if (pane.getValue() instanceof Integer) |
964 |
JOptionPane pane = new JOptionPane(message, QUESTION_MESSAGE); |
JOptionPane pane = new JOptionPane(message, QUESTION_MESSAGE); |
965 |
pane.setWantsInput(true); |
pane.setWantsInput(true); |
966 |
JDialog dialog = pane.createDialog(parentComponent, null); |
JDialog dialog = pane.createDialog(parentComponent, null); |
|
dialog.pack(); |
|
967 |
dialog.show(); |
dialog.show(); |
968 |
|
|
969 |
return (String) pane.getInputValue(); |
return (String) pane.getInputValue(); |
990 |
pane.setInitialSelectionValue(initialSelectionValue); |
pane.setInitialSelectionValue(initialSelectionValue); |
991 |
pane.setWantsInput(true); |
pane.setWantsInput(true); |
992 |
JDialog dialog = pane.createDialog(parentComponent, null); |
JDialog dialog = pane.createDialog(parentComponent, null); |
|
dialog.pack(); |
|
993 |
dialog.show(); |
dialog.show(); |
994 |
|
|
995 |
return (String) pane.getInputValue(); |
return (String) pane.getInputValue(); |
1015 |
JOptionPane pane = new JOptionPane(message, messageType); |
JOptionPane pane = new JOptionPane(message, messageType); |
1016 |
pane.setWantsInput(true); |
pane.setWantsInput(true); |
1017 |
JDialog dialog = pane.createDialog(parentComponent, title); |
JDialog dialog = pane.createDialog(parentComponent, title); |
|
dialog.pack(); |
|
1018 |
dialog.show(); |
dialog.show(); |
1019 |
|
|
1020 |
return (String) pane.getInputValue(); |
return (String) pane.getInputValue(); |
1047 |
pane.setSelectionValues(selectionValues); |
pane.setSelectionValues(selectionValues); |
1048 |
pane.setInitialSelectionValue(initialSelectionValue); |
pane.setInitialSelectionValue(initialSelectionValue); |
1049 |
JDialog dialog = pane.createDialog(parentComponent, title); |
JDialog dialog = pane.createDialog(parentComponent, title); |
|
dialog.pack(); |
|
1050 |
dialog.show(); |
dialog.show(); |
1051 |
|
|
1052 |
return pane.getInputValue(); |
return pane.getInputValue(); |
1067 |
JOptionPane pane = new JOptionPane(message, QUESTION_MESSAGE); |
JOptionPane pane = new JOptionPane(message, QUESTION_MESSAGE); |
1068 |
pane.setWantsInput(true); |
pane.setWantsInput(true); |
1069 |
JDialog dialog = pane.createDialog(null, null); |
JDialog dialog = pane.createDialog(null, null); |
|
dialog.pack(); |
|
1070 |
dialog.show(); |
dialog.show(); |
1071 |
|
|
1072 |
return (String) pane.getInputValue(); |
return (String) pane.getInputValue(); |
1091 |
pane.setWantsInput(true); |
pane.setWantsInput(true); |
1092 |
pane.setInitialSelectionValue(initialSelectionValue); |
pane.setInitialSelectionValue(initialSelectionValue); |
1093 |
JDialog dialog = pane.createDialog(null, null); |
JDialog dialog = pane.createDialog(null, null); |
|
dialog.pack(); |
|
1094 |
dialog.show(); |
dialog.show(); |
1095 |
|
|
1096 |
return (String) pane.getInputValue(); |
return (String) pane.getInputValue(); |
1395 |
{ |
{ |
1396 |
JOptionPane pane = new JOptionPane(message, INFORMATION_MESSAGE); |
JOptionPane pane = new JOptionPane(message, INFORMATION_MESSAGE); |
1397 |
JDialog dialog = pane.createDialog(parentComponent, null); |
JDialog dialog = pane.createDialog(parentComponent, null); |
|
dialog.pack(); |
|
1398 |
dialog.show(); |
dialog.show(); |
1399 |
} |
} |
1400 |
|
|
1413 |
{ |
{ |
1414 |
JOptionPane pane = new JOptionPane(message, messageType); |
JOptionPane pane = new JOptionPane(message, messageType); |
1415 |
JDialog dialog = pane.createDialog(parentComponent, title); |
JDialog dialog = pane.createDialog(parentComponent, title); |
|
dialog.pack(); |
|
1416 |
dialog.show(); |
dialog.show(); |
1417 |
} |
} |
1418 |
|
|
1433 |
JOptionPane pane = new JOptionPane(message, messageType); |
JOptionPane pane = new JOptionPane(message, messageType); |
1434 |
pane.setIcon(icon); |
pane.setIcon(icon); |
1435 |
JDialog dialog = pane.createDialog(parentComponent, title); |
JDialog dialog = pane.createDialog(parentComponent, title); |
|
dialog.pack(); |
|
1436 |
dialog.show(); |
dialog.show(); |
1437 |
} |
} |
1438 |
|
|
1462 |
options, initialValue); |
options, initialValue); |
1463 |
|
|
1464 |
JDialog dialog = pane.createDialog(parentComponent, title); |
JDialog dialog = pane.createDialog(parentComponent, title); |
|
dialog.pack(); |
|
1465 |
dialog.show(); |
dialog.show(); |
1466 |
|
|
1467 |
if (pane.getValue() instanceof Integer) |
if (pane.getValue() instanceof Integer) |