You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2018/06/12 08:01:35 UTC

[GitHub] sdedic closed pull request #586: NETBEANS-951: terminate application in headless mode

sdedic closed pull request #586: NETBEANS-951: terminate application in headless mode
URL: https://github.com/apache/incubator-netbeans/pull/586
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/o.n.core/src/org/netbeans/core/GuiRunLevel.java b/o.n.core/src/org/netbeans/core/GuiRunLevel.java
index f46f02898..c072a906c 100644
--- a/o.n.core/src/org/netbeans/core/GuiRunLevel.java
+++ b/o.n.core/src/org/netbeans/core/GuiRunLevel.java
@@ -36,6 +36,7 @@
 import org.openide.util.Exceptions;
 import org.openide.util.Lookup;
 import org.openide.util.NbBundle;
+import org.openide.util.RequestProcessor;
 import org.openide.util.lookup.ServiceProvider;
 import org.openide.windows.WindowManager;
 
@@ -67,12 +68,19 @@ public GuiRunLevel() {
         Splash.getInstance().increment(10);
 
         if (CLIOptions.isGui()) {
-        //---------------------------------------------------------------------------------------------------------
-        // initialize main window AFTER the setup wizard is finished
-
-        initializeMainWindow ();
-        StartLog.logProgress ("Main window initialized"); // NOI18N
-        Splash.getInstance().increment(1);
+            //---------------------------------------------------------------------------------------------------------
+            // initialize main window AFTER the setup wizard is finished
+
+            initializeMainWindow ();
+            StartLog.logProgress ("Main window initialized"); // NOI18N
+            Splash.getInstance().increment(1);
+        } else {
+            RequestProcessor.getDefault().post(new Runnable() {
+                @Override
+                public void run() {
+                    maybeDie(null);
+                }
+            });
         }
 
         // -----------------------------------------------------------------------------------------------------


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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