/** * Hides the proposal popup. */ public void hidePossibleCompletions() { if (fProposalPopup != null) fProposalPopup.hide(); }
/** * Hides the proposal popup. */ public void hidePossibleCompletions() { if (fProposalPopup != null) fProposalPopup.hide(); }
/** * Hides any open pop-ups. */ protected void hide() { if (fProposalPopup != null) fProposalPopup.hide(); if (fContextInfoPopup != null) fContextInfoPopup.hide(); }
/** * Hides any open pop-ups. */ protected void hide() { if (fProposalPopup != null) fProposalPopup.hide(); if (fContextInfoPopup != null) fContextInfoPopup.hide(); }
@Override public void uninstall() { if (fProposalPopup != null) fProposalPopup.hide(); if (fContextInfoPopup != null) fContextInfoPopup.hide(); manageAutoActivation(false); if (fCloser != null) { fCloser.uninstall(); fCloser= null; } fViewer= null; }
@Override public void uninstall() { if (fProposalPopup != null) fProposalPopup.hide(); if (fContextInfoPopup != null) fContextInfoPopup.hide(); manageAutoActivation(false); if (fCloser != null) { fCloser.uninstall(); fCloser= null; } fViewer= null; }
/** * Filters the displayed proposal based on the given cursor position and the * offset of the original invocation of the content assistant. * * @return <code>true</code> if there are still proposals left, <code>false</code> if the popup has been closed * @since 3.7 */ public boolean doFilterProposals() { fInvocationProcessedCounter= fInvocationCounter; int offset= fViewer.getSelectedRange().x; ICompletionProposal[] proposals= null; try { if (offset > -1) { DocumentEvent event= TextUtilities.mergeProcessedDocumentEvents(fDocumentEvents); proposals= computeFilteredProposals(offset, event); } } catch (BadLocationException x) { } finally { fDocumentEvents.clear(); } fFilterOffset= offset; if (proposals != null && proposals.length > 0) { setProposals(proposals); return true; } else { hide(); return false; } }
/** * Filters the displayed proposal based on the given cursor position and the * offset of the original invocation of the content assistant. * * @return <code>true</code> if there are still proposals left, <code>false</code> if the popup has been closed * @since 3.7 */ public boolean doFilterProposals() { fInvocationProcessedCounter= fInvocationCounter; int offset= fViewer.getSelectedRange().x; ICompletionProposal[] proposals= null; try { if (offset > -1) { DocumentEvent event= TextUtilities.mergeProcessedDocumentEvents(fDocumentEvents); proposals= computeFilteredProposals(offset, event); } } catch (BadLocationException x) { } finally { fDocumentEvents.clear(); } fFilterOffset= offset; if (proposals != null && proposals.length > 0) { setProposals(proposals); return true; } else { hide(); return false; } }
/** * Takes the selected proposal and applies it. * * @param stateMask the state mask * @return <code>true</code> iff a proposal has been inserted * @since 2.1 */ private boolean selectProposalWithMask(int stateMask) { if (fInvocationCounter != fInvocationProcessedCounter) if (!doFilterProposals()) return false; ICompletionProposal p= getSelectedProposal(); hide(); if (p != null) { insertProposal(p, (char) 0, stateMask, fViewer.getSelectedRange().x); return true; } return false; }
/** * Takes the selected proposal and applies it. * * @param stateMask the state mask * @return <code>true</code> iff a proposal has been inserted * @since 2.1 */ private boolean selectProposalWithMask(int stateMask) { if (fInvocationCounter != fInvocationProcessedCounter) if (!doFilterProposals()) return false; ICompletionProposal p= getSelectedProposal(); hide(); if (p != null) { insertProposal(p, (char) 0, stateMask, fViewer.getSelectedRange().x); return true; } return false; }