Search in sources :

Example 1 with ToolbarIconItem

use of delta.common.ui.swing.toolbar.ToolbarIconItem in project lotro-companion by dmorcellet.

the class AccountsManagementController method buildToolBar.

private ToolbarController buildToolBar() {
    ToolbarController controller = new ToolbarController();
    ToolbarModel model = controller.getModel();
    // New icon
    String newIconPath = getToolbarIconPath("new");
    ToolbarIconItem newIconItem = new ToolbarIconItem(NEW_ACCOUNT_ID, newIconPath, NEW_ACCOUNT_ID, "Create a new account...", "New");
    model.addToolbarIconItem(newIconItem);
    // Remove icon
    String deleteIconPath = getToolbarIconPath("delete");
    ToolbarIconItem deleteIconItem = new ToolbarIconItem(REMOVE_ACCOUNT_ID, deleteIconPath, REMOVE_ACCOUNT_ID, "Remove the selected account...", "Remove");
    model.addToolbarIconItem(deleteIconItem);
    controller.addActionListener(this);
    return controller;
}
Also used : ToolbarController(delta.common.ui.swing.toolbar.ToolbarController) ToolbarIconItem(delta.common.ui.swing.toolbar.ToolbarIconItem) ToolbarModel(delta.common.ui.swing.toolbar.ToolbarModel)

Example 2 with ToolbarIconItem

use of delta.common.ui.swing.toolbar.ToolbarIconItem in project lotro-companion by dmorcellet.

the class ToonsManagementController method buildToolBar.

private ToolbarController buildToolBar() {
    ToolbarController controller = new ToolbarController();
    ToolbarModel model = controller.getModel();
    // New icon
    String newIconPath = getToolbarIconPath("new");
    ToolbarIconItem newIconItem = new ToolbarIconItem(NEW_TOON_ID, newIconPath, NEW_TOON_ID, "Create a new character...", "New");
    model.addToolbarIconItem(newIconItem);
    // Remove icon
    String deleteIconPath = getToolbarIconPath("delete");
    ToolbarIconItem deleteIconItem = new ToolbarIconItem(REMOVE_TOON_ID, deleteIconPath, REMOVE_TOON_ID, "Remove the selected character...", "Remove");
    model.addToolbarIconItem(deleteIconItem);
    controller.addActionListener(this);
    // Import icon
    String importIconPath = getToolbarIconPath("import");
    ToolbarIconItem importIconItem = new ToolbarIconItem(IMPORT_TOON_ID, importIconPath, IMPORT_TOON_ID, "Import a character...", "Import");
    model.addToolbarIconItem(importIconItem);
    return controller;
}
Also used : ToolbarController(delta.common.ui.swing.toolbar.ToolbarController) ToolbarIconItem(delta.common.ui.swing.toolbar.ToolbarIconItem) ToolbarModel(delta.common.ui.swing.toolbar.ToolbarModel)

Example 3 with ToolbarIconItem

use of delta.common.ui.swing.toolbar.ToolbarIconItem in project lotro-companion by dmorcellet.

the class StashWindowController method buildToolBar.

private ToolbarController buildToolBar() {
    ToolbarController controller = new ToolbarController();
    ToolbarModel model = controller.getModel();
    // New icon
    String newIconPath = getToolbarIconPath("new");
    ToolbarIconItem newIconItem = new ToolbarIconItem(NEW_ITEM_ID, newIconPath, NEW_ITEM_ID, "Create a new character configuration...", "New");
    model.addToolbarIconItem(newIconItem);
    // Clone icon
    String cloneIconPath = getToolbarIconPath("copy");
    ToolbarIconItem cloneIconItem = new ToolbarIconItem(CLONE_ITEM_ID, cloneIconPath, CLONE_ITEM_ID, "Clone the selected character configuration...", "Clone");
    model.addToolbarIconItem(cloneIconItem);
    // Remove icon
    String deleteIconPath = getToolbarIconPath("delete");
    ToolbarIconItem deleteIconItem = new ToolbarIconItem(REMOVE_ITEM_ID, deleteIconPath, REMOVE_ITEM_ID, "Remove the selected character...", "Remove");
    model.addToolbarIconItem(deleteIconItem);
    // Register action listener
    controller.addActionListener(this);
    return controller;
}
Also used : ToolbarController(delta.common.ui.swing.toolbar.ToolbarController) ToolbarIconItem(delta.common.ui.swing.toolbar.ToolbarIconItem) ToolbarModel(delta.common.ui.swing.toolbar.ToolbarModel)

Example 4 with ToolbarIconItem

use of delta.common.ui.swing.toolbar.ToolbarIconItem in project lotro-companion by dmorcellet.

the class DeedsManagementController method buildToolBar.

private ToolbarController buildToolBar() {
    ToolbarController controller = new ToolbarController();
    ToolbarModel model = controller.getModel();
    // New icon
    String newIconPath = getToolbarIconPath("new");
    ToolbarIconItem newIconItem = new ToolbarIconItem(NEW_DEED_ID, newIconPath, NEW_DEED_ID, "Create a new deed...", "New");
    model.addToolbarIconItem(newIconItem);
    // Remove icon
    String deleteIconPath = getToolbarIconPath("delete");
    ToolbarIconItem deleteIconItem = new ToolbarIconItem(REMOVE_DEED_ID, deleteIconPath, REMOVE_DEED_ID, "Remove the selected deed...", "Remove");
    model.addToolbarIconItem(deleteIconItem);
    controller.addActionListener(this);
    return controller;
}
Also used : ToolbarController(delta.common.ui.swing.toolbar.ToolbarController) ToolbarIconItem(delta.common.ui.swing.toolbar.ToolbarIconItem) ToolbarModel(delta.common.ui.swing.toolbar.ToolbarModel)

Example 5 with ToolbarIconItem

use of delta.common.ui.swing.toolbar.ToolbarIconItem in project lotro-companion by dmorcellet.

the class CharacterFileWindowController method buildToolBar.

private ToolbarController buildToolBar() {
    ToolbarController controller = new ToolbarController();
    ToolbarModel model = controller.getModel();
    // New icon
    String newIconPath = getToolbarIconPath("new");
    ToolbarIconItem newIconItem = new ToolbarIconItem(NEW_TOON_DATA_ID, newIconPath, NEW_TOON_DATA_ID, "Create a new character configuration...", "New");
    model.addToolbarIconItem(newIconItem);
    // Clone icon
    String cloneIconPath = getToolbarIconPath("copy");
    ToolbarIconItem cloneIconItem = new ToolbarIconItem(CLONE_TOON_DATA_ID, cloneIconPath, CLONE_TOON_DATA_ID, "Clone the selected character configuration...", "Clone");
    model.addToolbarIconItem(cloneIconItem);
    // Remove icon
    String deleteIconPath = getToolbarIconPath("delete");
    ToolbarIconItem deleteIconItem = new ToolbarIconItem(REMOVE_TOON_DATA_ID, deleteIconPath, REMOVE_TOON_DATA_ID, "Remove the selected character...", "Remove");
    model.addToolbarIconItem(deleteIconItem);
    // Export icon
    String exportIconPath = getToolbarIconPath("export");
    ToolbarIconItem exportIconItem = new ToolbarIconItem(EXPORT_TOON_DATA_ID, exportIconPath, EXPORT_TOON_DATA_ID, "Export the selected character configuration...", "Export");
    model.addToolbarIconItem(exportIconItem);
    // Register action listener
    controller.addActionListener(this);
    return controller;
}
Also used : ToolbarController(delta.common.ui.swing.toolbar.ToolbarController) ToolbarIconItem(delta.common.ui.swing.toolbar.ToolbarIconItem) ToolbarModel(delta.common.ui.swing.toolbar.ToolbarModel)

Aggregations

ToolbarController (delta.common.ui.swing.toolbar.ToolbarController)6 ToolbarIconItem (delta.common.ui.swing.toolbar.ToolbarIconItem)6 ToolbarModel (delta.common.ui.swing.toolbar.ToolbarModel)6