/****************************************************************************
 *
 *	All rights reserved.  Unpublished, all rights reserved under
 *	copyright law and international treaty.  Use of a copyright notice
 *	is precautionary only and does not imply publication or disclosure.
 *	This software contains confidential information and trade secrets of
 *	Micro Focus International Ltd, and no part of this program or
 *	publication may be reproduced, transmitted, transcribed, stored in
 *	a retrieval system, or translated into any language or computer
 *	language, in any form or by any means, electronic, mechanical,
 *	magnetic, optical, chemical, manual or otherwise, without the prior
 *	written permission of:
 *
 *	Micro Focus International Ltd,
 *	The Lawn, Old Bath Road, Newbury, Berkshire, RG14 1QN, UK.
 *	(01635) 32646
 *
 *	RESTRICTED RIGHTS LEGEND
 *	Use, duplication, or disclosure by the Government is subject to
 *	restrictions as set forth in subparagraph (c)(1)(ii) of the Rights
 *	in Technical Data and Computer Software clause at DFARS 52.227-7013
 *	or subparagraphs (c)(1) and (2) of Commercial Computer Software -
 *	Restricted Rights at 48 CFR 52.227-19, as applicable.  Contact
 *	Micro Focus International Ltd, 701 East Middlefield Road,
 *	Mountain View, California 94043, USA.
 *
 ****************************************************************************/

/** Start of source module %M% **/

import javax.swing.UIManager;
import java.awt.*;

public class RecordDemoGui
{
  boolean packFrame = false;

  /**Construct the application*/
  public RecordDemoGui()
  {
    RecordDemoFrame frame = new RecordDemoFrame();
    //Validate frames that have preset sizes
    //Pack frames that have useful preferred size info, e.g. from their layout
    if (packFrame)
    {
      frame.pack();
    }
    else
    {
      frame.validate();
    }
    //Center the window
    Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
    Dimension frameSize = frame.getSize();
    if (frameSize.height > screenSize.height)
    {
      frameSize.height = screenSize.height;
    }
    if (frameSize.width > screenSize.width)
    {
      frameSize.width = screenSize.width;
    }
    frame.setLocation((screenSize.width - frameSize.width) / 2, (screenSize.height - frameSize.height) / 2);
    frame.setVisible(true);
  }
  /**Main method*/
  public static void main(String[] args) {
    try
    {
      UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
    }
    catch(Exception e)
    {
      e.printStackTrace();
    }
    new RecordDemoGui();
  }
}

/** End of source module %M% **/
