Package org.csm.jupdater.gui

Examples of org.csm.jupdater.gui.SplashScreen


    public static void main(String[] args) {

        new Thread() {

            public void run() {
                SplashScreen sp = new SplashScreen(ConfigurationManager.getProperty("SPLASH_IMAGE"));
                try {
                    sp.setVisible(true);
                    sp.changeShowedMessage("Initiating jUpdater");
                    sp.changeShowedMessage("Checking Versions");
                    sp.changeShowedMessage(UpdateManager.getActualVersion());

                    int updatesRemaining = DownloadManager.checkForUpdates(ConfigurationManager.getProperty("UPDATE_FILE_URL"),
                            ConfigurationManager.getProperty("UPDATE_FILE_PATH"));
                    sp.changeShowedMessage("Updates Remaning: " + updatesRemaining);

                    UpdateManager.downloadRemainingUpdates();

                    UpdateManager.installDownloadedUpdates();

                    sp.changeShowedMessage("Executing: "
                            + ConfigurationManager.getProperty("EXECUTION_FILE"));

                    Executer.executeJar(ConfigurationManager.getProperty("EXECUTION_FILE"));

                    sp.changeShowedMessage("Done");

                } catch (InterruptedException ex) {
                    Logger.getLogger(App.class.getName()).error(
                            ex.getStackTrace());
                } catch (IOException ex) {
                    Logger.getLogger(App.class.getName()).error(
                            ex.getStackTrace());
                } catch (Exception ex) {
                    Logger.getLogger(App.class.getName()).warn(
                            ex.getMessage());
                    Logger.getLogger(App.class.getName()).error(
                            ex.getStackTrace().toString());
                } finally {
                    sp.dispose();
                }
            }
        }.start();
    }
View Full Code Here

TOP

Related Classes of org.csm.jupdater.gui.SplashScreen

Copyright © 2018 www.massapicom. 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.