summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLV-426 <lv-426@taproot.org.il>2014-11-10 16:09:54 +0200
committerLV-426 <lv-426@taproot.org.il>2014-11-10 16:09:54 +0200
commitba6e95f3d76b84571ef2cf016b26fc98b2d75c43 (patch)
tree1306ea732317d1e0a9bab8852b5dc0ca1bfb3a38
parent0fed1a74d549ff6c84e162c3f4a3605848727dd8 (diff)
rename rhizicore -> rz_core, move towards common rz_ prefix
-rw-r--r--TODO2
-rw-r--r--scripts/buttons.js2
-rw-r--r--scripts/drag_n_drop.js2
-rw-r--r--scripts/history.js2
-rw-r--r--scripts/main.js2
-rw-r--r--scripts/rz_core.js (renamed from scripts/rhizicore.js)2
-rw-r--r--scripts/textanalysis.ui.js2
-rw-r--r--tests/base.js6
-rw-r--r--tests/test_analyzer.js4
9 files changed, 12 insertions, 12 deletions
diff --git a/TODO b/TODO
index cca74f1b..47bf1885 100644
--- a/TODO
+++ b/TODO
@@ -1,6 +1,6 @@
This is generic, not yet divided into a bunch of actionable items:
-break down rhizicore.js
+break down rz_core.js
reduce amount of globals to 1.
make it testable without a browser, not using some headless automation - node stuff.
diff --git a/scripts/buttons.js b/scripts/buttons.js
index ef56594d..19c772eb 100644
--- a/scripts/buttons.js
+++ b/scripts/buttons.js
@@ -1,6 +1,6 @@
"use strict"
-define('buttons', ['jquery', 'FileSaver', 'rhizicore'], function ($, saveAs, RZ) {
+define('buttons', ['jquery', 'FileSaver', 'rz_core'], function ($, saveAs, RZ) {
$('.tutorial').click(function(){});
var key="#47989379";
diff --git a/scripts/drag_n_drop.js b/scripts/drag_n_drop.js
index 0f16c6fd..1669a58a 100644
--- a/scripts/drag_n_drop.js
+++ b/scripts/drag_n_drop.js
@@ -1,4 +1,4 @@
-define('drag_n_drop', ['jquery', 'jquery-ui', 'rhizicore'], function($, __unused_jqueryui, RZ) {
+define('drag_n_drop', ['jquery', 'jquery-ui', 'rz_core'], function($, __unused_jqueryui, RZ) {
function init() {
console.log('rhizi: init drag-n-drop');
diff --git a/scripts/history.js b/scripts/history.js
index 72f9e846..3e231329 100644
--- a/scripts/history.js
+++ b/scripts/history.js
@@ -6,7 +6,7 @@
// exceptions but that shouldn't break the console, as evidenced by the '__commandLineAPI is not defined'
// error below.
//
-// Uncaught TypeError: Can't add property addednodes, object is not extensible rhizicore.js:4
+// Uncaught TypeError: Can't add property addednodes, object is not extensible rz_core.js:4
// Uncaught TypeError: Can't add property text, object is not extensible textanalysis.js:3
// Uncaught TypeError: Can't add property key, object is not extensible buttons.js:5
// Uncaught ReferenceError: sentence is not defined robot.js:11
diff --git a/scripts/main.js b/scripts/main.js
index 1c029b2d..bc246925 100644
--- a/scripts/main.js
+++ b/scripts/main.js
@@ -1,4 +1,4 @@
-define('main', ['rhizicore', 'textanalysis.ui', 'buttons', 'history', 'drag_n_drop', 'robot'],
+define('main', ['rz_core', 'textanalysis.ui', 'buttons', 'history', 'drag_n_drop', 'robot'],
function(RZ, textanalysis_ui, buttons, history, drag_n_drop, robot) {
return {
main: function() {
diff --git a/scripts/rhizicore.js b/scripts/rz_core.js
index 588e240a..3a55839c 100644
--- a/scripts/rhizicore.js
+++ b/scripts/rz_core.js
@@ -1,6 +1,6 @@
"use strict"
-define('rhizicore',
+define('rz_core',
['jquery', 'd3', 'consts', 'signal', 'util', 'model/graph'],
function($, d3, consts, signal, util, model_graph) {
diff --git a/scripts/textanalysis.ui.js b/scripts/textanalysis.ui.js
index 503e5796..946ce0d5 100644
--- a/scripts/textanalysis.ui.js
+++ b/scripts/textanalysis.ui.js
@@ -1,6 +1,6 @@
"use strict"
-define('textanalysis.ui', ['autocomplete', 'rhizicore', 'textanalysis', 'signal', 'consts'],
+define('textanalysis.ui', ['autocomplete', 'rz_core', 'textanalysis', 'signal', 'consts'],
function(autocomplete, RZ, textanalysis, signal, consts) {
var text = ""; // Last text of sentence
var element_name = '#textanalyser';
diff --git a/tests/base.js b/tests/base.js
index 6ec22cf6..72ce28b4 100644
--- a/tests/base.js
+++ b/tests/base.js
@@ -64,17 +64,17 @@ function run_tests(settings) {
}
function reset(window) {
- window.require('rhizicore').graph.clear();
+ window.require('rz_core').graph.clear();
}
function nodes(window) {
- return window.require('rhizicore').force.nodes().map(function (n) {
+ return window.require('rz_core').force.nodes().map(function (n) {
return n.name;
});
}
function links(window) {
- return window.require('rhizicore').force.links().map(function (l) {
+ return window.require('rz_core').force.links().map(function (l) {
debugger;
return [l.source.name, l.target.name, l.name];
});
diff --git a/tests/test_analyzer.js b/tests/test_analyzer.js
index 0df43e49..441f0dde 100644
--- a/tests/test_analyzer.js
+++ b/tests/test_analyzer.js
@@ -22,7 +22,7 @@ base.run_tests({
var analyzeSentence = window.require('textanalysis.ui').analyzeSentence;
if (process.argv.length > 2) {
analyzeSentence(process.argv.slice(2).join(" "), true);
- base.dump_graphviz(window.require('rhizicore').force);
+ base.dump_graphviz(window.require('rz_core').force);
} else {
for (var k = 0; k < data.length; ++k) {
var sentence = data[k][0];
@@ -41,7 +41,7 @@ base.run_tests({
console.log('expected: ' + expected_links);
console.log('got: ' + links);
}
- base.dump_graphviz(window.require('rhizicore').force);
+ base.dump_graphviz(window.require('rz_core').force);
}
}
process.exit();