Package net.sf.gluebooster.java.booster.basic.gui.swing

Examples of net.sf.gluebooster.java.booster.basic.gui.swing.SwingFactory


    return container;
  }

  @Override
  public void init() {
    JFrame frame = new SwingFactory().createFrame("Languages Demo", 800,
        500, true, new BorderLayout());

    container = frame;
    controller = new LanguagesBasicDemoConfigurationControllerDelegate(this);

    SwingFactory guiFactory = new SwingFactory();

    Button chineseFrenchButton = createButton(
        CHINESE_FRENCH_LABEL,
        LanguagesBasicDemoConfigurationConstants.ACTION_CHOOSE_CHINESE_FRENCH_DICTIONARY);

    Button chineseGermanButton = createButton(
        CHINESE_GERMAN_LABEL,
        LanguagesBasicDemoConfigurationConstants.ACTION_CHOOSE_CHINESE_GERMAN_DICTIONARY);

    Button characterComponentsButton = createButton(
        CHARACTER_COMPONENTS_LABEL,
        LanguagesBasicDemoConfigurationConstants.ACTION_CHOOSE_CHARACTER_COMPONENTS_FILE);

    Button chineseTextButton = createButton(
        "Chinese Text",
        LanguagesBasicDemoConfigurationConstants.ACTION_CHOOSE_CHINESE_TEXT_FILE);

    Button runButton = createButton("Run",
        LanguagesBasicDemoConstants.ACTION_CREATE_VOCABULARY,
        mainActionListener);
    frame.add(runButton, BorderLayout.SOUTH);

    Button findVocabularyButton = createButton("Find vocabulary",
        LanguagesBasicDemoConstants.ACTION_FIND_WORDS_FOR_VOCABULARY,
        mainActionListener);
    frame.add(findVocabularyButton, BorderLayout.NORTH);

    JMenuBar menuBar = new JMenuBar();
    frame.setJMenuBar(menuBar);

    JMenu projectMenu = new JMenu("Configuration");
    menuBar.add(projectMenu);

    guiFactory.addMenuItem(projectMenu, "Edit",
            LanguagesBasicDemoConfigurationConstants.ACTION_EDIT_CONFIGURATION,
        controller);

    guiFactory.addMenuItem(projectMenu, "Save",
            LanguagesBasicDemoConfigurationConstants.ACTION_SAVE_CONFIGURATION,
        controller);

    guiFactory.addMenuItem(projectMenu, "Load",
            LanguagesBasicDemoConfigurationConstants.ACTION_LOAD_CONFIGURATION,
        controller);

    JMenu helpMenu = new JMenu("Help");
    menuBar.add(helpMenu);

    guiFactory.addMenuItem(helpMenu,
        LanguagesBasicDemoConstants.ACTION_CREATE_DOCUMENTATION,
        LanguagesBasicDemoConstants.ACTION_CREATE_DOCUMENTATION,
        controller);

    configurationDialog = new JDialog(frame, "Configuration");
View Full Code Here

TOP

Related Classes of net.sf.gluebooster.java.booster.basic.gui.swing.SwingFactory

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.