How to detect import completion in DocumentEvent?
已回答
I'm using a caret, document and selection listener to track changes to a document. While the document is being edited, things are fine. However, when import completion triggers, the caret jumps to the beginning of the file, the system inserts the using statement, the caret jumps back. The user doesn't see it, of course, but events for these changes are generated.
How can I detect that import completion is taking place when receiving a caret/document/selection event? Basically I want to filter (= avoid recording) them.
请先登录再写评论。
You could try and determine context/parent PSI structure and determine whether it is in irrelevant place for your needs.