Package com.aesthete.swingobjects.showcase

Source Code of com.aesthete.swingobjects.showcase.Launcher

package com.aesthete.swingobjects.showcase;

import javax.swing.SwingUtilities;

import com.aesthete.swingobjects.SwingObjectProperties;
import com.aesthete.swingobjects.SwingObjectsInit;
import com.aesthete.swingobjects.fw.common.config.FrameFactory;
import com.aesthete.swingobjects.fw.common.util.CommonUI;

public class Launcher {

  public static void main(String[] args) {
    try {
      SwingObjectProperties props = new SwingObjectProperties();
      props.setAppPropsFile(Launcher.class.getResource("application.properties").getFile());
      props.setErrorPropsFile(Launcher.class.getResource("error.properties").getFile());
      props.setFramesXmlFile(Launcher.class.getResource("frames.xml").getFile());
      props.setLog4jFile(Launcher.class.getResource("log4j.properties").getFile());
      props.setSwingActionXmlFile(Launcher.class.getResource("swingaction.xml").getFile());

      SwingObjectsInit.initSwingObjects(props);

      SwingUtilities.invokeLater(new Runnable() {
        public void run() {
          LogonFrame frame = (LogonFrame) FrameFactory.getFrame(FrameFactoryEnum.logonPanel.name());
          CommonUI.showOnScreen(frame);
        }
      });

    } catch (Exception e) {
      e.printStackTrace();
    }

  }
}
TOP

Related Classes of com.aesthete.swingobjects.showcase.Launcher

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.