summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Simianer <p@simianer.de>2015-11-06 16:10:02 +0100
committerPatrick Simianer <p@simianer.de>2015-11-06 16:10:02 +0100
commit886337bdf83c33edf2361ffa45239aa5195ca367 (patch)
tree8c864e8231c78dd9488543af02cca2be25a1935e
parent5184db137d585746e3c8ab933a6ed460fd312458 (diff)
cleanup
-rwxr-xr-xderivation_to_json/derivation_to_json.rb2
-rw-r--r--external/README4
-rw-r--r--footer.inc.php (renamed from footer.php)0
-rw-r--r--header.inc.php (renamed from header.php)0
-rw-r--r--index.php4
-rw-r--r--interface.php4
-rw-r--r--js/common.js11
-rw-r--r--js/debug.js3
-rw-r--r--js/lfpe.js7
9 files changed, 15 insertions, 20 deletions
diff --git a/derivation_to_json/derivation_to_json.rb b/derivation_to_json/derivation_to_json.rb
index afd62b7..f7307cc 100755
--- a/derivation_to_json/derivation_to_json.rb
+++ b/derivation_to_json/derivation_to_json.rb
@@ -83,7 +83,7 @@ class Rule
x -= rx
y -= ry
if @ha[x]
- @ha[x] << y
+ @ha[x] << y
else
@ha[x] = [y]
end
diff --git a/external/README b/external/README
index 166b2d9..c14f4eb 100644
--- a/external/README
+++ b/external/README
@@ -1,5 +1,5 @@
+scripts taken from Moses [https://github.com/moses-smt/mosesdecoder]
+
github.com/pks/scripts @e137509a77e3a8c12af32852ebba893dacb53f85
moses @7b02017da1e2a09486627b543446ec78e51541a7
-taken from Moses [https://github.com/moses-smt/mosesdecoder]
-
diff --git a/footer.php b/footer.inc.php
index 8709538..8709538 100644
--- a/footer.php
+++ b/footer.inc.php
diff --git a/header.php b/header.inc.php
index e812943..e812943 100644
--- a/header.php
+++ b/header.inc.php
diff --git a/index.php b/index.php
index 22118e2..cab79c6 100644
--- a/index.php
+++ b/index.php
@@ -8,7 +8,7 @@
<body onload="">
-<?php include("header.php"); ?>
+<?php include("header.inc.php"); ?>
<form method="get" action="interface.php">
<strong>Please enter your session key:</strong> <input type="text" id="key" name="key" />
@@ -40,7 +40,7 @@
</p>
</div>
-<?php include("footer.php"); ?>
+<?php include("footer.inc.php"); ?>
</body>
</html>
diff --git a/interface.php b/interface.php
index 5a27ae1..ab38f72 100644
--- a/interface.php
+++ b/interface.php
@@ -15,7 +15,7 @@
<body>
-<?php include("header.php"); ?>
+<?php include("header.inc.php"); ?>
<!-- Derivation editor -->
<div id="derivation_editor">
@@ -102,7 +102,7 @@ foreach($db->raw_source_segments as $s) {
<p class="small" style="text-align:right"><a href="#">^</a></p>
-<?php include("footer.php"); ?>
+<?php include("footer.inc.php"); ?>
</body>
</html>
diff --git a/js/common.js b/js/common.js
index 92dc74b..4e7d3fe 100644
--- a/js/common.js
+++ b/js/common.js
@@ -1,6 +1,9 @@
-var data,
- ui_type;
-
+/*
+ * (common) global vars
+ *
+ */
+var data, // data (from JSON)
+ ui_type; // 't' (text) or 'g' (graphical)
/*
* hacky way to remove class from node
@@ -17,7 +20,7 @@ function removeClass(node, className)
}
/*
- *
+ * toggle display of element (by id)
*
*/
function toggleDisplay(id)
diff --git a/js/debug.js b/js/debug.js
index d69dd2b..76c7b80 100644
--- a/js/debug.js
+++ b/js/debug.js
@@ -9,6 +9,3 @@ $().ready(function()
})
})
-$("#reset").click(function(){
-
-});
diff --git a/js/lfpe.js b/js/lfpe.js
index fec5d99..30f7787 100644
--- a/js/lfpe.js
+++ b/js/lfpe.js
@@ -72,7 +72,7 @@ function catch_return(e)
}
/*
- *
+ * working/not working
*
*/
function working()
@@ -103,11 +103,6 @@ function working()
pause_button.setAttribute("disabled", "disabled");
target_textarea.setAttribute("disabled", "disabled");
}
-
-/*
- *
- *
- */
function not_working(fadein=true)
{
// elements