Package com.eteks.sweethome3d.swing

Examples of com.eteks.sweethome3d.swing.UnfocusableToolBar


  /**
   * Returns the tool bar of this pane.
   */
  private JToolBar createToolBar(UserPreferences preferences,
                                 EditorController controller) {
    JToolBar toolBar = new UnfocusableToolBar();
    toolBar.setFloatable(false);
    ActionMap actionMap = getActionMap();
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(EditorView.ActionType.NEW_LIBRARY)));
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(EditorView.ActionType.OPEN)));
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(EditorView.ActionType.SAVE)));
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(EditorView.ActionType.SAVE_AS)));
    toolBar.add(Box.createRigidArea(new Dimension(2, 2)));
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(EditorView.ActionType.PREFERENCES)));
    toolBar.addSeparator();
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(ActionType.IMPORT_FURNITURE)));
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(ActionType.MODIFY_FURNITURE)));
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(ActionType.DELETE)));
    toolBar.add(Box.createRigidArea(new Dimension(2, 2)));
    JComponent furnitureLanguageView = (JComponent)controller.getFurnitureLanguageController().getView();
    furnitureLanguageView.setMaximumSize(furnitureLanguageView.getPreferredSize());
    toolBar.add(furnitureLanguageView);
    toolBar.addSeparator();
    toolBar.add(new ResourceAction.ToolBarAction(actionMap.get(EditorView.ActionType.ABOUT)));
    return toolBar;
  }
View Full Code Here

TOP

Related Classes of com.eteks.sweethome3d.swing.UnfocusableToolBar

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.