Color.java (getAlpha): Prevent sign-extended alpha values.
2003-08-12 Graydon Hoare <graydon@redhat.com> * java/awt/Color.java (getAlpha): Prevent sign-extended alpha values. From-SVN: r70401
This commit is contained in:
parent
4717fcc7f7
commit
479f4325c8
@ -1,3 +1,8 @@
|
||||
2003-08-12 Graydon Hoare <graydon@redhat.com>
|
||||
|
||||
* java/awt/Color.java (getAlpha):
|
||||
Prevent sign-extended alpha values.
|
||||
|
||||
2003-08-12 Tom Tromey <tromey@redhat.com>
|
||||
|
||||
* gij.cc (main): Handle -? and -X.
|
||||
|
@ -496,7 +496,7 @@ public class Color implements Paint, Serializable
|
||||
public int getAlpha()
|
||||
{
|
||||
// Do not inline getRGB() to value, because of SystemColor.
|
||||
return (getRGB() & ALPHA_MASK) >> 24;
|
||||
return (getRGB() & ALPHA_MASK) >>> 24;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user