Skip to content
This repository has been archived by the owner on Nov 17, 2020. It is now read-only.

Commit

Permalink
add info (to be able to test scala-ide version for specific behavior)…
Browse files Browse the repository at this point in the history
…. Currently no special behavior if scala-ide.version >= 4.0.0 , the auto-detection of scala-library into maven container doesn't seems to work.
  • Loading branch information
davidB committed Oct 13, 2014
1 parent 6e57223 commit b78a29d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import org.eclipse.core.runtime.Plugin;
import org.osgi.framework.Bundle;
import org.osgi.framework.BundleContext;
import org.osgi.framework.Version;

public class Activator extends Plugin {

Expand Down Expand Up @@ -41,6 +42,7 @@ public void start(BundleContext context) throws Exception {
Bundle bundle = bundles[j];
if(ids.pluginId.equals(bundle.getSymbolicName())) {
_scalaPluginIds = ids;
_scalaPluginIds.version = bundle.getVersion();
}
}
}
Expand All @@ -58,6 +60,8 @@ class ScalaPluginIds {
protected String natureId;

protected String containerLibId;

protected Version version;

public ScalaPluginIds(String pluginId, String natureId, String containerLibId) {
super();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ public class ScalaProjectConfigurator extends AbstractSourcesGenerationProjectCo

public ScalaProjectConfigurator() {
super();

mapSourceTypeWeight = new HashMap<String, Integer>();
mapSourceTypeWeight.put("src/main/", 9000);
mapSourceTypeWeight.put("src/test/", 1000);
Expand Down Expand Up @@ -113,6 +114,11 @@ private String scalaNatureId() {
ScalaPluginIds ids = Activator.getInstance().scalaPluginIds();
return (ids == null)?null : ids.natureId;
}

// private boolean shouldManageClasspath() {
// Version v4 = new Version(4,0,0);
// return v4.compareTo(Activator.getInstance().scalaPluginIds().version) > 0;
// }

@Override
public void configure(ProjectConfigurationRequest request, IProgressMonitor monitor) throws CoreException {
Expand Down

0 comments on commit b78a29d

Please sign in to comment.