Show inline property sheet for convenience.
1.1 --- a/modulemanager/manifest.mf Tue Oct 11 11:03:32 2011 -0400
1.2 +++ b/modulemanager/manifest.mf Tue Oct 11 11:25:35 2011 -0400
1.3 @@ -2,4 +2,4 @@
1.4 OpenIDE-Module: org.netbeans.modules.modulemanager/1
1.5 OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/modulemanager/Bundle.properties
1.6 OpenIDE-Module-Layer: org/netbeans/modules/modulemanager/resources/mf-layer.xml
1.7 -OpenIDE-Module-Specification-Version: 0.9
1.8 +OpenIDE-Module-Specification-Version: 1.0
2.1 --- a/modulemanager/src/org/netbeans/modules/modulemanager/ModuleNode.java Tue Oct 11 11:03:32 2011 -0400
2.2 +++ b/modulemanager/src/org/netbeans/modules/modulemanager/ModuleNode.java Tue Oct 11 11:25:35 2011 -0400
2.3 @@ -64,7 +64,6 @@
2.4 import javax.swing.Action;
2.5 import org.openide.DialogDisplayer;
2.6 import org.openide.NotifyDescriptor;
2.7 -import org.openide.actions.PropertiesAction;
2.8 import org.openide.nodes.AbstractNode;
2.9 import org.openide.nodes.Children;
2.10 import org.openide.nodes.Node;
2.11 @@ -189,17 +188,10 @@
2.12 SystemAction.get(ModuleNodeActions.UninstallAction.class),
2.13 null,
2.14 SystemAction.get(ModuleNodeActions.SortAction.class),
2.15 - null,
2.16 - SystemAction.get(PropertiesAction.class),
2.17 };
2.18 }
2.19
2.20 @Override
2.21 - public Action getPreferredAction() {
2.22 - return SystemAction.get(PropertiesAction.class);
2.23 - }
2.24 -
2.25 - @Override
2.26 public void destroy() {
2.27 if (ModuleNodeUtils.confirmUninstall(new Node [] { this })) {
2.28 uninstall();
2.29 @@ -661,8 +653,6 @@
2.30 SystemAction.get(ModuleNodeActions.UninstallAction.class),
2.31 null,
2.32 SystemAction.get(ModuleNodeActions.SortAction.class),
2.33 - null,
2.34 - SystemAction.get(PropertiesAction.class),
2.35 };
2.36 }
2.37
3.1 --- a/modulemanager/src/org/netbeans/modules/modulemanager/ModuleSelectionPanel.form Tue Oct 11 11:03:32 2011 -0400
3.2 +++ b/modulemanager/src/org/netbeans/modules/modulemanager/ModuleSelectionPanel.form Tue Oct 11 11:25:35 2011 -0400
3.3 @@ -12,13 +12,57 @@
3.4 <AuxValue name="FormSettings_generateFQN" type="java.lang.Boolean" value="true"/>
3.5 <AuxValue name="FormSettings_generateMnemonicsCode" type="java.lang.Boolean" value="true"/>
3.6 <AuxValue name="FormSettings_i18nAutoMode" type="java.lang.Boolean" value="false"/>
3.7 + <AuxValue name="FormSettings_layoutCodeTarget" type="java.lang.Integer" value="1"/>
3.8 <AuxValue name="FormSettings_listenerGenerationStyle" type="java.lang.Integer" value="0"/>
3.9 <AuxValue name="FormSettings_variablesLocal" type="java.lang.Boolean" value="false"/>
3.10 <AuxValue name="FormSettings_variablesModifier" type="java.lang.Integer" value="2"/>
3.11 - <AuxValue name="designerSize" type="java.awt.Dimension" value="-84,-19,0,5,115,114,0,18,106,97,118,97,46,97,119,116,46,68,105,109,101,110,115,105,111,110,65,-114,-39,-41,-84,95,68,20,2,0,2,73,0,6,104,101,105,103,104,116,73,0,5,119,105,100,116,104,120,112,0,0,2,20,0,0,2,42"/>
3.12 </AuxValues>
3.13
3.14 - <Layout class="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout"/>
3.15 + <Layout>
3.16 + <DimensionLayout dim="0">
3.17 + <Group type="103" groupAlignment="0" attributes="0">
3.18 + <Group type="102" alignment="0" attributes="0">
3.19 + <EmptySpace min="-2" max="-2" attributes="0"/>
3.20 + <Group type="103" groupAlignment="0" attributes="0">
3.21 + <Component id="descriptionPane" pref="818" max="32767" attributes="0"/>
3.22 + <Group type="102" attributes="0">
3.23 + <Group type="103" groupAlignment="0" attributes="0">
3.24 + <Component id="modulesLabel" alignment="0" min="-2" max="-2" attributes="0"/>
3.25 + <Component id="descriptionLabel" alignment="0" min="-2" max="-2" attributes="0"/>
3.26 + <Component id="uninstallButton" alignment="0" min="-2" pref="107" max="-2" attributes="0"/>
3.27 + </Group>
3.28 + <EmptySpace min="0" pref="0" max="32767" attributes="0"/>
3.29 + </Group>
3.30 + <Group type="102" attributes="0">
3.31 + <Component id="modulesPane" max="32767" attributes="0"/>
3.32 + <EmptySpace min="-2" pref="18" max="-2" attributes="0"/>
3.33 + <Component id="propertyPane" max="32767" attributes="0"/>
3.34 + </Group>
3.35 + </Group>
3.36 + <EmptySpace min="-2" max="-2" attributes="0"/>
3.37 + </Group>
3.38 + </Group>
3.39 + </DimensionLayout>
3.40 + <DimensionLayout dim="1">
3.41 + <Group type="103" groupAlignment="0" attributes="0">
3.42 + <Group type="102" attributes="0">
3.43 + <EmptySpace min="-2" max="-2" attributes="0"/>
3.44 + <Component id="modulesLabel" min="-2" max="-2" attributes="0"/>
3.45 + <EmptySpace min="-2" max="-2" attributes="0"/>
3.46 + <Group type="103" groupAlignment="0" attributes="0">
3.47 + <Component id="modulesPane" pref="386" max="32767" attributes="0"/>
3.48 + <Component id="propertyPane" max="32767" attributes="0"/>
3.49 + </Group>
3.50 + <EmptySpace type="separate" max="-2" attributes="0"/>
3.51 + <Component id="descriptionLabel" min="-2" max="-2" attributes="0"/>
3.52 + <EmptySpace max="-2" attributes="0"/>
3.53 + <Component id="descriptionPane" min="-2" pref="94" max="-2" attributes="0"/>
3.54 + <EmptySpace max="-2" attributes="0"/>
3.55 + <Component id="uninstallButton" min="-2" max="-2" attributes="0"/>
3.56 + </Group>
3.57 + </Group>
3.58 + </DimensionLayout>
3.59 + </Layout>
3.60 <SubComponents>
3.61 <Component class="javax.swing.JLabel" name="modulesLabel">
3.62 <Properties>
3.63 @@ -29,11 +73,6 @@
3.64 <ResourceString bundle="org/netbeans/modules/modulemanager/Bundle.properties" key="ModuleSelectionPanel_ModuleLabel_text" replaceFormat="org.openide.util.NbBundle.getBundle({sourceFileName}.class).getString("{key}")"/>
3.65 </Property>
3.66 </Properties>
3.67 - <Constraints>
3.68 - <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription">
3.69 - <GridBagConstraints gridX="0" gridY="0" gridWidth="0" gridHeight="1" fill="0" ipadX="0" ipadY="0" insetsTop="7" insetsLeft="11" insetsBottom="0" insetsRight="0" anchor="16" weightX="0.0" weightY="0.0"/>
3.70 - </Constraint>
3.71 - </Constraints>
3.72 </Component>
3.73 <Component class="javax.swing.JButton" name="uninstallButton">
3.74 <Properties>
3.75 @@ -44,11 +83,6 @@
3.76 <Events>
3.77 <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="uninstallButtonActionPerformed"/>
3.78 </Events>
3.79 - <Constraints>
3.80 - <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription">
3.81 - <GridBagConstraints gridX="1" gridY="1" gridWidth="0" gridHeight="0" fill="2" ipadX="0" ipadY="0" insetsTop="2" insetsLeft="8" insetsBottom="0" insetsRight="12" anchor="11" weightX="0.15" weightY="1.0"/>
3.82 - </Constraint>
3.83 - </Constraints>
3.84 </Component>
3.85 <Component class="javax.swing.JLabel" name="descriptionLabel">
3.86 <Properties>
3.87 @@ -59,11 +93,6 @@
3.88 <ResourceString bundle="org/netbeans/modules/modulemanager/Bundle.properties" key="LBL_ModuleSelectionPanel_descriptionLabel" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
3.89 </Property>
3.90 </Properties>
3.91 - <Constraints>
3.92 - <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription">
3.93 - <GridBagConstraints gridX="0" gridY="2" gridWidth="0" gridHeight="1" fill="0" ipadX="0" ipadY="0" insetsTop="8" insetsLeft="11" insetsBottom="0" insetsRight="0" anchor="16" weightX="0.0" weightY="0.0"/>
3.94 - </Constraint>
3.95 - </Constraints>
3.96 </Component>
3.97 <Container class="javax.swing.JScrollPane" name="descriptionPane">
3.98 <Properties>
3.99 @@ -74,11 +103,6 @@
3.100 <Dimension value="[400, 70]"/>
3.101 </Property>
3.102 </Properties>
3.103 - <Constraints>
3.104 - <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription">
3.105 - <GridBagConstraints gridX="0" gridY="3" gridWidth="1" gridHeight="0" fill="2" ipadX="0" ipadY="0" insetsTop="2" insetsLeft="11" insetsBottom="0" insetsRight="0" anchor="11" weightX="0.85" weightY="0.2"/>
3.106 - </Constraint>
3.107 - </Constraints>
3.108
3.109 <Layout class="org.netbeans.modules.form.compat2.layouts.support.JScrollPaneSupportLayout"/>
3.110 <SubComponents>
3.111 @@ -90,11 +114,20 @@
3.112 </SubComponents>
3.113 </Container>
3.114 <Container class="javax.swing.JPanel" name="modulesPane">
3.115 - <Constraints>
3.116 - <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription">
3.117 - <GridBagConstraints gridX="0" gridY="1" gridWidth="1" gridHeight="1" fill="1" ipadX="0" ipadY="0" insetsTop="2" insetsLeft="11" insetsBottom="0" insetsRight="0" anchor="10" weightX="0.85" weightY="0.8"/>
3.118 - </Constraint>
3.119 - </Constraints>
3.120 + <Properties>
3.121 + <Property name="background" type="java.awt.Color" editor="org.netbeans.beaninfo.editors.ColorEditor">
3.122 + <Color blue="cc" green="ff" red="ff" type="rgb"/>
3.123 + </Property>
3.124 + </Properties>
3.125 +
3.126 + <Layout class="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout"/>
3.127 + </Container>
3.128 + <Container class="javax.swing.JPanel" name="propertyPane">
3.129 + <Properties>
3.130 + <Property name="background" type="java.awt.Color" editor="org.netbeans.beaninfo.editors.ColorEditor">
3.131 + <Color blue="99" green="ff" red="99" type="rgb"/>
3.132 + </Property>
3.133 + </Properties>
3.134
3.135 <Layout class="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout"/>
3.136 </Container>
4.1 --- a/modulemanager/src/org/netbeans/modules/modulemanager/ModuleSelectionPanel.java Tue Oct 11 11:03:32 2011 -0400
4.2 +++ b/modulemanager/src/org/netbeans/modules/modulemanager/ModuleSelectionPanel.java Tue Oct 11 11:25:35 2011 -0400
4.3 @@ -71,6 +71,7 @@
4.4 import org.openide.awt.StatusDisplayer;
4.5 import org.openide.explorer.ExplorerManager;
4.6 import org.openide.explorer.ExplorerUtils;
4.7 +import org.openide.explorer.propertysheet.PropertySheetView;
4.8 import org.openide.explorer.view.TreeTableView;
4.9 import org.openide.nodes.Node;
4.10 import org.openide.nodes.PropertySupport;
4.11 @@ -124,6 +125,9 @@
4.12 getAccessibleContext().setAccessibleDescription(
4.13 NbBundle.getBundle (ModuleSelectionPanel.class).getString ("ACD_ModuleSelectionPanel_ExplorerPanel")); // NOI18N
4.14 modulesPane.add(treeTableView);
4.15 + PropertySheetView propSheet = new PropertySheetView();
4.16 + propSheet.setDescriptionAreaVisible(false);
4.17 + propertyPane.add(propSheet);
4.18
4.19 //Fix for NPE on WinXP L&F - either may be null - Tim
4.20 Font f = UIManager.getFont("controlFont"); // NOI18N
4.21 @@ -338,8 +342,8 @@
4.22 * WARNING: Do NOT modify this code. The content of this method is
4.23 * always regenerated by the Form Editor.
4.24 */
4.25 - private void initComponents() {//GEN-BEGIN:initComponents
4.26 - java.awt.GridBagConstraints gridBagConstraints;
4.27 + // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
4.28 + private void initComponents() {
4.29
4.30 modulesLabel = new javax.swing.JLabel();
4.31 uninstallButton = new javax.swing.JButton();
4.32 @@ -347,77 +351,72 @@
4.33 descriptionPane = new javax.swing.JScrollPane();
4.34 description = new javax.swing.JEditorPane();
4.35 modulesPane = new javax.swing.JPanel();
4.36 + propertyPane = new javax.swing.JPanel();
4.37
4.38 - setLayout(new java.awt.GridBagLayout());
4.39 + setName(NbBundle.getMessage(ModuleSelectionPanel.class, "LBL_ModuleSelectionPanel_Name")); // NOI18N
4.40
4.41 - setName(NbBundle.getMessage(ModuleSelectionPanel.class, "LBL_ModuleSelectionPanel_Name"));
4.42 modulesLabel.setLabelFor(modulesPane);
4.43 - org.openide.awt.Mnemonics.setLocalizedText(modulesLabel, org.openide.util.NbBundle.getBundle(ModuleSelectionPanel.class).getString("ModuleSelectionPanel_ModuleLabel_text"));
4.44 - gridBagConstraints = new java.awt.GridBagConstraints();
4.45 - gridBagConstraints.gridx = 0;
4.46 - gridBagConstraints.gridy = 0;
4.47 - gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
4.48 - gridBagConstraints.anchor = java.awt.GridBagConstraints.SOUTHWEST;
4.49 - gridBagConstraints.insets = new java.awt.Insets(7, 11, 0, 0);
4.50 - add(modulesLabel, gridBagConstraints);
4.51 + org.openide.awt.Mnemonics.setLocalizedText(modulesLabel, org.openide.util.NbBundle.getBundle(ModuleSelectionPanel.class).getString("ModuleSelectionPanel_ModuleLabel_text")); // NOI18N
4.52
4.53 - org.openide.awt.Mnemonics.setLocalizedText(uninstallButton, org.openide.util.NbBundle.getMessage(ModuleSelectionPanel.class, "BTN_ModuleSelectionPanel_Uninstall"));
4.54 + org.openide.awt.Mnemonics.setLocalizedText(uninstallButton, org.openide.util.NbBundle.getMessage(ModuleSelectionPanel.class, "BTN_ModuleSelectionPanel_Uninstall")); // NOI18N
4.55 uninstallButton.addActionListener(new java.awt.event.ActionListener() {
4.56 public void actionPerformed(java.awt.event.ActionEvent evt) {
4.57 uninstallButtonActionPerformed(evt);
4.58 }
4.59 });
4.60
4.61 - gridBagConstraints = new java.awt.GridBagConstraints();
4.62 - gridBagConstraints.gridx = 1;
4.63 - gridBagConstraints.gridy = 1;
4.64 - gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
4.65 - gridBagConstraints.gridheight = java.awt.GridBagConstraints.REMAINDER;
4.66 - gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
4.67 - gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTH;
4.68 - gridBagConstraints.weightx = 0.15;
4.69 - gridBagConstraints.weighty = 1.0;
4.70 - gridBagConstraints.insets = new java.awt.Insets(2, 8, 0, 12);
4.71 - add(uninstallButton, gridBagConstraints);
4.72 -
4.73 descriptionLabel.setLabelFor(descriptionPane);
4.74 - org.openide.awt.Mnemonics.setLocalizedText(descriptionLabel, org.openide.util.NbBundle.getMessage(ModuleSelectionPanel.class, "LBL_ModuleSelectionPanel_descriptionLabel"));
4.75 - gridBagConstraints = new java.awt.GridBagConstraints();
4.76 - gridBagConstraints.gridx = 0;
4.77 - gridBagConstraints.gridy = 2;
4.78 - gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
4.79 - gridBagConstraints.anchor = java.awt.GridBagConstraints.SOUTHWEST;
4.80 - gridBagConstraints.insets = new java.awt.Insets(8, 11, 0, 0);
4.81 - add(descriptionLabel, gridBagConstraints);
4.82 + org.openide.awt.Mnemonics.setLocalizedText(descriptionLabel, org.openide.util.NbBundle.getMessage(ModuleSelectionPanel.class, "LBL_ModuleSelectionPanel_descriptionLabel")); // NOI18N
4.83
4.84 descriptionPane.setMinimumSize(new java.awt.Dimension(400, 70));
4.85 descriptionPane.setPreferredSize(new java.awt.Dimension(400, 70));
4.86 +
4.87 description.setEditable(false);
4.88 descriptionPane.setViewportView(description);
4.89
4.90 - gridBagConstraints = new java.awt.GridBagConstraints();
4.91 - gridBagConstraints.gridx = 0;
4.92 - gridBagConstraints.gridy = 3;
4.93 - gridBagConstraints.gridheight = java.awt.GridBagConstraints.REMAINDER;
4.94 - gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
4.95 - gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTH;
4.96 - gridBagConstraints.weightx = 0.85;
4.97 - gridBagConstraints.weighty = 0.2;
4.98 - gridBagConstraints.insets = new java.awt.Insets(2, 11, 0, 0);
4.99 - add(descriptionPane, gridBagConstraints);
4.100 -
4.101 + modulesPane.setBackground(new java.awt.Color(255, 255, 204));
4.102 modulesPane.setLayout(new java.awt.BorderLayout());
4.103
4.104 - gridBagConstraints = new java.awt.GridBagConstraints();
4.105 - gridBagConstraints.gridx = 0;
4.106 - gridBagConstraints.gridy = 1;
4.107 - gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
4.108 - gridBagConstraints.weightx = 0.85;
4.109 - gridBagConstraints.weighty = 0.8;
4.110 - gridBagConstraints.insets = new java.awt.Insets(2, 11, 0, 0);
4.111 - add(modulesPane, gridBagConstraints);
4.112 + propertyPane.setBackground(new java.awt.Color(153, 255, 153));
4.113 + propertyPane.setLayout(new java.awt.BorderLayout());
4.114
4.115 - }//GEN-END:initComponents
4.116 + javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
4.117 + this.setLayout(layout);
4.118 + layout.setHorizontalGroup(
4.119 + layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
4.120 + .addGroup(layout.createSequentialGroup()
4.121 + .addContainerGap()
4.122 + .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
4.123 + .addComponent(descriptionPane, javax.swing.GroupLayout.DEFAULT_SIZE, 818, Short.MAX_VALUE)
4.124 + .addGroup(layout.createSequentialGroup()
4.125 + .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
4.126 + .addComponent(modulesLabel)
4.127 + .addComponent(descriptionLabel)
4.128 + .addComponent(uninstallButton, javax.swing.GroupLayout.PREFERRED_SIZE, 107, javax.swing.GroupLayout.PREFERRED_SIZE))
4.129 + .addGap(0, 0, Short.MAX_VALUE))
4.130 + .addGroup(layout.createSequentialGroup()
4.131 + .addComponent(modulesPane, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
4.132 + .addGap(18, 18, 18)
4.133 + .addComponent(propertyPane, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
4.134 + .addContainerGap())
4.135 + );
4.136 + layout.setVerticalGroup(
4.137 + layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
4.138 + .addGroup(layout.createSequentialGroup()
4.139 + .addContainerGap()
4.140 + .addComponent(modulesLabel)
4.141 + .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
4.142 + .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
4.143 + .addComponent(modulesPane, javax.swing.GroupLayout.DEFAULT_SIZE, 386, Short.MAX_VALUE)
4.144 + .addComponent(propertyPane, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
4.145 + .addGap(18, 18, 18)
4.146 + .addComponent(descriptionLabel)
4.147 + .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
4.148 + .addComponent(descriptionPane, javax.swing.GroupLayout.PREFERRED_SIZE, 94, javax.swing.GroupLayout.PREFERRED_SIZE)
4.149 + .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
4.150 + .addComponent(uninstallButton))
4.151 + );
4.152 + }// </editor-fold>//GEN-END:initComponents
4.153
4.154 private void uninstallButtonActionPerformed (java.awt.event.ActionEvent evt) {//GEN-FIRST:event_uninstallButtonActionPerformed
4.155 ModuleNodeUtils.doUninstall (manager.getSelectedNodes ());
4.156 @@ -433,6 +432,7 @@
4.157 private javax.swing.JScrollPane descriptionPane;
4.158 private javax.swing.JLabel modulesLabel;
4.159 private javax.swing.JPanel modulesPane;
4.160 + private javax.swing.JPanel propertyPane;
4.161 private javax.swing.JButton uninstallButton;
4.162 // End of variables declaration//GEN-END:variables
4.163