This was dying with a NullPointerException when you started it up using
'ant tt-run' with no dictionary. Now it starts up and shows you a nice error message, "Dictionary could not be loaded!", instead.
This commit is contained in:
parent
e198519c5f
commit
2bb499e5a7
1 changed files with 2 additions and 1 deletions
|
@ -70,7 +70,7 @@ public abstract class ScannerPanel extends Panel implements ActionListener
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
status.setText("Dictionary could no be loaded!");
|
status.setText("Dictionary could not be loaded!");
|
||||||
exito=false;
|
exito=false;
|
||||||
}
|
}
|
||||||
add(panel1, BorderLayout.NORTH);
|
add(panel1, BorderLayout.NORTH);
|
||||||
|
@ -88,6 +88,7 @@ public abstract class ScannerPanel extends Panel implements ActionListener
|
||||||
{
|
{
|
||||||
int rows, n;
|
int rows, n;
|
||||||
|
|
||||||
|
if (null == scanner) return null;
|
||||||
String dictionaries[] = scanner.getDictionaryDescriptions();
|
String dictionaries[] = scanner.getDictionaryDescriptions();
|
||||||
if (dictionaries!=null)
|
if (dictionaries!=null)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue