private static Artifact getPreloaderArtifact(Artifact rootArtifact, Project project) {
    for (PackagingElement<?> element : rootArtifact.getRootElement().getChildren()) {
      if (element instanceof ArtifactPackagingElement) {
        final Artifact artifact = ((ArtifactPackagingElement)element)
          .findArtifact(ArtifactManager.getInstance(project).getResolvingContext());
        if (artifact != null && artifact.getArtifactType() instanceof JavaFxPreloaderArtifactType) {
          return artifact;
        }
      }
    }
    return null;
  }
private static Artifact getPreloaderArtifact(Artifact rootArtifact, Project project)