本文整理汇总了Java中org.openide.explorer.view.NodeListModel类的典型用法代码示例。如果您正苦于以下问题:Java NodeListModel类的具体用法?Java NodeListModel怎么用?Java NodeListModel使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
NodeListModel类属于org.openide.explorer.view包,在下文中一共展示了NodeListModel类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: ToolBarView
import org.openide.explorer.view.NodeListModel; //导入依赖的package包/类
ToolBarView(final ExplorerManager manager, org.openide.nodes.Node root, javax.swing.Action helpAction) {
super();
this.manager=manager;
this.helpAction=helpAction;
// same as before...
setLayout(new java.awt.GridBagLayout());
ActionMap map = getActionMap();
// ...and initialization of lookup variable
lookup = ExplorerUtils.createLookup (manager, map);
ChoiceView cView = new ChoiceView();
((NodeListModel)(cView.getModel())).setNode(root);
setFloatable(false);
((NodeListModel)(cView.getModel())).setDepth(5);
java.awt.GridBagConstraints gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 0;
gridBagConstraints.gridy = 0;
gridBagConstraints.insets = new java.awt.Insets(0, 2, 4, 0);
add(cView,gridBagConstraints);
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = 0;
gridBagConstraints.weightx = 1.0;
JPanel filler = new JPanel();
add(filler,gridBagConstraints);
javax.swing.JButton helpButton = new javax.swing.JButton(helpAction);
helpButton.setText("");
helpButton.setContentAreaFilled(false);
helpButton.setFocusPainted(false);
helpButton.setBorderPainted(false);
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridx = 2;
gridBagConstraints.gridy = 0;
//gridBagConstraints.weightx = 1.0;
add(helpButton,gridBagConstraints);
}
开发者ID:apache,项目名称:incubator-netbeans,代码行数:41,代码来源:ToolBarDesignEditor.java
示例2: createModel
import org.openide.explorer.view.NodeListModel; //导入依赖的package包/类
@Override
protected NodeListModel createModel() {
return new CheckNodeListModel();
}
开发者ID:arodchen,项目名称:MaxSim,代码行数:5,代码来源:CheckListView.java
注:本文中的org.openide.explorer.view.NodeListModel类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论