List of usage examples for org.eclipse.jface.fieldassist IControlContentAdapter getCursorPosition
public int getCursorPosition(Control control);
From source file:custom.jface.widgets.ContentProposalAdapterPlus.java
License:Open Source License
private void recordCursorPosition() { if (isValid()) { IControlContentAdapter adapter = getControlContentAdapter(); insertionPos = adapter.getCursorPosition(control); // see https://bugs.eclipse.org/bugs/show_bug.cgi?id=139063 if (adapter instanceof IControlContentAdapter2) { selectionRange = ((IControlContentAdapter2) adapter).getSelection(control); }/*from w w w. j a v a 2 s. c om*/ } }
From source file:org.csstudio.autocomplete.ui.content.ContentProposalAdapter.java
License:Open Source License
private void recordCursorPosition() { if (isValid()) { IControlContentAdapter adapter = getControlContentAdapter(); cursorPos = adapter.getCursorPosition(control); // see https://bugs.eclipse.org/bugs/show_bug.cgi?id=139063 if (adapter instanceof IControlContentAdapter2) { selectionRange = ((IControlContentAdapter2) adapter).getSelection(control); }//from w w w.j av a 2s .co m } }