6391806: JLabel and AbstractButton's imageUpdate method should be better specified
Reviewed-by: psadhukhan, prr
This commit is contained in:
parent
0ade2641f7
commit
3677b55b45
@ -2146,11 +2146,12 @@ public abstract class AbstractButton extends JComponent implements ItemSelectabl
|
||||
|
||||
|
||||
/**
|
||||
* This is overridden to return false if the current <code>Icon</code>'s
|
||||
* <code>Image</code> is not equal to the
|
||||
* passed in <code>Image</code> <code>img</code>.
|
||||
* If the button icon for the current button state is either {@code null}
|
||||
* or not an {@code ImageIcon} with an {@code Image} equal to the
|
||||
* passed in {@code Image}, return {@code false}; otherwise it
|
||||
* will delegate to the super-class.
|
||||
*
|
||||
* @param img the <code>Image</code> to be compared
|
||||
* @param img the {@code Image} to be compared
|
||||
* @param infoflags flags used to repaint the button when the image
|
||||
* is updated and which determine how much is to be painted
|
||||
* @param x the x coordinate
|
||||
|
@ -874,8 +874,18 @@ public class JLabel extends JComponent implements SwingConstants, Accessible
|
||||
|
||||
|
||||
/**
|
||||
* This is overridden to return false if the current Icon's Image is
|
||||
* not equal to the passed in Image <code>img</code>.
|
||||
* If the component is not showing or either the icon or disabled
|
||||
* icon is not an {@code ImageIcon} with an {@code Image}
|
||||
* equal to the passed in {@code Image}, return {@code false};
|
||||
* otherwise it will delegate to the super-class.
|
||||
*
|
||||
* @param img the {@code Image} to be compared
|
||||
* @param infoflags flags used to repaint the label when the image
|
||||
* is updated and which determine how much is to be painted
|
||||
* @param x the x coordinate
|
||||
* @param y the y coordinate
|
||||
* @param w the width
|
||||
* @param h the height
|
||||
*
|
||||
* @see java.awt.image.ImageObserver
|
||||
* @see java.awt.Component#imageUpdate(java.awt.Image, int, int, int, int, int)
|
||||
|
Loading…
x
Reference in New Issue
Block a user