Is there an API to check if a file opened in the editor was updated in terms of its content
Answered
I need an API to check if a file opened in the editor was changed (since it gets opened) in terms of its content
no matter whether it was saved or not. For example I open file with text a:
If I then type ab it must return true (= updated)
Or if I then type ab + ctrl+z it must return false (even if IDEA has already saved the file).
There is a getModificationStamp() in the VirtualFile, but it is updated only on save as well as Editor.isModified() call.
Is there a simple quick API to achieve that?
Is there a simple quick API to achieve that?
Please sign in to leave a comment.
See com.intellij.openapi.fileEditor.FileDocumentManager#isFileModified
Unfortunately it works the same way as the mentioned APIs.