85 |
/** |
/** |
86 |
* This is a helper class that listens to the buttons located at the bottom |
* This is a helper class that listens to the buttons located at the bottom |
87 |
* of the JOptionPane. |
* of the JOptionPane. |
88 |
|
* |
89 |
|
* @specnote Apparently this class was intended to be protected, |
90 |
|
* but was made public by a compiler bug and is now |
91 |
|
* public for compatibility. |
92 |
*/ |
*/ |
93 |
protected class ButtonActionListener implements ActionListener |
public class ButtonActionListener implements ActionListener |
94 |
{ |
{ |
95 |
/** The index of the option this button represents. */ |
/** The index of the option this button represents. */ |
96 |
protected int buttonIndex; |
protected int buttonIndex; |
156 |
* This helper layout manager is responsible for the layout of the button |
* This helper layout manager is responsible for the layout of the button |
157 |
* area. The button area is the panel that holds the buttons which |
* area. The button area is the panel that holds the buttons which |
158 |
* represent the options. |
* represent the options. |
159 |
|
* |
160 |
|
* @specnote Apparently this class was intended to be protected, |
161 |
|
* but was made public by a compiler bug and is now |
162 |
|
* public for compatibility. |
163 |
*/ |
*/ |
164 |
protected class ButtonAreaLayout implements LayoutManager |
// FIXME: should be static |
165 |
|
public class ButtonAreaLayout implements LayoutManager |
166 |
{ |
{ |
167 |
/** Whether this layout will center the buttons. */ |
/** Whether this layout will center the buttons. */ |
168 |
protected boolean centersChildren = true; |
protected boolean centersChildren = true; |
375 |
|
|
376 |
/** |
/** |
377 |
* This helper class handles property change events from the JOptionPane. |
* This helper class handles property change events from the JOptionPane. |
378 |
|
* |
379 |
|
* @specnote Apparently this class was intended to be protected, |
380 |
|
* but was made public by a compiler bug and is now |
381 |
|
* public for compatibility. |
382 |
*/ |
*/ |
383 |
public class PropertyChangeHandler implements PropertyChangeListener |
public class PropertyChangeHandler implements PropertyChangeListener |
384 |
{ |
{ |
466 |
private transient Border buttonBorder; |
private transient Border buttonBorder; |
467 |
|
|
468 |
/** The string used to describe OK buttons. */ |
/** The string used to describe OK buttons. */ |
|
// FIXME: wrong name for a constant. |
|
469 |
private static final String OK_STRING = "OK"; |
private static final String OK_STRING = "OK"; |
470 |
|
|
471 |
/** The string used to describe Yes buttons. */ |
/** The string used to describe Yes buttons. */ |
|
// FIXME: wrong name for a constant. |
|
472 |
private static final String YES_STRING = "Yes"; |
private static final String YES_STRING = "Yes"; |
473 |
|
|
474 |
/** The string used to describe No buttons. */ |
/** The string used to describe No buttons. */ |
|
// FIXME: wrong name for a constant. |
|
475 |
private static final String NO_STRING = "No"; |
private static final String NO_STRING = "No"; |
476 |
|
|
477 |
/** The string used to describe Cancel buttons. */ |
/** The string used to describe Cancel buttons. */ |
|
// FIXME: wrong name for a constant. |
|
478 |
private static final String CANCEL_STRING = "Cancel"; |
private static final String CANCEL_STRING = "Cancel"; |
479 |
|
|
480 |
/** The container for the message area. |
/** The container for the message area. |