UIWindow disappering act

Hi i have written a little UIWindow to act as an info panel in a game im doing. I worte it and tested it using one of the first example programs ( one displying a rotated cube) and it worked fine followed my mouse when i moved it an everything:)

I then brought it into the game im writing, and for some reason unknown to me, it will not disply itself.

I have ran a few tests of it and the point() method i’m using to diaplay the graphics is being called as expected but it’s just not being rendered to the canvas???

Any suggestions would be great:)

Any code examples?

heres the class for the infoWindow, as i said it worked when i brought it into one of the simple demo programs from the getting started guide but when i brought it into my project notting is being rendered. I thought i might have been a threading issue, so i created and showed it using the rendering thread but still no luck??? again any help would be great thanks



public class InfoWindow extends UIWindow{
      
      private UIWindowManager windowMgr = null;
      private JPanel root = null;
      private InfoCanvas infoCanvas = new InfoCanvas();
      
      public InfoWindow(Canvas3D canvas){
            
            super(210, 110, true, false);
            windowMgr = new UIWindowManager(canvas);
            
            root = new JPanel(true);
            root.setSize(210, 110); 
            root.setOpaque(false);
            root.add(infoCanvas);
            
            windowMgr.addOverlay(this);
            setRoot(root);
                  
      }
      
      /**
   * 
   */
      public synchronized void update(){
            
            super.update();
            setRoot(root);
            
      }
      
      /**
   * 
   */
      public synchronized void setMessage(String message){
            
            infoCanvas.message = message;
            
      }
      
      /**
   * 
   */
      public synchronized void setLocation(Point location){
            
            System.out.println ("Setting info window location");
            windowMgr.setPosition(this, location.x, location.y);
            
      }
      
      public synchronized void setVisible(boolean isVisible){
            
            System.out.println ("Setting info window visible");
            windowMgr.setVisible(this, isVisible);      
            
      }
      
      /**
   * 
   */
      private class InfoCanvas extends Canvas{
            
            public String message = "";
            
            public InfoCanvas(){
                  setBounds(0, 0, 200, 100);
                  setVisible(true);
            }
            
            /**
         * 
         */
            public void paint(Graphics g){
                  
                  System.out.println ("Painting InfoWindow");
                  
                  Graphics2D g2d = (Graphics2D)g;
                  
                  g2d.setPaint(new Color(0.15f, 0.0f, 0.60f));
                  g2d.fillRoundRect(0, 0, 200, 100, 20, 20);
                  g2d.setPaint(new Color(0.25f, 0.0f, 0.70f));
                  g2d.fillRoundRect(5, 5, 190, 90, 20, 20);
                  
                  g2d.setPaint(new Color(0.8f, 0.6f, 0.9f));
                  g2d.drawString(message , 10, 50);
                  
            }      
      }      
}