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


##########
platform/openide.awt/src/org/openide/awt/ContextAction.java:
##########
@@ -366,36 +363,10 @@ private Object delegate0(Lookup.Provider everything, 
List<?> data, boolean getAc
                 }
                 instDelegate = new WeakReference<>(d);
             } else {
-                instDelegate = NONE;
+                instDelegate = null;

Review Comment:
   good catch ... all the code actually tests for null



##########
platform/openide.awt/src/org/openide/awt/ContextAction.java:
##########
@@ -173,27 +176,27 @@ public synchronized void 
removePropertyChangeListener(PropertyChangeListener lis
             }
         }
     }
-    
+
     protected void startListeners() {
-        performer.startListeners();

Review Comment:
   Question: why not start/stop listening on action own Performer (Enabler) ?



##########
platform/openide.awt/src/org/openide/awt/ContextAction.java:
##########
@@ -366,36 +363,10 @@ private Object delegate0(Lookup.Provider everything, 
List<?> data, boolean getAc
                 }
                 instDelegate = new WeakReference<>(d);
             } else {
-                instDelegate = NONE;
+                instDelegate = null;
             }
             return d;
         }
-        
-        void stopListeners() {

Review Comment:
   I am not sure that this does not break action enablement.



-- 
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