Package org.eclipse.jface.text
Interface IWidgetTokenKeeperExtension
-
- All Known Implementing Classes:
ContentAssistant,InformationPresenter,SubjectControlContentAssistant
public interface IWidgetTokenKeeperExtensionExtension interface forIWidgetTokenKeeper.Replaces the original
requestWidgetTokenfunctionality with a new priority based approach. Adds the concept of focus handling.- Since:
- 3.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanrequestWidgetToken(IWidgetTokenOwner owner, int priority)The given widget token owner requests the widget token from this token keeper.booleansetFocus(IWidgetTokenOwner owner)Requests the receiver to give focus to its popup shell, hover, or similar.
-
-
-
Method Detail
-
requestWidgetToken
boolean requestWidgetToken(IWidgetTokenOwner owner, int priority)
The given widget token owner requests the widget token from this token keeper. Returnstrueif the token is released by this token keeper. Note, the keeper must not callreleaseWidgetToken(IWidgetTokenKeeper)explicitly.The general contract is that the receiver should release the token if
priorityexceeds the receiver's priority.- Parameters:
owner- the token ownerpriority- the priority of the request- Returns:
trueif token has been releasedfalseotherwise
-
setFocus
boolean setFocus(IWidgetTokenOwner owner)
Requests the receiver to give focus to its popup shell, hover, or similar. There is no assumption made whether the receiver actually succeeded in taking the focus. The return value gives a hint whether the receiver tried to take focus.- Parameters:
owner- the token owner- Returns:
trueif the receiver tried to take focus,falseif it did not.
-
-