mbien commented on code in PR #9303:
URL: https://github.com/apache/netbeans/pull/9303#discussion_r3018015000
##########
platform/core.startup/src/org/netbeans/core/startup/Splash.java:
##########
@@ -147,35 +155,59 @@ final int getProgress() {
/** Enables or disables splash component and its progress
* animation
*/
- public void setRunning(boolean running) {
- if (CLIOptions.isNoSplash()) {
+ public void setRunning(boolean show) {
+ if (CLIOptions.isNoSplash() || GraphicsEnvironment.isHeadless()) {
return;
}
- if (comp == null) {
- // ignore all manipulations
- return;
+ Runnable edtAction;
+ if (show) {
+ edtAction = () -> {
+ if (painter == null) {
+ try {
+ SplashScreen splashScreen =
SplashScreen.getSplashScreen();
+ if (splashScreen != null) {
+ painter = new
SplashPainter(splashScreen.createGraphics(), null, false);
Review Comment:
> That isn't, or at least shouldn't, be what is happening. If the JDK splash
window is there, we should be drawing in to it not opening a separate window.
I was wondering about that but I wasn't sure. I believe both approaches
would work (replace vs reuse). In any case this code didn't really change
anything there as far as i can tell. NB 29 behaves identical when i pass
`-J-splash:/home/mbien/splash_green.gif` to it
--
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