Permalink
Browse files

Merge branch 'master' of https://github.com/EBI-Metabolights/ISAcreat…

…orPlugins

Conflicts:
	Metabolomics/src/main/java/org/isatools/plugins/metabolights/assignments/ui/DataEntrySheet.java
  • Loading branch information...
2 parents 4fe573b + 2cfb68b commit fee0e39cfbd73a74394615fa731182100f2387fb khaug committed Oct 20, 2011
View
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" output="target/classes" path="src/main/java"/>
+ <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
+ <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
View
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>metabolomics</name>
+ <comment>Test. NO_M2ECLIPSE_SUPPORT: Project files created with the maven-eclipse-plugin are not supported in M2Eclipse.</comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.maven.ide.eclipse.maven2Builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.maven.ide.eclipse.maven2Nature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
@@ -0,0 +1,6 @@
+#Mon Oct 17 17:44:29 BST 2011
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+org.eclipse.jdt.core.compiler.compliance=1.5
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
+org.eclipse.jdt.core.compiler.source=1.5
@@ -0,0 +1,8 @@
+#Mon Oct 17 17:44:27 BST 2011
+activeProfiles=
+eclipse.preferences.version=1
+fullBuildGoals=process-test-resources
+resolveWorkspaceProjects=true
+resourceFilterGoals=process-resources resources\:testResources
+skipCompilerPlugin=true
+version=1
@@ -47,7 +47,7 @@ private IsaCreatorInfo getIsaCreatorInfo() {
}
@InjectedResource
- private ImageIcon saveIcon, saveIconOver, loadIcon, loadIconOver, okIcon;
+ private ImageIcon saveIcon, saveIconOver, loadIcon, loadIconOver, okIcon, okIconOver;
public DataEntrySheet(EditorUI parentFrame, TableReferenceObject tableReferenceObject) {
ResourceInjector.get("metabolights-fileeditor-package.style").inject(this);
@@ -61,8 +61,53 @@ public void createGUI() {
sheet = new Spreadsheet(parentFrame, getIsaCreatorInfo().addTableRefSampleColumns(tableReferenceObject), ""); // Add the sample columns to the definition
createTopPanel();
add(getIsaCreatorInfo().addSpreadsheetSampleColumns(sheet), BorderLayout.CENTER); // Add the sample columns to the spreadsheet
+ createBottomPanel();
}
+ public void createBottomPanel(){
+ JPanel bottomPannel = new JPanel(new BorderLayout());
+ bottomPannel.setBackground(UIHelper.BG_COLOR);
+
+ Box buttonContainer = Box.createHorizontalBox();
+ buttonContainer.setBackground(UIHelper.BG_COLOR);
+
+ JLabel file = new JLabel();
+ file.setBackground(UIHelper.BG_COLOR);
+
+ // Not available in the first load (without ISACreator)
+ if (!parentFrame.getAmIAlone()){
+ file.setText(getFileName());
+ }
+
+ bottomPannel.add(file);
+
+ final JLabel okButton = new JLabel(okIcon);
+ okButton.addMouseListener(new MouseAdapter() {
+ @Override
+ public void mousePressed(MouseEvent mouseEvent) {
+ saveFile();
+ parentFrame.setCurrentCellValue(fileName);
+ parentFrame.confirm();
+ }
+ @Override
+ public void mouseExited(MouseEvent mouseEvent) {
+ okButton.setIcon(okIcon);
+ }
+
+ @Override
+ public void mouseEntered(MouseEvent mouseEvent) {
+ okButton.setIcon(okIconOver);
+ }
+ });
+
+ buttonContainer.add(okButton);
+
+ bottomPannel.add(buttonContainer, BorderLayout.EAST);
+
+ add(bottomPannel, BorderLayout.SOUTH);
+
+
+ }
public void createTopPanel() {
JPanel topContainer = new JPanel(new BorderLayout());
topContainer.setBackground(UIHelper.BG_COLOR);
@@ -109,21 +154,11 @@ public void mouseEntered(MouseEvent mouseEvent) {
}
});
- final JLabel okButton = new JLabel(okIcon);
- okButton.addMouseListener(new MouseAdapter() {
- @Override
- public void mousePressed(MouseEvent mouseEvent) {
- parentFrame.setCurrentCellValue(fileName);
- parentFrame.confirm();
- }
- });
buttonContainer.add(saveButton);
buttonContainer.add(Box.createHorizontalStrut(5));
buttonContainer.add(loadButton);
- buttonContainer.add(Box.createHorizontalStrut(5));
- buttonContainer.add(okButton);
-
+
topContainer.add(buttonContainer, BorderLayout.EAST);
add(topContainer, BorderLayout.NORTH);
@@ -102,7 +102,9 @@ private void createCentralPanel(String technologyType) {
}
public void confirm(){
+ setVisible(false);
firePropertyChange("confirm", "1", "2");
+
}
/**
@@ -5,6 +5,8 @@ DataEntrySheet.saveIcon=/images/metabolights/saveIcon.png
DataEntrySheet.saveIconOver=/images/metabolights/saveIconOver.png
DataEntrySheet.loadIcon=/images/metabolights/loadIcon.png
DataEntrySheet.loadIconOver=/images/metabolights/loadIconOver.png
-DataEntrySheet.okIcon=/images/metabolights/ok.png
-
-
+DataEntrySheet.okIcon=/images/metabolights/ok.png
+DataEntrySheet.okIconOver=/images/metabolights/ok_over.png
+DataEntrySheet.cancelIcon=/images/metabolights/cancel.png
+DataEntrySheet.cancelIconOver=/images/metabolights/cancel_over.png
+
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
View
@@ -0,0 +1,4 @@
+rm ../../ISAcreator/Plugins/*.jar
+mvn clean install
+cp ./target/metabolomics*.jar ../../ISAcreator/Plugins/
+ls -Fla ../../ISAcreator/Plugins

0 comments on commit fee0e39

Please sign in to comment.