mirror of
https://gitlab.com/AutumnMeowMeow/jexer
synced 2024-09-19 11:50:19 -06:00
fix npe
This commit is contained in:
parent
937d475421
commit
87f1b95190
1 changed files with 11 additions and 3 deletions
|
@ -1492,7 +1492,10 @@ public class TTerminalWidget extends TScrollableWidget
|
|||
synchronized (dirtyQueue) {
|
||||
dirtyQueue.add(display);
|
||||
}
|
||||
getApplication().doRepaint();
|
||||
TApplication app = getApplication();
|
||||
if (app != null) {
|
||||
app.doRepaint();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1502,8 +1505,11 @@ public class TTerminalWidget extends TScrollableWidget
|
|||
* may be on a different location.
|
||||
*/
|
||||
public void displayChanged(final boolean cursorOnly) {
|
||||
TApplication app = getApplication();
|
||||
if (cursorOnly) {
|
||||
getApplication().doRepaint();
|
||||
if (app != null) {
|
||||
app.doRepaint();
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1516,7 +1522,9 @@ public class TTerminalWidget extends TScrollableWidget
|
|||
if (readDisplay) {
|
||||
readEmulatorDisplay();
|
||||
}
|
||||
getApplication().doRepaint();
|
||||
if (app != null) {
|
||||
app.doRepaint();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue