diff options
author | Michael Koch <mkoch@gcc.gnu.org> | 2005-04-25 20:58:13 +0000 |
---|---|---|
committer | Michael Koch <mkoch@gcc.gnu.org> | 2005-04-25 20:58:13 +0000 |
commit | 84e0bcb8c5ba97ea0b2c07559f5c2957069de7e5 (patch) | |
tree | 47bf146f4f42a0c5e1d493a32e405cf8e3712fcd /libjava/gnu/java | |
parent | 4b30c6bda06ac549212f96617c4c3e171e56876a (diff) | |
download | gcc-84e0bcb8c5ba97ea0b2c07559f5c2957069de7e5.zip gcc-84e0bcb8c5ba97ea0b2c07559f5c2957069de7e5.tar.gz gcc-84e0bcb8c5ba97ea0b2c07559f5c2957069de7e5.tar.bz2 |
[multiple changes]
2005-04-25 Jeroen Frijters <jeroen@frijters.net>
* java/awt/GraphicsEnvironment.java
(localGraphicsEnvironment): New field.
(getLocalGraphicsEnvironment): Added support for java.awt.graphicsenv
property.
(isHeadless): Added support for java.awt.headless property.
(isHeadlessInstance): Call headless().
2005-04-25 Roman Kennke <roman@kennke.org>
* gnu/java/awt/peer/gtk/GdkScreenGraphicsDevice.java
(getDisplayMode): Added. Returns the current display mode.
(isFullScreenSupported): Added.
* java/awt/GraphicsDevice.java
(setFullScreenWindow): Implemented a primitive fullscreen mode.
This resizes and relocates the fullscreen window so that it uses
the whole screen. This is not a fully accelerated fullscreen
exclusive mode.
From-SVN: r98740
Diffstat (limited to 'libjava/gnu/java')
-rw-r--r-- | libjava/gnu/java/awt/peer/gtk/GdkScreenGraphicsDevice.java | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/libjava/gnu/java/awt/peer/gtk/GdkScreenGraphicsDevice.java b/libjava/gnu/java/awt/peer/gtk/GdkScreenGraphicsDevice.java index bd7b46a..c74fb88 100644 --- a/libjava/gnu/java/awt/peer/gtk/GdkScreenGraphicsDevice.java +++ b/libjava/gnu/java/awt/peer/gtk/GdkScreenGraphicsDevice.java @@ -38,6 +38,8 @@ exception statement from your version. */ package gnu.java.awt.peer.gtk; +import java.awt.Dimension; +import java.awt.DisplayMode; import java.awt.GraphicsConfiguration; import java.awt.GraphicsDevice; @@ -79,4 +81,35 @@ public class GdkScreenGraphicsDevice extends GraphicsDevice // FIXME: query X for default configuration return new GdkGraphicsConfiguration(this); } + + + /** + * Returns the current display mode of this device, or null if unknown. + * + * @return the current display mode + * @see #setDisplayMode(DisplayMode) + * @see #getDisplayModes() + * @since 1.4 + */ + public DisplayMode getDisplayMode() + { + // determine display mode + Dimension dim = getToolkit().getScreenSize(); + DisplayMode mode = new DisplayMode(dim.width, dim.height, 0, + DisplayMode.REFRESH_RATE_UNKNOWN); + return mode; + } + + /** + * This device does not yet support fullscreen exclusive mode, so this + * returns <code>false</code>. + * + * @return <code>false</code> + * @since 1.4 + */ + public boolean isFullScreenSupported() + { + return false; + } + } |