sdedic commented on code in PR #4249:
URL: https://github.com/apache/netbeans/pull/4249#discussion_r903070388


##########
platform/openide.text/src/org/openide/cookies/EditorCookie.java:
##########
@@ -144,6 +144,11 @@ interface Observable extends EditorCookie {
          */
         public static final String PROP_OPENED_PANES = "openedPanes";
 
+        /** This property is fired on the EDT when the reloading state of the
+         * document has changed; reloading is due to an external file change.
+         */
+        public static final String PROP_RELOADING = "reloading";

Review Comment:
   missing `@since`



##########
platform/openide.text/apichanges.xml:
##########
@@ -25,21 +25,41 @@
 <apidef name="text">Text API</apidef>
 </apidefs>
 <changes>
-      <change id="ask.on.document.reload">
-          <api name="text"/>
-          <summary>Rebrand defaults for Reload Editor Dialog</summary>
-          <version major="6" minor="80"/>
-          <date day="22" month="1" year="2021"/>
-          <author login="dbalek"/>
-          <compatibility addition="yes" binary="compatible" source="compatible"
-                         semantic="incompatible" deletion="no"
-                         modification="no"/>
-          <description>
-              A branding API to disable showing reload externally modified 
document dialog
-              - <a 
href="architecture-summary.html#group-branding">ASK_OnReload</a>.
-          </description>
-          <class package="org.openide.text" name="CloneableEditorSupport"/>
-      </change>
+    <change id="EditorCookie.Observalble.PROP_RELOADING">
+        <api name="text"/>
+        <summary>Added EditorCookie.Observalble.PROP_RELOADING and associated 
begin/end events</summary>
+        <version major="6" minor="86"/>
+        <date day="22" month="6" year="2022"/>
+        <author login="errael"/>
+        <compatibility addition="yes" binary="compatible" source="compatible"
+                       semantic="compatible" deletion="no"
+                       modification="no"/>
+        <description>
+                Added EditorCookie.Observalble.PROP_RELOADING and associated
+                begin/end events so that editor modules can handle external 
file change.
+                These events are fired on the EDT by the document's 
CloneableEditorSupport;
+                evt.getNewValue() is a Boolean, true signals the start of 
reload
+                and false the end.
+                One use adjust carets to keep the same line/column before and 
after
+                reload of an externally modified file.
+        </description>
+        <class package="org.openide.text" name="CloneableEditorSupport"/>

Review Comment:
   Also mention `EditorCookie`



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to