@Override
  public Image getImage(final Object element) {
    String iconName = "titan.gif";
    if (element instanceof IOutlineElement) {
      IOutlineElement e = (IOutlineElement) element;
      iconName = e.getOutlineIcon();
    } else if (element instanceof List<?>) {
      iconName = "imports.gif";
    }

    return ImageCache.getImage(iconName);
  }
  /*
   * (non-Javadoc)
   *
   * @see org.eclipse.jface.wizard.Wizard#performFinish()
   */
  @Override
  public boolean performFinish() {
    if (mainPage.getContainerFullPath().append(mainPage.getFileName()).getFileExtension() == null) {
      mainPage.setFileName(
          mainPage.getFileName() + '.' + GlobalParser.SUPPORTED_TTCN3_EXTENSIONS[1]);
    }
    final IFile newModule = mainPage.createNewFile();
    if (newModule != null) {
      try {
        if (optionsPage.isExcludeFromBuildSelected()) {
          newModule.setPersistentProperty(
              new QualifiedName(
                  FileBuildPropertyData.QUALIFIER,
                  FileBuildPropertyData.EXCLUDE_FROM_BUILD_PROPERTY),
              TRUE);
        }

        ProjectFileHandler pfHandler = new ProjectFileHandler(newModule.getProject());
        pfHandler.saveProjectSettings();
        newModule.touch(new NullProgressMonitor());

        WorkspaceJob refreshJob =
            new WorkspaceJob("Refreshing built resources") {
              @Override
              public IStatus runInWorkspace(final IProgressMonitor monitor) {
                boolean proceedingOK = SymbolicLinkHandler.createSymlinks(newModule);
                if (proceedingOK) {
                  proceedingOK = TITANBuilder.removeExecutable(newModule.getProject());
                }
                if (proceedingOK) {
                  proceedingOK = TITANBuilder.removeMakefile(newModule.getProject());
                }
                if (proceedingOK) {
                  TITANBuilder.invokeBuild(newModule.getProject());
                }

                return Status.OK_STATUS;
              }
            };
        refreshJob.setPriority(Job.LONG);
        refreshJob.setUser(false);
        refreshJob.setSystem(true);
        refreshJob.setProperty(
            IProgressConstants.ICON_PROPERTY, ImageCache.getImageDescriptor("titan.gif"));
        refreshJob.schedule();

        selectAndRevealNewModule(newModule);
      } catch (CoreException e) {
        ErrorReporter.logExceptionStackTrace(e);
      }
    }
    return true;
  }