FileDocCategorySizeDatePackage
MainFrame.javaAPI DocExample3408Thu Oct 13 14:58:00 BST 2005com.samscdrental.display

MainFrame

public class MainFrame extends JFrame

Title: Sams CD Rental Store

Description:

Copyright: Copyright (c) 2004

Company:

author
Ken Pugh
version
1.0

Fields Summary
private static final long
serialVersionUID
JToggleButton
checkoutButton
JToggleButton
checkinButton
JLabel
generalFrame
Constructors Summary
public MainFrame()

	   
	
		try
		{
			jbInit();
		}
		catch ( Exception e )
		{
			e.printStackTrace();
		}
	
Methods Summary
voidcheckinButton_actionPerformed(java.awt.event.ActionEvent e)

		CheckinDialog checkinDialog = new CheckinDialog();
		checkinDialog.setBounds( 50, 50, 400, 300 );
		checkinDialog.setVisible( true );
	
voidcheckoutButton_actionPerformed(java.awt.event.ActionEvent e)

		CheckoutDialog checkoutDialog = new CheckoutDialog();
		checkoutDialog.setBounds( 50, 50, 400, 300 );

		checkoutDialog.setVisible( true );
	
private voidjbInit()

		checkoutButton.setMaximumSize( new Dimension( 71, 23 ) );
		checkoutButton.setMinimumSize( new Dimension( 71, 23 ) );
		checkoutButton.setText( "Checkout" );
		checkoutButton.setBounds( new Rectangle( 93, 126, 106, 31 ) );
		checkoutButton.addActionListener( new
										  MainFrame_checkoutButton_actionAdapter( this ) );
		checkinButton.setText( "Checkin" );
		checkinButton.setBounds( new Rectangle( 221, 126, 106, 31 ) );
		checkinButton.addActionListener( new
										 MainFrame_checkinButton_actionAdapter( this ) );
		this.getContentPane().setLayout( null );
		generalFrame.setFont( new java.awt.Font( "Dialog", 1, 20 ) );
		generalFrame.setText( "Sam\'s CD Rental" );
		generalFrame.setBounds( new Rectangle( 126, 44, 176, 43 ) );
		this.setLocale( java.util.Locale.getDefault() );
		this.setResizable( false );
		this.setTitle( "Sam\'s CD Rental" );
		this.addWindowListener( new MainFrame_this_windowAdapter( this ) );
		this.getContentPane().add( checkinButton, null );
		this.getContentPane().add( checkoutButton, null );
		this.getContentPane().add( generalFrame, null );

	
voidthis_windowClosing(java.awt.event.WindowEvent e)

		RentalOperations aRentalOperations =
			RentalOperations.getInstance();
		aRentalOperations.dispose();

		System.exit( 0 );