Package no.geosoft.cc.ui

Examples of no.geosoft.cc.ui.SplashScreen


     */
    public static void main(String[] args) {
        try {
            System.setProperty("sun.awt.exception.handler", ExceptionHandler.class.getName());

            final SplashScreen splash = new SplashScreen("/org/owasp/webscarab/webscarab_logo.gif");
            splash.open(10000);
            initLogging();

            try {
                Preferences.loadPreferences(null);
            } catch (IOException ioe) {
                System.err.println("Error loading preferences: " + ioe);
                System.exit(1);
            }

            // Provide default Copy/Paste/etc actions on text components
            Toolkit.getDefaultToolkit().getSystemEventQueue().push(new TextComponentContextMenu());

            Framework framework = new Framework();

            boolean lite = Boolean.valueOf(Preferences.getPreference("WebScarab.lite", "false")).booleanValue();

            File t = null;
            if (args != null && args.length == 1) {
              t = new File(args[0]);
            }
            final File session = t;
           
            final WebScarabUI ui;
           
            if (! lite) {
              UIFramework uif = new UIFramework(framework);
                loadAllPlugins(framework, uif);
                ui = uif;
            } else {
              Lite uif = new Lite(framework);
                loadLitePlugins(framework, uif);
                ui = uif;
            }
            try {
              ExceptionHandler.setParentComponent(ui.getFrame());
                SwingUtilities.invokeAndWait(new Runnable() {
                    public void run() {
                      JFrame frame = ui.getFrame();
                        frame.setVisible(true);
                        frame.toFront();
                        frame.requestFocus();
                        splash.close();
                    if (session != null && session.isDirectory())
                      ui.loadSession(session);
                    else
                          ui.createTemporarySession();

View Full Code Here


     */
    public static void main(String[] args) {
        try {
            System.setProperty("sun.awt.exception.handler", ExceptionHandler.class.getName());

            final SplashScreen splash = new SplashScreen("/org/owasp/webscarab/webscarab_logo.gif");
            splash.open(10000);
            initLogging();

            try {
                Preferences.loadPreferences(null);
            } catch (IOException ioe) {
                System.err.println("Error loading preferences: " + ioe);
                System.exit(1);
            }

            // Provide default Copy/Paste/etc actions on text components
            Toolkit.getDefaultToolkit().getSystemEventQueue().push(new TextComponentContextMenu());

            Framework framework = new Framework();

            boolean lite = Boolean.valueOf(Preferences.getPreference("WebScarab.lite", "true")).booleanValue();

            if (args != null && args.length > 0) {
                if (args[0].equalsIgnoreCase("lite")) {
                    lite = true;
                    if (args.length>1) {
                        String[] trim = new String[args.length-1];
                        System.arraycopy(args, 1, trim, 0, args.length-1);
                        args = trim;
                    } else {
                        args = new String[0];
                    }
                }
            }

            if (! lite) {
                final UIFramework uif = new UIFramework(framework);
                ExceptionHandler.setParentComponent(uif);
                loadAllPlugins(framework, uif);
                try {
                    SwingUtilities.invokeAndWait(new Runnable() {
                        public void run() {
                            uif.setVisible(true);
                            uif.toFront();
                            uif.requestFocus();
                            splash.close();
                        }
                    });
                } catch (Exception e) {
                    System.err.println("Error loading GUI: " + e.getMessage());
                    e.printStackTrace();
                    System.exit(1);
                }
                uif.run();
            } else {
                final Lite uif = new Lite(framework);
                ExceptionHandler.setParentComponent(uif);
                loadLitePlugins(framework, uif);
                try {
                    SwingUtilities.invokeAndWait(new Runnable() {
                        public void run() {
                            uif.setVisible(true);
                            uif.toFront();
                            uif.requestFocus();
                            splash.close();
                        }
                    });
                } catch (Exception e) {
                    System.err.println("Error loading GUI: " + e.getMessage());
                    e.printStackTrace();
View Full Code Here

TOP

Related Classes of no.geosoft.cc.ui.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.