//
// $Id: ViewerFrame.java,v 1.30 2002/02/19 01:27:34 mdb Exp $

package com.threerings.miso.viewer;

import java.awt.Color;
import java.awt.Component;
import java.awt.GraphicsConfiguration;

import javax.swing.JFrame;

import com.samskivert.swing.GroupLayout;
import com.samskivert.swing.VGroupLayout;

/**
 * The viewer frame is the main application window.
 */
public class ViewerFrame extends JFrame
{
    /**
     * Creates a frame in which the viewer application can operate.
     */
    public ViewerFrame (GraphicsConfiguration gc)
    {
	super(gc);

        // set up the frame options
        setTitle("Scene Viewer");
        setUndecorated(true);
        setResizable(false);
        setDefaultCloseOperation(EXIT_ON_CLOSE);

        // center the scene view within the frame
        GroupLayout gl = new VGroupLayout();
        gl.setJustification(GroupLayout.CENTER);
        gl.setOffAxisJustification(GroupLayout.CENTER);
        getContentPane().setLayout(gl);

        // set the frame and content panel background to black
        setBackground(Color.black);
        getContentPane().setBackground(Color.black);
    }

    /**
     * Sets the panel displayed by this frame.
     */
    public void setPanel (Component panel)
    {
        // if we had an old panel, remove it
        if (_panel != null) {
            getContentPane().remove(_panel);
        }    

        // now add the new one
        _panel = panel;
	getContentPane().add(_panel);
    }

    protected Component _panel;
}

@@ -26,17 +26,17 @@
 va,v 1.3
-0
+1
  2002/02
@@ -44,15 +44,15 @@
 19 0
-1:27:34
+7:42:51
  mdb
@@ -96,16 +96,46 @@
 iewer;%0A%0A
+import java.awt.BorderLayout;%0A
 import j
@@ -248,92 +248,8 @@
 e;%0A%0A
-import com.samskivert.swing.GroupLayout;%0Aimport com.samskivert.swing.VGroupLayout;%0A%0A
 /**%0A
@@ -682,249 +682,8 @@
 );%0A%0A
-        // center the scene view within the frame%0A        GroupLayout gl = new VGroupLayout();%0A        gl.setJustification(GroupLayout.CENTER);%0A        gl.setOffAxisJustification(GroupLayout.CENTER);%0A        getContentPane().setLayout(gl);%0A%0A
     
@@ -1139,16 +1139,16 @@
  panel;%0A
-
 %09getCont
@@ -1163,24 +1163,45 @@
 ).add(_panel
+, BorderLayout.CENTER
 );%0A    %7D%0A%0A  

Use a BorderLayout.