Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit bae98ca
Showing
140 changed files
with
2,674 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
This is a Bazaar control directory. | ||
Do not change any files in this directory. | ||
See http://bazaar-vcs.org/ for more information about Bazaar. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Bazaar-NG meta directory, format 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
bound_location = bzr+ssh://creationix/home/tim/code/haml_js/ | ||
bound = True |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Bazaar Branch Format 6 (bzr 0.15) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
10 tim@beast-20090703042640-572k1iqdqz6ipyy5 |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
BZR conflict list format 1 |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Bazaar Working Tree Format 4 (bzr 0.15) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Bazaar pack repository format 1 (needs bzr 0.92) |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file not shown.
Binary file added
BIN
+167 Bytes
.bzr/repository/obsolete_packs/139e074c06dd2bbc74963456664a4495.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+163 Bytes
.bzr/repository/obsolete_packs/139e074c06dd2bbc74963456664a4495.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/139e074c06dd2bbc74963456664a4495.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file added
BIN
+462 Bytes
.bzr/repository/obsolete_packs/139e074c06dd2bbc74963456664a4495.tix
Binary file not shown.
Binary file added
BIN
+167 Bytes
.bzr/repository/obsolete_packs/29632f277a4c473ac9a009e20e194903.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+163 Bytes
.bzr/repository/obsolete_packs/29632f277a4c473ac9a009e20e194903.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/29632f277a4c473ac9a009e20e194903.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file added
BIN
+464 Bytes
.bzr/repository/obsolete_packs/29632f277a4c473ac9a009e20e194903.tix
Binary file not shown.
Binary file added
BIN
+167 Bytes
.bzr/repository/obsolete_packs/2f2a4f9a962f3eeeba266835a5d5b928.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+163 Bytes
.bzr/repository/obsolete_packs/2f2a4f9a962f3eeeba266835a5d5b928.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/2f2a4f9a962f3eeeba266835a5d5b928.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file not shown.
Binary file added
BIN
+166 Bytes
.bzr/repository/obsolete_packs/5da261d2f4c5631dd073410bba19e53c.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+162 Bytes
.bzr/repository/obsolete_packs/5da261d2f4c5631dd073410bba19e53c.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/5da261d2f4c5631dd073410bba19e53c.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file added
BIN
+827 Bytes
.bzr/repository/obsolete_packs/5da261d2f4c5631dd073410bba19e53c.tix
Binary file not shown.
Binary file added
BIN
+127 Bytes
.bzr/repository/obsolete_packs/716252034b9b9f45890911936f6bbc87.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+125 Bytes
.bzr/repository/obsolete_packs/716252034b9b9f45890911936f6bbc87.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/716252034b9b9f45890911936f6bbc87.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file not shown.
Binary file added
BIN
+163 Bytes
.bzr/repository/obsolete_packs/8b1e24522b58e1073ef71de3f34c2ed0.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+163 Bytes
.bzr/repository/obsolete_packs/8b1e24522b58e1073ef71de3f34c2ed0.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/8b1e24522b58e1073ef71de3f34c2ed0.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/8b1e24522b58e1073ef71de3f34c2ed0.tix
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=2 | ||
key_elements=2 | ||
len=0 | ||
|
Binary file added
BIN
+170 Bytes
.bzr/repository/obsolete_packs/b9d5ec32c0d0633dd5814d84bcb5ac0d.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+165 Bytes
.bzr/repository/obsolete_packs/b9d5ec32c0d0633dd5814d84bcb5ac0d.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/b9d5ec32c0d0633dd5814d84bcb5ac0d.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file not shown.
Binary file added
BIN
+166 Bytes
.bzr/repository/obsolete_packs/c032e4444ba96431d36f13960a572ae1.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+163 Bytes
.bzr/repository/obsolete_packs/c032e4444ba96431d36f13960a572ae1.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/c032e4444ba96431d36f13960a572ae1.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file added
BIN
+632 Bytes
.bzr/repository/obsolete_packs/c032e4444ba96431d36f13960a572ae1.tix
Binary file not shown.
Binary file added
BIN
+176 Bytes
.bzr/repository/obsolete_packs/cf492219ec3088e2ac8bc5c8526c0157.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+172 Bytes
.bzr/repository/obsolete_packs/cf492219ec3088e2ac8bc5c8526c0157.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/cf492219ec3088e2ac8bc5c8526c0157.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file not shown.
Binary file added
BIN
+167 Bytes
.bzr/repository/obsolete_packs/dff91be33810630a1903a9af050d79df.iix
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+163 Bytes
.bzr/repository/obsolete_packs/dff91be33810630a1903a9af050d79df.rix
Binary file not shown.
5 changes: 5 additions & 0 deletions
5
.bzr/repository/obsolete_packs/dff91be33810630a1903a9af050d79df.six
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Bazaar Graph Index 1 | ||
node_ref_lists=0 | ||
key_elements=1 | ||
len=0 | ||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
function getparam(key, d) { | ||
var value = window.location.href.match(new RegExp("[?&]"+key+"=([^&#]*)")); | ||
return value ? value[1] : d; | ||
} | ||
|
||
$(function(){ | ||
$('head').append($( | ||
'<link type="text/css" href="css/' + getparam("skin", "ui-darkness") +'/jquery-ui-1.7.2.custom.css" rel="stylesheet" />' + | ||
'<script type="text/javascript" src="pages/' + getparam("page", "index") +'.js"></script>' | ||
)); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
|
||
run File.new('.') |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Large diffs are not rendered by default.
Oops, something went wrong.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
|
||
(function($){function toIntegersAtLease(n) | ||
{return n<10?'0'+n:n;} | ||
Date.prototype.toJSON=function(date) | ||
{return this.getUTCFullYear()+'-'+ | ||
toIntegersAtLease(this.getUTCMonth())+'-'+ | ||
toIntegersAtLease(this.getUTCDate());};var escapeable=/["\\\x00-\x1f\x7f-\x9f]/g;var meta={'\b':'\\b','\t':'\\t','\n':'\\n','\f':'\\f','\r':'\\r','"':'\\"','\\':'\\\\'};$.quoteString=function(string) | ||
{if(escapeable.test(string)) | ||
{return'"'+string.replace(escapeable,function(a) | ||
{var c=meta[a];if(typeof c==='string'){return c;} | ||
c=a.charCodeAt();return'\\u00'+Math.floor(c/16).toString(16)+(c%16).toString(16);})+'"';} | ||
return'"'+string+'"';};$.toJSON=function(o,compact) | ||
{var type=typeof(o);if(type=="undefined") | ||
return"undefined";else if(type=="number"||type=="boolean") | ||
return o+"";else if(o===null) | ||
return"null";if(type=="string") | ||
{return $.quoteString(o);} | ||
if(type=="object"&&typeof o.toJSON=="function") | ||
return o.toJSON(compact);if(type!="function"&&typeof(o.length)=="number") | ||
{var ret=[];for(var i=0;i<o.length;i++){ret.push($.toJSON(o[i],compact));} | ||
if(compact) | ||
return"["+ret.join(",")+"]";else | ||
return"["+ret.join(", ")+"]";} | ||
if(type=="function"){throw new TypeError("Unable to convert object of type 'function' to json.");} | ||
var ret=[];for(var k in o){var name;type=typeof(k);if(type=="number") | ||
name='"'+k+'"';else if(type=="string") | ||
name=$.quoteString(k);else | ||
continue;var val=$.toJSON(o[k],compact);if(typeof(val)!="string"){continue;} | ||
if(compact) | ||
ret.push(name+":"+val);else | ||
ret.push(name+": "+val);} | ||
return"{"+ret.join(", ")+"}";};$.compactJSON=function(o) | ||
{return $.toJSON(o,true);};$.evalJSON=function(src) | ||
{return eval("("+src+")");};$.secureEvalJSON=function(src) | ||
{var filtered=src;filtered=filtered.replace(/\\["\\\/bfnrtu]/g,'@');filtered=filtered.replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,']');filtered=filtered.replace(/(?:^|:|,)(?:\s*\[)+/g,'');if(/^[\],:{}\s]*$/.test(filtered)) | ||
return eval("("+src+")");else | ||
throw new SyntaxError("Error parsing JSON, source is not valid.");};})(jQuery); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,214 @@ | ||
// requires jquery-ui | ||
|
||
// Test an object for it's constructor type. Sort of a reverse, discriminatory instanceof | ||
function isTypeOf(t, c){ if (t === undefined) {return 'undefined';} return t.constructor.toString().match(new RegExp(c, 'i')) !== null; } | ||
|
||
|
||
function each(obj, fn) | ||
{ | ||
if (isTypeOf(obj, "Array")) | ||
{ | ||
for (i in obj) { | ||
fn(i, obj[i]); | ||
} | ||
} | ||
else { | ||
for (var k in obj) { | ||
if (obj.hasOwnProperty(k)) { | ||
fn(k, obj[k]); | ||
} | ||
} | ||
} | ||
return obj; | ||
} | ||
|
||
function trace(message, obj) | ||
{ | ||
console.log(message, obj); | ||
return obj; | ||
} | ||
|
||
function collect(obj, fn) | ||
{ | ||
var accum = []; | ||
each(obj, function(i,v){ accum.push(fn(i,v)); }); | ||
return accum; | ||
} | ||
|
||
function inspect(data, limit) { | ||
if (limit === undefined) { | ||
limit = 5; | ||
} | ||
if (limit <= 0) {return "...";} | ||
if (isTypeOf(data, "Array")) { | ||
var accum = ["ul"]; | ||
each(data, function(k,v){ accum.push(["li", inspect(v, limit-1)]); }); | ||
return accum; | ||
} | ||
else if (isTypeOf(data, "String")) { | ||
return '"'+data.replace(/\"/g,'\\"').replace(/\t/g,'\\t').replace(/\n/g,'\\n')+'"'; | ||
} | ||
else if (isTypeOf(data, "Object")) { | ||
var accum = ["dl"]; | ||
each(data, function(k,v){ | ||
accum.push(["dt", k+":"]); | ||
accum.push(["dd", inspect(v, limit-1)]); | ||
}); | ||
return accum; | ||
} | ||
else { | ||
return data+""; | ||
} | ||
} | ||
|
||
|
||
function small_header(options, content) | ||
{ | ||
return ["p.ui-state-default ui-corner-all", { | ||
style: "padding:4px;margin: 10px 0" | ||
}, | ||
["span.ui-icon.ui-icon-" + options.icon, {style: "float:left; margin:-2px 5px 0 0;" }], | ||
content | ||
]; | ||
} | ||
|
||
function button(options, content) | ||
{ | ||
return ["button.ui-state-default ui-button ui-corner-all", { | ||
style:"float: left; margin: 0 5px; line-height:13px;", | ||
$:{bind:["click", options.callback]} | ||
}, | ||
["span.ui-icon.ui-icon-" + options.icon, {style: "float:left; margin:-2px 3px -2px -2px;" }], | ||
content | ||
]; | ||
} | ||
|
||
// Options: | ||
// | ||
// title - the title of the dialoc | ||
// callback - a function called with true or false | ||
// | ||
function confirmation_dialog(options, content) | ||
{ | ||
return ["div", { | ||
title: options.title, | ||
$:{dialog: [{ | ||
bgiframe: true, | ||
resizable: false, | ||
modal: true, | ||
buttons: { | ||
Ok: function() { | ||
jQuery(this).dialog('close'); | ||
options.callback(true); | ||
}, | ||
Cancel: function() { | ||
jQuery(this).dialog('close'); | ||
options.callback(false); | ||
} | ||
}, | ||
close: function() { | ||
$(this).remove(); | ||
} | ||
}]} | ||
}, ["p", | ||
["span.ui-icon ui-icon-alert", {style:"float:left; margin:0 7px 20px 0;"}], | ||
content | ||
] | ||
]; | ||
} | ||
|
||
|
||
// Options: | ||
// | ||
// title - dialog title | ||
// w - dialog width | ||
// h - dialog content height | ||
function inline_dialog(options, content) | ||
{ | ||
return ["div", { | ||
title: options.title, | ||
$:{dialog: [{ | ||
bgiframe: true, | ||
height: 29+options.h, | ||
width: options.w, | ||
modal: true, | ||
resizable: true, | ||
close: function(e){ | ||
$(this).remove(); | ||
if (options.close) { | ||
options.close(e); | ||
} | ||
} | ||
}]} | ||
}, | ||
content | ||
]; | ||
} | ||
|
||
// Meta example: | ||
// { | ||
// name: {type:"text"}, | ||
// description: {type:"textarea",title:"Long Description"} | ||
// } | ||
// Data is reference to actual data store. | ||
function form_builder(meta, data, notify) | ||
{ | ||
var disabled; | ||
if (notify === undefined) | ||
{ | ||
disabled = true; | ||
notify = function(){}; | ||
} | ||
return collect(meta, function(name, options) { | ||
if (!options.label) { | ||
options.label = name.charAt(0).toUpperCase() + name.substr(1).toLowerCase(); | ||
} | ||
var content; | ||
switch (options.type) { | ||
case "textarea": | ||
content = ["textarea.ui-widget-content ui-corner-all", { | ||
style:"width:250px;padding:5px;margin:2px 15px;height:100px", | ||
name:name, | ||
$:{ | ||
bind:["keyup", function(e){data[name]=this.value;notify(name);}], | ||
$: function() { if (disabled){this.attr("disabled", "disabled").addClass('ui-state-disabled');} } | ||
} | ||
}, data[name]]; | ||
break; | ||
case "slider": | ||
content = ["div", {style: "width:260px; margin:15px;", $:{ | ||
slider: [{ | ||
value: data[name], | ||
change: function(event, ui) { data[name] = ui.value;notify(name); }, | ||
}], | ||
$: function() { if (disabled){this.slider('disable');} } | ||
}}]; | ||
break; | ||
case "eq": | ||
content = [".clearfix", collect(data[name], function(i,v){ | ||
return ["div", {_: {height: "120px", "float": "left", margin: "15px"}, $:{ | ||
slider: [{ | ||
value: v, | ||
range:"min", | ||
orientation:"vertical", | ||
change: function(event, ui) { data[name][i] = ui.value;notify(name); } | ||
}], | ||
$: function() { if (disabled){this.slider('disable');} } | ||
}} | ||
]; | ||
})]; | ||
break; | ||
default: | ||
content = ["input.ui-widget-content ui-corner-all", { | ||
style:"padding:5px;width:250px;margin:2px 15px", | ||
name:name, | ||
value:data[name], | ||
$:{ | ||
bind:["keyup", function(e){data[name] = this.value;notify(name);}], | ||
$: function() { if (disabled){this.attr("disabled", "disabled").addClass('ui-state-disabled');} } | ||
}}]; | ||
break; | ||
} | ||
return [["p", {style:"font-weight:bold;"}, options.label], content]; | ||
}); | ||
} |
Oops, something went wrong.