use of com.limegroup.gnutella.gui.options.ConfigureOptionsAction in project frostwire by frostwire.
the class LibraryExplorer method setupTree.
private void setupTree() {
tree = new LibraryIconTree(model);
tree.setRowHeight(TableSettings.DEFAULT_TABLE_ROW_HEIGHT.getValue());
tree.setRootVisible(false);
tree.setShowsRootHandles(false);
tree.getSelectionModel().setSelectionMode(TreeSelectionModel.SINGLE_TREE_SELECTION);
tree.setCellRenderer(new NodeRenderer());
tree.setDragEnabled(true);
tree.setTransferHandler(new LibraryFilesTransferHandler(tree));
((BasicTreeUI) tree.getUI()).setExpandedIcon(null);
((BasicTreeUI) tree.getUI()).setCollapsedIcon(null);
SkinPopupMenu popup = new SkinPopupMenu();
popup.add(new SkinMenuItem(refreshAction));
popup.add(new SkinMenuItem(exploreAction));
popup.add(new SkinMenuItem(new ConfigureOptionsAction(OptionsConstructor.SHARED_KEY, I18n.tr("Configure Options"), I18n.tr("You can configure the FrostWire\'s Options."))));
tree.addMouseListener(new DefaultMouseListener(new TreeMouseObserver(tree, popup)));
tree.addKeyListener(new KeyAdapter() {
@Override
public void keyReleased(KeyEvent e) {
if (LibraryUtils.isRefreshKeyEvent(e)) {
refreshSelection(true);
}
}
});
treeSelectionListener = new LibraryExplorerTreeSelectionListener();
tree.addTreeSelectionListener(treeSelectionListener);
ToolTipManager.sharedInstance().registerComponent(tree);
}
use of com.limegroup.gnutella.gui.options.ConfigureOptionsAction in project frostwire by frostwire.
the class AbstractLibraryTableMediator method buildListeners.
@Override
protected void buildListeners() {
super.buildListeners();
SEND_TO_FRIEND_ACTION = new SendToFriendAction();
OPTIONS_ACTION = new ConfigureOptionsAction(OptionsConstructor.LIBRARY_KEY, tr("Options"), tr("You can configure the folders you share in FrostWire\'s Options."));
}
Aggregations