public void linkActivated(HyperlinkEvent e) {
String ref = (String)e.getHref();
if (ref.equals(START_HREF)) {
Object data = descriptionPanel.getControl().getData(ICompositeCheatsheetTags.TASK);
if (data instanceof EditableTask) {
EditableTask task = (EditableTask)data;
task.setStarted();
}
}
if (ref.equals(SKIP_HREF)) {
Object data = descriptionPanel.getControl().getData(ICompositeCheatsheetTags.TASK);
if (data instanceof AbstractTask) {
AbstractTask task = (AbstractTask)data;
task.setState(ICompositeCheatSheetTask.SKIPPED);
}
}
if (ref.equals(REVIEW_TAG)) {
Object data = descriptionPanel.getControl().getData(ICompositeCheatsheetTags.TASK);
if (data instanceof EditableTask) {