Also need to cope with non-component _root in BackFrameManager
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@228 ed5b42cb-e716-0410-a449-f6a68f950b19
This commit is contained in:
@@ -85,7 +85,8 @@ public class BackFrameManager extends FrameManager
|
||||
// we cache our frame's graphics object so that we can avoid
|
||||
// instantiating a new one on every tick
|
||||
if (_fgfx == null) {
|
||||
_fgfx = (Graphics2D)((Component)_root).getGraphics();
|
||||
Component comp = (_root instanceof Component) ? (Component)_root : _window;
|
||||
_fgfx = (Graphics2D)(comp.getGraphics());
|
||||
}
|
||||
_fgfx.drawImage(_backimg, 0, 0, null);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user