Package org.jdesktop.application

Examples of org.jdesktop.application.ApplicationActionMap


        return bar;
    }

    private JToolBar createToolBar() {
        ApplicationActionMap actionMap = getActionMap();
        JToolBar bar = new JToolBar();
        bar.setRollover(true);
        toolBarMap.clear();
        final boolean hideText = !p.getBoolean(PREF_GUI_SHOW_TEXT_IN_TOOLBAR, true);
        for (String actionName : TOOLBAR) {
            if (TOOLBAR_SEPARATOR.equals(actionName)) {
                bar.addSeparator();
            } else {
                AbstractButton bt;
                if (actionName.startsWith(TOOLBAR_TOGGLE_BUTTON)) {
                    actionName = StringUtils.substring(actionName, TOOLBAR_TOGGLE_BUTTON.length());
                    bt = new JToggleButton(actionMap.get(actionName));
                } else {
                    bt = new JButton(actionMap.get(actionName));
                }
                bt.setFocusable(false);
                bt.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
                bt.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
                bt.setHideActionText(hideText);
View Full Code Here


        labelDescription = new JLabel(description);
        textFieldPath = new JTextField(oldPath);
        textFieldPath.setColumns(30);

        ApplicationActionMap actionMap = app.getContext().getActionMap(this);

        buttonOk = new JButton(actionMap.get(ACTION_OK));
        buttonCancel = new JButton(actionMap.get(ACTION_CANCEL));
        buttonBrowse = new JButton(actionMap.get(ACTION_BROWSE));

        JSeparator separator = new JSeparator();

        getRootPane().setDefaultButton(buttonOk);
View Full Code Here

        getRootPane().setDefaultButton(okButton);
        this.pack();
    }

    private void initComponents() {
        ApplicationActionMap actionMap = mediator.getApplication().getContext().getActionMap(this);
        ResourceMap resourceMap = mediator.getApplication().getContext().getResourceMap(OptionsDialog.class);
        getRootPane().setLayout(new BorderLayout());

        JPanel buttonsPanel = createButtonsPanel(actionMap, resourceMap);
        JPanel generalPanel = createGeneralPanel(actionMap, resourceMap);
View Full Code Here

TOP

Related Classes of org.jdesktop.application.ApplicationActionMap

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.