public final class ContestExplorer extends org.eclipse.ui.part.ViewPart implements IContestSelectionListener, org.eclipse.jface.viewers.ISelectionChangedListener
Modifier and Type | Field and Description |
---|---|
private ContestInfo |
contestInfo
Current contest information.
|
static java.lang.String |
ID
Identifier of this view.
|
static java.lang.String |
MENU_CONTRIBUTION
Menu contribution identifier.
|
static java.lang.String |
MENU_ID
Identifier of the contextual menu registered.
|
private org.eclipse.jface.viewers.TableViewer |
viewer
Viewer instance this view expose.
|
Constructor and Description |
---|
ContestExplorer() |
Modifier and Type | Method and Description |
---|---|
void |
contestSelected(ContestInfo contestInfo)
Notifies that the current contextual
ContestInfo
instance has changed. |
private void |
createContextualMenu()
Creates and registers the contextual menu associated to the internal viewer.
|
void |
createPartControl(org.eclipse.swt.widgets.Composite parent) |
private org.eclipse.swt.graphics.Image |
getImage(java.lang.Object element)
Functional method that acts as a
Supplier of Image
to display for a given problem instance. |
private java.util.List<Problem> |
getProblems()
Functional method that acts as a
Supplier of available
probem. |
void |
selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent event) |
void |
setFocus() |
checkSite, getViewSite, init, init, saveState, setContentDescription, setInitializationData, setPartName
addPartPropertyListener, addPropertyListener, dispose, firePartPropertyChanged, firePropertyChange, getAdapter, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, getTitleImage, getTitleToolTip, removePartPropertyListener, removePropertyListener, setPartProperty, setSite, setTitle, setTitleImage, setTitleToolTip, showBusy
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public static final java.lang.String ID
public static final java.lang.String MENU_ID
public static final java.lang.String MENU_CONTRIBUTION
private org.eclipse.jface.viewers.TableViewer viewer
private ContestInfo contestInfo
private java.util.List<Problem> getProblems()
Supplier
of available
probem.private org.eclipse.swt.graphics.Image getImage(java.lang.Object element)
Supplier
of Image
to display for a given problem instance.element
- Problem instance to retrieve image from.public void createPartControl(org.eclipse.swt.widgets.Composite parent)
createPartControl
in interface org.eclipse.ui.IWorkbenchPart
createPartControl
in class org.eclipse.ui.part.WorkbenchPart
private void createContextualMenu()
public void selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent event)
selectionChanged
in interface org.eclipse.jface.viewers.ISelectionChangedListener
public void contestSelected(ContestInfo contestInfo)
ContestInfo
instance has changed.contestSelected
in interface IContestSelectionListener
contestInfo
- Newly selected contest instance.public void setFocus()
setFocus
in interface org.eclipse.ui.IWorkbenchPart
setFocus
in class org.eclipse.ui.part.WorkbenchPart