/** * Removes any listeners that were installed by the document. */ private void removeListeners() { listenToTextChanges(false); fHistory.removeOperationHistoryListener(fHistoryListener); fHistoryListener= null; }
/** * Removes any listeners that were installed by the document. */ private void removeListeners() { listenToTextChanges(false); fHistory.removeOperationHistoryListener(fHistoryListener); fHistoryListener= null; }
@Override public void disconnect() { if (fReferenceCount > 0) { fManagerCache.clear(); fReferenceCount--; } if (fReferenceCount == 0) { if (fOperationListener != null) OperationHistoryFactory.getOperationHistory().removeOperationHistoryListener(fOperationListener); if (fResourceListener != null) ResourcesPlugin.getWorkspace().removeResourceChangeListener(fResourceListener); fOperationListener= null; } }
@Override public void disconnect() { if (fReferenceCount > 0) { fManagerCache.clear(); fReferenceCount--; } if (fReferenceCount == 0) { if (fOperationListener != null) OperationHistoryFactory.getOperationHistory().removeOperationHistoryListener(fOperationListener); if (fResourceListener != null) ResourcesPlugin.getWorkspace().removeResourceChangeListener(fResourceListener); fOperationListener= null; } }
public void removeListener(IUndoManagerListener listener) { if (fListeners == null) return; fListeners.remove(listener); if (fListeners.size() == 0) { fOperationHistroy.removeOperationHistoryListener(fOperationHistoryListener); fListeners= null; fOperationHistoryListener= null; } }
@Override public void removeListener(IUndoManagerListener listener) { if (fListeners == null) return; fListeners.remove(listener); if (fListeners.size() == 0) { fOperationHistory.removeOperationHistoryListener(fOperationHistoryListener); fListeners= null; fOperationHistoryListener= null; } }
/** * {@inheritDoc} */ public void disconnect() { if (fReferenceCount > 0) { fUndoStack.fManagerCache.clear(); fReferenceCount--; } if (fReferenceCount == 0) { if (fOperationListener != null) OperationHistoryFactory.getOperationHistory().removeOperationHistoryListener(fOperationListener); if (fResourceListener != null) ResourcesPlugin.getWorkspace().removeResourceChangeListener(fResourceListener); fUndoStack= null; fRedoQueue= null; fOperationListener= null; } }
/** * Shutdown the workspace undo monitor. Unhooks the listeners. */ public void shutdown() { if (Policy.DEBUG_UNDOMONITOR) { System.out.println(DEBUG_PREFIX + "Shutting Down"); //$NON-NLS-1$ } if (resourceListener != null) { ResourcesPlugin.getWorkspace().removeResourceChangeListener( resourceListener); } if (historyListener != null) { getOperationHistory().removeOperationHistoryListener( historyListener); } }
@Override public void removeListener(IUndoManagerListener listener) { if (fListeners == null) return; fListeners.remove(listener); if (fListeners.size() == 0) { fOperationHistory.removeOperationHistoryListener(fOperationHistoryListener); fListeners= null; fOperationHistoryListener= null; } }
protected void uninstallUndoRedoSupport(OperationHistoryListener listener) { IOperationHistory operationHistory = PlatformUI.getWorkbench().getOperationSupport().getOperationHistory(); operationHistory.removeOperationHistoryListener(listener); }
private void deactivateHandlers() { if (quickAssistHandlerActivation != null) { handlerService.deactivateHandler(quickAssistHandlerActivation); quickAssistHandlerActivation = null; } if (contentAssistHandlerActivation != null) { handlerService.deactivateHandler(contentAssistHandlerActivation); contentAssistHandlerActivation = null; } undoRedoListener.setViewer(null); OperationHistoryFactory.getOperationHistory().removeOperationHistoryListener(undoRedoListener); }
@Override public void dispose() { IOperationHistory history = getHistory(); if (history != null) { history.removeOperationHistoryListener(historyListener); } if (isInvalid()) { return; } site.getPage().removePartListener(partListener); site = null; progressDialog = null; // We do not flush the history for our undo context because it may be // used elsewhere. It is up to clients to clean up the history // appropriately. // We do null out the context to signify that this handler is no longer // accessing the history. undoContext = null; }
protected void handleDispose() { removeTextListener(this); removeSelectionChangedListener(this); EditorsUI.getPreferenceStore().removePropertyChangeListener(fPreferenceChangeListener); IOperationHistory history = getHistory(); if (history != null) history.removeOperationHistoryListener(this); super.handleDispose(); }
/** * Unregister all previously installed listeners from the text viewer. */ private void removeListeners() { StyledText text= fTextViewer.getTextWidget(); if (text != null) { if (fKeyAndMouseListener != null) { text.removeMouseListener(fKeyAndMouseListener); text.removeKeyListener(fKeyAndMouseListener); fKeyAndMouseListener= null; } if (fTextInputListener != null) { fTextViewer.removeTextInputListener(fTextInputListener); fTextInputListener= null; } listenToTextChanges(false); fHistory.removeOperationHistoryListener(fHistoryListener); } }
/** * Unregister all previously installed listeners from the text viewer. */ private void removeListeners() { StyledText text= fTextViewer.getTextWidget(); if (text != null) { if (fKeyAndMouseListener != null) { text.removeMouseListener(fKeyAndMouseListener); text.removeKeyListener(fKeyAndMouseListener); fKeyAndMouseListener= null; } if (fTextInputListener != null) { fTextViewer.removeTextInputListener(fTextInputListener); fTextInputListener= null; } listenToTextChanges(false); fHistory.removeOperationHistoryListener(fHistoryListener); } }
/** * The viewer is no longer part of the UI, it's a wrapper only. The disposal * doesn't take place while releasing the editor pane's children. The method * have to be called it manually. The wrapped viewer is disposed as a * regular viewer, while disposing the UI. */ public void dispose() { getSourceViewer().removeTextListener(this); getSourceViewer().removeSelectionChangedListener(this); EditorsUI.getPreferenceStore().removePropertyChangeListener(fPreferenceChangeListener); IOperationHistory history = getHistory(); if (history != null) history.removeOperationHistoryListener(this); }
OperationHistoryFactory.getOperationHistory().removeOperationHistoryListener(operationHistoryListener);