public class ItemSelectedPropertyTester
extends org.eclipse.core.expressions.PropertyTester
implements org.eclipse.jface.viewers.ISelectionChangedListener
PropertyTester
for determining if an
Item
has been selected in the ItemViewer
. This is
necessary to enable/disable the DeleteItemHandler
when the selection
is not-empty/empty. Note that this property is tested by the
IEvaluationService
and is used by the DeleteItemHandler
extension (org.eclipse.ui.handlers
).Constructor and Description |
---|
ItemSelectedPropertyTester() |
Modifier and Type | Method and Description |
---|---|
void |
selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent event)
When the
ItemViewer 's selection changes, this sets
itemSelected . |
boolean |
test(java.lang.Object receiver,
java.lang.String property,
java.lang.Object[] args,
java.lang.Object expectedValue)
Returns whether or not the selection in the
ItemViewer is
empty. |
public boolean test(java.lang.Object receiver, java.lang.String property, java.lang.Object[] args, java.lang.Object expectedValue)
ItemViewer
is
empty.test
in interface org.eclipse.core.expressions.IPropertyTester
public void selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent event)
ItemViewer
's selection changes, this sets
itemSelected
.selectionChanged
in interface org.eclipse.jface.viewers.ISelectionChangedListener