old_sql 1.16.0 → 1.17.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (273) hide show
  1. data/README.md +24 -13
  2. data/app/controllers/old_sql/report_controller.rb +3 -17
  3. data/app/views/layouts/old_sql/chart.html.erb +11 -0
  4. data/app/views/old_sql/report/chart.html.erb +8 -25
  5. data/lib/generators/old_sql/templates/user_design_template.csv +2 -3
  6. data/lib/generators/old_sql/templates/user_old_sql_demo_chart_design.yml +18 -9
  7. data/lib/old_sql/report_design/chart.rb +2 -2
  8. data/lib/old_sql/report_design/chart_item.rb +4 -4
  9. data/lib/old_sql/report_design/chart_parser.rb +2 -2
  10. data/public/javascripts/old_sql/chart.js +33 -0
  11. metadata +5 -265
  12. data/public/javascripts/old_sql/MochiKit-1.4.2/Changes +0 -362
  13. data/public/javascripts/old_sql/MochiKit-1.4.2/LICENSE.txt +0 -69
  14. data/public/javascripts/old_sql/MochiKit-1.4.2/MANIFEST +0 -179
  15. data/public/javascripts/old_sql/MochiKit-1.4.2/META.json +0 -17
  16. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Async.html +0 -814
  17. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Base.html +0 -1703
  18. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Color.html +0 -755
  19. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/DOM.html +0 -1197
  20. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/DateTime.html +0 -168
  21. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/DragAndDrop.html +0 -187
  22. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Format.html +0 -300
  23. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Iter.html +0 -524
  24. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Logging.html +0 -420
  25. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/LoggingPane.html +0 -142
  26. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Position.html +0 -38
  27. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Selector.html +0 -240
  28. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Signal.html +0 -508
  29. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Sortable.html +0 -244
  30. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Style.html +0 -385
  31. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/VersionHistory.html +0 -384
  32. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/Visual.html +0 -1161
  33. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/html/MochiKit/index.html +0 -447
  34. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/js/toc.js +0 -113
  35. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Async.rst +0 -767
  36. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Base.rst +0 -1445
  37. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Color.rst +0 -651
  38. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/DOM.rst +0 -1143
  39. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/DateTime.rst +0 -145
  40. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/DragAndDrop.rst +0 -197
  41. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Format.rst +0 -258
  42. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Iter.rst +0 -454
  43. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Logging.rst +0 -348
  44. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/LoggingPane.rst +0 -128
  45. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Position.rst +0 -26
  46. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Selector.rst +0 -203
  47. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Signal.rst +0 -498
  48. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Sortable.rst +0 -186
  49. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Style.rst +0 -353
  50. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/VersionHistory.rst +0 -362
  51. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/Visual.rst +0 -895
  52. data/public/javascripts/old_sql/MochiKit-1.4.2/doc/rst/MochiKit/index.rst +0 -83
  53. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/ajax_tables/ajax_tables.css +0 -69
  54. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/ajax_tables/ajax_tables.js +0 -401
  55. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/ajax_tables/domains.json +0 -10
  56. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/ajax_tables/domains.xml +0 -40
  57. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/ajax_tables/index.html +0 -96
  58. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/color_wheel/color_wheel.css +0 -4
  59. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/color_wheel/color_wheel.js +0 -95
  60. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/color_wheel/index.html +0 -31
  61. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/dnd_sortable.css +0 -23
  62. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/dropmarker.png +0 -0
  63. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/icon.png +0 -0
  64. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/index.html +0 -54
  65. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/sortable2_test.html +0 -150
  66. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/sortable3_test.html +0 -42
  67. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/sortable4_test.html +0 -90
  68. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/sortable5_test.html +0 -29
  69. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/sortable_test.html +0 -38
  70. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/dnd_sortable/sortable_tree_test.html +0 -189
  71. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/draggable/draggable.css +0 -28
  72. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/draggable/draggable.js +0 -73
  73. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/draggable/index.html +0 -38
  74. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_bigslide.html +0 -36
  75. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_blind.html +0 -65
  76. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_blindslide.html +0 -31
  77. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_combi.css +0 -18
  78. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_fadeappear.html +0 -61
  79. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_grow_shrink.html +0 -38
  80. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_onload.html +0 -67
  81. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_queue.html +0 -67
  82. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_queue_limit.html +0 -30
  83. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_scroll.html +0 -483
  84. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/effects_slide.html +0 -62
  85. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/full.html +0 -71
  86. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/icon.png +0 -0
  87. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/effects/index.html +0 -150
  88. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/interpreter/index.html +0 -88
  89. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/interpreter/interpreter.css +0 -54
  90. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/interpreter/interpreter.js +0 -373
  91. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/key_events/index.html +0 -78
  92. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/key_events/key_events.css +0 -5
  93. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/key_events/key_events.js +0 -85
  94. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/logging_pane/index.html +0 -46
  95. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/logging_pane/logging_pane.css +0 -78
  96. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/logging_pane/logging_pane.js +0 -11
  97. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/mochiregexp/index.html +0 -74
  98. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/mochiregexp/mochiregexp.css +0 -73
  99. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/mochiregexp/mochiregexp.js +0 -125
  100. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/mouse_events/index.html +0 -88
  101. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/mouse_events/mouse_events.css +0 -17
  102. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/mouse_events/mouse_events.js +0 -59
  103. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/rounded_corners/index.html +0 -28
  104. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/rounded_corners/rounded_corners.css +0 -3
  105. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/rounded_corners/rounded_corners.js +0 -19
  106. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/simple_dnd/dnd_boxes.html +0 -45
  107. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/simple_dnd/dnd_full.html +0 -119
  108. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/simple_dnd/dnd_ghost.html +0 -40
  109. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/simple_dnd/dnd_hoverclass.html +0 -43
  110. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/simple_dnd/dnd_scroll.html +0 -91
  111. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/simple_dnd/dnd_snap.html +0 -54
  112. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/simple_dnd/index.html +0 -93
  113. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/simple_dnd/simple_dnd.css +0 -64
  114. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/sortable_tables/index.html +0 -71
  115. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/sortable_tables/sortable_tables.css +0 -66
  116. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/sortable_tables/sortable_tables.js +0 -203
  117. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/SyntaxHighlighter.css +0 -177
  118. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/Tests.html +0 -339
  119. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shBrushCSharp.js +0 -30
  120. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shBrushDelphi.js +0 -31
  121. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shBrushJScript.js +0 -22
  122. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shBrushPhp.js +0 -23
  123. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shBrushPython.js +0 -71
  124. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shBrushSql.js +0 -40
  125. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shBrushVb.js +0 -29
  126. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shBrushXml.js +0 -61
  127. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/lib/SyntaxHighlighter/shCore.js +0 -622
  128. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/view-source.css +0 -1
  129. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/view-source.html +0 -19
  130. data/public/javascripts/old_sql/MochiKit-1.4.2/examples/view-source/view-source.js +0 -70
  131. data/public/javascripts/old_sql/MochiKit-1.4.2/include/_img/bg_docheader.gif +0 -0
  132. data/public/javascripts/old_sql/MochiKit-1.4.2/include/_img/g_bullet.gif +0 -0
  133. data/public/javascripts/old_sql/MochiKit-1.4.2/include/_img/g_logo_doc.gif +0 -0
  134. data/public/javascripts/old_sql/MochiKit-1.4.2/include/css/documentation.css +0 -130
  135. data/public/javascripts/old_sql/MochiKit-1.4.2/include/css/general.css +0 -48
  136. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Async.js +0 -682
  137. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Base.js +0 -1489
  138. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Color.js +0 -863
  139. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/DOM.js +0 -1256
  140. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/DateTime.js +0 -222
  141. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/DragAndDrop.js +0 -793
  142. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Format.js +0 -304
  143. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Iter.js +0 -844
  144. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Logging.js +0 -315
  145. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/LoggingPane.js +0 -353
  146. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/MochiKit.js +0 -188
  147. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/MockDOM.js +0 -115
  148. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Position.js +0 -236
  149. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Selector.js +0 -415
  150. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Signal.js +0 -897
  151. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Sortable.js +0 -589
  152. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Style.js +0 -594
  153. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Test.js +0 -162
  154. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/Visual.js +0 -2026
  155. data/public/javascripts/old_sql/MochiKit-1.4.2/lib/MochiKit/__package__.js +0 -18
  156. data/public/javascripts/old_sql/MochiKit-1.4.2/packed/MochiKit/MochiKit.js +0 -7829
  157. data/public/javascripts/old_sql/MochiKit-1.4.2/packed/MochiKit/__package__.js +0 -6
  158. data/public/javascripts/old_sql/MochiKit-1.4.2/packed/MochiKit/customize.html +0 -251
  159. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/FakeJSAN.js +0 -40
  160. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/SimpleTest/SimpleTest.js +0 -381
  161. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/SimpleTest/TestRunner.js +0 -159
  162. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/SimpleTest/test.css +0 -28
  163. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/cli.js +0 -6
  164. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/index.html +0 -25
  165. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/standalone.js +0 -16
  166. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_Base.js +0 -577
  167. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_Color.js +0 -137
  168. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_DateTime.js +0 -52
  169. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_DragAndDrop.js +0 -30
  170. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_Format.js +0 -89
  171. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_Iter.js +0 -186
  172. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_Logging.js +0 -88
  173. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Async.html +0 -408
  174. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Async.json +0 -1
  175. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Base.html +0 -34
  176. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Color.html +0 -84
  177. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-DOM-Safari.html +0 -48
  178. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-DOM.html +0 -363
  179. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-DateTime.html +0 -39
  180. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-DragAndDrop.html +0 -54
  181. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Format.html +0 -39
  182. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Iter.html +0 -38
  183. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-JSAN.html +0 -32
  184. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Logging.html +0 -40
  185. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-MochiKit.html +0 -18
  186. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Selector.html +0 -295
  187. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Signal.html +0 -43
  188. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Style.html +0 -223
  189. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_MochiKit-Visual.html +0 -197
  190. data/public/javascripts/old_sql/MochiKit-1.4.2/tests/test_Signal.js +0 -481
  191. data/public/javascripts/old_sql/plotkit-0.9.1/COPYING +0 -28
  192. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/Base.js +0 -406
  193. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/Canvas.js +0 -683
  194. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/EasyPlot.js +0 -161
  195. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/Layout.js +0 -756
  196. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/PlotKit.js +0 -151
  197. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/PlotKit_Packed.js +0 -2177
  198. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/SVG.js +0 -705
  199. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/SweetCanvas.js +0 -348
  200. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/SweetSVG.js +0 -247
  201. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/dummy.svg +0 -9
  202. data/public/javascripts/old_sql/plotkit-0.9.1/PlotKit/excanvas.js +0 -723
  203. data/public/javascripts/old_sql/plotkit-0.9.1/README +0 -1
  204. data/public/javascripts/old_sql/plotkit-0.9.1/doc/MochiKitAdditions.html +0 -2
  205. data/public/javascripts/old_sql/plotkit-0.9.1/doc/MochiKitAdditions.txt +0 -2
  206. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.Base.html +0 -302
  207. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.Base.txt +0 -139
  208. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.Canvas.html +0 -172
  209. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.Canvas.txt +0 -81
  210. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.EasyPlot.html +0 -155
  211. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.EasyPlot.txt +0 -50
  212. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.Layout.html +0 -428
  213. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.Layout.txt +0 -330
  214. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.QuickStart.html +0 -368
  215. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.QuickStart.txt +0 -256
  216. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.Renderer.html +0 -436
  217. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.Renderer.txt +0 -299
  218. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.SVG.html +0 -159
  219. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.SVG.txt +0 -64
  220. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.SweetCanvas.html +0 -131
  221. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.SweetCanvas.txt +0 -34
  222. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.SweetSVG.html +0 -131
  223. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.SweetSVG.txt +0 -34
  224. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.html +0 -334
  225. data/public/javascripts/old_sql/plotkit-0.9.1/doc/PlotKit.txt +0 -151
  226. data/public/javascripts/old_sql/plotkit-0.9.1/doc/SVGCanvasCompat.html +0 -304
  227. data/public/javascripts/old_sql/plotkit-0.9.1/doc/SVGCanvasCompat.txt +0 -144
  228. data/public/javascripts/old_sql/plotkit-0.9.1/doc/barsample.png +0 -0
  229. data/public/javascripts/old_sql/plotkit-0.9.1/doc/black.png +0 -0
  230. data/public/javascripts/old_sql/plotkit-0.9.1/doc/blue.png +0 -0
  231. data/public/javascripts/old_sql/plotkit-0.9.1/doc/cyan.png +0 -0
  232. data/public/javascripts/old_sql/plotkit-0.9.1/doc/doc.css +0 -62
  233. data/public/javascripts/old_sql/plotkit-0.9.1/doc/generate.py +0 -37
  234. data/public/javascripts/old_sql/plotkit-0.9.1/doc/green.png +0 -0
  235. data/public/javascripts/old_sql/plotkit-0.9.1/doc/orange.png +0 -0
  236. data/public/javascripts/old_sql/plotkit-0.9.1/doc/piesample.png +0 -0
  237. data/public/javascripts/old_sql/plotkit-0.9.1/doc/purple.png +0 -0
  238. data/public/javascripts/old_sql/plotkit-0.9.1/doc/red.png +0 -0
  239. data/public/javascripts/old_sql/plotkit-0.9.1/scripts/custom_rhino.jar +0 -0
  240. data/public/javascripts/old_sql/plotkit-0.9.1/scripts/pack.py +0 -58
  241. data/public/javascripts/old_sql/plotkit-0.9.1/tests/axis.html +0 -31
  242. data/public/javascripts/old_sql/plotkit-0.9.1/tests/basic.html +0 -25
  243. data/public/javascripts/old_sql/plotkit-0.9.1/tests/basic.js +0 -143
  244. data/public/javascripts/old_sql/plotkit-0.9.1/tests/debug.html +0 -56
  245. data/public/javascripts/old_sql/plotkit-0.9.1/tests/demo-svg.html +0 -58
  246. data/public/javascripts/old_sql/plotkit-0.9.1/tests/demo-svg.js +0 -133
  247. data/public/javascripts/old_sql/plotkit-0.9.1/tests/demo.html +0 -57
  248. data/public/javascripts/old_sql/plotkit-0.9.1/tests/demo.js +0 -136
  249. data/public/javascripts/old_sql/plotkit-0.9.1/tests/dynamic.html +0 -161
  250. data/public/javascripts/old_sql/plotkit-0.9.1/tests/img/firefox.png +0 -0
  251. data/public/javascripts/old_sql/plotkit-0.9.1/tests/img/konqueror.png +0 -0
  252. data/public/javascripts/old_sql/plotkit-0.9.1/tests/img/mozilla.ico +0 -0
  253. data/public/javascripts/old_sql/plotkit-0.9.1/tests/img/msie.gif +0 -0
  254. data/public/javascripts/old_sql/plotkit-0.9.1/tests/img/opera.ico +0 -0
  255. data/public/javascripts/old_sql/plotkit-0.9.1/tests/img/safari.gif +0 -0
  256. data/public/javascripts/old_sql/plotkit-0.9.1/tests/labels-img.html +0 -38
  257. data/public/javascripts/old_sql/plotkit-0.9.1/tests/labels.html +0 -43
  258. data/public/javascripts/old_sql/plotkit-0.9.1/tests/prototype_compat.html +0 -28
  259. data/public/javascripts/old_sql/plotkit-0.9.1/tests/quickstart-easy.html +0 -29
  260. data/public/javascripts/old_sql/plotkit-0.9.1/tests/quickstart-horiz.html +0 -53
  261. data/public/javascripts/old_sql/plotkit-0.9.1/tests/quickstart-neg.html +0 -29
  262. data/public/javascripts/old_sql/plotkit-0.9.1/tests/quickstart-svg.html +0 -61
  263. data/public/javascripts/old_sql/plotkit-0.9.1/tests/quickstart.html +0 -57
  264. data/public/javascripts/old_sql/plotkit-0.9.1/tests/sample.txt +0 -6
  265. data/public/javascripts/old_sql/plotkit-0.9.1/tests/svg-sweet.html +0 -29
  266. data/public/javascripts/old_sql/plotkit-0.9.1/tests/svg-sweet.js +0 -141
  267. data/public/javascripts/old_sql/plotkit-0.9.1/tests/svg.html +0 -26
  268. data/public/javascripts/old_sql/plotkit-0.9.1/tests/svg.js +0 -147
  269. data/public/javascripts/old_sql/plotkit-0.9.1/tests/sweet.html +0 -24
  270. data/public/javascripts/old_sql/plotkit-0.9.1/tests/sweet.js +0 -89
  271. data/public/javascripts/old_sql/plotkit-0.9.1/tests/tests.css +0 -66
  272. data/public/javascripts/old_sql/plotkit-0.9.1/tests/testsvg.html +0 -20
  273. data/public/javascripts/old_sql/plotkit-0.9.1/tests/testsvg.js +0 -31
@@ -1 +0,0 @@
1
- .invisible {display: none;}
@@ -1,19 +0,0 @@
1
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
- <html>
3
- <head>
4
- <title>MochiKit Example Source Viewer</title>
5
- <script type="text/javascript" src="../../lib/MochiKit/MochiKit.js"></script>
6
- <link href="view-source.css" rel="stylesheet" type="text/css" />
7
- <link href="lib/SyntaxHighlighter/SyntaxHighlighter.css" rel="stylesheet" type="text/css" />
8
- <script type="text/javascript" src="view-source.js"></script>
9
- <script type="text/javascript" src="lib/SyntaxHighlighter/shCore.js"></script>
10
- <script type="text/javascript" src="lib/SyntaxHighlighter/shBrushJScript.js"></script>
11
- <script type="text/javascript" src="lib/SyntaxHighlighter/shBrushXml.js"></script>
12
- </head>
13
- <body onload="viewSource();">
14
- <h3 id="filename"></h3>
15
- <div id="codeview" class="invisible">
16
- <textarea name="code" id="code"></textarea>
17
- </div>
18
- </body>
19
- </html>
@@ -1,70 +0,0 @@
1
- /*
2
-
3
- Do syntax highlighting on every textarea inside of a "codeview" element
4
-
5
- The content of textareas are URLs, not code!
6
-
7
- */
8
- var viewSource = function () {
9
- var filename = location.hash;
10
- if (!filename) {
11
- filename = location.hash = "view-source/view-source.js";
12
- }
13
- filename = lstrip(filename, "#");
14
- var href = "../" + filename;
15
- replaceChildNodes("filename", "loading ", A({"href": href}, filename));
16
- replaceChildNodes("code", href);
17
- ext = filename.split(".").pop();
18
- var classes = {
19
- "html": "xml",
20
- "js": "javascript",
21
- "json": "javascript",
22
- "xml": "xml"
23
- };
24
- updateNodeAttributes("code", {"class": classes[ext]});
25
- syntaxHighlight(filename);
26
- };
27
-
28
- var syntaxHighlight = function (filename) {
29
- var swapContents = function (dest, req) {
30
- replaceChildNodes(dest, req.responseText);
31
- };
32
-
33
- var showParsing = function () {
34
- replaceChildNodes("filename",
35
- "parsing ",
36
- A({"href": "../" + filename}, filename)
37
- );
38
- return wait(0);
39
- };
40
-
41
- var finishSyntaxHighlight = function () {
42
- dp.sh.HighlightAll("code", true, true, false);
43
- replaceChildNodes("filename", A({"href": "../" + filename}, filename));
44
- removeElementClass("codeview", "invisible");
45
- };
46
-
47
- var elems = getElementsByTagAndClassName("textarea", null, "codeview");
48
- var dl = new Deferred();
49
- var deferredCount = 0;
50
- var checkDeferredList = function () {
51
- deferredCount -= 1;
52
- if (!deferredCount) {
53
- dl.callback();
54
- }
55
- };
56
- for (var i = 0; i < elems.length; i++) {
57
- var elem = elems[i];
58
- if (elem.name != "code") {
59
- continue;
60
- }
61
- var url = strip(scrapeText(elem))
62
- var d = doXHR(url).addCallback(
63
- partial(swapContents, elem)
64
- );
65
- deferredCount += 1;
66
- d.addCallback(checkDeferredList);
67
- }
68
- dl.addCallback(showParsing);
69
- dl.addCallback(finishSyntaxHighlight);
70
- };
@@ -1,130 +0,0 @@
1
- /**************************
2
- **** GENERAL ****
3
- ***************************/
4
- body {
5
- font-size: 76%;
6
- color: #5C5D5F;
7
- margin: 0;
8
- font-family: Verdana, Helvetica, sans-serif;
9
- background: url("../_img/bg_docheader.gif") repeat-x;
10
- }
11
-
12
- /* ---- TYPOGRAPHY ----------------------*/
13
-
14
- h1, h2, h3, h4, h5, h6 {
15
- margin: 0;
16
- color: #8ba726;
17
- font-family: Trebuchet MS, verdana, sans-serif;
18
- }
19
-
20
- h1 { font-size: 2em; margin-bottom: .5em; border-bottom: 1px dotted #aaaaaa; }
21
-
22
- h1 em { color: #8ba726; font-style: normal; background: none; }
23
-
24
- h1 a { color: #8ba726; }
25
- h1 a:hover { background: none; border: none; color: #8ba726; }
26
-
27
-
28
- h2 { font-size: 1.4em; margin-bottom: .3em; font-weight: normal; }
29
- h3 { font-size: 1.2em; }
30
- h4 { font-size: 1.1em; font-family: Verdana, Helvetica, sans-serif; }
31
-
32
- a { color: #8ba726; }
33
- a:hover {
34
- text-decoration: none;
35
- background: #faffe9;
36
- padding: .1;
37
- border-bottom: 1px dotted #8ba726;
38
- }
39
- a.email {
40
- background: url(../../images/icon_email.gif) no-repeat left center;
41
- padding-left: 15px;
42
- }
43
- p a { font-weight: bold; }
44
- p { line-height: 1.5em; margin: 0em 0em 1em; color: #5C5D5F; }
45
- em { font-weight: bold; background-color: transparent; }
46
-
47
- ul, ol { line-height: 1.5em; }
48
- ul { list-style: none; margin: 0em 0em 1em 1.8em; padding: 0; }
49
-
50
-
51
- dl { }
52
- dt { font-weight: bold; margin-bottom: .2em; color: #4B4545; }
53
- dd { margin-left: 2em; margin-bottom: 2em; }
54
- tt { font-size: 120%; }
55
-
56
- strong { color: #4b81bc; font-weight: bold; }
57
- .weak { font-size: .9em; font-weight: normal; }
58
- .contextual { font-size: .9em; color: #888; }
59
-
60
- #mainlink {
61
- margin-top: 34px;
62
- margin-left: 20px;
63
- }
64
-
65
- a.indexlink {
66
- float: right;
67
- font-size: 1.5em;
68
- margin-right: 2em;
69
- }
70
-
71
- div.document {
72
- margin: 0em 20px 1em;
73
- padding-top: 20px;
74
- padding-left: 10px;
75
- }
76
- div.section { margin-bottom: 2em; }
77
-
78
-
79
- a.footnote-reference {
80
- vertical-align: super;
81
- font-size: 50%;
82
- text-decoration: none;
83
- }
84
-
85
- pre.literal-block {
86
- padding: 5px;
87
- font-size: 120%;
88
- color: #1C1D1F;
89
- background: #f3f3f3;
90
- padding: 1em 2em;
91
- border-left: 3px solid #ccc;
92
- }
93
-
94
- ul.simple { list-style: none; margin: 0em 0em 1em 1.3em; padding: 0; }
95
- ul.simple li {
96
- background: url("../_img/g_bullet.gif") no-repeat left .5em;
97
- padding-left: 12px;
98
- }
99
-
100
- tt { color: #1C1D1F; }
101
- table { border: 0px; }
102
- table th { border: 0px; border-bottom: 1px solid #aaaaaa; }
103
- table td { border: 0px; }
104
- table th, table td { padding: 3px; }
105
-
106
- .img {
107
- letter-spacing: -1000em;
108
- text-indent : -999em;
109
- overflow: hidden;
110
- display: block;
111
- background-repeat: repeat;
112
- background-color: transparent;
113
- /* IE FLICKER FIX - no background position! */
114
- }
115
- /* Just for Opera, but hide from MacIE */
116
- /*\*/html>body .img { letter-spacing : normal; text-indent : -999em; overflow : hidden;}
117
- /* End of hack */
118
-
119
-
120
- /* ---- GENERAL ELEMENTS ----------------*/
121
-
122
- hr {
123
- border: none;
124
- border-bottom: 1px solid #aaa;
125
- background: none;
126
- height: 1px;
127
- }
128
- a img { border: none; text-decoration: none; }
129
- .clear { clear: both; }
130
- .invisible { display: none; }
@@ -1,48 +0,0 @@
1
- body { font-size: 76%; color: #5C5D5F; margin: 0; font-family: Verdana, Helvetica, sans-serif; }
2
-
3
- /* ---- TYPOGRAPHY ----------------------*/
4
-
5
- h1, h2, h3, h4, h5, h6 { margin: 0; color: #4B81BC; font-family: Trebuchet MS, verdana, sans-serif; }
6
- h1 { font-size: 2em; margin-bottom: .5em; }
7
- h1 em { color: #00C5E8; font-style: normal; background: none; }
8
-
9
- h2 { font-size: 1.4em; margin-bottom: .3em; font-weight: normal; }
10
- h3 { font-size: 1.2em; }
11
- h4 { font-size: 1.1em; font-family: Verdana, Helvetica, sans-serif; }
12
-
13
- a { color: #4b81bc; }
14
- a:hover { color: #abd038; }
15
- a.email { background: url(../../images/icon_email.gif) no-repeat left center; padding-left: 15px; }
16
- p a { font-weight: bold; }
17
- p { line-height: 1.5em; margin: 0em 0em 1em; color: #5C5D5F; }
18
- em { font-style: normal; background-color: #FFFDD4; }
19
-
20
- ul, ol { line-height: 1.5em; }
21
- ul { list-style: none; margin: 0em 0em 1em 1.8em; padding: 0; }
22
-
23
- dl { }
24
- dt { font-weight: bold; margin-bottom: .2em; color: #4B4545; }
25
- dd { margin-left: 2em; margin-bottom: 2em; }
26
- tt { font-size: 120%; }
27
-
28
- strong { color: #4b81bc; font-weight: bold; }
29
- .weak { font-size: .9em; font-weight: normal; }
30
- .contextual { font-size: .9em; color: #888; }
31
-
32
-
33
- .img {
34
- letter-spacing: -1000em; text-indent : -999em; overflow: hidden; display: block;
35
- background-repeat: repeat; background-color: transparent; /* IE FLICKER FIX - no background position! */
36
- }
37
- /* Just for Opera, but hide from MacIE */
38
- /*\*/html>body .img { letter-spacing : normal; text-indent : -999em; overflow : hidden;}
39
- /* End of hack */
40
-
41
-
42
- /* ---- GENERAL ELEMENTS ----------------*/
43
-
44
- hr { border: none; border-bottom: 1px solid #aaa; background: none; height: 1px; }
45
- a img { border: none; }
46
- .clear { clear: both; }
47
-
48
- .invisible { display: none; }
@@ -1,682 +0,0 @@
1
- /***
2
-
3
- MochiKit.Async 1.4.2
4
-
5
- See <http://mochikit.com/> for documentation, downloads, license, etc.
6
-
7
- (c) 2005 Bob Ippolito. All rights Reserved.
8
-
9
- ***/
10
-
11
- MochiKit.Base._deps('Async', ['Base']);
12
-
13
- MochiKit.Async.NAME = "MochiKit.Async";
14
- MochiKit.Async.VERSION = "1.4.2";
15
- MochiKit.Async.__repr__ = function () {
16
- return "[" + this.NAME + " " + this.VERSION + "]";
17
- };
18
- MochiKit.Async.toString = function () {
19
- return this.__repr__();
20
- };
21
-
22
- /** @id MochiKit.Async.Deferred */
23
- MochiKit.Async.Deferred = function (/* optional */ canceller) {
24
- this.chain = [];
25
- this.id = this._nextId();
26
- this.fired = -1;
27
- this.paused = 0;
28
- this.results = [null, null];
29
- this.canceller = canceller;
30
- this.silentlyCancelled = false;
31
- this.chained = false;
32
- };
33
-
34
- MochiKit.Async.Deferred.prototype = {
35
- /** @id MochiKit.Async.Deferred.prototype.repr */
36
- repr: function () {
37
- var state;
38
- if (this.fired == -1) {
39
- state = 'unfired';
40
- } else if (this.fired === 0) {
41
- state = 'success';
42
- } else {
43
- state = 'error';
44
- }
45
- return 'Deferred(' + this.id + ', ' + state + ')';
46
- },
47
-
48
- toString: MochiKit.Base.forwardCall("repr"),
49
-
50
- _nextId: MochiKit.Base.counter(),
51
-
52
- /** @id MochiKit.Async.Deferred.prototype.cancel */
53
- cancel: function () {
54
- var self = MochiKit.Async;
55
- if (this.fired == -1) {
56
- if (this.canceller) {
57
- this.canceller(this);
58
- } else {
59
- this.silentlyCancelled = true;
60
- }
61
- if (this.fired == -1) {
62
- this.errback(new self.CancelledError(this));
63
- }
64
- } else if ((this.fired === 0) && (this.results[0] instanceof self.Deferred)) {
65
- this.results[0].cancel();
66
- }
67
- },
68
-
69
- _resback: function (res) {
70
- /***
71
-
72
- The primitive that means either callback or errback
73
-
74
- ***/
75
- this.fired = ((res instanceof Error) ? 1 : 0);
76
- this.results[this.fired] = res;
77
- this._fire();
78
- },
79
-
80
- _check: function () {
81
- if (this.fired != -1) {
82
- if (!this.silentlyCancelled) {
83
- throw new MochiKit.Async.AlreadyCalledError(this);
84
- }
85
- this.silentlyCancelled = false;
86
- return;
87
- }
88
- },
89
-
90
- /** @id MochiKit.Async.Deferred.prototype.callback */
91
- callback: function (res) {
92
- this._check();
93
- if (res instanceof MochiKit.Async.Deferred) {
94
- throw new Error("Deferred instances can only be chained if they are the result of a callback");
95
- }
96
- this._resback(res);
97
- },
98
-
99
- /** @id MochiKit.Async.Deferred.prototype.errback */
100
- errback: function (res) {
101
- this._check();
102
- var self = MochiKit.Async;
103
- if (res instanceof self.Deferred) {
104
- throw new Error("Deferred instances can only be chained if they are the result of a callback");
105
- }
106
- if (!(res instanceof Error)) {
107
- res = new self.GenericError(res);
108
- }
109
- this._resback(res);
110
- },
111
-
112
- /** @id MochiKit.Async.Deferred.prototype.addBoth */
113
- addBoth: function (fn) {
114
- if (arguments.length > 1) {
115
- fn = MochiKit.Base.partial.apply(null, arguments);
116
- }
117
- return this.addCallbacks(fn, fn);
118
- },
119
-
120
- /** @id MochiKit.Async.Deferred.prototype.addCallback */
121
- addCallback: function (fn) {
122
- if (arguments.length > 1) {
123
- fn = MochiKit.Base.partial.apply(null, arguments);
124
- }
125
- return this.addCallbacks(fn, null);
126
- },
127
-
128
- /** @id MochiKit.Async.Deferred.prototype.addErrback */
129
- addErrback: function (fn) {
130
- if (arguments.length > 1) {
131
- fn = MochiKit.Base.partial.apply(null, arguments);
132
- }
133
- return this.addCallbacks(null, fn);
134
- },
135
-
136
- /** @id MochiKit.Async.Deferred.prototype.addCallbacks */
137
- addCallbacks: function (cb, eb) {
138
- if (this.chained) {
139
- throw new Error("Chained Deferreds can not be re-used");
140
- }
141
- this.chain.push([cb, eb]);
142
- if (this.fired >= 0) {
143
- this._fire();
144
- }
145
- return this;
146
- },
147
-
148
- _fire: function () {
149
- /***
150
-
151
- Used internally to exhaust the callback sequence when a result
152
- is available.
153
-
154
- ***/
155
- var chain = this.chain;
156
- var fired = this.fired;
157
- var res = this.results[fired];
158
- var self = this;
159
- var cb = null;
160
- while (chain.length > 0 && this.paused === 0) {
161
- // Array
162
- var pair = chain.shift();
163
- var f = pair[fired];
164
- if (f === null) {
165
- continue;
166
- }
167
- try {
168
- res = f(res);
169
- fired = ((res instanceof Error) ? 1 : 0);
170
- if (res instanceof MochiKit.Async.Deferred) {
171
- cb = function (res) {
172
- self._resback(res);
173
- self.paused--;
174
- if ((self.paused === 0) && (self.fired >= 0)) {
175
- self._fire();
176
- }
177
- };
178
- this.paused++;
179
- }
180
- } catch (err) {
181
- fired = 1;
182
- if (!(err instanceof Error)) {
183
- err = new MochiKit.Async.GenericError(err);
184
- }
185
- res = err;
186
- }
187
- }
188
- this.fired = fired;
189
- this.results[fired] = res;
190
- if (cb && this.paused) {
191
- // this is for "tail recursion" in case the dependent deferred
192
- // is already fired
193
- res.addBoth(cb);
194
- res.chained = true;
195
- }
196
- }
197
- };
198
-
199
- MochiKit.Base.update(MochiKit.Async, {
200
- /** @id MochiKit.Async.evalJSONRequest */
201
- evalJSONRequest: function (req) {
202
- return MochiKit.Base.evalJSON(req.responseText);
203
- },
204
-
205
- /** @id MochiKit.Async.succeed */
206
- succeed: function (/* optional */result) {
207
- var d = new MochiKit.Async.Deferred();
208
- d.callback.apply(d, arguments);
209
- return d;
210
- },
211
-
212
- /** @id MochiKit.Async.fail */
213
- fail: function (/* optional */result) {
214
- var d = new MochiKit.Async.Deferred();
215
- d.errback.apply(d, arguments);
216
- return d;
217
- },
218
-
219
- /** @id MochiKit.Async.getXMLHttpRequest */
220
- getXMLHttpRequest: function () {
221
- var self = arguments.callee;
222
- if (!self.XMLHttpRequest) {
223
- var tryThese = [
224
- function () { return new XMLHttpRequest(); },
225
- function () { return new ActiveXObject('Msxml2.XMLHTTP'); },
226
- function () { return new ActiveXObject('Microsoft.XMLHTTP'); },
227
- function () { return new ActiveXObject('Msxml2.XMLHTTP.4.0'); },
228
- function () {
229
- throw new MochiKit.Async.BrowserComplianceError("Browser does not support XMLHttpRequest");
230
- }
231
- ];
232
- for (var i = 0; i < tryThese.length; i++) {
233
- var func = tryThese[i];
234
- try {
235
- self.XMLHttpRequest = func;
236
- return func();
237
- } catch (e) {
238
- // pass
239
- }
240
- }
241
- }
242
- return self.XMLHttpRequest();
243
- },
244
-
245
- _xhr_onreadystatechange: function (d) {
246
- // MochiKit.Logging.logDebug('this.readyState', this.readyState);
247
- var m = MochiKit.Base;
248
- if (this.readyState == 4) {
249
- // IE SUCKS
250
- try {
251
- this.onreadystatechange = null;
252
- } catch (e) {
253
- try {
254
- this.onreadystatechange = m.noop;
255
- } catch (e) {
256
- }
257
- }
258
- var status = null;
259
- try {
260
- status = this.status;
261
- if (!status && m.isNotEmpty(this.responseText)) {
262
- // 0 or undefined seems to mean cached or local
263
- status = 304;
264
- }
265
- } catch (e) {
266
- // pass
267
- // MochiKit.Logging.logDebug('error getting status?', repr(items(e)));
268
- }
269
- // 200 is OK, 201 is CREATED, 204 is NO CONTENT
270
- // 304 is NOT MODIFIED, 1223 is apparently a bug in IE
271
- if (status == 200 || status == 201 || status == 204 ||
272
- status == 304 || status == 1223) {
273
- d.callback(this);
274
- } else {
275
- var err = new MochiKit.Async.XMLHttpRequestError(this, "Request failed");
276
- if (err.number) {
277
- // XXX: This seems to happen on page change
278
- d.errback(err);
279
- } else {
280
- // XXX: this seems to happen when the server is unreachable
281
- d.errback(err);
282
- }
283
- }
284
- }
285
- },
286
-
287
- _xhr_canceller: function (req) {
288
- // IE SUCKS
289
- try {
290
- req.onreadystatechange = null;
291
- } catch (e) {
292
- try {
293
- req.onreadystatechange = MochiKit.Base.noop;
294
- } catch (e) {
295
- }
296
- }
297
- req.abort();
298
- },
299
-
300
-
301
- /** @id MochiKit.Async.sendXMLHttpRequest */
302
- sendXMLHttpRequest: function (req, /* optional */ sendContent) {
303
- if (typeof(sendContent) == "undefined" || sendContent === null) {
304
- sendContent = "";
305
- }
306
-
307
- var m = MochiKit.Base;
308
- var self = MochiKit.Async;
309
- var d = new self.Deferred(m.partial(self._xhr_canceller, req));
310
-
311
- try {
312
- req.onreadystatechange = m.bind(self._xhr_onreadystatechange,
313
- req, d);
314
- req.send(sendContent);
315
- } catch (e) {
316
- try {
317
- req.onreadystatechange = null;
318
- } catch (ignore) {
319
- // pass
320
- }
321
- d.errback(e);
322
- }
323
-
324
- return d;
325
-
326
- },
327
-
328
- /** @id MochiKit.Async.doXHR */
329
- doXHR: function (url, opts) {
330
- /*
331
- Work around a Firefox bug by dealing with XHR during
332
- the next event loop iteration. Maybe it's this one:
333
- https://bugzilla.mozilla.org/show_bug.cgi?id=249843
334
- */
335
- var self = MochiKit.Async;
336
- return self.callLater(0, self._doXHR, url, opts);
337
- },
338
-
339
- _doXHR: function (url, opts) {
340
- var m = MochiKit.Base;
341
- opts = m.update({
342
- method: 'GET',
343
- sendContent: ''
344
- /*
345
- queryString: undefined,
346
- username: undefined,
347
- password: undefined,
348
- headers: undefined,
349
- mimeType: undefined
350
- */
351
- }, opts);
352
- var self = MochiKit.Async;
353
- var req = self.getXMLHttpRequest();
354
- if (opts.queryString) {
355
- var qs = m.queryString(opts.queryString);
356
- if (qs) {
357
- url += "?" + qs;
358
- }
359
- }
360
- // Safari will send undefined:undefined, so we have to check.
361
- // We can't use apply, since the function is native.
362
- if ('username' in opts) {
363
- req.open(opts.method, url, true, opts.username, opts.password);
364
- } else {
365
- req.open(opts.method, url, true);
366
- }
367
- if (req.overrideMimeType && opts.mimeType) {
368
- req.overrideMimeType(opts.mimeType);
369
- }
370
- req.setRequestHeader("X-Requested-With", "XMLHttpRequest");
371
- if (opts.headers) {
372
- var headers = opts.headers;
373
- if (!m.isArrayLike(headers)) {
374
- headers = m.items(headers);
375
- }
376
- for (var i = 0; i < headers.length; i++) {
377
- var header = headers[i];
378
- var name = header[0];
379
- var value = header[1];
380
- req.setRequestHeader(name, value);
381
- }
382
- }
383
- return self.sendXMLHttpRequest(req, opts.sendContent);
384
- },
385
-
386
- _buildURL: function (url/*, ...*/) {
387
- if (arguments.length > 1) {
388
- var m = MochiKit.Base;
389
- var qs = m.queryString.apply(null, m.extend(null, arguments, 1));
390
- if (qs) {
391
- return url + "?" + qs;
392
- }
393
- }
394
- return url;
395
- },
396
-
397
- /** @id MochiKit.Async.doSimpleXMLHttpRequest */
398
- doSimpleXMLHttpRequest: function (url/*, ...*/) {
399
- var self = MochiKit.Async;
400
- url = self._buildURL.apply(self, arguments);
401
- return self.doXHR(url);
402
- },
403
-
404
- /** @id MochiKit.Async.loadJSONDoc */
405
- loadJSONDoc: function (url/*, ...*/) {
406
- var self = MochiKit.Async;
407
- url = self._buildURL.apply(self, arguments);
408
- var d = self.doXHR(url, {
409
- 'mimeType': 'text/plain',
410
- 'headers': [['Accept', 'application/json']]
411
- });
412
- d = d.addCallback(self.evalJSONRequest);
413
- return d;
414
- },
415
-
416
- /** @id MochiKit.Async.wait */
417
- wait: function (seconds, /* optional */value) {
418
- var d = new MochiKit.Async.Deferred();
419
- var m = MochiKit.Base;
420
- if (typeof(value) != 'undefined') {
421
- d.addCallback(function () { return value; });
422
- }
423
- var timeout = setTimeout(
424
- m.bind("callback", d),
425
- Math.floor(seconds * 1000));
426
- d.canceller = function () {
427
- try {
428
- clearTimeout(timeout);
429
- } catch (e) {
430
- // pass
431
- }
432
- };
433
- return d;
434
- },
435
-
436
- /** @id MochiKit.Async.callLater */
437
- callLater: function (seconds, func) {
438
- var m = MochiKit.Base;
439
- var pfunc = m.partial.apply(m, m.extend(null, arguments, 1));
440
- return MochiKit.Async.wait(seconds).addCallback(
441
- function (res) { return pfunc(); }
442
- );
443
- }
444
- });
445
-
446
-
447
- /** @id MochiKit.Async.DeferredLock */
448
- MochiKit.Async.DeferredLock = function () {
449
- this.waiting = [];
450
- this.locked = false;
451
- this.id = this._nextId();
452
- };
453
-
454
- MochiKit.Async.DeferredLock.prototype = {
455
- __class__: MochiKit.Async.DeferredLock,
456
- /** @id MochiKit.Async.DeferredLock.prototype.acquire */
457
- acquire: function () {
458
- var d = new MochiKit.Async.Deferred();
459
- if (this.locked) {
460
- this.waiting.push(d);
461
- } else {
462
- this.locked = true;
463
- d.callback(this);
464
- }
465
- return d;
466
- },
467
- /** @id MochiKit.Async.DeferredLock.prototype.release */
468
- release: function () {
469
- if (!this.locked) {
470
- throw TypeError("Tried to release an unlocked DeferredLock");
471
- }
472
- this.locked = false;
473
- if (this.waiting.length > 0) {
474
- this.locked = true;
475
- this.waiting.shift().callback(this);
476
- }
477
- },
478
- _nextId: MochiKit.Base.counter(),
479
- repr: function () {
480
- var state;
481
- if (this.locked) {
482
- state = 'locked, ' + this.waiting.length + ' waiting';
483
- } else {
484
- state = 'unlocked';
485
- }
486
- return 'DeferredLock(' + this.id + ', ' + state + ')';
487
- },
488
- toString: MochiKit.Base.forwardCall("repr")
489
-
490
- };
491
-
492
- /** @id MochiKit.Async.DeferredList */
493
- MochiKit.Async.DeferredList = function (list, /* optional */fireOnOneCallback, fireOnOneErrback, consumeErrors, canceller) {
494
-
495
- // call parent constructor
496
- MochiKit.Async.Deferred.apply(this, [canceller]);
497
-
498
- this.list = list;
499
- var resultList = [];
500
- this.resultList = resultList;
501
-
502
- this.finishedCount = 0;
503
- this.fireOnOneCallback = fireOnOneCallback;
504
- this.fireOnOneErrback = fireOnOneErrback;
505
- this.consumeErrors = consumeErrors;
506
-
507
- var cb = MochiKit.Base.bind(this._cbDeferred, this);
508
- for (var i = 0; i < list.length; i++) {
509
- var d = list[i];
510
- resultList.push(undefined);
511
- d.addCallback(cb, i, true);
512
- d.addErrback(cb, i, false);
513
- }
514
-
515
- if (list.length === 0 && !fireOnOneCallback) {
516
- this.callback(this.resultList);
517
- }
518
-
519
- };
520
-
521
- MochiKit.Async.DeferredList.prototype = new MochiKit.Async.Deferred();
522
-
523
- MochiKit.Async.DeferredList.prototype._cbDeferred = function (index, succeeded, result) {
524
- this.resultList[index] = [succeeded, result];
525
- this.finishedCount += 1;
526
- if (this.fired == -1) {
527
- if (succeeded && this.fireOnOneCallback) {
528
- this.callback([index, result]);
529
- } else if (!succeeded && this.fireOnOneErrback) {
530
- this.errback(result);
531
- } else if (this.finishedCount == this.list.length) {
532
- this.callback(this.resultList);
533
- }
534
- }
535
- if (!succeeded && this.consumeErrors) {
536
- result = null;
537
- }
538
- return result;
539
- };
540
-
541
- /** @id MochiKit.Async.gatherResults */
542
- MochiKit.Async.gatherResults = function (deferredList) {
543
- var d = new MochiKit.Async.DeferredList(deferredList, false, true, false);
544
- d.addCallback(function (results) {
545
- var ret = [];
546
- for (var i = 0; i < results.length; i++) {
547
- ret.push(results[i][1]);
548
- }
549
- return ret;
550
- });
551
- return d;
552
- };
553
-
554
- /** @id MochiKit.Async.maybeDeferred */
555
- MochiKit.Async.maybeDeferred = function (func) {
556
- var self = MochiKit.Async;
557
- var result;
558
- try {
559
- var r = func.apply(null, MochiKit.Base.extend([], arguments, 1));
560
- if (r instanceof self.Deferred) {
561
- result = r;
562
- } else if (r instanceof Error) {
563
- result = self.fail(r);
564
- } else {
565
- result = self.succeed(r);
566
- }
567
- } catch (e) {
568
- result = self.fail(e);
569
- }
570
- return result;
571
- };
572
-
573
-
574
- MochiKit.Async.EXPORT = [
575
- "AlreadyCalledError",
576
- "CancelledError",
577
- "BrowserComplianceError",
578
- "GenericError",
579
- "XMLHttpRequestError",
580
- "Deferred",
581
- "succeed",
582
- "fail",
583
- "getXMLHttpRequest",
584
- "doSimpleXMLHttpRequest",
585
- "loadJSONDoc",
586
- "wait",
587
- "callLater",
588
- "sendXMLHttpRequest",
589
- "DeferredLock",
590
- "DeferredList",
591
- "gatherResults",
592
- "maybeDeferred",
593
- "doXHR"
594
- ];
595
-
596
- MochiKit.Async.EXPORT_OK = [
597
- "evalJSONRequest"
598
- ];
599
-
600
- MochiKit.Async.__new__ = function () {
601
- var m = MochiKit.Base;
602
- var ne = m.partial(m._newNamedError, this);
603
-
604
- ne("AlreadyCalledError",
605
- /** @id MochiKit.Async.AlreadyCalledError */
606
- function (deferred) {
607
- /***
608
-
609
- Raised by the Deferred if callback or errback happens
610
- after it was already fired.
611
-
612
- ***/
613
- this.deferred = deferred;
614
- }
615
- );
616
-
617
- ne("CancelledError",
618
- /** @id MochiKit.Async.CancelledError */
619
- function (deferred) {
620
- /***
621
-
622
- Raised by the Deferred cancellation mechanism.
623
-
624
- ***/
625
- this.deferred = deferred;
626
- }
627
- );
628
-
629
- ne("BrowserComplianceError",
630
- /** @id MochiKit.Async.BrowserComplianceError */
631
- function (msg) {
632
- /***
633
-
634
- Raised when the JavaScript runtime is not capable of performing
635
- the given function. Technically, this should really never be
636
- raised because a non-conforming JavaScript runtime probably
637
- isn't going to support exceptions in the first place.
638
-
639
- ***/
640
- this.message = msg;
641
- }
642
- );
643
-
644
- ne("GenericError",
645
- /** @id MochiKit.Async.GenericError */
646
- function (msg) {
647
- this.message = msg;
648
- }
649
- );
650
-
651
- ne("XMLHttpRequestError",
652
- /** @id MochiKit.Async.XMLHttpRequestError */
653
- function (req, msg) {
654
- /***
655
-
656
- Raised when an XMLHttpRequest does not complete for any reason.
657
-
658
- ***/
659
- this.req = req;
660
- this.message = msg;
661
- try {
662
- // Strange but true that this can raise in some cases.
663
- this.number = req.status;
664
- } catch (e) {
665
- // pass
666
- }
667
- }
668
- );
669
-
670
-
671
- this.EXPORT_TAGS = {
672
- ":common": this.EXPORT,
673
- ":all": m.concat(this.EXPORT, this.EXPORT_OK)
674
- };
675
-
676
- m.nameFunctions(this);
677
-
678
- };
679
-
680
- MochiKit.Async.__new__();
681
-
682
- MochiKit.Base._exportSymbols(this, MochiKit.Async);