Examples of MBSWizardHandler


Examples of org.eclipse.cdt.managedbuilder.ui.wizards.MBSWizardHandler

      ManagedBuildManager.getBuildPropertyManager();
    final IBuildPropertyValue[] vs = buildManager
      .getPropertyType(MBSWizardHandler.ARTIFACT).getSupportedValues();
    Arrays.sort(vs, BuildListComparator.getInstance());

    MBSWizardHandler handler = null;

    toolchainLoop:
    for (IBuildPropertyValue value : vs){
      final IToolChain[] toolChains = ManagedBuildManager
        .getExtensionsToolChains(MBSWizardHandler.ARTIFACT, value.getId(), false);
      if (toolChains != null && toolChains.length > 0){
        for (IToolChain tc : toolChains){
          if (!tc.isAbstract() &&
              !tc.isSystemObject() &&
              tc.isSupported() &&
              ManagedBuildManager.isPlatformOk(tc))
          {
            handler = new LocalMBSWizardHandler(
                value, EclimPlugin.getShell(), null, tc);

            // stop once we've found a toolchain w/ a config
            CfgHolder[] cfgs = handler.getCfgItems(false);
            if (cfgs != null &&
                cfgs.length > 0 &&
                cfgs[0].getConfiguration() != null)
            {
              break toolchainLoop;
            }
          }
        }

        // handle case where no toolchain w/ a config was found, like on
        // windows when eclipse can't find cygwin or mingw.
        IToolChain ntc = ManagedBuildManager
          .getExtensionToolChain(ConfigurationDataProvider.PREF_TC_ID);
        handler = new LocalSTDWizardHandler(
            value, EclimPlugin.getShell(), null, ntc);
      }
    }

    try{
      handler.createProject(project, true, true, new NullProgressMonitor());
      ICProject cproject = CUtils.getCProject(project);
      CCorePlugin.getIndexManager().reindex(cproject);
    }catch(Exception e){
      throw new RuntimeException(e);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.