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


##########
ide/projectui/src/org/netbeans/modules/project/ui/groups/OpenFolderAsGroupAction.java:
##########
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.netbeans.modules.project.ui.groups;
+
+import java.awt.HeadlessException;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.io.File;
+import javax.swing.JFileChooser;
+import org.netbeans.spi.project.ui.support.ProjectChooser;
+import org.openide.awt.ActionID;
+import org.openide.awt.ActionReference;
+import org.openide.awt.ActionRegistration;
+import org.openide.filesystems.FileObject;
+import org.openide.filesystems.FileUtil;
+import org.openide.util.NbBundle.Messages;
+
+@ActionID(
+        category = "Project",
+        id = "org.netbeans.modules.project.ui.groups.OpenFolderAsGroupAction"
+)
+@ActionRegistration(
+        displayName = "#CTL_OpenFolderAsGroupAction",
+        lazy = true, asynchronous = true
+)
+@ActionReference(path = "Menu/File", position = 1200, separatorAfter = 1250)
+@Messages("CTL_OpenFolderAsGroupAction=Open Fol&der as Workspace...")
+public final class OpenFolderAsGroupAction implements ActionListener {
+    @Override
+    public void actionPerformed(ActionEvent ev) {
+        File dir = showWorkspaceFolderChooser(null, null);

Review Comment:
   This new _Open Folder as Workspace..._ action provides the [same function as 
is currently 
hidden](https://github.com/apache/netbeans/pull/9631/changes#r4062966049) in 
the _Projects Group..._ dialog, but it is way **more straightforward**:
   
   <img width="223" height="376" alt="Open Folder (as Workspace)..." 
src="https://github.com/user-attachments/assets/44d1f323-5aae-4845-89a7-29f352bc9bee";
 />
   
   Just choose the new action, then select a folder in the file chooser and 
voilá! No change in NetBeans abilities, ... but now they are exposed to the 
world the way the (current development) world [wants to see 
them](https://cwiki.apache.org/confluence/download/attachments/446071397/image-2026-8-18_8-39-37.png?version=1&modificationDate=1787035178000&api=v2)
   
   
    



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