src/java.desktop/share/classes/sun/awt/SunGraphicsCallback.java
Print this page
*** 1,7 ****
/*
! * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
--- 1,7 ----
/*
! * Copyright (c) 1999, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
*** 45,59 ****
g.translate(bounds.x, bounds.y);
}
g.clipRect(0, 0, bounds.width, bounds.height);
}
- @SuppressWarnings("deprecation")
public final void runOneComponent(Component comp, Rectangle bounds,
Graphics g, Shape clip,
int weightFlags) {
! if (comp == null || comp.getPeer() == null || !comp.isVisible()) {
return;
}
boolean lightweight = comp.isLightweight();
if ((lightweight && (weightFlags & LIGHTWEIGHTS) == 0) ||
(!lightweight && (weightFlags & HEAVYWEIGHTS) == 0)) {
--- 45,58 ----
g.translate(bounds.x, bounds.y);
}
g.clipRect(0, 0, bounds.width, bounds.height);
}
public final void runOneComponent(Component comp, Rectangle bounds,
Graphics g, Shape clip,
int weightFlags) {
! if (comp == null || !comp.isDisplayable() || !comp.isVisible()) {
return;
}
boolean lightweight = comp.isLightweight();
if ((lightweight && (weightFlags & LIGHTWEIGHTS) == 0) ||
(!lightweight && (weightFlags & HEAVYWEIGHTS) == 0)) {