protected JComponent buildToolbar() {
   final JToolBar bar = new JToolBar();
   ToolBarBuilder builder = new ToolBarBuilder(bar);
   Action a = CommandUtils.createViewAction(this, "buscar");
   a.putValue(Action.NAME, "Buscar");
   a.putValue(Action.SHORT_DESCRIPTION, "Buscar facturas en otro periodo");
   builder.add(a);
   builder.add(buildFilterPanel());
   return builder.getToolBar();
 }
Exemple #2
0
 /**
  * Permite crear una barra de herramientas a ser colocada en la parte izquierda del panel y en
  * posición vertical Subclases que quieran agregar mas acciones deberan llamar super.bukldToolbar
  * para obtener el builder pre configurado
  *
  * @return
  */
 protected JComponent buildToolbar() {
   final JToolBar bar = new JToolBar();
   ToolBarBuilder builder = new ToolBarBuilder(bar);
   if (manejarPeriodo) {
     // builder.add(getPeriodoLabel());
   } else {
     builder.add(CommandUtils.createLoadAction(this, "load"));
     builder.add(buildFilterPanel());
   }
   addButton(builder);
   return builder.getToolBar();
 }
Exemple #3
0
 private JToolBar buildToolBar() {
   final ToolBarBuilder bar = new ToolBarBuilder("Track Toolbar");
   ToolBarButton button = null;
   button = (ToolBarButton) ComponentFactory.createToolBarButton(Actions.UNLOCK_ID);
   button.putClientProperty(Resources.EDITOR_COMPONENT, this);
   bar.add(button);
   button = (ToolBarButton) ComponentFactory.createToolBarButton(Actions.COMMIT_ID);
   button.putClientProperty(Resources.EDITOR_COMPONENT, this);
   bar.add(button);
   button = (ToolBarButton) ComponentFactory.createToolBarButton(Actions.ROLLBACK_ID);
   button.putClientProperty(Resources.EDITOR_COMPONENT, this);
   bar.add(button);
   button = (ToolBarButton) ComponentFactory.createToolBarButton(Actions.DELETE_ID);
   button.putClientProperty(Resources.EDITOR_COMPONENT, this);
   bar.add(button);
   button = (ToolBarButton) ComponentFactory.createToolBarButton(Actions.FILE_RENAME_ID);
   button.putClientProperty(Resources.EDITOR_COMPONENT, this);
   bar.add(button);
   return bar.getToolBar();
 }