Skip to content

Commit

Permalink
Fixed preview frame popping up before main frame.
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre-Luc Paour committed Jun 25, 2003
1 parent 75dfbc1 commit c937893
Showing 1 changed file with 10 additions and 11 deletions.
21 changes: 10 additions & 11 deletions com/gallery/GalleryRemote/MainFrame.java
Expand Up @@ -66,7 +66,7 @@ public class MainFrame extends javax.swing.JFrame
public static final String MODULE = "MainFrame";
public static final String FILE_TYPE = ".grg";

PreviewFrame previewFrame = new PreviewFrame();
PreviewFrame previewFrame = null;

public DefaultComboBoxModel galleries = null;
//private Gallery currentGallery = null;
Expand Down Expand Up @@ -186,14 +186,22 @@ public void initComponents()

jPictureInspector.setMainFrame( this );

previewFrame.initComponents();

setGalleries(galleries);

jInspectorDivider.setDividerLocation( GalleryRemote.getInstance().properties.getIntProperty( "inspectorDividerLocation" ) );

setVisible( true );

previewFrame = new PreviewFrame();
previewFrame.initComponents();
previewFrame.addWindowListener(
new java.awt.event.WindowAdapter() {
public void windowClosing( java.awt.event.WindowEvent e ) {
jCheckBoxMenuPreview.setState( false );
}
} );

if ( GalleryRemote.getInstance().properties.getShowPreview() ) {
previewFrame.setVisible( true );
}
Expand All @@ -209,8 +217,6 @@ private void setGalleries(DefaultComboBoxModel galleries) {
jGalleryCombo.setModel( galleries );
galleries.addListDataListener(this);
updateGalleryParams();

//resetUIState();
}


Expand Down Expand Up @@ -875,13 +881,6 @@ public void windowClosing( java.awt.event.WindowEvent e ) {
thisWindowClosing( e );
}
} );
previewFrame.addWindowListener(
new java.awt.event.WindowAdapter()
{
public void windowClosing( java.awt.event.WindowEvent e ) {
jCheckBoxMenuPreview.setState( false );
}
} );
jPicturesList.addKeyListener(
new KeyAdapter()
{
Expand Down

0 comments on commit c937893

Please sign in to comment.