focusOnSelectionAction.setEnabled(false);
historyAction = new Action() {
public void run() {
if (historyStack.size() > 0) {
IvyNodeElement element = (IvyNodeElement) historyStack.pop();
forwardStack.push(currentRoot);
forwardAction.setEnabled(true);
focusOn(element);
if (historyStack.size() <= 0) {
historyAction.setEnabled(false);
}
}
}
};
historyAction.setText("Back");
historyAction.setToolTipText("Back");
historyAction.setEnabled(false);
historyAction.setImageDescriptor(PlatformUI.getWorkbench().getSharedImages()
.getImageDescriptor(ISharedImages.IMG_TOOL_BACK));
forwardAction = new Action() {
public void run() {
if (forwardStack.size() > 0) {
IvyNodeElement element = (IvyNodeElement) forwardStack.pop();
historyStack.push(currentRoot);
historyAction.setEnabled(true);
focusOn(element);