|
From: <se...@us...> - 2008-05-06 11:22:54
|
Revision: 92
http://acmcontester.svn.sourceforge.net/acmcontester/?rev=92&view=rev
Author: sem62
Date: 2008-05-06 04:22:53 -0700 (Tue, 06 May 2008)
Log Message:
-----------
Modified summary page.
Modified Paths:
--------------
WebEditor/src/edu/lnu/FireFly/WebEditor/WebEditor.java
WebEditor/template/LectureModel.html
WebEditor/template/global/SummaryPage.js
Added Paths:
-----------
WebEditor/template/global/images/
WebEditor/template/global/images/completed.gif
WebEditor/template/global/images/incomplete.gif
WebEditor/template/global/images/undefined.gif
Modified: WebEditor/src/edu/lnu/FireFly/WebEditor/WebEditor.java
===================================================================
--- WebEditor/src/edu/lnu/FireFly/WebEditor/WebEditor.java 2008-05-06 09:48:50 UTC (rev 91)
+++ WebEditor/src/edu/lnu/FireFly/WebEditor/WebEditor.java 2008-05-06 11:22:53 UTC (rev 92)
@@ -41,7 +41,7 @@
public static WebEditor instance = null;
- protected Manifest manifest = ManifestFactory.createManifest();
+ protected Manifest manifest = null;
protected JMenuItem openMenuItem = null;
@@ -84,7 +84,6 @@
@Override
public void init() {
-
Settings.getInstance().setCourseLocation(getParameter("courseLocation"));
Settings.getInstance().setServiceLocation(getParameter("serviceLocation"));
Settings.getInstance().setTemplateLocation(getParameter("templateLocation"));
Modified: WebEditor/template/LectureModel.html
===================================================================
--- WebEditor/template/LectureModel.html 2008-05-06 09:48:50 UTC (rev 91)
+++ WebEditor/template/LectureModel.html 2008-05-06 11:22:53 UTC (rev 92)
@@ -3,9 +3,15 @@
<title>title</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf8" />
<script type="text/javascript" src="global/APIWrapper.js"></script>
+ <script type="text/javascript">
+ function finish(){
+ SetValue("cmi.completionStatus", "completed");
+ Terminate();
+ }
+ </script>
</head>
-<body onload="Initialize();" onunload="Terminate();">
+<body onload="Initialize();" onunload="finish();">
<div id="lecture_caption">
<!--caption start-->New caption<!--caption end-->
</div>
Modified: WebEditor/template/global/SummaryPage.js
===================================================================
--- WebEditor/template/global/SummaryPage.js 2008-05-06 09:48:50 UTC (rev 91)
+++ WebEditor/template/global/SummaryPage.js 2008-05-06 11:22:53 UTC (rev 92)
@@ -5,7 +5,7 @@
document.write(s);
}
-function ins(title, min, max, raw){
+function ins(title, min, max, raw, completionStatus){
var percents = 100*(raw-min)/(max-min) + " %";
rowNum++;
@@ -13,7 +13,7 @@
td += 1 - (rowNum % 2) + 1;
td += "'>";
- document.write("<TR>" + td + rowNum);
+ document.write("<TR>" + td + rowNum + "<img src='global/images/" + completionStatus + ".gif'>");
document.write(td + title);
document.write(td + min);
document.write(td + max);
@@ -37,7 +37,7 @@
title = " " + title;
}
- ins(title, getScore(id, "min"), getScore(id, "max"), getScore(id, "raw"));
+ ins(title, getScore(id, "min"), getScore(id, "max"), getScore(id, "raw"), getCompletionStatus(id));
}
function getObjectiveIndex(id){
@@ -51,6 +51,13 @@
return -1;
}
+function getCompletionStatus(objectiveID){
+ var index = getObjectiveIndex(objectiveID);
+ var res = GetValue("cmi.objectives." + index + ".completionStatus");
+
+ return res != null ? res : "undefined";
+}
+
function getScore(objectiveID, field){
var index = getObjectiveIndex(objectiveID);
var res = GetValue("cmi.objectives." + index + ".score." + field);
Added: WebEditor/template/global/images/completed.gif
===================================================================
(Binary files differ)
Property changes on: WebEditor/template/global/images/completed.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: WebEditor/template/global/images/incomplete.gif
===================================================================
(Binary files differ)
Property changes on: WebEditor/template/global/images/incomplete.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: WebEditor/template/global/images/undefined.gif
===================================================================
(Binary files differ)
Property changes on: WebEditor/template/global/images/undefined.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|