mbien commented on code in PR #9677:
URL: https://github.com/apache/netbeans/pull/9677#discussion_r4213090676


##########
platform/core.startup/src/org/netbeans/core/startup/Splash.java:
##########
@@ -546,21 +551,17 @@ public SplashPainter(Progress model, Graphics graphics, 
JComponent comp, boolean
             }
         }
 
-        long next;
         final void repaint(Rectangle r) {
             if (comp != null) {
                 comp.repaint(r);
             } else {
-                if (next < System.currentTimeMillis()) {
-                    paint();
-                    try {
-                        SplashScreen ss = SplashScreen.getSplashScreen();
-                        if (ss != null) {
-                            ss.update();
-                        }
-                    } catch (IllegalStateException splashAlreadyClosed) {}
-                    next = System.currentTimeMillis() + 200;
-                }
+                paint();

Review Comment:
   the original logic (which was left in tact when splash was moved to the EDT 
in https://github.com/apache/netbeans/pull/9303) is still in place.
   
   `setRunning()` checks if `getSplashScreen()` returns something, if it does 
it initializes a different painter while leaving comp null. So this branch is 
still theoretically reachable when the splash launcher flag is used. It still 
exists in the windows launcher AFAIR. I remember testing this with two splash 
pngs, one was green one was blue - probably a comment somewhere on the original 
PR.
   
   Also: i think `setRunning(false)` should also set comp to null but I 
probably didn't do that since the getter is public - this could cause an NPE 
somewhere.



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