jtulach commented on code in PR #9670:
URL: https://github.com/apache/netbeans/pull/9670#discussion_r4204556069


##########
ide/projectui/src/org/netbeans/modules/project/ui/groups/Group.java:
##########
@@ -184,7 +184,7 @@ public static void setActiveGroup(Group nue, boolean 
isNewGroup) {
             }
         } else {
             OpenProjectListSettings settings = 
OpenProjectListSettings.getInstance();
-            settings.setOpenProjectsURLsAsStrings(nue != null ? 
nue.projectPaths() : getProjectPathsByPreferences(noneGroupPref));
+            settings.setOpenProjectsURLsAsStrings(nue != null ? 
nue.projectPaths() : Collections.emptyList());

Review Comment:
   Here is the new approach:
   - let `--close-group` not only close the group (if any)
   - but also empty the list of projects
   - if I got it right, that's exactly what @neilcsmith-net [hinted 
here](https://github.com/apache/netbeans/pull/9670#issuecomment-6013735356):
   
   > The `--close-group` option does cover some of your scenario. That might be 
better **enforcing an empty group** anyway?
   > @mbien wrote and [Neil 
replied](https://github.com/apache/netbeans/pull/9670#issuecomment-6024181565):
   > > i use --close-group often. It starts in group none which should be empty 
by default.
   > Mine is rarely empty. As said above, I wonder whether the default for that 
option, and for switching to none in the UI, would be better as a clean slate.
   
   - Exactly! Clean state is better.
   - when @jglick introduced the project groups:
      - Jesse (probably) wanted to keep compatibility with the prior state
      - e.g. when one opts for groups and the opts out by closing them...
      - one gets to a previous state just like _groups support wouldn't exists_
   - that made some sense but it shows its limits these days - let's change 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

Reply via email to