'Called whenever the documents state (on disk etc) has been changed
by the editor (eg, as the result of a save operation)'

def _DocumentStateChanged(self):

    if self.GetPathName():
        try:
            self.fileStat = os.stat(self.GetPathName())
        except os.error:
            self.fileStat = None
    else:
        self.fileStat = None
    self.watcherThread._DocumentStateChanged()
    self._UpdateUIForState()
    self._ApplyOptionalToViews('_UpdateUIForState')
    self._ApplyOptionalToViews('SetReadOnly', self._IsReadOnly())
    self._ApplyOptionalToViews('SCISetSavePoint')
    import pywin.debugger
    if (pywin.debugger.currentDebugger is not None):
        pywin.debugger.currentDebugger.UpdateDocumentLineStates(self)
