--- a/tool/run/plugins/spdx/create.java
+++ b/tool/run/plugins/spdx/create.java
@@ -69,7 +69,6 @@
addChildNode("from web", "application-dock-270.png", "mainWeb");
addChildNode("from folder", "folder-smiley.png", "mainFolder");
- addChildNode("from zipped file", "vise-drawer.png", "mainZip");
}
@@ -79,20 +78,20 @@
*/
@Override
public void main(WebRequest request){
- //request.setPage("spdxDialog.html");
- String result = "<html>\n" +
-// "<head>\n" +
-// "<style type=\"text/css\">body {font-family:verdana,arial,"
-// + "sans-serif;font-size:10pt;margin:30px;}</style>"
-// + "</head>\n" +
-// "\n" +
- "<body>"
- + ""
- + "Testing stuff!"
- + ""
- + "</body>"
- + "</html>";
- request.setAnswer(result);
+ request.setPage("spdxMain.html");
+// String result = "<html>\n" +
+//// "<head>\n" +
+//// "<style type=\"text/css\">body {font-family:verdana,arial,"
+//// + "sans-serif;font-size:10pt;margin:30px;}</style>"
+//// + "</head>\n" +
+//// "\n" +
+// "<body>"
+// + ""
+// + "Testing stuff!"
+// + ""
+// + "</body>"
+// + "</html>";
+// request.setAnswer(result);
}
@@ -274,17 +273,6 @@
// third step, create the SPDX document from the extracted files
String result = createDocument(extractedFolder, this);
- // all done here, explain where the SPDX document can be found
- nextStep =
- html.link("SPDX summary",
- "/spdx/show?x=summary&"
- + param.spdx + "=" + result)
- + " | " +
- html.link("Show full text",
- "/spdx/show?x=full&"
- + param.spdx + "=" + result)
- ;
-
}
};
task.launch();
@@ -315,6 +303,21 @@
// all done
task.setStatus("All done!");
task.setPercentageComplete(100);
+
+
+ // all done here, explain where the SPDX document can be found
+ task.nextStep =
+ html.link("SPDX summary",
+ "/spdx/show?x=summary&"
+ + param.spdx + "=" + result)
+ + " | " +
+ html.link("Show full text",
+ "/spdx/show?x=full&"
+ + param.spdx + "=" + result)
+ ;
+ // when all things said and done
+ concludeCreation(newSPDX);
+
return result;
}
@@ -428,8 +431,20 @@
}
-
+/**
+ * Do the things that are necessary after creating a new SPDX document, such as
+ * updating the tree view
+ */
+private void concludeCreation(DocumentCreate newSPDX){
+ String UID = newSPDX.UID;
+ // refresh the tree
+ swingUtils.refreshAll(core.studio.getTree(), UID);
}
+
+}
+
+
+
//
// /**