Popups in fullscreen exclusive?

My game is running in fullscreen exclusive mode but I need to open the occasional dialog box which new shows in front of the fullscreen main frame. Is there any way of making popups such as Dialogs or other frames appear in fullscreen exclusive mode?

Since when did any game you ever played written in even the most powerful languages and 2d/3d api's ever display a popup during the programs run in fullscreen exclusive mode? (Error popup dialogs that end the game dont count. Unless you 'wanted' your app to end after a popup of course... o_O)
Now, as for a more efficient/robust/intuitive/cooler etc way to display important information to the user, perhaps your game (I'm assuming its a game due to where this is posted) should draw its own frame lookalike that could function just like a popup, only it resided in the game, and had its own look and feel. ( a look that should undoubtly be way more apealing to your audience than a standard dialog...)

Similar Messages

  • AWT Popup Menu in Fullscreen Exclusive + JOGL

    Our application runs in Fullscreen Exclusive mode and uses JOGL. We want the user to be able to access right-click Popup menus like in other applications. (Obviously, this isn't a game; but I figured I'd post here because game developers are the only ones likely to be familiar with Fullscreen Exclusive.)
    On Windows, I was pleasantly suprised to find that popupMenu.show() just works when I'm in Fullscreen Exclusive. The menu appears, works correctly, etc.
    On Mac OS X 10.3+, the menu does not appear. I've developed a clumsy workaround (basically, go out of fullscreen exclusive to show the menu, and then go back in when mouse events start coming again). Frankly, the way it works on a Mac is what I expected on the PC. I wouldn't expect a Popup Menu (being another window) to be able to appear over a fullscreen exclusive window.
    My question is this: Is the Windows behavior a bug? Is it video driver dependent? (It seems to work OK with all the machines we've tested on... ATI, NVIDIA, Intel) Should I be doing my Mac hack on the Windows platform to avoid some unforseen problem?
    Also, any idea what Linux or other platforms would do?

    I am not sure why that works in one OS and not the others.
    All I can say is that if it was a game, we would draw the popup menu ourself within the frame in our rendering loop, that is garunteed to work in all OS's. But your probably using AWT or SWING components. Sounds like it may be a compadibility issue, I would check the bug lists to see if that is a known issue that is being worked on.

  • Event Handling in Fullscreen Exclusive Mode???????

    WIndows XP SP2
    ATI 8500 All-In-Wonder
    JDK 1.6
    800x600 32dpi 200 refresh
    1-6 buffer strategy.
    the graphic rendering thread DOESN'T sleep.
    Here's my problem. I have a bad trade off. In fullscreen exclusive mode my animation runs <30 fps and jerks when rendering. i.e. stop and go movement (not flickering/jittering just hesitant motion) when the animation is running. I solved this problem by raising the thread priority of the rendering (7-8). . . this resulted in latency/no activity for my input events both key and mouse. For instance closing the program alt-f4 will arbitrarily fail or be successful when the thread priority is raised above 6.
    How does one accomplish a >30 fps and Instant event handling simultaneously in Fullscreen Exclusive Mode?
    Is there a way to raise thread priority for event handling?
    Ultimately I want to be able to perform my animations and handle key and mouse input events without having a visible 'hiccups' on the screen.
    Much Appreciated!

    If I remember correctly the processor is a 1.4(or)6ghz AMD Duron
    Total = 1048048kb
    Available = 106084kb
    Sys Cache = 211788kb
    PF Usage = 1.01 GB
    I solved some of the problem after posting this thread. . . .
    I inserted a thread.sleep(1) and my alt-f4 operation worked unhindered with the elevated thread priority.
    I haven't tested it with mouse event or any other key event but at the moment it looks I may have solved the problem.
    If so, my next question will be is there a way to reduce the amount of cpu power needed to run the program.
    I'm afraid that the other classes that I'm adding will actually become even more process consuming than the actually rendering thread.
    public class RenderScreen extends Thread
      // Screen Rendering status code
      protected final static int RUNNING = 0,
                                 PAUSED = -1;
      // frames per second and process time counters
      protected long now = 0, fps = 0, fpsCount = 0, cycTime = 0;
      // thread status
      protected int status = 0;
      protected Screen screen;
      public void setStatus(int i){ status = i; };
      public void setTarget(Screen screen){ this.screen=screen; };
      public void run()
        setName("Screen Render");
        screen.createBufferStrategy(1);
        screen.strategy = screen.getBufferStrategy();
        for(;;)
          if(status == RUNNING)
            now = System.currentTimeMillis();
            while(System.currentTimeMillis() <= now+1000)
              // call system processes
              // fps increment / repaint interface
              fpsCount++;
              screen.renderView();
              try { Thread.sleep(1);}catch(InterruptedException ie){ ie.printStackTrace(); }
            fps = fpsCount;
            cycTime = System.currentTimeMillis() - (now + 1000);
            fpsCount=0;
      public RenderScreen(){};
      public RenderScreen(Screen screen){ this.screen=screen; };
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.image.*;
    import javax.swing.*;
    public class Screen extends Window
      BufferedImage image = new BufferedImage(800,600,BufferedImage.TYPE_INT_RGB);
      Graphics2D gdd = image.createGraphics();
      MediaTracker tracker = new MediaTracker(this);
      Image bground = getToolkit().getImage("MajorityRule.jpg"),
            bawl = getToolkit().getImage("bawl.gif");
      RenderScreen rScreen = new RenderScreen(this);
      BufferStrategy strategy;
      Graphics g;
      Rectangle rect = new Rectangle(400,0,150,150);
      //Game game = new Game();
      public void renderView()
        g = strategy.getDrawGraphics();
        //--------- Game Procedures [start]
        gdd.drawImage(bground,0,0,this);
        gdd.drawString("fps: ["+rScreen.fps+"] Cycle Time: ["+rScreen.cycTime+"]",0,10);
        //--------- Game Procedures [end]
        //---------test
        gdd.drawImage(bawl,rect.x,rect.y,rect.width,rect.height,this);
        rect.translate(0,1);
        g.drawImage(image,0,0,this);
        //g.dispose();
        strategy.show();
      public Screen(JFrame frame)
        super(frame);
        try
          tracker.addImage(bground,0);
          tracker.addImage(bawl,1);
          tracker.waitForAll();
        catch(InterruptedException ie){ ie.printStackTrace(); }
        setBackground(Color.black);
        setForeground(Color.white);
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class MajorityRule extends JFrame
      // Graphic System Handlers
      GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
      GraphicsDevice gd = ge.getDefaultScreenDevice();
      GraphicsConfiguration gc = gd.getDefaultConfiguration();
      Screen screen = new Screen(this);
      Paper paper = new Paper();
      public void windowed()
        paper.setSize(getWidth(),getHeight());
        getContentPane().add(paper);
        setResizable(false);
        setVisible(true);
      public void fullscreen()
        DisplayMode dMode = new DisplayMode(800,600,32,200);
        screen.setBounds(0,0,800,600);
        if (gd.isFullScreenSupported()) gd.setFullScreenWindow(screen);
        if (gd.isDisplayChangeSupported()){ gd.setDisplayMode(dMode); };
        screen.setIgnoreRepaint(true);
        screen.setVisible(true);
        screen.rScreen.setPriority(Thread.MAX_PRIORITY);
        screen.rScreen.start();
        screen.requestFocus();
      public MajorityRule(String args[])
        setTitle("Majority Rule [Testing Block]");
        setBounds(0,0,410,360);
        setDefaultCloseOperation(EXIT_ON_CLOSE);
        getContentPane().setLayout(null);
        if (args.length > 0 && args[0].equals("-window")) windowed();
        else fullscreen();
      public static void main(String args[])
        new MajorityRule(args);
    };

  • Swing Components and Fullscreen Exclusive

    Hi, I am trying to write a program that can switch between full screen and windowed mode seamlessly, while still being able to use standard swing components. I have never worked with the full screen exclusive mode before and am having trouble getting the components to repaint properly.
    The following code works fine in the windowed and undecorated modes, however when I switch to fullscreen exclusive mode all components disappear and only repaint upon mouseover or other interaction. Calls to repaint do not make any difference.
    import java.awt.Dimension;
    import java.awt.DisplayMode;
    import java.awt.FlowLayout;
    import java.awt.GraphicsDevice;
    import java.awt.GraphicsEnvironment;
    import java.awt.Toolkit;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import javax.swing.JButton;
    import javax.swing.JFrame;
    import javax.swing.WindowConstants;
    public class FullscreenTests {
         private static boolean hwlast = false;
         private static GraphicsDevice dev = GraphicsEnvironment.getLocalGraphicsEnvironment().getDefaultScreenDevice();
         public static void main(String[] args) {
              final JFrame fMain = new JFrame("Title");
              fMain.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
              fMain.getRootPane().setLayout(new FlowLayout());
              JButton win = new JButton("Windowed");
              win.addActionListener(new ActionListener () {
                   public void actionPerformed (ActionEvent e) {
                        setWindowed(fMain);
              fMain.getRootPane().add(win);
              JButton ful = new JButton("Fullscreen");
              ful.addActionListener(new ActionListener () {
                   public void actionPerformed (ActionEvent e) {
                        setFullscreen(fMain);
              fMain.getRootPane().add(ful);
              JButton hw = new JButton("HW Fullscreen");
              hw.addActionListener(new ActionListener () {
                   public void actionPerformed (ActionEvent e) {
                        setHWFullscreen(fMain);
              fMain.getRootPane().add(hw);
              setWindowed(fMain);
         public static void setWindowed(JFrame f) {
              if (hwlast == true) {
                   dev.setFullScreenWindow(null);
                   hwlast = false;
              f.dispose();
              f.setIgnoreRepaint(false);
              f.setUndecorated(false);
              Dimension d = Toolkit.getDefaultToolkit().getScreenSize();
              f.setSize(new Dimension(808,634));
              f.setMinimumSize(new Dimension(808,634));
              f.setLocation((d.width-f.getWidth())/2, (d.height-f.getHeight())/2);
              f.setVisible(true);
         public static void setHWFullscreen(JFrame f) {
              hwlast = true;
              f.dispose();
              f.setUndecorated(true);
              f.setIgnoreRepaint(true);
              f.setVisible(true);
              dev.setFullScreenWindow(f);
              dev.setDisplayMode(new DisplayMode(800, 600, 32, DisplayMode.REFRESH_RATE_UNKNOWN));
         public static void setFullscreen(JFrame f) {
              if (hwlast == true) {
                   dev.setFullScreenWindow(null);
                   hwlast = false;
              f.dispose();
              f.setIgnoreRepaint(false);
              f.setUndecorated(true);
              f.setSize(Toolkit.getDefaultToolkit().getScreenSize());
              f.setLocation(0,0);
              f.setVisible(true);
    }On the same note, if there are better ways of doing this I would be glad to know. This is just a quick test so I haven't done any checks etc when switching to fullscreen exclusive.

       public static void setHWFullscreen (JFrame f) {
          hwlast = true;
          f.dispose ();
          f.setUndecorated (true);
          f.setIgnoreRepaint (true);
          // add this
          Graphics g = f.getGraphics ();
          f.paintAll (g);
          f.setVisible (true);
          dev.setFullScreenWindow (f);
          dev.setDisplayMode (new DisplayMode (800, 600, 32, DisplayMode.REFRESH_RATE_UNKNOWN));
       }db

  • JMF video while in Fullscreen Exclusive

    I am trying to show a video (using JMF) in my window while in fullscreen exclusive mode. Its for a game. It works occasionally. What I've done is turned of the repetitive rendering (from the game loop), and just added the visual component to the window (it can do its own painting). Sometimes it works fine, other times you just hear the sound, and other times its just grey or black.
    Does anybody have any idea how to get the current frame, and draw it so that I can keep the repetitive rendering (from the game loop) running.
    Any other ideas are appreciated too.

    Never written a fullscreen exclusive application. In fact, I've never even heard of such a thing.
    http://download.oracle.com/javase/tutorial/extra/fullscreen/exclusivemode.html
    "In full-screen exclusive applications, painting is usually done actively by the program itself"
    Ah. So no, I don't think JMF would support that because it's not going to be actively rendering, only passively rendering in response to paint requests. It's AWT/Swing based, after all...
    But, the fact that JMF doesn't support it does not mean JMF can't support it. JMF provides a custom Renderer interface which you could implement to actively render the stuff. It'll essentially give you a copy of the video frame in a Buffer object which you can then turn into an image using the BufferToImage class and then render that however you'd render an image for a full screen exclusive application...

  • Java 3D and fullscreen exclusive mode

    Hello all. I have the following problem: if I try to set fullscreen exclusive mode by calling
    device.setFullScreenWindow(window);
    then Java renders nothing. If I remove this line of code, everything works perfectly. Any ideas?
    Thanks in advance!

    you can't do that like that! it's a bit more conplicated. if you haven't,take a look at that:
    http://java.sun.com/docs/books/tutorial/extra/fullscreen/index.html

  • JMF In Fullscreen Exclusive Mode

    Hello,
    I was wondering if anyone could let me know if JMF is supported inside a Fullscreen Exclusive Application? I seem to have no problem setting up JMF Video output for a standard JFrame/Frame, but when setting a "fullscreenWindow" the Player turns black. I cannot seem to find any posts on whether this is supported or if there are bugs when in Fullscreen Exclusive Mode.
    Thanks
    -Michael Morris

    Never written a fullscreen exclusive application. In fact, I've never even heard of such a thing.
    http://download.oracle.com/javase/tutorial/extra/fullscreen/exclusivemode.html
    "In full-screen exclusive applications, painting is usually done actively by the program itself"
    Ah. So no, I don't think JMF would support that because it's not going to be actively rendering, only passively rendering in response to paint requests. It's AWT/Swing based, after all...
    But, the fact that JMF doesn't support it does not mean JMF can't support it. JMF provides a custom Renderer interface which you could implement to actively render the stuff. It'll essentially give you a copy of the video frame in a Buffer object which you can then turn into an image using the BufferToImage class and then render that however you'd render an image for a full screen exclusive application...

  • How to get out of fullscreen exclusive mode?

    I have a program that runs in full screen exclusive mode, I'd like the program to start up in windowed mode instead.
    I spent several hours trying to make it run in window mode, but I can't seem to figure it out :/
    Here's the code:
            if (graphicsDevice.isFullScreenSupported()) {
                graphicsDevice.setFullScreenWindow(this);
            if (graphicsDevice.isDisplayChangeSupported() == false) {
                return false;
            boolean displayModeAvailable = false;
            DisplayMode[] displayModes = graphicsDevice.getDisplayModes();
            for (DisplayMode mode : displayModes) {
                if (screenWidth == mode.getWidth() && screenHeight == mode.getHeight()
                        && screenColorDepth == mode.getBitDepth()) {
                    displayModeAvailable = true;
            if (displayModeAvailable == false) {
                return false;
            DisplayMode targetDisplayMode =
                    new DisplayMode(screenWidth, screenHeight,
                        screenColorDepth, DisplayMode.REFRESH_RATE_UNKNOWN);
            try {
                graphicsDevice.setDisplayMode(targetDisplayMode);
            } catch (IllegalArgumentException exception) {
                return false;
            if (EventQueue.isDispatchThread() == false) {
                EventQueue.invokeAndWait(new Runnable() {
                    public void run() {
                        createBufferStrategy(2);
            } else {
                createBufferStrategy(2);
            bufferStrategy = getBufferStrategy();
            try {
                graphics2D = (Graphics2D) bufferStrategy.getDrawGraphics();
                gameRender(graphics2D);
                if (drawGameStatistics) {
                    gameStatisticsRecorder.drawStatistics(graphics2D, 0, 0);
                graphics2D.dispose();
            } catch (Exception exception) {
                System.err.println("GameEngine.gameRender: " +
                        "Error cannot render screen:" + exception.toString());
                exception.printStackTrace();
            }Thanks

    Have you read these?
    [http://java.sun.com/docs/books/tutorial/extra/fullscreen/]
    [http://java.sun.com/docs/books/tutorial/extra/fullscreen/exclusivemode.html]
    db

  • Exiting programs that have use the fullscreen exclusive mode

    I have lots of problems, this is one of them:
    When making a program that uses fullscreen mode, the program does not exit by itself when it comes to the end of the program. In fact the only way I can get it to exit is through System.exit(0);
    And I don't want to use that for numerous reasons.
    try
    gd.setFullScreenWindow(jw);
    gd.setDisplayMode(dm[theDisplayMode]);
    finally
    gd.setDisplayMode(oldDisplayMode);
    gd.setFullScreenWindow(null);
    end of program......
              }

    I have lots of problems, this is one of them:
    When making a program that uses fullscreen mode, the program does not exit by itself when it comes to the end of the program. In fact the only way I can get it to exit is through System.exit(0);
    And I don't want to use that for numerous reasons.
    try
    gd.setFullScreenWindow(jw);
    gd.setDisplayMode(dm[theDisplayMode]);
    finally
    gd.setDisplayMode(oldDisplayMode);
    gd.setFullScreenWindow(null);
    end of program......
              }

  • Fullscreen Exclusive Mode

    Hi
    I am currently playing around with the new fullscreen api that is included with SDK1.4. But I have a problem. I would like to have images and Swing components showing at the same time and controling when to paint this. I am working with the code from the tutorial http://java.sun.com/docs/books/tutorial/extra/fullscreen/index.html . So far I can display the image but no Swing component. Can someone help me?
    * This test takes a number up to 13 as an argument (assumes 2 by
    * default) and creates a multiple buffer strategy with the number of
    * buffers given.  This application enters full-screen mode, if available,
    * and flips back and forth between each buffer (each signified by a different
    * color).
    import java.awt.*;
    import java.awt.image.BufferStrategy;
    import java.awt.event.*;
    import javax.swing.event.*;
    import javax.swing.*;
    public class MultiBufferTest {
        private static DisplayMode[] BEST_DISPLAY_MODES = new DisplayMode[] {
            new DisplayMode(800, 600, 32, 0),
        Frame mainFrame;
        boolean remove = false;
        public MultiBufferTest(int numBuffers, GraphicsDevice device) {
            try {
                Image image = (new LoadImage("mypic.jpg")).getImage();
                GraphicsConfiguration gc = device.getDefaultConfiguration();
                mainFrame = new Frame(gc);
                mainFrame.setUndecorated(true);
                mainFrame.setIgnoreRepaint(true);
                device.setFullScreenWindow(mainFrame);
                if (device.isDisplayChangeSupported()) {
                    chooseBestDisplayMode(device);
                Rectangle bounds = mainFrame.getBounds();
                mainFrame.createBufferStrategy(2);
                mainFrame.addMouseMotionListener(new MA());
                mainFrame.addMouseListener(new MA());
                JLabel label = new JLabel("hi");
                label.setLocation(new Point(200, 200));
                label.setForeground(new Color(122,23,52));
                mainFrame.add(label);
                BufferStrategy bufferStrategy = mainFrame.getBufferStrategy();
                int x, y;
                x=0;
                y=0;
                boolean done = false;
                while (!done){
                   Graphics g = bufferStrategy.getDrawGraphics();
                   if (!bufferStrategy.contentsLost()) {
                      g.setColor(Color.black);
                      g.fillRect(0,0,bounds.width, bounds.height);
                      mainFrame.paintComponents(g);
                      if (!remove)
                         g.drawImage(image, x, y, 60, 60, mainFrame);
                      bufferStrategy.show();
                      g.dispose();
            } catch (Exception e) {
                e.printStackTrace();
            } finally {
                device.setFullScreenWindow(null);
        public void removeImage(){
           remove = true;
        private static DisplayMode getBestDisplayMode(GraphicsDevice device) {
            for (int x = 0; x < BEST_DISPLAY_MODES.length; x++) {
                DisplayMode[] modes = device.getDisplayModes();
                for (int i = 0; i < modes.length; i++) {
                    if (modes.getWidth() == BEST_DISPLAY_MODES[x].getWidth()
    && modes[i].getHeight() == BEST_DISPLAY_MODES[x].getHeight()
    && modes[i].getBitDepth() == BEST_DISPLAY_MODES[x].getBitDepth()
    return BEST_DISPLAY_MODES[x];
    return null;
    public static void chooseBestDisplayMode(GraphicsDevice device) {
    DisplayMode best = getBestDisplayMode(device);
    if (best != null) {
    device.setDisplayMode(best);
    public static void main(String[] args) {
    try {
    int numBuffers = 2;
    if (args != null && args.length > 0) {
    numBuffers = Integer.parseInt(args[0]);
    if (numBuffers < 2 || numBuffers > COLORS.length) {
    System.err.println("Must specify between 2 and "
    + COLORS.length + " buffers");
    System.exit(1);
    GraphicsEnvironment env = GraphicsEnvironment.
    getLocalGraphicsEnvironment();
    GraphicsDevice device = env.getDefaultScreenDevice();
    MultiBufferTest test = new MultiBufferTest(numBuffers, device);
    } catch (Exception e) {
    e.printStackTrace();
    System.exit(0);
    public class MA extends MouseInputAdapter{
              public void mouseClicked(MouseEvent e){
              public void mouseEntered(MouseEvent e){
              public void mouseExited(MouseEvent e){
              public void mousePressed(MouseEvent e){
    if (e.getX() < 60 && e.getY() < 60)
    removeImage();
              public void mouseReleased(MouseEvent e){
              public void mouseMoved(MouseEvent e) {
              public void mouseDragged(MouseEvent e) {
    //CLASS LOADIMAGE.JAVA
    import java.awt.*;
    class LoadImage extends Component{
    Image image;
    public LoadImage( String path ){
    Toolkit toolkit = getToolkit();
    MediaTracker tracker = new MediaTracker(this);
    image = toolkit.getImage(path);
    tracker.addImage(image,0);
    try {
    tracker.waitForID(0);
    catch(InterruptedException e){
    System.out.println("fel vid inl�sning av bilder");
    public Image getImage(){
    return image;

    If anyone is interested here is a code that solves the problem.
    * This test takes a number up to 13 as an argument (assumes 2 by
    * default) and creates a multiple buffer strategy with the number of
    * buffers given.  This application enters full-screen mode, if available,
    * and flips back and forth between each buffer (each signified by a different
    * color).
    import java.awt.*;
    import java.awt.image.BufferStrategy;
    import java.awt.event.*;
    import javax.swing.event.*;
    import javax.swing.*;
    public class MultiBufferTest {
        int x, y;
        private static DisplayMode[] BEST_DISPLAY_MODES = new DisplayMode[] {
            new DisplayMode(800, 600, 32, 0),
            new DisplayMode(800, 600, 16, 0),
        Frame mainFrame;
        boolean remove = false;
        public MultiBufferTest(int numBuffers, GraphicsDevice device) {
            try {
                Image image = (new LoadImage("backmask.jpg")).getImage();
                GraphicsConfiguration gc = device.getDefaultConfiguration();
                mainFrame = new Frame(gc);
                mainFrame.setUndecorated(true);
                mainFrame.setIgnoreRepaint(true);
                device.setFullScreenWindow(mainFrame);
                if (device.isDisplayChangeSupported())
                    chooseBestDisplayMode(device);
                Rectangle bounds = mainFrame.getBounds();
                mainFrame.createBufferStrategy(2);
                mainFrame.addMouseMotionListener(new MA());
                mainFrame.addMouseListener(new MA());
                JButton button = new JButton("ASDFJKSADFKASDFJK");
                button.setBounds(200, 200, 200, 200);
                mainFrame.add(button);
                BufferStrategy bufferStrategy = mainFrame.getBufferStrategy();
                x=0;
                y=0;
                boolean done = false;
                while (!done){
                   Graphics g = bufferStrategy.getDrawGraphics();
                   if (!bufferStrategy.contentsLost()) {
                      g.setColor(Color.black);
                      g.fillRect(0,0,bounds.width, bounds.height);
                      g.drawImage(image, x, y, 60, 60, mainFrame);
                      mainFrame.paint(g);
                      bufferStrategy.show();
                      g.dispose();                
            } catch (Exception e) {
                e.printStackTrace();
            } finally {
                device.setFullScreenWindow(null);
        public void removeImage(){
           remove = true;
        private static DisplayMode getBestDisplayMode(GraphicsDevice device) {
            for (int x = 0; x < BEST_DISPLAY_MODES.length; x++) {
                DisplayMode[] modes = device.getDisplayModes();
                for (int i = 0; i < modes.length; i++) {
                    if (modes.getWidth() == BEST_DISPLAY_MODES[x].getWidth()
    && modes[i].getHeight() == BEST_DISPLAY_MODES[x].getHeight()
    && modes[i].getBitDepth() == BEST_DISPLAY_MODES[x].getBitDepth()
    return BEST_DISPLAY_MODES[x];
    return null;
    public static void chooseBestDisplayMode(GraphicsDevice device) {
    DisplayMode best = getBestDisplayMode(device);
    if (best != null) {
    device.setDisplayMode(best);
    public static void main(String[] args) {
    try {
    GraphicsEnvironment env = GraphicsEnvironment.
    getLocalGraphicsEnvironment();
    GraphicsDevice device = env.getDefaultScreenDevice();
    MultiBufferTest test = new MultiBufferTest(2, device);
    } catch (Exception e) {
    e.printStackTrace();
    System.exit(0);
    public class MA extends MouseInputAdapter{
              public void mouseClicked(MouseEvent e){
    x = e.getX();
    y = e.getY();
              public void mouseEntered(MouseEvent e){
              public void mouseExited(MouseEvent e){
              public void mousePressed(MouseEvent e){
    x = e.getX();
    y = e.getY();
              public void mouseReleased(MouseEvent e){
    x = e.getX();
    y = e.getY();
              public void mouseMoved(MouseEvent e) {
    x = e.getX();
    y = e.getY();
              public void mouseDragged(MouseEvent e) {
    x = e.getX();
    y = e.getY();

  • Popup when fullscreen fails

    Hi everyone, I am working on a swf movie that includes a button to display it in fullscreen mode.
    I have seen that there are few PCs that don't support this functionality (old flash version or corrupt installation), so I would like to give them the possibility to view my flash movie in a new web page through the javascript window.open.
    I've created the code and test it using a button and it works fine. What I would really like to do is to to show it only when flash detects that fullscreen is failing or the installation is corrupt. I've already tried with a try catch inside my fullscreen button, but it doesn't seem to recognize that there is a failure.
    I'm using ActionScript 2, my embed has enabled allowScriptAccess and allowFullScreen.
    I use this function to open my flash movie in a new window
    function OpenEmbedInPopUp():Void{
    getURL("javascript:openwindow('mymovie.swf')");
    This is my javascript function
    function openwindow(winurl)
       var screen_height = window.screen.availHeight-50;
       var screen_width = window.screen.availWidth;
       window.open(winurl,'','location=0,status=1,left=0,top=0,height='+screen_height+'px,width= '+screen_width+'px');
    Thanks

    Hi,
    The message would have maintained in the Transaction code OVAH
    Path:  IMG-> SALES & DISTRIBTION-> SALES->SALES DOCUMENTS->DEFINE VARIABLE MESSAGES.
    Please check the message is available in this transaction, if so then remove it
    Hope it will solve, please revert back if needed further info
    thanks,
    santosh

  • Fullscreen exclusive problems!

    I have noticed that if I set my device to anything less than 640x480, The mouse thinks the screen is larger. You can drag the mouse like a whole 3 inches off the bottom of the screen which should be impossible, any way around this? A resolution of 512x384 really beefs up rendering smoothness.

    2.1.8.5?! Ack! You REEEAAALLLY need to upgrade. There's been about 5 billion driver releases between those and the ones we use now (4.3.4.9). Trust me, once you upgrade, Windows will magically look better, animation will be smoother, and your framerates will be higher.

  • Is it possible to use fullscreen and exclusive mode with a jfilechooser?

    is there a way to use them together? while in fullscreen exclusive mode the jfilechooser doesn't attach to fullscreen window and it halts the program.. I've tried setting the parent frame as the fullscreen frame but it's all glitched.. am I missing something?
    thank you,
    best regards,
    Jacopo

    For reference, the cross-post can be found here:
    Is it possible to use network devices (cDAQ-9188) with a PXI Real Time system?
    Jayme W.
    Applications Engineer
    National Instruments

  • How to set fullscreen mode window

    hi there.. ive seen the fullscreen exclusive mode examples and doc in java 1.4.0 still i cant get to set my window.. anybody around here got those examples to run? how did u do it?
    and did you made a program that can run in fullscreen and draw into it? like 640x480x32bit? or anything else..please let me know..

    Do not if I understand you, but would this help?
    void maximize() {
    Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
    Insets ins=insets();
    resize(screenSize.width-(ins.left+ins.right)-16,screenSize.height-(ins.top+ins.bottom)-48);
    Dimension frameSize = size();
    move((screenSize.width- frameSize.width) / 2, 0) ;
    validate();
    }

  • Applet, Frame and fullscreen

    Hi!
    Have an application wich is a Applet and also can run as a desktop program. The fullscreen desktop function some time ago sotpped work, now I have been testing to discover the problem and discovered the Applet does not work correctly when inside my Frame, the Panel class also does not work, only the JPanel is drawed in my fullscreen.
    So, I want to ask why the Applet does not work anymore when the Frame is in fullscreen exclusive mode?... and what is the best practice in this case, because I want my game to run in desktop and inside web browser?
    Thanks in advance

    Janio wrote:
    Ok, the browser window wrapper does nothing in particular, in fact it can be replaced by a Frame using java web start, but maybe the users will get intimidated by this approach.And maybe they won't. Developers seem to have a greater fear of apps. launched using JWS than users do.
    Note that an app. launched using JWS will work for more users than an applet. There are constant browser/JRE interaction bugs discovered, that trip up applet deployment.
    I just want an alternative for this problem with Applets inside frames.Applets can be dropped into a frames, but it requires some extra hassles. If you control the code, I would not recommend going that way.
    (And now I re-read this thread from the top..)
    I am confused by what you mean by 'full-screen' in combination with 'applet'. An applet embedded in a web page has its size set in HTML. If you want something to be full-screen, it would require the applet launching a free-floating (J)Frame, (J)Window or (J)Dialog (etc.). Is that what it does?

Maybe you are looking for

  • New User Question:  How do I enable comments in Reader when this option is greyed out on my menu?

    I cannot figure out what I am missing here.  I have a PDF Portfolio completed and now want to E-Mail for Review.  But this option is greyed out on my Comment Menu dropdown list.  What to do?  Thanks!

  • Web IC Sales Order ERP Integration (Workcentre IC_SLO_ERP)

    System: CRM 2007 s4 and ECC 6 I have integrated ERP Sales Order within my Web IC aplication.  I'm able to create ERP orders from within the CRM based Web IC using the work centre IC_SLO_ERP.  I can save the orders and the orders are saved to SAP ECC

  • Opening a PDF inside Flash compile errors

    I'm trying to open a pdf inside flash.  I followed a tutorial online but I'm have issues with the compiler.  Here's my code: import flash.html.HTMLLoader; import flash.html.HTMLPDFCapability; import flash.html.HTMLWindowCreateOptions; if( HTMLLoader.

  • "Automatically play movies when opened" preference broken

    I recently upgraded from QT player to QT Pro 7.5. It all works just fine, but the Preferences setting "Automatically play movies when opened" appears to have broken in the process. Movies and audio all open properly, but I must click the "Play" butto

  • PS2 Development Mess!

    I got my PS2 and I am happy to have it. I want to make a game for it, and I know that there is a homebrew community, so I don't need to be an official developer. I went to ps2dev.org and read some of the pages on development. I have downloaded the to