diff options
author | sgilbertson <sgilbertson@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-07-15 16:07:18 +0000 |
---|---|---|
committer | sgilbertson <sgilbertson@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-07-15 16:07:18 +0000 |
commit | 581d57e6c0faef95b511984510372d09ca55210c (patch) | |
tree | 36d9688009aa0d1293f407c7660e7901e7986ce0 /libjava/gnu/awt/xlib/XGraphicsConfiguration.java | |
parent | 53c0d211319a9f957d984f6e40b2828e1c586d47 (diff) | |
download | ppe42-gcc-581d57e6c0faef95b511984510372d09ca55210c.tar.gz ppe42-gcc-581d57e6c0faef95b511984510372d09ca55210c.zip |
2005-07-15 Scott Gilbertson <scottg@mantatest.com>
* gnu/awt/xlib/XCanvasPeer.java (attributes): New field.
(eventMask): New field.
(XCanvasPeer(Component)): Use attributes field.
(setBackground): Implemented.
(setEventMask): Process mask only if changed.
* gnu/awt/xlib/XEventLoop.java (class): Iplement Runnable.
(eventLoopThread): New field.
(XEventLoop(Display,EventQueue)): Start eventLoopThread.
(interrupt): Removed.
(run): New method.
* gnu/awt/xlib/XEventQueue.java (getNextEvent): Process Container
and Component events.
* gnu/awt/xlib/XFramePeer.java (processingConfigureNotify): New
field.
(configureNotify): Set and clear processingConfigureNotify.
(setBounds): Process only if processingConfigureNotify is false.
(toBack): Implemented.
(toFront): Implemented.
* gnu/awt/xlib/XGraphics.java (setColor): Ignore null color.
* gnu/awt/xlib/XGraphicsConfiguration.java (getPixel): Ignore null
color.
* gnu/awt/xlib/XToolkit.java (nativeQueueEmpty): Always return true.
(wakeNativeQueue): Do nothing.
(iterateNativeQueue): Do queue.wait if blocking.
* gnu/gcj/xlib/Font.java (loadFont): New method.
(loadFontImpl): Renamed native method, was loadFont.
* gnu/gcj/xlib/Window.java (toFront): New method.
(toBack): New method.
* gnu/gcj/xlib/natFont.cc (loadFontImpl): Renamed method, was
loadFont.
* gnu/gcj/xlib/natWindow.cc (toBack): New method.
(toFront): New method.
* gnu/gcj/xlib/natXAnyEvent.cc (loadNext): Removed timeout.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@102057 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/gnu/awt/xlib/XGraphicsConfiguration.java')
-rw-r--r-- | libjava/gnu/awt/xlib/XGraphicsConfiguration.java | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/libjava/gnu/awt/xlib/XGraphicsConfiguration.java b/libjava/gnu/awt/xlib/XGraphicsConfiguration.java index bdbf3e18a74..d1202b83791 100644 --- a/libjava/gnu/awt/xlib/XGraphicsConfiguration.java +++ b/libjava/gnu/awt/xlib/XGraphicsConfiguration.java @@ -522,17 +522,20 @@ public class XGraphicsConfiguration extends GraphicsConfiguration }; */ - float[] normalizedComponents = - { - ((float)color.getRed ()) / 255F, - ((float)color.getGreen ()) / 255F, - ((float)color.getBlue ()) / 255F, - 1 - }; int[] unnormalizedComponents = { 0, 0, 0, 0xff }; ColorModel cm = getColorModel (); - cm.getUnnormalizedComponents(normalizedComponents, 0, - unnormalizedComponents, 0); + if (color != null) + { + float[] normalizedComponents = + { + ((float)color.getRed ()) / 255F, + ((float)color.getGreen ()) / 255F, + ((float)color.getBlue ()) / 255F, + 1 + }; + cm.getUnnormalizedComponents(normalizedComponents, 0, + unnormalizedComponents, 0); + } return cm.getDataElement (unnormalizedComponents, 0); } } |