Dialog.java (constructor): Accept null title as per spec.
* java/awt/Dialog.java (constructor): Accept null title as per spec. * java/awt/FileDialog.java (constructor): Throw exception on invalid argument as per spec. From-SVN: r75444
This commit is contained in:
parent
b7a9b4af03
commit
975fde59af
3 changed files with 19 additions and 4 deletions
|
@ -147,6 +147,11 @@ public
|
|||
FileDialog(Frame parent, String title, int mode)
|
||||
{
|
||||
super(parent, title, true);
|
||||
|
||||
if ((mode != LOAD) && (mode != SAVE))
|
||||
throw new IllegalArgumentException (
|
||||
"Mode argument must be either LOAD or SAVE");
|
||||
|
||||
setMode (mode);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue