/** * Show wait completion result. Always called from AWT. */ private void performWait() { getPane().setTitle(NbBundle.getBundle(org.netbeans.editor.BaseKit.class).getString("ext.Completion.wait")); getView().setResult((CompletionQuery.Result)null); if (isPaneVisible()) { getJDCPopupPanel().refresh(); } else { getJDCPopupPanel().setCompletionVisible(true); } }
/** Set the visibility of the view. This method should * be used mainly for hiding the completion pane. If used * with visible set to true it calls the <tt>popup(false)</tt>. */ public void setPaneVisible(boolean visible) { trace("ENTRY setPaneVisible " + visible); // NOI18N if (visible) { if (extEditorUI.getComponent() != null) { popupImpl(false); } } else { if (pane != null) { cancelRequestImpl(); invalidateLastResult(); getJDCPopupPanel().setCompletionVisible(false); caretPos=-1; } } }
/** Set the visibility of the view. This method should * be used mainly for hiding the completion pane. If used * with visible set to true it calls the <tt>popup(false)</tt>. */ public void setPaneVisible(boolean visible) { trace("ENTRY setPaneVisible " + visible); // NOI18N if (visible) { if (extEditorUI.getComponent() != null) { popupImpl(false); } } else { if (pane != null) { cancelRequestImpl(); invalidateLastResult(); getJDCPopupPanel().setCompletionVisible(false); caretPos=-1; } } }
/** * Show result popup. Always called from AWT. */ protected void performResults() { // sample CompletionQuery.Result res = lastResult; if (res != null) { if (instantSubstitution && res.getData().size() == 1 && !isPaneVisible() && instantSubstitution(caretPos)) return; getPane().setTitle(res.getTitle()); getView().setResult(res); if (isPaneVisible()) { getJDCPopupPanel().refresh(); } else { getJDCPopupPanel().setCompletionVisible(true); } } else { getJDCPopupPanel().setCompletionVisible(false); if (!isKeyPressed()) { caretPos=-1; } else { setKeyPressed(false); } } }
/** * Show result popup. Always called from AWT. */ protected void performResults() { // sample CompletionQuery.Result res = lastResult; if (res != null) { if (instantSubstitution && res.getData().size() == 1 && !isPaneVisible() && instantSubstitutionImpl(caretPos)) return; getPane().setTitle(res.getTitle()); getView().setResult(res); if (isPaneVisible()) { getJDCPopupPanel().refresh(); } else { getJDCPopupPanel().setCompletionVisible(true); } } else { getJDCPopupPanel().setCompletionVisible(false); if (!isKeyPressed()) { caretPos=-1; } else { setKeyPressed(false); } } }
/** * Show wait completion result. Always called from AWT. */ private void performWait() { getPane().setTitle(LocaleSupport.getString("ext.Completion.wait")); getView().setResult((CompletionQuery.Result)null); if (isPaneVisible()) { getJDCPopupPanel().refresh(); } else { getJDCPopupPanel().setCompletionVisible(true); } }
if((caretPos!=-1) && (Utilities.getRowStart(component,component.getCaret().getDot()) != Utilities.getRowStart(component,caretPos)) && ((component.getCaret().getDot()-caretPos)>0) ){ getJDCPopupPanel().setCompletionVisible(false); caretPos=-1; return;
if((caretPos!=-1) && (Utilities.getRowStart(component,component.getCaret().getDot()) != Utilities.getRowStart(component,caretPos)) && ((component.getCaret().getDot()-caretPos)>0) ){ getJDCPopupPanel().setCompletionVisible(false); caretPos=-1; return;