projects
/
gnome.introspection-doc-generator
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
8c3a823
)
JSDOC/Packer.js
author
alan
<alan@alanfast.akbkhome.com>
Wed, 21 Apr 2010 05:50:33 +0000
(13:50 +0800)
committer
alan
<alan@alanfast.akbkhome.com>
Wed, 21 Apr 2010 05:50:33 +0000
(13:50 +0800)
JSDOC/Packer.js
patch
|
blob
|
history
diff --git
a/JSDOC/Packer.js
b/JSDOC/Packer.js
index
59cc4c9
..
911ca8c
100644
(file)
--- a/
JSDOC/Packer.js
+++ b/
JSDOC/Packer.js
@@
-25,7
+25,7
@@
var x = new Packer({
files : [ "/location/of/file1.js", "/location/of/file2.js", ... ],
target : "/tmp/output.js",
debugTarget : "/tmp/output.debug.js", // merged file without compression.
files : [ "/location/of/file1.js", "/location/of/file2.js", ... ],
target : "/tmp/output.js",
debugTarget : "/tmp/output.debug.js", // merged file without compression.
- translateJ
son
: "/tmp/translate.json",
+ translateJ
SON
: "/tmp/translate.json",
);
);
@@
-102,7
+102,7
@@
Packer.prototype = {
*/
tmpDir : '/tmp',
*/
tmpDir : '/tmp',
- translateJ
son
: '', // json based list of strings in all files.
+ translateJ
SON
: '', // json based list of strings in all files.
/**
* @prop cleanup {Boolean} (optional) clean up temp files after done -
/**
* @prop cleanup {Boolean} (optional) clean up temp files after done -
@@
-179,14
+179,14
@@
Packer.prototype = {
}
}
- if (this.translateJ
son
) {
+ if (this.translateJ
SON
) {
print("MERGING LANGUAGE");
File.write(this.target, "if (typeof(_T) == 'undefined') { _T={};}\n");
print("MERGING LANGUAGE");
File.write(this.target, "if (typeof(_T) == 'undefined') { _T={};}\n");
- File.write(this.translateJ
son
, "");
+ File.write(this.translateJ
SON
, "");
for(var i=0; i < this.files.length; i++) {
var file = this.files[i];
var transfile= this.tmpDir + '/' +file.replace(/\//g, '.') +'.lang.trans';
for(var i=0; i < this.files.length; i++) {
var file = this.files[i];
var transfile= this.tmpDir + '/' +file.replace(/\//g, '.') +'.lang.trans';
@@
-203,7
+203,7
@@
Packer.prototype = {
if (File.exists(transfile)) {
var str = File.read(transfile);
if (str.length) {
if (File.exists(transfile)) {
var str = File.read(transfile);
if (str.length) {
- File.append(this.translateJ
son
, str);
+ File.append(this.translateJ
SON
, str);
}
if (this.cleanup) {
File.remove(transfile);
}
if (this.cleanup) {
File.remove(transfile);
@@
-259,7
+259,7
@@
Packer.prototype = {
var toks = tr.tokenize(new TextStream(str)); // dont merge xxx + . + yyyy etc.
// at this point we can write a language file...
var toks = tr.tokenize(new TextStream(str)); // dont merge xxx + . + yyyy etc.
// at this point we can write a language file...
- if (this.translateJ
son
) {
+ if (this.translateJ
SON
) {
this.writeTranslateFile(fn, minfile, tr.translateMap);
}
this.writeTranslateFile(fn, minfile, tr.translateMap);
}
@@
-347,7
+347,7
@@
Packer.prototype = {
{
//print("STRING HANDLER");
// callback when outputing compressed file,
{
//print("STRING HANDLER");
// callback when outputing compressed file,
- if (!this.translate) {
+ if (!this.translate
JSON
) {
// print("TURNED OFF");
return tok.outData;
}
// print("TURNED OFF");
return tok.outData;
}