Class SuggesterConnector
java.lang.Object
com.vaadin.client.ui.AbstractConnector
com.vaadin.client.extensions.AbstractExtensionConnector
io.jmix.ui.widget.client.addon.aceeditor.SuggesterConnector
- All Implemented Interfaces:
com.google.gwt.event.shared.EventHandler
,com.vaadin.client.communication.StateChangeEvent.StateChangeHandler
,com.vaadin.client.ServerConnector
,com.vaadin.shared.Connector
,AceEditorWidget.SelectionChangeListener
,GwtAceKeyboardHandler
,SuggestPopup.SuggestionSelectedListener
,Serializable
- Direct Known Subclasses:
JmixSuggesterConnector
public class SuggesterConnector
extends com.vaadin.client.extensions.AbstractExtensionConnector
implements GwtAceKeyboardHandler, SuggestPopup.SuggestionSelectedListener, AceEditorWidget.SelectionChangeListener
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.jmix.ui.widget.client.addon.aceeditor.gwt.GwtAceKeyboardHandler
GwtAceKeyboardHandler.Command
-
Field Summary
Modifier and TypeFieldDescriptionprotected AceEditorConnector
protected static final int
protected SuggestPopup
protected static final int
protected SuggesterServerRpc
protected boolean
protected boolean
protected boolean
protected Integer
protected boolean
protected AceRange
protected String
protected AceEditorWidget
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected SuggestPopup
protected void
extend
(com.vaadin.client.ServerConnector target) getState()
protected String
handleKeyboard
(com.google.gwt.core.client.JavaScriptObject data, int hashId, String keyString, int keyCode, GwtAceKeyboardEvent e) Called on key press.protected GwtAceKeyboardHandler.Command
keyPressWhileSuggesting
(int keyCode) void
void
onStateChanged
(com.vaadin.client.communication.StateChangeEvent stateChangeEvent) void
protected void
setPopupPosition
(SuggestPopup popup) protected void
setSuggs
(List<TransportSuggestion> suggs) protected void
protected void
protected void
void
protected void
Methods inherited from class com.vaadin.client.extensions.AbstractExtensionConnector
setParent
Methods inherited from class com.vaadin.client.ui.AbstractConnector
addStateChangeHandler, addStateChangeHandler, createState, doInit, ensureHandlerManager, fireEvent, forceStateChange, getChildren, getConnection, getConnectorId, getParent, getResourceUrl, getRpcImplementations, getRpcProxy, getStateType, getTag, hasEventListener, init, isEnabled, onUnregister, registerRpc, removeStateChangeHandler, removeStateChangeHandler, setChildren, setTag, unregisterRpc, updateEnabledState
-
Field Details
-
CURSOR_LINE_HEIGHT
protected static final int CURSOR_LINE_HEIGHT- See Also:
-
POPUP_OFFSET
protected static final int POPUP_OFFSET- See Also:
-
connector
-
widget
-
serverRpc
-
suggStartText
-
suggStartCursor
-
suggesting
protected boolean suggesting -
popup
-
suggestionStartId
-
startSuggestingOnNextSelectionChange
protected boolean startSuggestingOnNextSelectionChange -
suggestOnDot
protected boolean suggestOnDot -
showDescriptions
protected boolean showDescriptions
-
-
Constructor Details
-
SuggesterConnector
public SuggesterConnector()
-
-
Method Details
-
onStateChanged
public void onStateChanged(com.vaadin.client.communication.StateChangeEvent stateChangeEvent) - Specified by:
onStateChanged
in interfacecom.vaadin.client.communication.StateChangeEvent.StateChangeHandler
- Overrides:
onStateChanged
in classcom.vaadin.client.ui.AbstractConnector
-
getState
- Specified by:
getState
in interfacecom.vaadin.client.ServerConnector
- Overrides:
getState
in classcom.vaadin.client.ui.AbstractConnector
-
setSuggs
-
createSuggestionPopup
-
extend
protected void extend(com.vaadin.client.ServerConnector target) - Specified by:
extend
in classcom.vaadin.client.extensions.AbstractExtensionConnector
-
handleKeyboard
public GwtAceKeyboardHandler.Command handleKeyboard(com.google.gwt.core.client.JavaScriptObject data, int hashId, String keyString, int keyCode, GwtAceKeyboardEvent e) Description copied from interface:GwtAceKeyboardHandler
Called on key press.- Specified by:
handleKeyboard
in interfaceGwtAceKeyboardHandler
- Returns:
- command
-
startSuggesting
protected void startSuggesting() -
suggestionSelected
- Specified by:
suggestionSelected
in interfaceSuggestPopup.SuggestionSelectedListener
-
noSuggestionSelected
public void noSuggestionSelected()- Specified by:
noSuggestionSelected
in interfaceSuggestPopup.SuggestionSelectedListener
-
stopAskingForSuggestions
protected void stopAskingForSuggestions() -
stopSuggesting
protected void stopSuggesting() -
keyPressWhileSuggesting
-
getWord
-
selectionChanged
public void selectionChanged()- Specified by:
selectionChanged
in interfaceAceEditorWidget.SelectionChangeListener
-
setPopupPosition
-
updatePopupPosition
protected void updatePopupPosition()
-