mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 00:01:50 +00:00
On a slow machine, there's a NullException as getGraphics() returns after
UI disappears.
This commit is contained in:
parent
b553b3670f
commit
abe3909f53
@ -41,8 +41,11 @@ public class Animation extends Component implements Runnable
|
||||
{
|
||||
try
|
||||
{
|
||||
Graphics g;
|
||||
fThread.sleep(100);
|
||||
paint(getGraphics());
|
||||
g = getGraphics();
|
||||
if (g != null)
|
||||
paint(getGraphics());
|
||||
fCurrent++;
|
||||
fCurrent %= fGlyphs.length;
|
||||
if (fCurrent == 0)
|
||||
|
Loading…
Reference in New Issue
Block a user