/** Is called under getLock () to close the document. */ private boolean doCloseDocument() { boolean fireEvent = false; // notifies the support that cesEnv().removePropertyChangeListener(getListener()); try { LOCAL_CLOSE_DOCUMENT.set(Boolean.TRUE); callNotifyUnmodified(); } finally { LOCAL_CLOSE_DOCUMENT.set(Boolean.FALSE); } StyledDocument d = getDoc(); if (d != null) { d.removeUndoableEditListener(getUndoRedo()); addRemoveDocListener(d, false); } if (positionManager != null) { positionManager.documentClosed(); } documentStatus = DOCUMENT_NO; fireEvent = true; setDoc(null, false); kit = null; getUndoRedo().discardAllEdits(); updateLineSet(true); return fireEvent; }
getPositionManager().documentClosed(); updateLineSet(true); fireDocumentChange(doc, true);
getPositionManager().documentClosed(); updateLineSet(true); fireDocumentChange(doc, true);
/** Is called under getLock () to close the document. */ private void doCloseDocument () { prepareTask = null; // notifies the support that env ().removePropertyChangeListener(getListener()); notifyUnmodified (); if (doc != null) { doc.removeUndoableEditListener (getUndoRedo ()); doc.removeDocumentListener(getListener()); } if (positionManager != null) { positionManager.documentClosed (); documentStatus = DOCUMENT_NO; fireDocumentChange(doc, true); } documentStatus = DOCUMENT_NO; doc = null; kit = null; getUndoRedo().discardAllEdits(); updateLineSet (true); }
/** Is called under getLock () to close the document. */ private void doCloseDocument () { prepareTask = null; // notifies the support that env ().removePropertyChangeListener(getListener()); notifyUnmodified (); if (doc != null) { doc.removeUndoableEditListener (getUndoRedo ()); doc.removeDocumentListener(getListener()); } if (positionManager != null) { positionManager.documentClosed (); documentStatus = DOCUMENT_NO; fireDocumentChange(doc, true); } documentStatus = DOCUMENT_NO; doc = null; kit = null; getUndoRedo().discardAllEdits(); updateLineSet (true); }