当前位置: 首页>>代码示例>>Java>>正文


Java WizardDescriptor.Panel方法代码示例

本文整理汇总了Java中org.openide.WizardDescriptor.Panel方法的典型用法代码示例。如果您正苦于以下问题:Java WizardDescriptor.Panel方法的具体用法?Java WizardDescriptor.Panel怎么用?Java WizardDescriptor.Panel使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.openide.WizardDescriptor的用法示例。


在下文中一共展示了WizardDescriptor.Panel方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: createPanels

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
private List<WizardDescriptor.Panel<ShortcutWizard>> createPanels() {
    List<WizardDescriptor.Panel<ShortcutWizard>> _panels = new ArrayList<WizardDescriptor.Panel<ShortcutWizard>>();
    _panels.add(new IntroPanel.IntroWizardPanel());
    _panels.add(new SelectFolderPanel.SelectFolderWizardPanel(
            NbBundle.getMessage(ShortcutIterator.class, "SI_LBL_select_menu_to_add_to"),
            NbBundle.getMessage(ShortcutIterator.class, "SI_TEXT_menu_locn"),
            NbBundle.getMessage(ShortcutIterator.class, "SI_LBL_display_name_for_menu"),
            DataFolder.findFolder(FileUtil.getConfigFile("Menu")), // NOI18N
            true, ShortcutWizard.PROP_FOLDER_MENU));
    _panels.add(new SelectFolderPanel.SelectFolderWizardPanel(
            NbBundle.getMessage(ShortcutIterator.class, "SI_LBL_select_toolbar"),
            NbBundle.getMessage(ShortcutIterator.class, "SI_TEXT_toolbar_locn"),
            NbBundle.getMessage(ShortcutIterator.class, "SI_LBL_display_name_for_toolbar"),
            DataFolder.findFolder(FileUtil.getConfigFile("Toolbars")), // NOI18N
            false, ShortcutWizard.PROP_FOLDER_TOOL));
    _panels.add(new SelectKeyboardShortcutPanel.SelectKeyboardShortcutWizardPanel());
    _panels.add(new CustomizeScriptPanel.CustomizeScriptWizardPanel());
    return _panels;
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:20,代码来源:ShortcutIterator.java

示例2: current

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
/**
 * Returns current panel of the wizard.
 *
 * @return current panel of the wizard.
 */
@Override
public WizardDescriptor.Panel current() {
    String title = NbBundle.getMessage(MasterDetailWizard.class, "TITLE_MasterDetail");  // NOI18N
    wizard.putProperty("NewFileWizard_Title", title); // NOI18N
    if (steps == null) {
        initSteps();
    }
    WizardDescriptor.Panel panel;
    if (panelIndex < beforeStepsNo) {
        panel = delegateIterator.current();
    } else {
        panel = panels[panelIndex-beforeStepsNo];
    }
    JComponent comp = (JComponent)panel.getComponent();
    if ((panelIndex < beforeStepsNo) || (comp.getClientProperty(WIZARD_PANEL_CONTENT_DATA) == null)) {
        comp.putClientProperty(WIZARD_PANEL_CONTENT_DATA, steps);
    }
    if (comp.getClientProperty(WIZARD_PANEL_CONTENT_SELECTED_INDEX) == null) {
        comp.putClientProperty(WIZARD_PANEL_CONTENT_SELECTED_INDEX, panelIndex);
    }
    return panel;
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:28,代码来源:MasterDetailWizard.java

示例3: createPanels

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
private WizardDescriptor.Panel[] createPanels(final WizardDescriptor wizardDescriptor) {
    // Ask for Java folders
    Project project = Templates.getProject(wizardDescriptor);
    Sources sources = ProjectUtils.getSources(project);
    SourceGroup[] groups = getTestRoots(sources);
    if (groups.length == 0) {
        if (SourceGroupModifier.createSourceGroup(project, JavaProjectConstants.SOURCES_TYPE_JAVA, JavaProjectConstants.SOURCES_HINT_TEST) != null) {
            groups = getTestRoots(sources);
        }
    }
    if (groups.length == 0) {
        groups = sources.getSourceGroups(Sources.TYPE_GENERIC);
        return new WizardDescriptor.Panel[]{
                    Templates.buildSimpleTargetChooser(project, groups).create()
                };
    } else {
        return new WizardDescriptor.Panel[]{
                    JavaTemplates.createPackageChooser(project, groups, new EmptyTestStepLocation())
                };
    }
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:22,代码来源:NewTestWizardIterator.java

示例4: getDTDPanel

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
private WizardDescriptor.Panel getDTDPanel() {
    if (dtdPanel == null) {
        dtdPanel = new DTDPanel();
        dtdPanel.setObject(model);
        
        String[] steps = new String[3];
        steps[0] = getTargetPanelName();
        steps[1] = getDocumentPanelName();
        steps[2] = getDTDPanelName();
        String[] newSteps = createSteps(beforeSteps,steps);
        dtdPanel.putClientProperty(
            WizardDescriptor.PROP_CONTENT_DATA,                                      // NOI18N
            newSteps
        );
        
    }
    return new AbstractPanel.WizardStep(dtdPanel);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:19,代码来源:XMLWizardIterator.java

示例5: currentComponent

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
private WizardDescriptor.Panel currentComponent() {   
    switch (current) {
        case TARGET_PANEL:
            return getTargetPanel();
        case DOCUMENT_PANEL:
            return getDocumentPanel();
        case CONSTRAINT_PANEL:
            switch (model.getType()) {
                case DocumentModel.DTD:
                    return getDTDPanel();
                case DocumentModel.SCHEMA:
                    return getSchemaPanel();
                default:
                    throw new IllegalStateException();
            }
        case CONTENT_PANEL:
            return getXMLContentPanel();
        default:
            throw new IllegalStateException();
    }
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:22,代码来源:XMLWizardIterator.java

示例6: getPanels

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
private List<WizardDescriptor.Panel<WizardDescriptor>> getPanels() {
    if (panels == null) {

        Project project = Templates.getProject(wizard);
        Sources sources = ProjectUtils.getSources(project);
        SourceGroup[] groups = sources.getSourceGroups(JavaProjectConstants.SOURCES_TYPE_JAVA);

        panels = new ArrayList<WizardDescriptor.Panel<WizardDescriptor>>();
        panels.add(JavaTemplates.createPackageChooser(project, groups));
        String[] steps = createSteps();

        for (int i = 0; i < panels.size(); i++) {
            Component c = panels.get(i).getComponent();
            if (steps[i] == null) {
                // Default step name to component name of panel. Mainly
                // useful for getting the name of the target chooser to
                // appear in the list of steps.
                steps[i] = c.getName();
            }
            if (c instanceof JComponent) { // assume Swing components
                JComponent jc = (JComponent) c;
                jc.putClientProperty(WizardDescriptor.PROP_TITLE, "New primitive");
                // Sets highlighted step
                jc.putClientProperty(WizardDescriptor.PROP_CONTENT_SELECTED_INDEX, i);
                // Set steps names shown on the left side of the wizard
                jc.putClientProperty(WizardDescriptor.PROP_CONTENT_DATA, steps);
                // Turn on subtitle creation on each step
                jc.putClientProperty(WizardDescriptor.PROP_AUTO_WIZARD_STYLE, true);
                // Show steps on the left side with the image on the background
                jc.putClientProperty(WizardDescriptor.PROP_CONTENT_DISPLAYED, true);
                // Turn on numbering of all steps
                jc.putClientProperty(WizardDescriptor.PROP_CONTENT_NUMBERED, true);
            }
        }
    }
    return panels;
}
 
开发者ID:kefik,项目名称:Pogamut3,代码行数:38,代码来源:NewPrimitiveWizardIterator.java

示例7: createPanels

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
@SuppressWarnings({"unchecked", "rawtypes"}) // XXX until rewrite panel storage
private WizardDescriptor.Panel<WizardDescriptor>[] createPanels(ValidationGroup enabledVG, ValidationGroup errorMsgVG) {
        return new WizardDescriptor.Panel[] {
            ArchetypeWizards.basicWizardPanel(errorMsgVG, false, archetype),
            new NbmWizardPanel(enabledVG, errorMsgVG, archetype)
        };
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:8,代码来源:NbmWizardIterator.java

示例8: getChooser

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
WizardDescriptor.Panel<WizardDescriptor> getChooser(TemplateWizard wizard, String type) {
    if (choosers == null) {
        choosers = new HashMap<>();
    }
    WizardDescriptor.Panel<WizardDescriptor> panel = choosers.get(type);
    
    if (panel == null) {
        panel = loadPanel(type, wizard);
        choosers.put(type, panel);
    }
    return panel;
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:13,代码来源:AbstractWizard.java

示例9: current

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
public WizardDescriptor.Panel current() {
    return getPanels()[index];
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:4,代码来源:HibernateConfigurationWizard.java

示例10: createPanels

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
private WizardDescriptor.Panel[] createPanels() {
    return new WizardDescriptor.Panel[]{
                new TemplateBotProjectWizardPanel(),};
}
 
开发者ID:kefik,项目名称:Pogamut3,代码行数:5,代码来源:TemplateBotProjectWizardIterator.java

示例11: current

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
@Override
public WizardDescriptor.Panel<WizardDescriptor> current () {
    assert panels != null;
    return panels.get (index);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:6,代码来源:LazyInstallUnitWizardIterator.java

示例12: current

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
public WizardDescriptor.Panel current() {
    return panels[index];
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:4,代码来源:NewTestSuiteWizardIterator.java

示例13: createPackageChooser

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
static WizardDescriptor.Panel<WizardDescriptor> createPackageChooser(Object project, String type) throws Exception {
    Project p = (Project) project;
    Sources src = ProjectUtils.getSources(p);
    SourceGroup[] groups = src.getSourceGroups(type);
    return JavaTemplates.createPackageChooser(p, groups);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:7,代码来源:JavaTemplates.java

示例14: current

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
@Override
public WizardDescriptor.Panel current() {
    return panels[index];
}
 
开发者ID:kefik,项目名称:Pogamut3,代码行数:5,代码来源:TemplateBotProjectWizardIterator.java

示例15: createPanels

import org.openide.WizardDescriptor; //导入方法依赖的package包/类
private WizardDescriptor.Panel[] createPanels(final WizardDescriptor wizardDescriptor) {
    return new WizardDescriptor.Panel[]{getTargetPanel()};
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:4,代码来源:TestSuiteWizardIterator.java


注:本文中的org.openide.WizardDescriptor.Panel方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。