sproutcore 1.4.0-java

Sign up to get free protection for your applications and to get access to all the features.
Files changed (1650) hide show
  1. data/DISTRIBUTION.yml +20 -0
  2. data/Gemfile +3 -0
  3. data/History.txt +54 -0
  4. data/README.txt +104 -0
  5. data/Rakefile +446 -0
  6. data/Todo.txt +1 -0
  7. data/VERSION.yml +7 -0
  8. data/bin/sc-build +18 -0
  9. data/bin/sc-build-number +18 -0
  10. data/bin/sc-docs +19 -0
  11. data/bin/sc-gen +18 -0
  12. data/bin/sc-init +18 -0
  13. data/bin/sc-manifest +18 -0
  14. data/bin/sc-server +18 -0
  15. data/bin/sproutcore +18 -0
  16. data/design/Technical Notes.graffle/QuickLook/Preview.pdf +0 -0
  17. data/design/Technical Notes.graffle/QuickLook/Thumbnail.tiff +0 -0
  18. data/design/Technical Notes.graffle/data.plist +5534 -0
  19. data/design/Technical Notes.graffle/image8.png +0 -0
  20. data/lib/Buildfile +140 -0
  21. data/lib/buildtasks/build.rake +103 -0
  22. data/lib/buildtasks/entry.rake +68 -0
  23. data/lib/buildtasks/manifest.rake +615 -0
  24. data/lib/buildtasks/render.rake +21 -0
  25. data/lib/buildtasks/target.rake +65 -0
  26. data/lib/doc_templates/jsdoc/allclasses.tmpl +17 -0
  27. data/lib/doc_templates/jsdoc/allfiles.tmpl +56 -0
  28. data/lib/doc_templates/jsdoc/class.tmpl +487 -0
  29. data/lib/doc_templates/jsdoc/index.tmpl +38 -0
  30. data/lib/doc_templates/jsdoc/publish.js +170 -0
  31. data/lib/doc_templates/jsdoc/static/default.css +162 -0
  32. data/lib/doc_templates/jsdoc/static/header.html +2 -0
  33. data/lib/doc_templates/jsdoc/static/index.html +19 -0
  34. data/lib/doc_templates/jsdoc/symbol.tmpl +35 -0
  35. data/lib/doc_templates/sproutcore/allclasses.tmpl +0 -0
  36. data/lib/doc_templates/sproutcore/allfiles.tmpl +56 -0
  37. data/lib/doc_templates/sproutcore/class.tmpl +674 -0
  38. data/lib/doc_templates/sproutcore/classes-json.tmpl +55 -0
  39. data/lib/doc_templates/sproutcore/index.tmpl +48 -0
  40. data/lib/doc_templates/sproutcore/publish.js +346 -0
  41. data/lib/doc_templates/sproutcore/static/default.css +258 -0
  42. data/lib/doc_templates/sproutcore/static/header.html +2 -0
  43. data/lib/doc_templates/sproutcore/static/index.html +19 -0
  44. data/lib/doc_templates/sproutcore/symbol.tmpl +35 -0
  45. data/lib/frameworks/sproutcore/Buildfile +101 -0
  46. data/lib/frameworks/sproutcore/CHANGELOG.md +170 -0
  47. data/lib/frameworks/sproutcore/HISTORY +697 -0
  48. data/lib/frameworks/sproutcore/README.md +68 -0
  49. data/lib/frameworks/sproutcore/apps/docs/core.js +27 -0
  50. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/QuickLook/Preview.pdf +0 -0
  51. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/QuickLook/Thumbnail.tiff +0 -0
  52. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/data.plist +14378 -0
  53. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/image10.png +0 -0
  54. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/image11.png +0 -0
  55. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/image13.png +0 -0
  56. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/image14.png +0 -0
  57. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/image8.png +0 -0
  58. data/lib/frameworks/sproutcore/apps/docs/design/Doc Viewer.graffle/image9.tiff +0 -0
  59. data/lib/frameworks/sproutcore/apps/docs/english.lproj/loading.rhtml +9 -0
  60. data/lib/frameworks/sproutcore/apps/docs/english.lproj/main_page.js +22 -0
  61. data/lib/frameworks/sproutcore/apps/docs/english.lproj/strings.js +15 -0
  62. data/lib/frameworks/sproutcore/apps/docs/main.js +30 -0
  63. data/lib/frameworks/sproutcore/apps/greenhouse/README +25 -0
  64. data/lib/frameworks/sproutcore/apps/greenhouse/TODO +72 -0
  65. data/lib/frameworks/sproutcore/apps/greenhouse/beautify.js +1058 -0
  66. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/design.js +20 -0
  67. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/file.js +75 -0
  68. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/files.js +40 -0
  69. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/layout.js +53 -0
  70. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/library.js +201 -0
  71. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/page.js +18 -0
  72. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/property.js +19 -0
  73. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/property_editor.js +17 -0
  74. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/target.js +20 -0
  75. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/targets.js +43 -0
  76. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/view_configs.js +100 -0
  77. data/lib/frameworks/sproutcore/apps/greenhouse/core.js +67 -0
  78. data/lib/frameworks/sproutcore/apps/greenhouse/core_file.js +124 -0
  79. data/lib/frameworks/sproutcore/apps/greenhouse/data_source.js +250 -0
  80. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/app_page.js +377 -0
  81. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/app-selector.css +111 -0
  82. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/button.css +310 -0
  83. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/dock.css +85 -0
  84. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/general.css +52 -0
  85. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/main-page.css +120 -0
  86. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/menu.css +52 -0
  87. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/modal.css +40 -0
  88. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/picker.css +188 -0
  89. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/search.css +60 -0
  90. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/tabbed.css +68 -0
  91. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/css/text-field.css +67 -0
  92. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/dialogs.js +302 -0
  93. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/fonts/museosans_500.eot +0 -0
  94. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/fonts/museosans_500.otf +0 -0
  95. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/fonts/museosans_500.woff +0 -0
  96. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/fonts/museosans_500_italic.eot +0 -0
  97. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/fonts/museosans_500_italic.otf +0 -0
  98. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/fonts/museosans_500_italic.woff +0 -0
  99. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/app-selector/choose-app.png +0 -0
  100. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/app-selector/list-item-sel.png +0 -0
  101. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule-xl/active-l.png +0 -0
  102. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule-xl/active-m.png +0 -0
  103. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule-xl/active-r.png +0 -0
  104. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule-xl/regular-l.png +0 -0
  105. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule-xl/regular-m.png +0 -0
  106. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule-xl/regular-r.png +0 -0
  107. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/active-l.png +0 -0
  108. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/active-r.png +0 -0
  109. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/disabled-l.png +0 -0
  110. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/disabled-r.png +0 -0
  111. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/regular-l.png +0 -0
  112. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/regular-r.png +0 -0
  113. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/sel-active-l.png +0 -0
  114. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/sel-active-r.png +0 -0
  115. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/sel-disabled-l.png +0 -0
  116. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/sel-disabled-r.png +0 -0
  117. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/sel-l.png +0 -0
  118. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/capsule/sel-r.png +0 -0
  119. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/active-l.png +0 -0
  120. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/active-m.png +0 -0
  121. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/active-r.png +0 -0
  122. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/cap-active-l.png +0 -0
  123. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/cap-active-r.png +0 -0
  124. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/cap-l.png +0 -0
  125. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/cap-r.png +0 -0
  126. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/cap-sel-active-l.png +0 -0
  127. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/cap-sel-active-r.png +0 -0
  128. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/cap-sel-l.png +0 -0
  129. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/cap-sel-r.png +0 -0
  130. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/disabled-l.png +0 -0
  131. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/disabled-m.png +0 -0
  132. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/disabled-r.png +0 -0
  133. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/regular-l.png +0 -0
  134. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/regular-m.png +0 -0
  135. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/regular-r.png +0 -0
  136. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-active-l.png +0 -0
  137. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-active-m.png +0 -0
  138. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-active-r.png +0 -0
  139. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-disabled-l.png +0 -0
  140. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-disabled-m.png +0 -0
  141. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-disabled-r.png +0 -0
  142. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-l.png +0 -0
  143. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-m.png +0 -0
  144. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/dark/sel-r.png +0 -0
  145. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/shared/active-m.png +0 -0
  146. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/shared/disabled-m.png +0 -0
  147. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/shared/regular-m.png +0 -0
  148. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/shared/sel-active-m.png +0 -0
  149. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/shared/sel-disabled-m.png +0 -0
  150. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/shared/sel-m.png +0 -0
  151. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/active-l.png +0 -0
  152. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/active-r.png +0 -0
  153. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/disabled-l.png +0 -0
  154. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/disabled-r.png +0 -0
  155. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/regular-l.png +0 -0
  156. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/regular-r.png +0 -0
  157. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/sel-active-l.png +0 -0
  158. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/sel-active-r.png +0 -0
  159. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/sel-disabled-l.png +0 -0
  160. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/sel-disabled-r.png +0 -0
  161. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/sel-l.png +0 -0
  162. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/buttons/square/sel-r.png +0 -0
  163. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/actions-active.png +0 -0
  164. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/actions.png +0 -0
  165. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/inspector-active.png +0 -0
  166. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/inspector.png +0 -0
  167. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/library-active.png +0 -0
  168. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/library.png +0 -0
  169. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/projects-active.png +0 -0
  170. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/projects.png +0 -0
  171. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/run-active.png +0 -0
  172. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/run.png +0 -0
  173. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/save-active.png +0 -0
  174. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/icons/save.png +0 -0
  175. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/logos/greenhouse-l.png +0 -0
  176. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/logos/greenhouse-s.png +0 -0
  177. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/logos/sproutcore.png +0 -0
  178. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/main-bg.png +0 -0
  179. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/bottom-left.png +0 -0
  180. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/bottom-right.png +0 -0
  181. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/bottom.png +0 -0
  182. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/close-active.png +0 -0
  183. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/close.png +0 -0
  184. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/left.png +0 -0
  185. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/pointer-bottom.png +0 -0
  186. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/pointer-left.png +0 -0
  187. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/pointer-right.png +0 -0
  188. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/pointer-top.png +0 -0
  189. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/right.png +0 -0
  190. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/search-active.png +0 -0
  191. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/search.png +0 -0
  192. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/top-left.png +0 -0
  193. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/top-right.png +0 -0
  194. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/picker/top.png +0 -0
  195. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/images/toolbar-bg.png +0 -0
  196. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/inspectors.js +365 -0
  197. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/loading.rhtml +9 -0
  198. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/main_page.js +95 -0
  199. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/strings.js +87 -0
  200. data/lib/frameworks/sproutcore/apps/greenhouse/fixtures/file.js +35 -0
  201. data/lib/frameworks/sproutcore/apps/greenhouse/main.js +28 -0
  202. data/lib/frameworks/sproutcore/apps/greenhouse/mixins/drop_down.js +97 -0
  203. data/lib/frameworks/sproutcore/apps/greenhouse/models/design.js +22 -0
  204. data/lib/frameworks/sproutcore/apps/greenhouse/models/dir.js +92 -0
  205. data/lib/frameworks/sproutcore/apps/greenhouse/models/file.js +51 -0
  206. data/lib/frameworks/sproutcore/apps/greenhouse/models/target.js +82 -0
  207. data/lib/frameworks/sproutcore/apps/greenhouse/models/view_config.js +49 -0
  208. data/lib/frameworks/sproutcore/apps/greenhouse/resources/test_page.js +37 -0
  209. data/lib/frameworks/sproutcore/apps/greenhouse/states/inspector.js +144 -0
  210. data/lib/frameworks/sproutcore/apps/greenhouse/states/library.js +133 -0
  211. data/lib/frameworks/sproutcore/apps/greenhouse/states/main.js +224 -0
  212. data/lib/frameworks/sproutcore/apps/greenhouse/states/modals.js +291 -0
  213. data/lib/frameworks/sproutcore/apps/greenhouse/states/ready.js +197 -0
  214. data/lib/frameworks/sproutcore/apps/greenhouse/tests/controllers/design.js +15 -0
  215. data/lib/frameworks/sproutcore/apps/greenhouse/tests/controllers/designs.js +15 -0
  216. data/lib/frameworks/sproutcore/apps/greenhouse/tests/controllers/file.js +15 -0
  217. data/lib/frameworks/sproutcore/apps/greenhouse/tests/controllers/files.js +15 -0
  218. data/lib/frameworks/sproutcore/apps/greenhouse/tests/models/file.js +15 -0
  219. data/lib/frameworks/sproutcore/apps/greenhouse/tests/models/view_config.js +15 -0
  220. data/lib/frameworks/sproutcore/apps/greenhouse/tests/views/list_item.js +15 -0
  221. data/lib/frameworks/sproutcore/apps/greenhouse/views/anchor.js +277 -0
  222. data/lib/frameworks/sproutcore/apps/greenhouse/views/application_list_item.js +19 -0
  223. data/lib/frameworks/sproutcore/apps/greenhouse/views/event_blocker.js +32 -0
  224. data/lib/frameworks/sproutcore/apps/greenhouse/views/label_designer.js +16 -0
  225. data/lib/frameworks/sproutcore/apps/greenhouse/views/list_item.js +42 -0
  226. data/lib/frameworks/sproutcore/apps/greenhouse/views/plist_item.js +39 -0
  227. data/lib/frameworks/sproutcore/apps/greenhouse/views/simple_button.js +157 -0
  228. data/lib/frameworks/sproutcore/apps/greenhouse/views/tear_off_picker.js +56 -0
  229. data/lib/frameworks/sproutcore/apps/greenhouse/views/web.js +44 -0
  230. data/lib/frameworks/sproutcore/apps/tests/controllers/detail.js +25 -0
  231. data/lib/frameworks/sproutcore/apps/tests/controllers/source.js +29 -0
  232. data/lib/frameworks/sproutcore/apps/tests/controllers/target.js +26 -0
  233. data/lib/frameworks/sproutcore/apps/tests/controllers/targets.js +86 -0
  234. data/lib/frameworks/sproutcore/apps/tests/controllers/tests.js +33 -0
  235. data/lib/frameworks/sproutcore/apps/tests/core.js +133 -0
  236. data/lib/frameworks/sproutcore/apps/tests/english.lproj/loading.rhtml +9 -0
  237. data/lib/frameworks/sproutcore/apps/tests/english.lproj/main_page.css +48 -0
  238. data/lib/frameworks/sproutcore/apps/tests/english.lproj/main_page.js +233 -0
  239. data/lib/frameworks/sproutcore/apps/tests/english.lproj/strings.js +26 -0
  240. data/lib/frameworks/sproutcore/apps/tests/main.js +27 -0
  241. data/lib/frameworks/sproutcore/apps/tests/states/no_targets.js +26 -0
  242. data/lib/frameworks/sproutcore/apps/tests/states/ready.js +56 -0
  243. data/lib/frameworks/sproutcore/apps/tests/states/ready_detail.js +41 -0
  244. data/lib/frameworks/sproutcore/apps/tests/states/ready_empty.js +48 -0
  245. data/lib/frameworks/sproutcore/apps/tests/states/ready_list.js +41 -0
  246. data/lib/frameworks/sproutcore/apps/tests/states/ready_loading.js +44 -0
  247. data/lib/frameworks/sproutcore/apps/tests/states/ready_no_tests.js +31 -0
  248. data/lib/frameworks/sproutcore/apps/tests/states/start.js +39 -0
  249. data/lib/frameworks/sproutcore/apps/tests/tests/controllers/detail.js +15 -0
  250. data/lib/frameworks/sproutcore/apps/tests/tests/controllers/source.js +15 -0
  251. data/lib/frameworks/sproutcore/apps/tests/tests/controllers/target.js +15 -0
  252. data/lib/frameworks/sproutcore/apps/tests/tests/controllers/targets.js +15 -0
  253. data/lib/frameworks/sproutcore/apps/tests/tests/controllers/tests.js +15 -0
  254. data/lib/frameworks/sproutcore/apps/tests/tests/models/target.js +15 -0
  255. data/lib/frameworks/sproutcore/apps/tests/tests/models/test.js +15 -0
  256. data/lib/frameworks/sproutcore/apps/tests/tests/views/offset_checkbox.js +15 -0
  257. data/lib/frameworks/sproutcore/apps/tests/views/offset_checkbox.js +26 -0
  258. data/lib/frameworks/sproutcore/apps/welcome/controllers/targets.js +49 -0
  259. data/lib/frameworks/sproutcore/apps/welcome/core.js +30 -0
  260. data/lib/frameworks/sproutcore/apps/welcome/english.lproj/loading.rhtml +10 -0
  261. data/lib/frameworks/sproutcore/apps/welcome/english.lproj/main_page.css +7 -0
  262. data/lib/frameworks/sproutcore/apps/welcome/english.lproj/main_page.js +77 -0
  263. data/lib/frameworks/sproutcore/apps/welcome/english.lproj/strings.js +15 -0
  264. data/lib/frameworks/sproutcore/apps/welcome/main.js +19 -0
  265. data/lib/frameworks/sproutcore/apps/welcome/tests/controllers/targets.js +15 -0
  266. data/lib/frameworks/sproutcore/design/CollectionView State Charts.graffle +4848 -0
  267. data/lib/frameworks/sproutcore/design/Design Charts.graffle +16845 -0
  268. data/lib/frameworks/sproutcore/design/Record State Table.numbers +0 -0
  269. data/lib/frameworks/sproutcore/design/SproutCore Datastore Design.graffle/QuickLook/Preview.pdf +0 -0
  270. data/lib/frameworks/sproutcore/design/SproutCore Datastore Design.graffle/QuickLook/Thumbnail.tiff +0 -0
  271. data/lib/frameworks/sproutcore/design/SproutCore Datastore Design.graffle/data.plist +19588 -0
  272. data/lib/frameworks/sproutcore/design/SproutCore Datastore Design.graffle/image8.png +0 -0
  273. data/lib/frameworks/sproutcore/design/SproutCore Design Template.graffle/QuickLook/Preview.pdf +0 -0
  274. data/lib/frameworks/sproutcore/design/SproutCore Design Template.graffle/QuickLook/Thumbnail.tiff +0 -0
  275. data/lib/frameworks/sproutcore/design/SproutCore Design Template.graffle/data.plist +1452 -0
  276. data/lib/frameworks/sproutcore/design/SproutCore Design Template.graffle/image8.png +0 -0
  277. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/QuickLook/Preview.pdf +0 -0
  278. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/QuickLook/Thumbnail.tiff +0 -0
  279. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/data.plist +24187 -0
  280. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image10.png +0 -0
  281. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image11.png +0 -0
  282. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image13.png +0 -0
  283. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image15.png +0 -0
  284. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image16.png +0 -0
  285. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image17.png +0 -0
  286. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image18.png +0 -0
  287. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image19.png +0 -0
  288. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image22.tiff +0 -0
  289. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image23.png +0 -0
  290. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image24.png +0 -0
  291. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image25.png +0 -0
  292. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image30.png +0 -0
  293. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image31.png +0 -0
  294. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image8.png +0 -0
  295. data/lib/frameworks/sproutcore/design/TestRunner Design.graffle/image9.png +0 -0
  296. data/lib/frameworks/sproutcore/design/greenhouse-statechart.graffle +9025 -0
  297. data/lib/frameworks/sproutcore/design/greenhouse-statechart.pdf +0 -0
  298. data/lib/frameworks/sproutcore/design/iphone-webapp-loading.psd +0 -0
  299. data/lib/frameworks/sproutcore/frameworks/animation/Buildfile +3 -0
  300. data/lib/frameworks/sproutcore/frameworks/animation/LICENSE +25 -0
  301. data/lib/frameworks/sproutcore/frameworks/animation/README.md +79 -0
  302. data/lib/frameworks/sproutcore/frameworks/animation/core.js +1192 -0
  303. data/lib/frameworks/sproutcore/frameworks/animation/tests/core.js +147 -0
  304. data/lib/frameworks/sproutcore/frameworks/bootstrap/README +9 -0
  305. data/lib/frameworks/sproutcore/frameworks/bootstrap/core.js +7 -0
  306. data/lib/frameworks/sproutcore/frameworks/bootstrap/setup_body_class_names.js +10 -0
  307. data/lib/frameworks/sproutcore/frameworks/bootstrap/system/browser.js +29 -0
  308. data/lib/frameworks/sproutcore/frameworks/bootstrap/system/loader.js +49 -0
  309. data/lib/frameworks/sproutcore/frameworks/core_tools/core.js +20 -0
  310. data/lib/frameworks/sproutcore/frameworks/core_tools/data_source.js +99 -0
  311. data/lib/frameworks/sproutcore/frameworks/core_tools/english.lproj/strings.js +15 -0
  312. data/lib/frameworks/sproutcore/frameworks/core_tools/fixtures/target.js +87 -0
  313. data/lib/frameworks/sproutcore/frameworks/core_tools/fixtures/test.js +44 -0
  314. data/lib/frameworks/sproutcore/frameworks/core_tools/models/target.js +108 -0
  315. data/lib/frameworks/sproutcore/frameworks/core_tools/models/test.js +48 -0
  316. data/lib/frameworks/sproutcore/frameworks/datastore/core.js +8 -0
  317. data/lib/frameworks/sproutcore/frameworks/datastore/data_sources/cascade.js +180 -0
  318. data/lib/frameworks/sproutcore/frameworks/datastore/data_sources/data_source.js +340 -0
  319. data/lib/frameworks/sproutcore/frameworks/datastore/data_sources/fixtures.js +393 -0
  320. data/lib/frameworks/sproutcore/frameworks/datastore/debug/json.js +71 -0
  321. data/lib/frameworks/sproutcore/frameworks/datastore/debug/standard_setup.js +96 -0
  322. data/lib/frameworks/sproutcore/frameworks/datastore/fixtures/author_fixtures.js +2503 -0
  323. data/lib/frameworks/sproutcore/frameworks/datastore/fixtures/sample.js +17 -0
  324. data/lib/frameworks/sproutcore/frameworks/datastore/models/child_attribute.js +122 -0
  325. data/lib/frameworks/sproutcore/frameworks/datastore/models/child_record.js +105 -0
  326. data/lib/frameworks/sproutcore/frameworks/datastore/models/children_attribute.js +81 -0
  327. data/lib/frameworks/sproutcore/frameworks/datastore/models/fetched_attribute.js +100 -0
  328. data/lib/frameworks/sproutcore/frameworks/datastore/models/many_attribute.js +153 -0
  329. data/lib/frameworks/sproutcore/frameworks/datastore/models/record.js +1201 -0
  330. data/lib/frameworks/sproutcore/frameworks/datastore/models/record_attribute.js +494 -0
  331. data/lib/frameworks/sproutcore/frameworks/datastore/models/single_attribute.js +159 -0
  332. data/lib/frameworks/sproutcore/frameworks/datastore/system/child_array.js +242 -0
  333. data/lib/frameworks/sproutcore/frameworks/datastore/system/many_array.js +415 -0
  334. data/lib/frameworks/sproutcore/frameworks/datastore/system/nested_store.js +588 -0
  335. data/lib/frameworks/sproutcore/frameworks/datastore/system/query.js +1600 -0
  336. data/lib/frameworks/sproutcore/frameworks/datastore/system/record_array.js +651 -0
  337. data/lib/frameworks/sproutcore/frameworks/datastore/system/store.js +2666 -0
  338. data/lib/frameworks/sproutcore/frameworks/datastore/tests/data_sources/fixtures.js +117 -0
  339. data/lib/frameworks/sproutcore/frameworks/datastore/tests/integration/contact_model.js +131 -0
  340. data/lib/frameworks/sproutcore/frameworks/datastore/tests/integration/cyclical_relationship.js +119 -0
  341. data/lib/frameworks/sproutcore/frameworks/datastore/tests/integration/mail_model.js +91 -0
  342. data/lib/frameworks/sproutcore/frameworks/datastore/tests/integration/test_runner_model.js +56 -0
  343. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/datetime_recordattribute.js +73 -0
  344. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/many_attribute.js +423 -0
  345. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/nested_records/nested_record.js +235 -0
  346. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/nested_records/nested_record_array.js +337 -0
  347. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/nested_records/nested_record_array_complex.js +421 -0
  348. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/nested_records/nested_record_complex.js +304 -0
  349. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/nested_records/parentless.js +134 -0
  350. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/core_methods.js +55 -0
  351. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/destroy.js +92 -0
  352. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/error_methods.js +56 -0
  353. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/normalize.js +273 -0
  354. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/readAttribute.js +53 -0
  355. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/refresh.js +48 -0
  356. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/storeDidChangeProperties.js +170 -0
  357. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/unknownProperty.js +66 -0
  358. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record/writeAttribute.js +112 -0
  359. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/record_attribute.js +252 -0
  360. data/lib/frameworks/sproutcore/frameworks/datastore/tests/models/single_attribute.js +284 -0
  361. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/many_array/core_methods.js +204 -0
  362. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/chain.js +180 -0
  363. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/commitChanges.js +171 -0
  364. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/commitChangesFromNestedStore.js +154 -0
  365. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/core_methods.js +70 -0
  366. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/dataHashDidChange.js +113 -0
  367. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/discardChanges.js +99 -0
  368. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/readDataHash.js +180 -0
  369. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/readEditableDataHash.js +126 -0
  370. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/removeDataHash.js +163 -0
  371. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/nested_store/writeDataHash.js +166 -0
  372. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/builders.js +219 -0
  373. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/compare.js +144 -0
  374. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/contains.js +131 -0
  375. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/containsRecordTypes.js +81 -0
  376. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/copy.js +30 -0
  377. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/evaluation.js +197 -0
  378. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/evaluation_of_records.js +92 -0
  379. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/expandedRecordTypes.js +64 -0
  380. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/parse.js +216 -0
  381. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/queryWithScope.js +57 -0
  382. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/record_type_is.js +43 -0
  383. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/registered_comparisons.js +66 -0
  384. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/query/registered_query_extensions.js +67 -0
  385. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/record_array/core_methods.js +177 -0
  386. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/record_array/error_methods.js +50 -0
  387. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/record_array/flush.js +177 -0
  388. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/cancelRecord.js +54 -0
  389. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/commitChangesFromNestedStore.js +133 -0
  390. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/commitRecord.js +211 -0
  391. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/core_methods.js +156 -0
  392. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/createRecord.js +72 -0
  393. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/dataHashDidChange.js +157 -0
  394. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/dataSourceCallbacks.js +278 -0
  395. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/destroyRecord.js +106 -0
  396. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/error_methods.js +62 -0
  397. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/find.js +530 -0
  398. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/init.js +23 -0
  399. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/pushChanges.js +61 -0
  400. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/readDataHash.js +74 -0
  401. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/readEditableDataHash.js +74 -0
  402. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/recordDidChange.js +73 -0
  403. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/removeDataHash.js +144 -0
  404. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/retrieveRecord.js +184 -0
  405. data/lib/frameworks/sproutcore/frameworks/datastore/tests/system/store/writeDataHash.js +125 -0
  406. data/lib/frameworks/sproutcore/frameworks/datejs/core.js +865 -0
  407. data/lib/frameworks/sproutcore/frameworks/datejs/english.lproj/en-US.js +186 -0
  408. data/lib/frameworks/sproutcore/frameworks/datejs/extras.js +332 -0
  409. data/lib/frameworks/sproutcore/frameworks/datejs/license.js +25 -0
  410. data/lib/frameworks/sproutcore/frameworks/datejs/parser.js +1116 -0
  411. data/lib/frameworks/sproutcore/frameworks/datejs/spanish.lproj/es-CO.js +186 -0
  412. data/lib/frameworks/sproutcore/frameworks/datejs/sugarpak.js +475 -0
  413. data/lib/frameworks/sproutcore/frameworks/datejs/time.js +269 -0
  414. data/lib/frameworks/sproutcore/frameworks/datejs/validators/datejs.js +34 -0
  415. data/lib/frameworks/sproutcore/frameworks/debug/core.js +114 -0
  416. data/lib/frameworks/sproutcore/frameworks/debug/invoke_once_last_debugging.js +265 -0
  417. data/lib/frameworks/sproutcore/frameworks/designer/coders/design.js +20 -0
  418. data/lib/frameworks/sproutcore/frameworks/designer/coders/localization.js +19 -0
  419. data/lib/frameworks/sproutcore/frameworks/designer/coders/object.js +347 -0
  420. data/lib/frameworks/sproutcore/frameworks/designer/controllers/controllers.js +16 -0
  421. data/lib/frameworks/sproutcore/frameworks/designer/controllers/design.js +37 -0
  422. data/lib/frameworks/sproutcore/frameworks/designer/controllers/designs.js +134 -0
  423. data/lib/frameworks/sproutcore/frameworks/designer/controllers/page_design.js +170 -0
  424. data/lib/frameworks/sproutcore/frameworks/designer/controllers/page_files.js +22 -0
  425. data/lib/frameworks/sproutcore/frameworks/designer/core.js +26 -0
  426. data/lib/frameworks/sproutcore/frameworks/designer/css/css_rule.js +22 -0
  427. data/lib/frameworks/sproutcore/frameworks/designer/css/css_style.js +29 -0
  428. data/lib/frameworks/sproutcore/frameworks/designer/css/css_style_sheet.js +201 -0
  429. data/lib/frameworks/sproutcore/frameworks/designer/designers/button.js +21 -0
  430. data/lib/frameworks/sproutcore/frameworks/designer/designers/label.js +16 -0
  431. data/lib/frameworks/sproutcore/frameworks/designer/designers/object_designer.js +296 -0
  432. data/lib/frameworks/sproutcore/frameworks/designer/designers/tab.js +18 -0
  433. data/lib/frameworks/sproutcore/frameworks/designer/designers/text_field.js +15 -0
  434. data/lib/frameworks/sproutcore/frameworks/designer/designers/view_designer.js +1259 -0
  435. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/css/designer.css +96 -0
  436. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/design_page.js +55 -0
  437. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/high_light.css +10 -0
  438. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/controller.png +0 -0
  439. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/dock-bg.png +0 -0
  440. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/dock-item-bg.png +0 -0
  441. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/dock-item-divider.png +0 -0
  442. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/dock-item-sel-bg.png +0 -0
  443. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/dock-item-sel-divider.png +0 -0
  444. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/main-bg.png +0 -0
  445. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/page.png +0 -0
  446. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/pane.png +0 -0
  447. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/images/view.png +0 -0
  448. data/lib/frameworks/sproutcore/frameworks/designer/english.lproj/selection_handles.css +58 -0
  449. data/lib/frameworks/sproutcore/frameworks/designer/ext/object.js +26 -0
  450. data/lib/frameworks/sproutcore/frameworks/designer/ext/page.js +86 -0
  451. data/lib/frameworks/sproutcore/frameworks/designer/ext/view.js +54 -0
  452. data/lib/frameworks/sproutcore/frameworks/designer/mixins/button.js +11 -0
  453. data/lib/frameworks/sproutcore/frameworks/designer/mixins/snap_lines.js +221 -0
  454. data/lib/frameworks/sproutcore/frameworks/designer/views/designer_drop_target.js +138 -0
  455. data/lib/frameworks/sproutcore/frameworks/designer/views/drawing.js +219 -0
  456. data/lib/frameworks/sproutcore/frameworks/designer/views/high_light.js +66 -0
  457. data/lib/frameworks/sproutcore/frameworks/designer/views/page_item_view.js +130 -0
  458. data/lib/frameworks/sproutcore/frameworks/designer/views/selection_handles.js +78 -0
  459. data/lib/frameworks/sproutcore/frameworks/desktop/core.js +18 -0
  460. data/lib/frameworks/sproutcore/frameworks/desktop/debug/drag.js +41 -0
  461. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/alert.css +56 -0
  462. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/debug/a_sample_image.jpg +0 -0
  463. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/debug/apple-logo1.jpeg +0 -0
  464. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/debug/iframe.html +23 -0
  465. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/disclosure.css +74 -0
  466. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/drag.css +7 -0
  467. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/icons.css +943 -0
  468. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/images/cap.png +0 -0
  469. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/images/downbutton.png +0 -0
  470. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/images/icons/shared.png +0 -0
  471. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/images/thumb-bottom.png +0 -0
  472. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/images/thumb-center.png +0 -0
  473. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/images/thumb-top.png +0 -0
  474. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/images/track.png +0 -0
  475. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/images/upbutton.png +0 -0
  476. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/list_item.css +161 -0
  477. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/menu.css +12 -0
  478. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/menu_item_view.css +109 -0
  479. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/modal.css +9 -0
  480. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/panel.css +91 -0
  481. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/picker.css +35 -0
  482. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/progress.css +33 -0
  483. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/radio.css +10 -0
  484. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/segmented.css +134 -0
  485. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/separator.css +19 -0
  486. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/slider.css +66 -0
  487. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/split.css +0 -0
  488. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/split_divider.css +6 -0
  489. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/strings.js +14 -0
  490. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/tab.css +7 -0
  491. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/toolbar.css +5 -0
  492. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/touch-scroller.css +196 -0
  493. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/video.css +3 -0
  494. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/well.css +71 -0
  495. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/border.js +138 -0
  496. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_fast_path.js +694 -0
  497. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_group.js +22 -0
  498. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_row_delegate.js +61 -0
  499. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_view_delegate.js +295 -0
  500. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/scrollable.js +253 -0
  501. data/lib/frameworks/sproutcore/frameworks/desktop/panes/alert.js +410 -0
  502. data/lib/frameworks/sproutcore/frameworks/desktop/panes/menu.js +1115 -0
  503. data/lib/frameworks/sproutcore/frameworks/desktop/panes/modal.js +71 -0
  504. data/lib/frameworks/sproutcore/frameworks/desktop/panes/palette.js +74 -0
  505. data/lib/frameworks/sproutcore/frameworks/desktop/panes/panel.js +180 -0
  506. data/lib/frameworks/sproutcore/frameworks/desktop/panes/picker.js +696 -0
  507. data/lib/frameworks/sproutcore/frameworks/desktop/panes/select_button.js +849 -0
  508. data/lib/frameworks/sproutcore/frameworks/desktop/panes/sheet.js +214 -0
  509. data/lib/frameworks/sproutcore/frameworks/desktop/protocols/drag_data_source.js +39 -0
  510. data/lib/frameworks/sproutcore/frameworks/desktop/protocols/drag_source.js +81 -0
  511. data/lib/frameworks/sproutcore/frameworks/desktop/protocols/drop_target.js +175 -0
  512. data/lib/frameworks/sproutcore/frameworks/desktop/protocols/responder.js +299 -0
  513. data/lib/frameworks/sproutcore/frameworks/desktop/system/drag.js +923 -0
  514. data/lib/frameworks/sproutcore/frameworks/desktop/system/key_bindings.js +40 -0
  515. data/lib/frameworks/sproutcore/frameworks/desktop/system/undo_manager.js +187 -0
  516. data/lib/frameworks/sproutcore/frameworks/desktop/tests/integration/dialog.js +43 -0
  517. data/lib/frameworks/sproutcore/frameworks/desktop/tests/mixins/border.js +96 -0
  518. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/alert/methods.js +10 -0
  519. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/alert/ui.js +152 -0
  520. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/menu/methods.js +135 -0
  521. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/menu/ui.js +223 -0
  522. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/palette/methods.js +10 -0
  523. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/palette/ui.js +35 -0
  524. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/pane_page.js +41 -0
  525. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/panel/methods.js +10 -0
  526. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/panel/ui.js +40 -0
  527. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/picker/methods.js +10 -0
  528. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/picker/ui.js +86 -0
  529. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/select_button/methods.js +194 -0
  530. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/select_button/ui.js +212 -0
  531. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/sheet/methods.js +10 -0
  532. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/sheet/ui.js +44 -0
  533. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/button/methods.js +124 -0
  534. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/button/ui.js +163 -0
  535. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/checkbox/methods.js +142 -0
  536. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/checkbox/ui.js +95 -0
  537. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/content.js +249 -0
  538. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/deleteSelection.js +82 -0
  539. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/deselect.js +215 -0
  540. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/displayProperties.js +31 -0
  541. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/itemViewForContentIndex.js +300 -0
  542. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/layerIdFor.js +65 -0
  543. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/length.js +88 -0
  544. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/mouse.js +240 -0
  545. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/nowShowing.js +121 -0
  546. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/reload.js +177 -0
  547. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/select.js +240 -0
  548. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/selectNextItem.js +205 -0
  549. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/selectPreviousItem.js +211 -0
  550. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/selection.js +141 -0
  551. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/collection/ui_diagram.js +182 -0
  552. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/date_field/methods.js +76 -0
  553. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/date_field/ui.js +456 -0
  554. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/disclosure/methods.js +10 -0
  555. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/disclosure/ui.js +64 -0
  556. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/grid/methods.js +10 -0
  557. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/grid/ui.js +10 -0
  558. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/render.js +92 -0
  559. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/rowDelegate.js +183 -0
  560. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/rowHeightForContentIndex.js +133 -0
  561. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/rowOffsetForContentIndex.js +131 -0
  562. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/ui_alternatingrows.js +130 -0
  563. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/ui_outline.js +56 -0
  564. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/ui_row_heights.js +205 -0
  565. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/ui_simple.js +127 -0
  566. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list_item.js +288 -0
  567. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/menu_item/methods.js +10 -0
  568. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/menu_item/ui.js +46 -0
  569. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/progress/methods.js +128 -0
  570. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/progress/ui.js +287 -0
  571. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/radio/methods.js +119 -0
  572. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/radio/ui.js +232 -0
  573. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/scroll/methods.js +143 -0
  574. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/scroll/ui.js +150 -0
  575. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/scroller.js +90 -0
  576. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/segmented/methods.js +119 -0
  577. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/segmented/ui.js +226 -0
  578. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/select/methods.js +144 -0
  579. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/select/ui.js +216 -0
  580. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/select_field/methods.js +132 -0
  581. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/select_field/ui.js +110 -0
  582. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/separator.js +37 -0
  583. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/source_list/methods.js +10 -0
  584. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/source_list/ui.js +10 -0
  585. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/split/methods.js +60 -0
  586. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/split/ui.js +52 -0
  587. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/stacked/ui_comments.js +231 -0
  588. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/static_content.js +46 -0
  589. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/tab/methods.js +54 -0
  590. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/tab/ui.js +88 -0
  591. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/web/methods.js +10 -0
  592. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/web/ui.js +110 -0
  593. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/well/ui.js +54 -0
  594. data/lib/frameworks/sproutcore/frameworks/desktop/views/button.js +619 -0
  595. data/lib/frameworks/sproutcore/frameworks/desktop/views/checkbox.js +112 -0
  596. data/lib/frameworks/sproutcore/frameworks/desktop/views/collection.js +3073 -0
  597. data/lib/frameworks/sproutcore/frameworks/desktop/views/date_field.js +319 -0
  598. data/lib/frameworks/sproutcore/frameworks/desktop/views/disclosure.js +77 -0
  599. data/lib/frameworks/sproutcore/frameworks/desktop/views/grid.js +207 -0
  600. data/lib/frameworks/sproutcore/frameworks/desktop/views/list.js +631 -0
  601. data/lib/frameworks/sproutcore/frameworks/desktop/views/list_item.js +836 -0
  602. data/lib/frameworks/sproutcore/frameworks/desktop/views/menu_item.js +681 -0
  603. data/lib/frameworks/sproutcore/frameworks/desktop/views/menu_scroll.js +588 -0
  604. data/lib/frameworks/sproutcore/frameworks/desktop/views/popup_button.js +298 -0
  605. data/lib/frameworks/sproutcore/frameworks/desktop/views/progress.js +250 -0
  606. data/lib/frameworks/sproutcore/frameworks/desktop/views/radio.js +376 -0
  607. data/lib/frameworks/sproutcore/frameworks/desktop/views/scene.js +204 -0
  608. data/lib/frameworks/sproutcore/frameworks/desktop/views/scroll.js +1790 -0
  609. data/lib/frameworks/sproutcore/frameworks/desktop/views/scroller.js +884 -0
  610. data/lib/frameworks/sproutcore/frameworks/desktop/views/segmented.js +678 -0
  611. data/lib/frameworks/sproutcore/frameworks/desktop/views/select.js +673 -0
  612. data/lib/frameworks/sproutcore/frameworks/desktop/views/select_field.js +324 -0
  613. data/lib/frameworks/sproutcore/frameworks/desktop/views/separator.js +36 -0
  614. data/lib/frameworks/sproutcore/frameworks/desktop/views/slider.js +286 -0
  615. data/lib/frameworks/sproutcore/frameworks/desktop/views/source_list.js +47 -0
  616. data/lib/frameworks/sproutcore/frameworks/desktop/views/source_list_group.js +169 -0
  617. data/lib/frameworks/sproutcore/frameworks/desktop/views/split.js +781 -0
  618. data/lib/frameworks/sproutcore/frameworks/desktop/views/split_divider.js +57 -0
  619. data/lib/frameworks/sproutcore/frameworks/desktop/views/stacked.js +110 -0
  620. data/lib/frameworks/sproutcore/frameworks/desktop/views/static_content.js +134 -0
  621. data/lib/frameworks/sproutcore/frameworks/desktop/views/tab.js +184 -0
  622. data/lib/frameworks/sproutcore/frameworks/desktop/views/thumb.js +53 -0
  623. data/lib/frameworks/sproutcore/frameworks/desktop/views/toolbar.js +49 -0
  624. data/lib/frameworks/sproutcore/frameworks/desktop/views/web.js +87 -0
  625. data/lib/frameworks/sproutcore/frameworks/desktop/views/well.js +85 -0
  626. data/lib/frameworks/sproutcore/frameworks/foundation/TESTING +46 -0
  627. data/lib/frameworks/sproutcore/frameworks/foundation/controllers/array.js +518 -0
  628. data/lib/frameworks/sproutcore/frameworks/foundation/controllers/controller.js +44 -0
  629. data/lib/frameworks/sproutcore/frameworks/foundation/controllers/object.js +342 -0
  630. data/lib/frameworks/sproutcore/frameworks/foundation/controllers/tree.js +124 -0
  631. data/lib/frameworks/sproutcore/frameworks/foundation/core.js +150 -0
  632. data/lib/frameworks/sproutcore/frameworks/foundation/debug/control_test_pane.js +193 -0
  633. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/blank.gif +0 -0
  634. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/bootstrap.rhtml +79 -0
  635. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/button_view.css +40 -0
  636. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/core.css +474 -0
  637. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/debug/control-test-pane.css +9 -0
  638. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore-logo.png +0 -0
  639. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore-startup-landscape.jpg +0 -0
  640. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore-startup-landscape.png +0 -0
  641. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore-startup-portrait.jpg +0 -0
  642. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore-startup-portrait.png +0 -0
  643. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore-startup.png +0 -0
  644. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/inline_editor.css +12 -0
  645. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/label.css +42 -0
  646. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/static_layout.css +5 -0
  647. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/strings.js +15 -0
  648. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/text_field.css +148 -0
  649. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/view.css +57 -0
  650. data/lib/frameworks/sproutcore/frameworks/foundation/ext/object.js +83 -0
  651. data/lib/frameworks/sproutcore/frameworks/foundation/ext/run_loop.js +162 -0
  652. data/lib/frameworks/sproutcore/frameworks/foundation/fixtures/file_exists.json +1 -0
  653. data/lib/frameworks/sproutcore/frameworks/foundation/fixtures/malformed.json +11 -0
  654. data/lib/frameworks/sproutcore/frameworks/foundation/license.js +30 -0
  655. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/button.js +360 -0
  656. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/collection_content.js +179 -0
  657. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/content_display.js +96 -0
  658. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/control.js +377 -0
  659. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/editable.js +152 -0
  660. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/inline_text_field.js +580 -0
  661. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/responder_context.js +269 -0
  662. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/selection_support.js +250 -0
  663. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/static_layout.js +77 -0
  664. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/string.js +543 -0
  665. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/tree_item_content.js +160 -0
  666. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/validatable.js +189 -0
  667. data/lib/frameworks/sproutcore/frameworks/foundation/panes/main.js +51 -0
  668. data/lib/frameworks/sproutcore/frameworks/foundation/panes/pane.js +848 -0
  669. data/lib/frameworks/sproutcore/frameworks/foundation/private/tree_item_observer.js +907 -0
  670. data/lib/frameworks/sproutcore/frameworks/foundation/protocols/inline_editor_delegate.js +84 -0
  671. data/lib/frameworks/sproutcore/frameworks/foundation/system/application.js +37 -0
  672. data/lib/frameworks/sproutcore/frameworks/foundation/system/benchmark.js +514 -0
  673. data/lib/frameworks/sproutcore/frameworks/foundation/system/browser.js +59 -0
  674. data/lib/frameworks/sproutcore/frameworks/foundation/system/builder.js +210 -0
  675. data/lib/frameworks/sproutcore/frameworks/foundation/system/bundle.js +337 -0
  676. data/lib/frameworks/sproutcore/frameworks/foundation/system/core_query.js +2049 -0
  677. data/lib/frameworks/sproutcore/frameworks/foundation/system/cursor.js +131 -0
  678. data/lib/frameworks/sproutcore/frameworks/foundation/system/datetime.js +1129 -0
  679. data/lib/frameworks/sproutcore/frameworks/foundation/system/device.js +143 -0
  680. data/lib/frameworks/sproutcore/frameworks/foundation/system/event.js +894 -0
  681. data/lib/frameworks/sproutcore/frameworks/foundation/system/exception_handler.js +85 -0
  682. data/lib/frameworks/sproutcore/frameworks/foundation/system/image_cache.js +432 -0
  683. data/lib/frameworks/sproutcore/frameworks/foundation/system/json.js +515 -0
  684. data/lib/frameworks/sproutcore/frameworks/foundation/system/locale.js +293 -0
  685. data/lib/frameworks/sproutcore/frameworks/foundation/system/math.js +57 -0
  686. data/lib/frameworks/sproutcore/frameworks/foundation/system/page.js +108 -0
  687. data/lib/frameworks/sproutcore/frameworks/foundation/system/platform.js +297 -0
  688. data/lib/frameworks/sproutcore/frameworks/foundation/system/ready.js +197 -0
  689. data/lib/frameworks/sproutcore/frameworks/foundation/system/render_context.js +988 -0
  690. data/lib/frameworks/sproutcore/frameworks/foundation/system/request.js +599 -0
  691. data/lib/frameworks/sproutcore/frameworks/foundation/system/responder.js +124 -0
  692. data/lib/frameworks/sproutcore/frameworks/foundation/system/response.js +538 -0
  693. data/lib/frameworks/sproutcore/frameworks/foundation/system/root_responder.js +2060 -0
  694. data/lib/frameworks/sproutcore/frameworks/foundation/system/routes.js +420 -0
  695. data/lib/frameworks/sproutcore/frameworks/foundation/system/task_queue.js +150 -0
  696. data/lib/frameworks/sproutcore/frameworks/foundation/system/text_selection.js +103 -0
  697. data/lib/frameworks/sproutcore/frameworks/foundation/system/time.js +473 -0
  698. data/lib/frameworks/sproutcore/frameworks/foundation/system/timer.js +551 -0
  699. data/lib/frameworks/sproutcore/frameworks/foundation/system/user_defaults.js +397 -0
  700. data/lib/frameworks/sproutcore/frameworks/foundation/system/utils.js +710 -0
  701. data/lib/frameworks/sproutcore/frameworks/foundation/tasks/preload_bundle.js +41 -0
  702. data/lib/frameworks/sproutcore/frameworks/foundation/tasks/task.js +17 -0
  703. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/array/array_case.js +218 -0
  704. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/array/enum_case.js +206 -0
  705. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/array/null_case.js +64 -0
  706. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/array/selection_support.js +318 -0
  707. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/array/single_case.js +136 -0
  708. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/object/empty_case.js +82 -0
  709. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/object/multiple_case.js +111 -0
  710. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/object/single_case.js +193 -0
  711. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/object/single_enumerable_case.js +265 -0
  712. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/tree/outline_case.js +108 -0
  713. data/lib/frameworks/sproutcore/frameworks/foundation/tests/controllers/tree/selection_support.js +340 -0
  714. data/lib/frameworks/sproutcore/frameworks/foundation/tests/debug/control_test_pane/methods.js +10 -0
  715. data/lib/frameworks/sproutcore/frameworks/foundation/tests/debug/control_test_pane/ui.js +113 -0
  716. data/lib/frameworks/sproutcore/frameworks/foundation/tests/integration/creating_views.js +113 -0
  717. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/button/content.js +195 -0
  718. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/button/displayProperties.js +89 -0
  719. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/button/keyEquivalents.js +57 -0
  720. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/button/ui.js +68 -0
  721. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/control/content.js +168 -0
  722. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/control/displayProperties.js +89 -0
  723. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/inline_text_field/api.js +52 -0
  724. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/inline_text_field/beginEditing.js +227 -0
  725. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/responder_context.js +75 -0
  726. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/staticLayout.js +142 -0
  727. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/string.js +83 -0
  728. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/validatable/ui.js +74 -0
  729. data/lib/frameworks/sproutcore/frameworks/foundation/tests/private/tree_item_observer/flat_case.js +325 -0
  730. data/lib/frameworks/sproutcore/frameworks/foundation/tests/private/tree_item_observer/group_case.js +718 -0
  731. data/lib/frameworks/sproutcore/frameworks/foundation/tests/private/tree_item_observer/outline_case.js +484 -0
  732. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/builder.js +42 -0
  733. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_core.js +1334 -0
  734. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_dimensions.js +387 -0
  735. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_selector.js +405 -0
  736. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/setClass.js +49 -0
  737. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/within.js +66 -0
  738. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/datetime.js +348 -0
  739. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/json.js +14 -0
  740. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/locale.js +134 -0
  741. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/math.js +39 -0
  742. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/begin.js +47 -0
  743. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/element.js +44 -0
  744. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/end.js +124 -0
  745. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/get.js +51 -0
  746. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/helpers_attr.js +50 -0
  747. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/helpers_basic.js +28 -0
  748. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/helpers_className.js +179 -0
  749. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/helpers_style.js +101 -0
  750. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/init.js +55 -0
  751. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/join.js +28 -0
  752. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/push_text.js +74 -0
  753. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/tag.js +46 -0
  754. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/update.js +218 -0
  755. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/request.js +223 -0
  756. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/root_responder/makeKeyPane.js +124 -0
  757. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/root_responder/makeMainPane.js +68 -0
  758. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/root_responder/makeMenuPane.js +48 -0
  759. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/root_responder/root_responder.js +101 -0
  760. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/root_responder/targetForAction.js +238 -0
  761. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/routes.js +352 -0
  762. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/task_queue.js +43 -0
  763. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/timer/invalidate.js +38 -0
  764. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/timer/invokeLater.js +201 -0
  765. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/timer/isPaused.js +71 -0
  766. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/timer/performAction.js +69 -0
  767. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/timer/schedule.js +170 -0
  768. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js +24 -0
  769. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/utils/normalizeURL.js +18 -0
  770. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/utils/range.js +62 -0
  771. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/utils/rect.js +99 -0
  772. data/lib/frameworks/sproutcore/frameworks/foundation/tests/validators/credit_card.js +35 -0
  773. data/lib/frameworks/sproutcore/frameworks/foundation/tests/validators/date.js +26 -0
  774. data/lib/frameworks/sproutcore/frameworks/foundation/tests/validators/number.js +47 -0
  775. data/lib/frameworks/sproutcore/frameworks/foundation/tests/validators/password.js +13 -0
  776. data/lib/frameworks/sproutcore/frameworks/foundation/tests/validators/validator.js +20 -0
  777. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/container/methods.js +10 -0
  778. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/container/ui.js +115 -0
  779. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/image/ui.js +59 -0
  780. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/label/ui.js +148 -0
  781. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/main_pane.js +31 -0
  782. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/pane/append_remove.js +124 -0
  783. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/pane/firstResponder.js +148 -0
  784. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/pane/keyPane.js +133 -0
  785. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/pane/layout.js +31 -0
  786. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/pane/sendEvent.js +206 -0
  787. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/text_field/methods.js +87 -0
  788. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/text_field/ui.js +530 -0
  789. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/clippingFrame.js +133 -0
  790. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/convertFrames.js +246 -0
  791. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/convertLayouts.js +145 -0
  792. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/createChildViews.js +122 -0
  793. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/createLayer.js +97 -0
  794. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/destroyLayer.js +83 -0
  795. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/didAppendToDocument.js +48 -0
  796. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/findLayerInParentLayer.js +50 -0
  797. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/init.js +50 -0
  798. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/insertBefore.js +200 -0
  799. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/isVisible.js +51 -0
  800. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/isVisibleInWindow.js +116 -0
  801. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/layer.js +150 -0
  802. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/layoutChildViews.js +162 -0
  803. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/layoutDidChange.js +127 -0
  804. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/layoutStyle.js +531 -0
  805. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/nextValidKeyView.js +110 -0
  806. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/parentViewDidChange.js +67 -0
  807. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/prepareContext.js +180 -0
  808. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/removeChild.js +189 -0
  809. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/render.js +83 -0
  810. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/replaceChild.js +29 -0
  811. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/updateLayer.js +146 -0
  812. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/updateLayerLocation.js +194 -0
  813. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/viewDidResize.js +202 -0
  814. data/lib/frameworks/sproutcore/frameworks/foundation/validators/credit_card.js +125 -0
  815. data/lib/frameworks/sproutcore/frameworks/foundation/validators/date.js +52 -0
  816. data/lib/frameworks/sproutcore/frameworks/foundation/validators/date_time.js +48 -0
  817. data/lib/frameworks/sproutcore/frameworks/foundation/validators/email.js +45 -0
  818. data/lib/frameworks/sproutcore/frameworks/foundation/validators/not_empty.js +33 -0
  819. data/lib/frameworks/sproutcore/frameworks/foundation/validators/number.js +98 -0
  820. data/lib/frameworks/sproutcore/frameworks/foundation/validators/password.js +86 -0
  821. data/lib/frameworks/sproutcore/frameworks/foundation/validators/positive_integer.js +84 -0
  822. data/lib/frameworks/sproutcore/frameworks/foundation/validators/validator.js +326 -0
  823. data/lib/frameworks/sproutcore/frameworks/foundation/views/container.js +139 -0
  824. data/lib/frameworks/sproutcore/frameworks/foundation/views/field.js +320 -0
  825. data/lib/frameworks/sproutcore/frameworks/foundation/views/image.js +180 -0
  826. data/lib/frameworks/sproutcore/frameworks/foundation/views/label.js +339 -0
  827. data/lib/frameworks/sproutcore/frameworks/foundation/views/text_field.js +946 -0
  828. data/lib/frameworks/sproutcore/frameworks/foundation/views/view.js +3313 -0
  829. data/lib/frameworks/sproutcore/frameworks/media/resources/controls.png +0 -0
  830. data/lib/frameworks/sproutcore/frameworks/media/resources/playeras3.fla +0 -0
  831. data/lib/frameworks/sproutcore/frameworks/media/resources/video.css +120 -0
  832. data/lib/frameworks/sproutcore/frameworks/media/resources/videoCanvas.swf +0 -0
  833. data/lib/frameworks/sproutcore/frameworks/media/views/audio.js +739 -0
  834. data/lib/frameworks/sproutcore/frameworks/media/views/controls.js +90 -0
  835. data/lib/frameworks/sproutcore/frameworks/media/views/media_slider.js +243 -0
  836. data/lib/frameworks/sproutcore/frameworks/media/views/mini_controls.js +63 -0
  837. data/lib/frameworks/sproutcore/frameworks/media/views/simple_controls.js +55 -0
  838. data/lib/frameworks/sproutcore/frameworks/media/views/video.js +832 -0
  839. data/lib/frameworks/sproutcore/frameworks/mini/license.js +28 -0
  840. data/lib/frameworks/sproutcore/frameworks/runtime/README +12 -0
  841. data/lib/frameworks/sproutcore/frameworks/runtime/core.js +1061 -0
  842. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/base.js +238 -0
  843. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/indexOf.js +33 -0
  844. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/insertAt.js +121 -0
  845. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/objectAt.js +34 -0
  846. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/popObject.js +50 -0
  847. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/pushObject.js +46 -0
  848. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/rangeObserver.js +371 -0
  849. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/removeAt.js +100 -0
  850. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/removeObject.js +49 -0
  851. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/replace.js +94 -0
  852. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/shiftObject.js +50 -0
  853. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/unshiftObject.js +47 -0
  854. data/lib/frameworks/sproutcore/frameworks/runtime/license.js +28 -0
  855. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/array.js +643 -0
  856. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/comparable.js +45 -0
  857. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/copyable.js +64 -0
  858. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/delegate_support.js +110 -0
  859. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/enumerable.js +1298 -0
  860. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/freezable.js +110 -0
  861. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/observable.js +1347 -0
  862. data/lib/frameworks/sproutcore/frameworks/runtime/private/chain_observer.js +141 -0
  863. data/lib/frameworks/sproutcore/frameworks/runtime/private/observer_queue.js +173 -0
  864. data/lib/frameworks/sproutcore/frameworks/runtime/private/observer_set.js +180 -0
  865. data/lib/frameworks/sproutcore/frameworks/runtime/protocols/observable_protocol.js +40 -0
  866. data/lib/frameworks/sproutcore/frameworks/runtime/protocols/sparse_array_delegate.js +131 -0
  867. data/lib/frameworks/sproutcore/frameworks/runtime/system/binding.js +1000 -0
  868. data/lib/frameworks/sproutcore/frameworks/runtime/system/cookie.js +160 -0
  869. data/lib/frameworks/sproutcore/frameworks/runtime/system/enumerator.js +107 -0
  870. data/lib/frameworks/sproutcore/frameworks/runtime/system/error.js +157 -0
  871. data/lib/frameworks/sproutcore/frameworks/runtime/system/index_set.js +1199 -0
  872. data/lib/frameworks/sproutcore/frameworks/runtime/system/logger.js +452 -0
  873. data/lib/frameworks/sproutcore/frameworks/runtime/system/object.js +888 -0
  874. data/lib/frameworks/sproutcore/frameworks/runtime/system/range_observer.js +271 -0
  875. data/lib/frameworks/sproutcore/frameworks/runtime/system/run_loop.js +295 -0
  876. data/lib/frameworks/sproutcore/frameworks/runtime/system/selection_set.js +697 -0
  877. data/lib/frameworks/sproutcore/frameworks/runtime/system/set.js +532 -0
  878. data/lib/frameworks/sproutcore/frameworks/runtime/system/sparse_array.js +379 -0
  879. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/IsEqual.js +60 -0
  880. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/beget.js +23 -0
  881. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/clone.js +84 -0
  882. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/compare.js +44 -0
  883. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/console.js +16 -0
  884. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/guidFor.js +182 -0
  885. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/inspect.js +27 -0
  886. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/isArray.js +25 -0
  887. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/itemType.js +39 -0
  888. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/keys.js +20 -0
  889. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js +30 -0
  890. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/objectForPropertyPath.js +19 -0
  891. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/tupleForPropertyPath.js +37 -0
  892. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/array.js +57 -0
  893. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/comparable.js +44 -0
  894. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/enumerable.js +622 -0
  895. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/observable/observable.js +667 -0
  896. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/observable/propertyChanges.js +155 -0
  897. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/observable/registerDependentKeys.js +79 -0
  898. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/propertyChanges.js +81 -0
  899. data/lib/frameworks/sproutcore/frameworks/runtime/tests/private/observer_queue/isObservingSuspended.js +55 -0
  900. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/binding.js +395 -0
  901. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/cookie.js +163 -0
  902. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/error.js +53 -0
  903. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/add.js +212 -0
  904. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/addEach.js +49 -0
  905. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/clone.js +43 -0
  906. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/contains.js +74 -0
  907. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/create.js +42 -0
  908. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/indexAfter.js +38 -0
  909. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/indexBefore.js +38 -0
  910. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/intersects.js +74 -0
  911. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/max.js +40 -0
  912. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/min.js +50 -0
  913. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/rangeStartForIndex.js +36 -0
  914. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/remove.js +189 -0
  915. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/removeEach.js +49 -0
  916. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/index_set/without.js +89 -0
  917. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/logger.js +177 -0
  918. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/object/base.js +195 -0
  919. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/object/bindings.js +360 -0
  920. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/range_observer/create.js +59 -0
  921. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/range_observer/destroy.js +75 -0
  922. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/range_observer/objectPropertyDidChange.js +117 -0
  923. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/range_observer/rangeDidChange.js +110 -0
  924. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/range_observer/update.js +65 -0
  925. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/run_loop.js +120 -0
  926. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/selection_set/add.js +92 -0
  927. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/selection_set/copy.js +17 -0
  928. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/selection_set/indexSetForSource.js +98 -0
  929. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/selection_set/isEqual.js +60 -0
  930. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/selection_set/remove.js +111 -0
  931. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/set.js +292 -0
  932. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/sparse_array.js +194 -0
  933. data/lib/frameworks/sproutcore/frameworks/statechart/core.js +11 -0
  934. data/lib/frameworks/sproutcore/frameworks/statechart/mixins/statechart.js +336 -0
  935. data/lib/frameworks/sproutcore/frameworks/statechart/system/state.js +176 -0
  936. data/lib/frameworks/sproutcore/frameworks/statechart/tests/basic.js +90 -0
  937. data/lib/frameworks/sproutcore/frameworks/statechart/tests/history.js +71 -0
  938. data/lib/frameworks/sproutcore/frameworks/statechart/tests/nested.js +59 -0
  939. data/lib/frameworks/sproutcore/frameworks/statechart/tests/transient.js +148 -0
  940. data/lib/frameworks/sproutcore/frameworks/table/mixins/table_delegate.js +41 -0
  941. data/lib/frameworks/sproutcore/frameworks/table/system/table_column.js +125 -0
  942. data/lib/frameworks/sproutcore/frameworks/table/views/table.js +439 -0
  943. data/lib/frameworks/sproutcore/frameworks/table/views/table_cell.js +62 -0
  944. data/lib/frameworks/sproutcore/frameworks/table/views/table_head.js +158 -0
  945. data/lib/frameworks/sproutcore/frameworks/table/views/table_header.js +212 -0
  946. data/lib/frameworks/sproutcore/frameworks/table/views/table_row.js +155 -0
  947. data/lib/frameworks/sproutcore/frameworks/testing/core.js +196 -0
  948. data/lib/frameworks/sproutcore/frameworks/testing/english.lproj/additions.css +8 -0
  949. data/lib/frameworks/sproutcore/frameworks/testing/english.lproj/runner.css +128 -0
  950. data/lib/frameworks/sproutcore/frameworks/testing/english.lproj/testsuite.css +136 -0
  951. data/lib/frameworks/sproutcore/frameworks/testing/extras.js +17 -0
  952. data/lib/frameworks/sproutcore/frameworks/testing/jquery.js +3559 -0
  953. data/lib/frameworks/sproutcore/frameworks/testing/qunit.js +827 -0
  954. data/lib/frameworks/sproutcore/frameworks/testing/system/dump.js +205 -0
  955. data/lib/frameworks/sproutcore/frameworks/testing/system/equiv.js +201 -0
  956. data/lib/frameworks/sproutcore/frameworks/testing/system/plan.js +695 -0
  957. data/lib/frameworks/sproutcore/frameworks/testing/system/runner.js +209 -0
  958. data/lib/frameworks/sproutcore/frameworks/testing/system/suite.js +228 -0
  959. data/lib/frameworks/sproutcore/frameworks/testing/utils.js +62 -0
  960. data/lib/frameworks/sproutcore/lib/index.rhtml +119 -0
  961. data/lib/frameworks/sproutcore/license.js +30 -0
  962. data/lib/frameworks/sproutcore/themes/empty_theme/tests/mini_icons.rhtml +69 -0
  963. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/button.css +41 -0
  964. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/core.css +8 -0
  965. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/backButton.png +0 -0
  966. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/blueButton.png +0 -0
  967. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/cancel.png +0 -0
  968. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/grayButton.png +0 -0
  969. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/leftButton.png +0 -0
  970. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/listArrow.png +0 -0
  971. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/listArrowSel.png +0 -0
  972. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/listGroup.png +0 -0
  973. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/loading.gif +0 -0
  974. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/pinstripes.png +0 -0
  975. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/rightButton.png +0 -0
  976. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/selection.png +0 -0
  977. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/thumb.png +0 -0
  978. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/toggle.png +0 -0
  979. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/toggleOn.png +0 -0
  980. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/toolButton.png +0 -0
  981. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/toolbar.png +0 -0
  982. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/images/whiteButton.png +0 -0
  983. data/lib/frameworks/sproutcore/themes/iphone_theme/english.lproj/strings.js +15 -0
  984. data/lib/frameworks/sproutcore/themes/standard_theme/Source/Panel.drawit/Data +0 -0
  985. data/lib/frameworks/sproutcore/themes/standard_theme/Source/Panel.drawit/QuickLook/Preview.jpg +0 -0
  986. data/lib/frameworks/sproutcore/themes/standard_theme/Source/Panel.drawit/QuickLook/Thumbnail.jpg +0 -0
  987. data/lib/frameworks/sproutcore/themes/standard_theme/Source/SproutCore Theme Buttons.psd +0 -0
  988. data/lib/frameworks/sproutcore/themes/standard_theme/Source/ToolbarView Pattern.drawit/Data +0 -0
  989. data/lib/frameworks/sproutcore/themes/standard_theme/Source/ToolbarView Pattern.drawit/QuickLook/Preview.jpg +0 -0
  990. data/lib/frameworks/sproutcore/themes/standard_theme/Source/ToolbarView Pattern.drawit/QuickLook/Thumbnail.jpg +0 -0
  991. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/10.png +0 -0
  992. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/100.png +0 -0
  993. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/102.png +0 -0
  994. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/110.png +0 -0
  995. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/120.png +0 -0
  996. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/127.png +0 -0
  997. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/18.png +0 -0
  998. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/19.png +0 -0
  999. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/2.png +0 -0
  1000. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/24.png +0 -0
  1001. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/26.png +0 -0
  1002. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/27.png +0 -0
  1003. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/28.png +0 -0
  1004. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/29.png +0 -0
  1005. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/30.png +0 -0
  1006. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/31.png +0 -0
  1007. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/33.png +0 -0
  1008. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/37.png +0 -0
  1009. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/41.png +0 -0
  1010. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/16/99.png +0 -0
  1011. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/10.png +0 -0
  1012. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/100.png +0 -0
  1013. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/102.png +0 -0
  1014. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/110.png +0 -0
  1015. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/120.png +0 -0
  1016. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/127.png +0 -0
  1017. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/18.png +0 -0
  1018. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/19.png +0 -0
  1019. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/2.png +0 -0
  1020. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/24.png +0 -0
  1021. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/26.png +0 -0
  1022. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/27.png +0 -0
  1023. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/28.png +0 -0
  1024. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/29.png +0 -0
  1025. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/30.png +0 -0
  1026. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/31.png +0 -0
  1027. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/33.png +0 -0
  1028. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/37.png +0 -0
  1029. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/41.png +0 -0
  1030. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/24/99.png +0 -0
  1031. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/10.png +0 -0
  1032. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/100.png +0 -0
  1033. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/102.png +0 -0
  1034. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/110.png +0 -0
  1035. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/120.png +0 -0
  1036. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/127.png +0 -0
  1037. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/18.png +0 -0
  1038. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/19.png +0 -0
  1039. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/2.png +0 -0
  1040. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/24.png +0 -0
  1041. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/26.png +0 -0
  1042. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/27.png +0 -0
  1043. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/28.png +0 -0
  1044. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/29.png +0 -0
  1045. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/30.png +0 -0
  1046. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/31.png +0 -0
  1047. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/33.png +0 -0
  1048. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/37.png +0 -0
  1049. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/41.png +0 -0
  1050. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/32/99.png +0 -0
  1051. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/48/10.png +0 -0
  1052. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/48/18.png +0 -0
  1053. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/48/19.png +0 -0
  1054. data/lib/frameworks/sproutcore/themes/standard_theme/Source/icons/48/2.png +0 -0
  1055. data/lib/frameworks/sproutcore/themes/standard_theme/Source/panel-sprite-x.drawit/Data +0 -0
  1056. data/lib/frameworks/sproutcore/themes/standard_theme/Source/panel-sprite-x.drawit/QuickLook/Preview.jpg +0 -0
  1057. data/lib/frameworks/sproutcore/themes/standard_theme/Source/panel-sprite-x.drawit/QuickLook/Thumbnail.jpg +0 -0
  1058. data/lib/frameworks/sproutcore/themes/standard_theme/Source/panel-sprite-y.drawit/Data +0 -0
  1059. data/lib/frameworks/sproutcore/themes/standard_theme/Source/panel-sprite-y.drawit/QuickLook/Preview.jpg +0 -0
  1060. data/lib/frameworks/sproutcore/themes/standard_theme/Source/panel-sprite-y.drawit/QuickLook/Thumbnail.jpg +0 -0
  1061. data/lib/frameworks/sproutcore/themes/standard_theme/Source/sc-theme-repeat-x-2.psd +0 -0
  1062. data/lib/frameworks/sproutcore/themes/standard_theme/Source/sc-theme-repeat-x.psd +0 -0
  1063. data/lib/frameworks/sproutcore/themes/standard_theme/Source/sc-theme-sprite.psd +0 -0
  1064. data/lib/frameworks/sproutcore/themes/standard_theme/Source/sc-theme-ysprite.psd +0 -0
  1065. data/lib/frameworks/sproutcore/themes/standard_theme/Source/shared-icons.psd +0 -0
  1066. data/lib/frameworks/sproutcore/themes/standard_theme/Source/sproutcore-logo.psd +0 -0
  1067. data/lib/frameworks/sproutcore/themes/standard_theme/Source/sticky-note.psd +0 -0
  1068. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/button.css +399 -0
  1069. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/checkbox.css +78 -0
  1070. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/collection.css +135 -0
  1071. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/core.css +76 -0
  1072. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/disclosure.css +57 -0
  1073. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/icons/mini_222222.png +0 -0
  1074. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/icons/mini_454545.png +0 -0
  1075. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/icons/mini_888888.png +0 -0
  1076. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/icons/mini_ffffff.png +0 -0
  1077. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/panels/sprite-x.png +0 -0
  1078. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/panels/sprite-y.png +0 -0
  1079. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/sc-scroller-repeat-x.png +0 -0
  1080. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/sc-scroller-repeat-y.png +0 -0
  1081. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/sc-scroller-sprite.png +0 -0
  1082. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/sc-theme-repeat-x.png +0 -0
  1083. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/sc-theme-ysprite.png +0 -0
  1084. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/images/sc-toolbar-view.png +0 -0
  1085. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/label.css +11 -0
  1086. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/list_item.css +82 -0
  1087. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/menu.css +20 -0
  1088. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/menu_item_view.css +36 -0
  1089. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/pane.css +18 -0
  1090. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/panel.css +33 -0
  1091. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/picker.css +17 -0
  1092. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/progress.css +27 -0
  1093. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/radio.css +125 -0
  1094. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/scroller.css +159 -0
  1095. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/segmented.css +275 -0
  1096. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/slider.css +94 -0
  1097. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/split_view.css +11 -0
  1098. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/tab.css +14 -0
  1099. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/table.css +14 -0
  1100. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/text_field.css +5 -0
  1101. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/toolbar.css +7 -0
  1102. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/well.css +36 -0
  1103. data/lib/gen/Buildfile +16 -0
  1104. data/lib/gen/app/Buildfile +36 -0
  1105. data/lib/gen/app/README +1 -0
  1106. data/lib/gen/app/USAGE +13 -0
  1107. data/lib/gen/app/templates/apps/@target_name@/core.js +27 -0
  1108. data/lib/gen/app/templates/apps/@target_name@/main.js +30 -0
  1109. data/lib/gen/app/templates/apps/@target_name@/resources/loading.rhtml +9 -0
  1110. data/lib/gen/app/templates/apps/@target_name@/resources/main_page.js +24 -0
  1111. data/lib/gen/controller/Buildfile +18 -0
  1112. data/lib/gen/controller/README +1 -0
  1113. data/lib/gen/controller/USAGE +13 -0
  1114. data/lib/gen/controller/templates/controllers/@filename@.js +18 -0
  1115. data/lib/gen/controller/templates/tests/controllers/@filename@.js +15 -0
  1116. data/lib/gen/data-source/Buildfile +18 -0
  1117. data/lib/gen/data-source/README +1 -0
  1118. data/lib/gen/data-source/USAGE +15 -0
  1119. data/lib/gen/data-source/templates/data_sources/@filename@.js +64 -0
  1120. data/lib/gen/design/Buildfile +23 -0
  1121. data/lib/gen/design/README +1 -0
  1122. data/lib/gen/design/USAGE +10 -0
  1123. data/lib/gen/design/templates/resources/@filename@.js +16 -0
  1124. data/lib/gen/framework/Buildfile +36 -0
  1125. data/lib/gen/framework/README +1 -0
  1126. data/lib/gen/framework/USAGE +13 -0
  1127. data/lib/gen/framework/templates/frameworks/@target_name@/core.js +21 -0
  1128. data/lib/gen/framework/templates/frameworks/@target_name@/english.lproj/strings.js +15 -0
  1129. data/lib/gen/language/Buildfile +26 -0
  1130. data/lib/gen/language/README +1 -0
  1131. data/lib/gen/language/USAGE +13 -0
  1132. data/lib/gen/language/templates/@filename@/strings.js +14 -0
  1133. data/lib/gen/model/Buildfile +16 -0
  1134. data/lib/gen/model/README +1 -0
  1135. data/lib/gen/model/USAGE +15 -0
  1136. data/lib/gen/model/templates/fixtures/@filename@.js +35 -0
  1137. data/lib/gen/model/templates/models/@filename@.js +19 -0
  1138. data/lib/gen/model/templates/tests/models/@filename@.js +15 -0
  1139. data/lib/gen/page/Buildfile +36 -0
  1140. data/lib/gen/page/README +1 -0
  1141. data/lib/gen/page/USAGE +15 -0
  1142. data/lib/gen/page/templates/pages/@target_name@/Buildfile +16 -0
  1143. data/lib/gen/page/templates/pages/@target_name@/core.js +22 -0
  1144. data/lib/gen/page/templates/pages/@target_name@/en.lproj/strings.js +14 -0
  1145. data/lib/gen/page/templates/pages/@target_name@/resources/body.css +1 -0
  1146. data/lib/gen/page/templates/pages/@target_name@/resources/body.rhtml +7 -0
  1147. data/lib/gen/project/Buildfile +45 -0
  1148. data/lib/gen/project/INIT +3 -0
  1149. data/lib/gen/project/README +1 -0
  1150. data/lib/gen/project/USAGE +2 -0
  1151. data/lib/gen/project/templates/@filename@/Buildfile +7 -0
  1152. data/lib/gen/project/templates/@filename@/README +7 -0
  1153. data/lib/gen/responder/Buildfile +18 -0
  1154. data/lib/gen/responder/README +1 -0
  1155. data/lib/gen/responder/USAGE +15 -0
  1156. data/lib/gen/responder/templates/states/@filename@.js +39 -0
  1157. data/lib/gen/test/Buildfile +25 -0
  1158. data/lib/gen/test/README +1 -0
  1159. data/lib/gen/test/USAGE +12 -0
  1160. data/lib/gen/test/templates/tests/@filename@.js +15 -0
  1161. data/lib/gen/theme/Buildfile +36 -0
  1162. data/lib/gen/theme/README +1 -0
  1163. data/lib/gen/theme/USAGE +13 -0
  1164. data/lib/gen/theme/templates/themes/@target_name@/resources/theme_styles.css +11 -0
  1165. data/lib/gen/view/Buildfile +18 -0
  1166. data/lib/gen/view/README +1 -0
  1167. data/lib/gen/view/USAGE +13 -0
  1168. data/lib/gen/view/templates/tests/views/@filename@.js +15 -0
  1169. data/lib/gen/view/templates/views/@filename@.js +18 -0
  1170. data/lib/sproutcore.rb +167 -0
  1171. data/lib/sproutcore/builders.rb +13 -0
  1172. data/lib/sproutcore/builders/base.rb +90 -0
  1173. data/lib/sproutcore/builders/bundle.rb +63 -0
  1174. data/lib/sproutcore/builders/combine.rb +60 -0
  1175. data/lib/sproutcore/builders/html.rb +211 -0
  1176. data/lib/sproutcore/builders/javascript.rb +101 -0
  1177. data/lib/sproutcore/builders/less.rb +41 -0
  1178. data/lib/sproutcore/builders/minify.rb +159 -0
  1179. data/lib/sproutcore/builders/sass.rb +65 -0
  1180. data/lib/sproutcore/builders/strings.rb +45 -0
  1181. data/lib/sproutcore/builders/stylesheet.rb +56 -0
  1182. data/lib/sproutcore/builders/test.rb +59 -0
  1183. data/lib/sproutcore/builders/test_index.rb +26 -0
  1184. data/lib/sproutcore/buildfile.rb +490 -0
  1185. data/lib/sproutcore/buildfile/build_task.rb +33 -0
  1186. data/lib/sproutcore/buildfile/buildfile_dsl.rb +169 -0
  1187. data/lib/sproutcore/buildfile/cloneable.rb +34 -0
  1188. data/lib/sproutcore/buildfile/early_time.rb +30 -0
  1189. data/lib/sproutcore/buildfile/invocation_chain.rb +64 -0
  1190. data/lib/sproutcore/buildfile/namespace.rb +33 -0
  1191. data/lib/sproutcore/buildfile/string_ext.rb +202 -0
  1192. data/lib/sproutcore/buildfile/task.rb +333 -0
  1193. data/lib/sproutcore/buildfile/task_arguments.rb +106 -0
  1194. data/lib/sproutcore/buildfile/task_manager.rb +195 -0
  1195. data/lib/sproutcore/deprecated/view_helper.rb +662 -0
  1196. data/lib/sproutcore/helpers.rb +11 -0
  1197. data/lib/sproutcore/helpers/capture_helper.rb +30 -0
  1198. data/lib/sproutcore/helpers/cssmin.rb +202 -0
  1199. data/lib/sproutcore/helpers/dom_id_helper.rb +21 -0
  1200. data/lib/sproutcore/helpers/entry_sorter.rb +128 -0
  1201. data/lib/sproutcore/helpers/html5_manifest.rb +88 -0
  1202. data/lib/sproutcore/helpers/packed_optimizer.rb +102 -0
  1203. data/lib/sproutcore/helpers/static_helper.rb +376 -0
  1204. data/lib/sproutcore/helpers/tag_helper.rb +182 -0
  1205. data/lib/sproutcore/helpers/text_helper.rb +303 -0
  1206. data/lib/sproutcore/models.rb +8 -0
  1207. data/lib/sproutcore/models/generator.rb +493 -0
  1208. data/lib/sproutcore/models/hash_struct.rb +124 -0
  1209. data/lib/sproutcore/models/manifest.rb +385 -0
  1210. data/lib/sproutcore/models/manifest_entry.rb +355 -0
  1211. data/lib/sproutcore/models/project.rb +267 -0
  1212. data/lib/sproutcore/models/target.rb +758 -0
  1213. data/lib/sproutcore/rack.rb +7 -0
  1214. data/lib/sproutcore/rack/builder.rb +344 -0
  1215. data/lib/sproutcore/rack/dev.rb +92 -0
  1216. data/lib/sproutcore/rack/docs.rb +24 -0
  1217. data/lib/sproutcore/rack/filesystem.rb +324 -0
  1218. data/lib/sproutcore/rack/proxy.rb +149 -0
  1219. data/lib/sproutcore/rack/service.rb +153 -0
  1220. data/lib/sproutcore/rack/test_runner.rb +24 -0
  1221. data/lib/sproutcore/render_engines/erubis.rb +55 -0
  1222. data/lib/sproutcore/render_engines/haml.rb +39 -0
  1223. data/lib/sproutcore/tools.rb +360 -0
  1224. data/lib/sproutcore/tools/build.rb +106 -0
  1225. data/lib/sproutcore/tools/build_number.rb +23 -0
  1226. data/lib/sproutcore/tools/docs.rb +53 -0
  1227. data/lib/sproutcore/tools/gen.rb +101 -0
  1228. data/lib/sproutcore/tools/init.rb +40 -0
  1229. data/lib/sproutcore/tools/manifest.rb +85 -0
  1230. data/lib/sproutcore/tools/server.rb +48 -0
  1231. data/lib/sproutcore/vendor/github_gem_lint.rb +22 -0
  1232. data/lib/sproutcore/vendor/jsdoc/README.txt +151 -0
  1233. data/lib/sproutcore/vendor/jsdoc/app/frame.js +33 -0
  1234. data/lib/sproutcore/vendor/jsdoc/app/frame/Chain.js +102 -0
  1235. data/lib/sproutcore/vendor/jsdoc/app/frame/Dumper.js +144 -0
  1236. data/lib/sproutcore/vendor/jsdoc/app/frame/Hash.js +47 -0
  1237. data/lib/sproutcore/vendor/jsdoc/app/frame/Link.js +142 -0
  1238. data/lib/sproutcore/vendor/jsdoc/app/frame/Namespace.js +10 -0
  1239. data/lib/sproutcore/vendor/jsdoc/app/frame/Opt.js +134 -0
  1240. data/lib/sproutcore/vendor/jsdoc/app/frame/Reflection.js +26 -0
  1241. data/lib/sproutcore/vendor/jsdoc/app/frame/String.js +93 -0
  1242. data/lib/sproutcore/vendor/jsdoc/app/frame/Testrun.js +129 -0
  1243. data/lib/sproutcore/vendor/jsdoc/app/handlers/FOODOC.js +26 -0
  1244. data/lib/sproutcore/vendor/jsdoc/app/handlers/XMLDOC.js +26 -0
  1245. data/lib/sproutcore/vendor/jsdoc/app/handlers/XMLDOC/DomReader.js +159 -0
  1246. data/lib/sproutcore/vendor/jsdoc/app/handlers/XMLDOC/XMLDoc.js +16 -0
  1247. data/lib/sproutcore/vendor/jsdoc/app/handlers/XMLDOC/XMLParse.js +292 -0
  1248. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC.js +98 -0
  1249. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/DocComment.js +200 -0
  1250. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/DocTag.js +294 -0
  1251. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/JsDoc.js +162 -0
  1252. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/JsPlate.js +100 -0
  1253. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/Lang.js +144 -0
  1254. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/Parser.js +109 -0
  1255. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/PluginManager.js +33 -0
  1256. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/Symbol.js +681 -0
  1257. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/SymbolSet.js +226 -0
  1258. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/TextStream.js +41 -0
  1259. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/Token.js +18 -0
  1260. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/TokenReader.js +332 -0
  1261. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/TokenStream.js +133 -0
  1262. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/Util.js +32 -0
  1263. data/lib/sproutcore/vendor/jsdoc/app/lib/JSDOC/Walker.js +453 -0
  1264. data/lib/sproutcore/vendor/jsdoc/app/main.js +74 -0
  1265. data/lib/sproutcore/vendor/jsdoc/app/plugins/commentSrcJson.js +19 -0
  1266. data/lib/sproutcore/vendor/jsdoc/app/plugins/frameworkPrototype.js +16 -0
  1267. data/lib/sproutcore/vendor/jsdoc/app/plugins/functionCall.js +10 -0
  1268. data/lib/sproutcore/vendor/jsdoc/app/plugins/publishSrcHilite.js +62 -0
  1269. data/lib/sproutcore/vendor/jsdoc/app/plugins/sproutcoreTags.js +26 -0
  1270. data/lib/sproutcore/vendor/jsdoc/app/plugins/symbolLink.js +9 -0
  1271. data/lib/sproutcore/vendor/jsdoc/app/plugins/tagParamConfig.js +31 -0
  1272. data/lib/sproutcore/vendor/jsdoc/app/plugins/tagSynonyms.js +43 -0
  1273. data/lib/sproutcore/vendor/jsdoc/app/run.js +346 -0
  1274. data/lib/sproutcore/vendor/jsdoc/app/t/TestDoc.js +144 -0
  1275. data/lib/sproutcore/vendor/jsdoc/app/t/runner.js +13 -0
  1276. data/lib/sproutcore/vendor/jsdoc/app/test.js +304 -0
  1277. data/lib/sproutcore/vendor/jsdoc/app/test/addon.js +24 -0
  1278. data/lib/sproutcore/vendor/jsdoc/app/test/anon_inner.js +14 -0
  1279. data/lib/sproutcore/vendor/jsdoc/app/test/augments.js +31 -0
  1280. data/lib/sproutcore/vendor/jsdoc/app/test/augments2.js +26 -0
  1281. data/lib/sproutcore/vendor/jsdoc/app/test/borrows.js +41 -0
  1282. data/lib/sproutcore/vendor/jsdoc/app/test/borrows2.js +23 -0
  1283. data/lib/sproutcore/vendor/jsdoc/app/test/config.js +22 -0
  1284. data/lib/sproutcore/vendor/jsdoc/app/test/constructs.js +18 -0
  1285. data/lib/sproutcore/vendor/jsdoc/app/test/encoding.js +10 -0
  1286. data/lib/sproutcore/vendor/jsdoc/app/test/encoding_other.js +12 -0
  1287. data/lib/sproutcore/vendor/jsdoc/app/test/functions_anon.js +39 -0
  1288. data/lib/sproutcore/vendor/jsdoc/app/test/functions_nested.js +33 -0
  1289. data/lib/sproutcore/vendor/jsdoc/app/test/global.js +13 -0
  1290. data/lib/sproutcore/vendor/jsdoc/app/test/globals.js +25 -0
  1291. data/lib/sproutcore/vendor/jsdoc/app/test/ignore.js +10 -0
  1292. data/lib/sproutcore/vendor/jsdoc/app/test/inner.js +16 -0
  1293. data/lib/sproutcore/vendor/jsdoc/app/test/jsdoc_test.js +477 -0
  1294. data/lib/sproutcore/vendor/jsdoc/app/test/lend.js +33 -0
  1295. data/lib/sproutcore/vendor/jsdoc/app/test/memberof.js +20 -0
  1296. data/lib/sproutcore/vendor/jsdoc/app/test/memberof_constructor.js +15 -0
  1297. data/lib/sproutcore/vendor/jsdoc/app/test/name.js +19 -0
  1298. data/lib/sproutcore/vendor/jsdoc/app/test/namespace_nested.js +23 -0
  1299. data/lib/sproutcore/vendor/jsdoc/app/test/nocode.js +13 -0
  1300. data/lib/sproutcore/vendor/jsdoc/app/test/oblit_anon.js +20 -0
  1301. data/lib/sproutcore/vendor/jsdoc/app/test/overview.js +20 -0
  1302. data/lib/sproutcore/vendor/jsdoc/app/test/param_inline.js +37 -0
  1303. data/lib/sproutcore/vendor/jsdoc/app/test/params_optional.js +8 -0
  1304. data/lib/sproutcore/vendor/jsdoc/app/test/prototype.js +17 -0
  1305. data/lib/sproutcore/vendor/jsdoc/app/test/prototype_nested.js +9 -0
  1306. data/lib/sproutcore/vendor/jsdoc/app/test/prototype_oblit.js +13 -0
  1307. data/lib/sproutcore/vendor/jsdoc/app/test/prototype_oblit_constructor.js +24 -0
  1308. data/lib/sproutcore/vendor/jsdoc/app/test/public.js +10 -0
  1309. data/lib/sproutcore/vendor/jsdoc/app/test/shared.js +42 -0
  1310. data/lib/sproutcore/vendor/jsdoc/app/test/shared2.js +2 -0
  1311. data/lib/sproutcore/vendor/jsdoc/app/test/shortcuts.js +22 -0
  1312. data/lib/sproutcore/vendor/jsdoc/app/test/static_this.js +13 -0
  1313. data/lib/sproutcore/vendor/jsdoc/app/test/synonyms.js +23 -0
  1314. data/lib/sproutcore/vendor/jsdoc/app/test/tosource.js +23 -0
  1315. data/lib/sproutcore/vendor/jsdoc/app/test/variable_redefine.js +14 -0
  1316. data/lib/sproutcore/vendor/jsdoc/changes.txt +47 -0
  1317. data/lib/sproutcore/vendor/jsdoc/conf/sample.conf +31 -0
  1318. data/lib/sproutcore/vendor/jsdoc/java/build.xml +36 -0
  1319. data/lib/sproutcore/vendor/jsdoc/java/build_1.4.xml +36 -0
  1320. data/lib/sproutcore/vendor/jsdoc/java/classes/js.jar +0 -0
  1321. data/lib/sproutcore/vendor/jsdoc/java/src/JsDebugRun.java +21 -0
  1322. data/lib/sproutcore/vendor/jsdoc/java/src/JsRun.java +21 -0
  1323. data/lib/sproutcore/vendor/jsdoc/jsdebug.jar +0 -0
  1324. data/lib/sproutcore/vendor/jsdoc/jsrun.jar +0 -0
  1325. data/lib/sproutcore/vendor/jsdoc/t/TestDoc.js +144 -0
  1326. data/lib/sproutcore/vendor/jsdoc/t/runner.js +13 -0
  1327. data/lib/sproutcore/vendor/jsdoc/test.js +304 -0
  1328. data/lib/sproutcore/vendor/jsdoc/test/addon.js +24 -0
  1329. data/lib/sproutcore/vendor/jsdoc/test/anon_inner.js +14 -0
  1330. data/lib/sproutcore/vendor/jsdoc/test/augments.js +31 -0
  1331. data/lib/sproutcore/vendor/jsdoc/test/augments2.js +26 -0
  1332. data/lib/sproutcore/vendor/jsdoc/test/borrows.js +41 -0
  1333. data/lib/sproutcore/vendor/jsdoc/test/borrows2.js +23 -0
  1334. data/lib/sproutcore/vendor/jsdoc/test/config.js +22 -0
  1335. data/lib/sproutcore/vendor/jsdoc/test/constructs.js +18 -0
  1336. data/lib/sproutcore/vendor/jsdoc/test/encoding.js +10 -0
  1337. data/lib/sproutcore/vendor/jsdoc/test/encoding_other.js +12 -0
  1338. data/lib/sproutcore/vendor/jsdoc/test/functions_anon.js +39 -0
  1339. data/lib/sproutcore/vendor/jsdoc/test/functions_nested.js +33 -0
  1340. data/lib/sproutcore/vendor/jsdoc/test/global.js +13 -0
  1341. data/lib/sproutcore/vendor/jsdoc/test/globals.js +25 -0
  1342. data/lib/sproutcore/vendor/jsdoc/test/ignore.js +10 -0
  1343. data/lib/sproutcore/vendor/jsdoc/test/inner.js +16 -0
  1344. data/lib/sproutcore/vendor/jsdoc/test/jsdoc_test.js +477 -0
  1345. data/lib/sproutcore/vendor/jsdoc/test/lend.js +33 -0
  1346. data/lib/sproutcore/vendor/jsdoc/test/memberof.js +20 -0
  1347. data/lib/sproutcore/vendor/jsdoc/test/memberof_constructor.js +15 -0
  1348. data/lib/sproutcore/vendor/jsdoc/test/name.js +19 -0
  1349. data/lib/sproutcore/vendor/jsdoc/test/namespace_nested.js +23 -0
  1350. data/lib/sproutcore/vendor/jsdoc/test/nocode.js +13 -0
  1351. data/lib/sproutcore/vendor/jsdoc/test/oblit_anon.js +20 -0
  1352. data/lib/sproutcore/vendor/jsdoc/test/overview.js +20 -0
  1353. data/lib/sproutcore/vendor/jsdoc/test/param_inline.js +37 -0
  1354. data/lib/sproutcore/vendor/jsdoc/test/params_optional.js +8 -0
  1355. data/lib/sproutcore/vendor/jsdoc/test/prototype.js +17 -0
  1356. data/lib/sproutcore/vendor/jsdoc/test/prototype_nested.js +9 -0
  1357. data/lib/sproutcore/vendor/jsdoc/test/prototype_oblit.js +13 -0
  1358. data/lib/sproutcore/vendor/jsdoc/test/prototype_oblit_constructor.js +24 -0
  1359. data/lib/sproutcore/vendor/jsdoc/test/public.js +10 -0
  1360. data/lib/sproutcore/vendor/jsdoc/test/shared.js +42 -0
  1361. data/lib/sproutcore/vendor/jsdoc/test/shared2.js +2 -0
  1362. data/lib/sproutcore/vendor/jsdoc/test/shortcuts.js +22 -0
  1363. data/lib/sproutcore/vendor/jsdoc/test/static_this.js +13 -0
  1364. data/lib/sproutcore/vendor/jsdoc/test/synonyms.js +23 -0
  1365. data/lib/sproutcore/vendor/jsdoc/test/tosource.js +23 -0
  1366. data/lib/sproutcore/vendor/jsdoc/test/variable_redefine.js +14 -0
  1367. data/lib/sproutcore/vendor/yui-compressor/SCyuicompressor-2.4.2.jar +0 -0
  1368. data/lib/sproutcore/vendor/yui-compressor/yuicompressor-2.4.2.jar +0 -0
  1369. data/lib/sproutcore/version.rb +11 -0
  1370. data/spec/buildtasks/build/copy_spec.rb +60 -0
  1371. data/spec/buildtasks/build/spec_helper.rb +36 -0
  1372. data/spec/buildtasks/manifest/catalog_spec.rb +48 -0
  1373. data/spec/buildtasks/manifest/hide_buildfiles_spec.rb +126 -0
  1374. data/spec/buildtasks/manifest/localize_spec.rb +97 -0
  1375. data/spec/buildtasks/manifest/prepare_build_tasks/bundle_spec.rb +254 -0
  1376. data/spec/buildtasks/manifest/prepare_build_tasks/combine_spec.rb +254 -0
  1377. data/spec/buildtasks/manifest/prepare_build_tasks/css_spec.rb +87 -0
  1378. data/spec/buildtasks/manifest/prepare_build_tasks/html_spec.rb +175 -0
  1379. data/spec/buildtasks/manifest/prepare_build_tasks/javascript_spec.rb +65 -0
  1380. data/spec/buildtasks/manifest/prepare_build_tasks/minify_spec.rb +70 -0
  1381. data/spec/buildtasks/manifest/prepare_build_tasks/packed_spec.rb +152 -0
  1382. data/spec/buildtasks/manifest/prepare_build_tasks/sass_spec.rb +98 -0
  1383. data/spec/buildtasks/manifest/prepare_build_tasks/strings_spec.rb +64 -0
  1384. data/spec/buildtasks/manifest/prepare_build_tasks/tests_spec.rb +163 -0
  1385. data/spec/buildtasks/manifest/prepare_spec.rb +43 -0
  1386. data/spec/buildtasks/manifest/spec_helper.rb +35 -0
  1387. data/spec/buildtasks/target_spec.rb +270 -0
  1388. data/spec/fixtures/builder_tests/Buildfile +20 -0
  1389. data/spec/fixtures/builder_tests/apps/bundle_test/bundle.js +1 -0
  1390. data/spec/fixtures/builder_tests/apps/combine_test/a.js +1 -0
  1391. data/spec/fixtures/builder_tests/apps/combine_test/b.js +1 -0
  1392. data/spec/fixtures/builder_tests/apps/combine_test/c.js +1 -0
  1393. data/spec/fixtures/builder_tests/apps/combine_test/english.lproj/a.css +1 -0
  1394. data/spec/fixtures/builder_tests/apps/combine_test/english.lproj/b.css +1 -0
  1395. data/spec/fixtures/builder_tests/apps/combine_test/english.lproj/c.css +1 -0
  1396. data/spec/fixtures/builder_tests/apps/html_test/english.lproj/bar1_sample.rhtml +2 -0
  1397. data/spec/fixtures/builder_tests/apps/html_test/english.lproj/erb_sample.html.erb +1 -0
  1398. data/spec/fixtures/builder_tests/apps/html_test/english.lproj/icons/image.png +0 -0
  1399. data/spec/fixtures/builder_tests/apps/html_test/english.lproj/image.jpg +0 -0
  1400. data/spec/fixtures/builder_tests/apps/html_test/english.lproj/rhtml_sample.rhtml +1 -0
  1401. data/spec/fixtures/builder_tests/apps/html_test/english.lproj/strings.js +4 -0
  1402. data/spec/fixtures/builder_tests/apps/html_test/english.lproj/style.css +0 -0
  1403. data/spec/fixtures/builder_tests/apps/html_test/french.lproj/french-icons/fr.png +0 -0
  1404. data/spec/fixtures/builder_tests/apps/html_test/french.lproj/strings.js +4 -0
  1405. data/spec/fixtures/builder_tests/apps/html_test/lib/layout_template.rhtml +1 -0
  1406. data/spec/fixtures/builder_tests/apps/html_test/scripts.js +0 -0
  1407. data/spec/fixtures/builder_tests/apps/javascript_test/sc_static.js +15 -0
  1408. data/spec/fixtures/builder_tests/apps/javascript_test/sc_super.js +4 -0
  1409. data/spec/fixtures/builder_tests/apps/javascript_test/strings.js +7 -0
  1410. data/spec/fixtures/builder_tests/apps/less_test/sample.less +4 -0
  1411. data/spec/fixtures/builder_tests/apps/sass_test/sample.sass +4 -0
  1412. data/spec/fixtures/builder_tests/apps/sass_test/sample.scss +4 -0
  1413. data/spec/fixtures/builder_tests/apps/strings_test/lproj/strings.js +8 -0
  1414. data/spec/fixtures/builder_tests/apps/stylesheet_test/build_directives.css +9 -0
  1415. data/spec/fixtures/builder_tests/apps/stylesheet_test/sc_static.css +12 -0
  1416. data/spec/fixtures/builder_tests/apps/test_test/lib/alt_layout.rhtml +1 -0
  1417. data/spec/fixtures/builder_tests/apps/test_test/lib/test_layout.rhtml +3 -0
  1418. data/spec/fixtures/builder_tests/apps/test_test/tests/qunit_test.js +1 -0
  1419. data/spec/fixtures/builder_tests/apps/test_test/tests/qunit_test2.js +1 -0
  1420. data/spec/fixtures/builder_tests/apps/test_test/tests/rhtml_test.rhtml +4 -0
  1421. data/spec/fixtures/builder_tests/frameworks/debug/core.js +0 -0
  1422. data/spec/fixtures/builder_tests/frameworks/debug/english.lproj/dummy.css +0 -0
  1423. data/spec/fixtures/builder_tests/frameworks/dynamic_req_target_1/dynamic_req_js_1.js +0 -0
  1424. data/spec/fixtures/builder_tests/frameworks/dynamic_req_target_1/english.lproj/dynamic_req_style_1.css +0 -0
  1425. data/spec/fixtures/builder_tests/frameworks/qunit/core.js +0 -0
  1426. data/spec/fixtures/builder_tests/frameworks/qunit/english.lproj/dummy.css +0 -0
  1427. data/spec/fixtures/builder_tests/frameworks/req_target_1/english.lproj/req_style_1.css +0 -0
  1428. data/spec/fixtures/builder_tests/frameworks/req_target_1/english.lproj/strings.js +4 -0
  1429. data/spec/fixtures/builder_tests/frameworks/req_target_1/english.lproj/test.rhtml +1 -0
  1430. data/spec/fixtures/builder_tests/frameworks/req_target_1/req_js_1.js +0 -0
  1431. data/spec/fixtures/builder_tests/frameworks/req_target_2/english.lproj/req_style_2.css +0 -0
  1432. data/spec/fixtures/builder_tests/frameworks/req_target_2/english.lproj/test.rhtml +1 -0
  1433. data/spec/fixtures/builder_tests/frameworks/req_target_2/javascript.js +1 -0
  1434. data/spec/fixtures/builder_tests/frameworks/req_target_2/lib/alt_layout.rhtml +0 -0
  1435. data/spec/fixtures/builder_tests/frameworks/req_target_2/req_js_2.js +0 -0
  1436. data/spec/fixtures/builder_tests/themes/sample_theme/Buildfile +1 -0
  1437. data/spec/fixtures/buildfiles/basic/Buildfile +11 -0
  1438. data/spec/fixtures/buildfiles/basic/task_module.rake +6 -0
  1439. data/spec/fixtures/buildfiles/installed/Buildfile +5 -0
  1440. data/spec/fixtures/buildfiles/installed/Buildfile2 +5 -0
  1441. data/spec/fixtures/buildfiles/project_test/Buildfile +4 -0
  1442. data/spec/fixtures/buildfiles/project_test/not_project/Buildfile +2 -0
  1443. data/spec/fixtures/buildfiles/project_test/not_project/child/PLACEHOLDER +0 -0
  1444. data/spec/fixtures/entry_for_project/Buildfile +1 -0
  1445. data/spec/fixtures/entry_for_project/apps/test_app/entry.txt +0 -0
  1446. data/spec/fixtures/entry_for_project/apps/test_app/frameworks/nested/PLACEHOLDER +0 -0
  1447. data/spec/fixtures/entry_for_project/frameworks/shared/PLACEHOLDER +0 -0
  1448. data/spec/fixtures/entry_for_project/frameworks/unrelated/PLACEHOLDER +0 -0
  1449. data/spec/fixtures/find_targets/custom/Buildfile +8 -0
  1450. data/spec/fixtures/find_targets/custom/bars/bar1/bars/bar1/PLACEHOLDER +0 -0
  1451. data/spec/fixtures/find_targets/custom/bars/bar1/bars/bar2/PLACEHOLDER +0 -0
  1452. data/spec/fixtures/find_targets/custom/bars/bar1/foos/foo1/PLACEHOLDER +0 -0
  1453. data/spec/fixtures/find_targets/custom/bars/bar1/foos/foo2/PLACEHOLDER +0 -0
  1454. data/spec/fixtures/find_targets/custom/foos/custom_foos/Buildfile +5 -0
  1455. data/spec/fixtures/find_targets/custom/foos/custom_foos/custom_foodir/foo1/PLACEHOLDER +0 -0
  1456. data/spec/fixtures/find_targets/custom/foos/custom_foos/custom_foodir/foo2/PLACEHOLDER +0 -0
  1457. data/spec/fixtures/find_targets/custom/foos/custom_foos/foos/not_foo1/PLACEHOLDER +0 -0
  1458. data/spec/fixtures/find_targets/custom/foos/foo1/bars/bar1/PLACEHOLDER +0 -0
  1459. data/spec/fixtures/find_targets/custom/foos/foo1/bars/bar2/PLACEHOLDER +0 -0
  1460. data/spec/fixtures/find_targets/nested/Buildfile +8 -0
  1461. data/spec/fixtures/find_targets/nested/apps/app1/Buildfile +1 -0
  1462. data/spec/fixtures/find_targets/nested/apps/app1/apps/nested_app/PLACEHOLDER +0 -0
  1463. data/spec/fixtures/find_targets/standard/Apps/app1/frameworks/framework1/PLACEHOLDER +0 -0
  1464. data/spec/fixtures/find_targets/standard/Apps/app1/frameworks/framework2/PLACEHOLDER +0 -0
  1465. data/spec/fixtures/find_targets/standard/clients/client1/PLACEHOLDER +0 -0
  1466. data/spec/fixtures/find_targets/standard/frameworks/framework1/frameworks/framework1/PLACEHOLDER +0 -0
  1467. data/spec/fixtures/find_targets/standard/frameworks/framework2/PLACEHOLDER +0 -0
  1468. data/spec/fixtures/find_targets/standard/themes/theme1/PLACEHOLDER +0 -0
  1469. data/spec/fixtures/find_targets/standard/themes/theme2/PLACEHOLDER +0 -0
  1470. data/spec/fixtures/languages/apps/caps_long_names/English.lproj/PLACEHOLDER +0 -0
  1471. data/spec/fixtures/languages/apps/caps_long_names/FreNCH.lproj/PLACEHOLDER +0 -0
  1472. data/spec/fixtures/languages/apps/caps_long_names/UnknOWN.lproj/PLACEHOLDER +0 -0
  1473. data/spec/fixtures/languages/apps/long_names/english.lproj/PLACEHOLDER +0 -0
  1474. data/spec/fixtures/languages/apps/long_names/french.lproj/PLACEHOLDER +0 -0
  1475. data/spec/fixtures/languages/apps/long_names/german.lproj/PLACEHOLDER +0 -0
  1476. data/spec/fixtures/languages/apps/long_names/italian.lproj/PLACEHOLDER +0 -0
  1477. data/spec/fixtures/languages/apps/long_names/japanese.lproj/PLACEHOLDER +0 -0
  1478. data/spec/fixtures/languages/apps/long_names/spanish.lproj/PLACEHOLDER +0 -0
  1479. data/spec/fixtures/languages/apps/long_names/unknown.lproj/PLACEHOLDER +0 -0
  1480. data/spec/fixtures/languages/apps/no_names/PLACEHOLDER +0 -0
  1481. data/spec/fixtures/languages/apps/short_names/de.lproj/PLACEHOLDER +0 -0
  1482. data/spec/fixtures/languages/apps/short_names/en-CA.lproj/PLACEHOLDER +0 -0
  1483. data/spec/fixtures/languages/apps/short_names/en-GB.lproj/PLACEHOLDER +0 -0
  1484. data/spec/fixtures/languages/apps/short_names/en-US.lproj/PLACEHOLDER +0 -0
  1485. data/spec/fixtures/languages/apps/short_names/en.lproj/PLACEHOLDER +0 -0
  1486. data/spec/fixtures/languages/apps/short_names/es.lproj/PLACEHOLDER +0 -0
  1487. data/spec/fixtures/languages/apps/short_names/foo.lproj/PLACEHOLDER +0 -0
  1488. data/spec/fixtures/languages/apps/short_names/fr.lproj/PLACEHOLDER +0 -0
  1489. data/spec/fixtures/languages/apps/short_names/it.lproj/PLACEHOLDER +0 -0
  1490. data/spec/fixtures/languages/apps/short_names/ja.lproj/PLACEHOLDER +0 -0
  1491. data/spec/fixtures/ordered_entries/apps/no_requires/1.js +1 -0
  1492. data/spec/fixtures/ordered_entries/apps/no_requires/B.js +1 -0
  1493. data/spec/fixtures/ordered_entries/apps/no_requires/a.js +1 -0
  1494. data/spec/fixtures/ordered_entries/apps/no_requires/a/a.js +1 -0
  1495. data/spec/fixtures/ordered_entries/apps/no_requires/a/b.js +1 -0
  1496. data/spec/fixtures/ordered_entries/apps/no_requires/b/a.js +1 -0
  1497. data/spec/fixtures/ordered_entries/apps/no_requires/c.js +1 -0
  1498. data/spec/fixtures/ordered_entries/apps/no_requires/core.js +1 -0
  1499. data/spec/fixtures/ordered_entries/apps/no_requires/english.lproj/B.css +0 -0
  1500. data/spec/fixtures/ordered_entries/apps/no_requires/english.lproj/a.css +0 -0
  1501. data/spec/fixtures/ordered_entries/apps/no_requires/english.lproj/a/a.css +0 -0
  1502. data/spec/fixtures/ordered_entries/apps/no_requires/english.lproj/a/b.css +0 -0
  1503. data/spec/fixtures/ordered_entries/apps/no_requires/english.lproj/b/a.css +0 -0
  1504. data/spec/fixtures/ordered_entries/apps/no_requires/english.lproj/c.css +0 -0
  1505. data/spec/fixtures/ordered_entries/apps/no_requires/english.lproj/strings.js +1 -0
  1506. data/spec/fixtures/ordered_entries/apps/no_requires/main.js +1 -0
  1507. data/spec/fixtures/ordered_entries/apps/no_requires/resources/main_page.js +1 -0
  1508. data/spec/fixtures/ordered_entries/apps/no_requires/t.js +1 -0
  1509. data/spec/fixtures/ordered_entries/apps/no_requires/utils.js +1 -0
  1510. data/spec/fixtures/ordered_entries/apps/with_requires/a.js +2 -0
  1511. data/spec/fixtures/ordered_entries/apps/with_requires/b.js +3 -0
  1512. data/spec/fixtures/ordered_entries/apps/with_requires/c.js +2 -0
  1513. data/spec/fixtures/ordered_entries/apps/with_requires/english.lproj/a.css +2 -0
  1514. data/spec/fixtures/ordered_entries/apps/with_requires/english.lproj/b.css +2 -0
  1515. data/spec/fixtures/ordered_entries/apps/with_requires/english.lproj/c.css +2 -0
  1516. data/spec/fixtures/ordered_entries/apps/with_requires/english.lproj/d.js +1 -0
  1517. data/spec/fixtures/real_world/Buildfile +12 -0
  1518. data/spec/fixtures/real_world/apps/account/README +1 -0
  1519. data/spec/fixtures/real_world/apps/calendar/README +1 -0
  1520. data/spec/fixtures/real_world/apps/contacts/README_BEFORE_EDITING +1 -0
  1521. data/spec/fixtures/real_world/apps/files/README +1 -0
  1522. data/spec/fixtures/real_world/apps/mail/README +1 -0
  1523. data/spec/fixtures/real_world/apps/mobile_photos/README +1 -0
  1524. data/spec/fixtures/real_world/apps/photos/README +1 -0
  1525. data/spec/fixtures/real_world/apps/uploader/README +1 -0
  1526. data/spec/fixtures/real_world/frameworks/core_files/PLACEHOLDER +0 -0
  1527. data/spec/fixtures/real_world/frameworks/core_photos/PLACEHOLDER +0 -0
  1528. data/spec/fixtures/real_world/frameworks/shared/PLACEHOLDER +0 -0
  1529. data/spec/fixtures/real_world/frameworks/sproutcore/Buildfile +26 -0
  1530. data/spec/fixtures/real_world/frameworks/sproutcore/README +1 -0
  1531. data/spec/fixtures/real_world/frameworks/sproutcore/apps/docs/PLACEHOLDER +0 -0
  1532. data/spec/fixtures/real_world/frameworks/sproutcore/apps/test_runner/PLACEHOLDER +0 -0
  1533. data/spec/fixtures/real_world/frameworks/sproutcore/core.js +0 -0
  1534. data/spec/fixtures/real_world/frameworks/sproutcore/debug/debug-resource.html +0 -0
  1535. data/spec/fixtures/real_world/frameworks/sproutcore/debug/sample_debug.js +0 -0
  1536. data/spec/fixtures/real_world/frameworks/sproutcore/demo2.js +0 -0
  1537. data/spec/fixtures/real_world/frameworks/sproutcore/demo3.scss +0 -0
  1538. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/debug/sample_debug-loc.js +0 -0
  1539. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/demo.css +4 -0
  1540. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/demo.html +1 -0
  1541. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/demo2.sass +0 -0
  1542. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/demo3.scss +0 -0
  1543. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/demo4.less +0 -0
  1544. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/file_extension_test.haml +0 -0
  1545. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/file_extension_test.html.erb +1 -0
  1546. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/file_extension_test.rhtml +0 -0
  1547. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/fixtures/sample_fixtures-loc.js +0 -0
  1548. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/has_require.css +4 -0
  1549. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/no_require.css +1 -0
  1550. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/no_sc_resource.rhtml +1 -0
  1551. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/protocols/sample-loc.js +0 -0
  1552. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/sc_resource.css +6 -0
  1553. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/sc_resource.rhtml +3 -0
  1554. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/strings.js +1 -0
  1555. data/spec/fixtures/real_world/frameworks/sproutcore/english.lproj/tests/sample-loc.js +0 -0
  1556. data/spec/fixtures/real_world/frameworks/sproutcore/fixtures/sample-json-fixture.json +1 -0
  1557. data/spec/fixtures/real_world/frameworks/sproutcore/fixtures/sample_fixtures.js +0 -0
  1558. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/application/PLACEHOLDER +0 -0
  1559. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/costello/core.js +0 -0
  1560. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/data_store/PLACEHOLDER +0 -0
  1561. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/debug/PLACEHOLDER +0 -0
  1562. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/desktop/PLACEHOLDER +0 -0
  1563. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/empty_theme/PLACEHOLDER +0 -0
  1564. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/foundation/PLACEHOLDER +0 -0
  1565. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/mobile/PLACEHOLDER +0 -0
  1566. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/qunit/PLACEHOLDER +0 -0
  1567. data/spec/fixtures/real_world/frameworks/sproutcore/frameworks/uploader/PLACEHOLDER +0 -0
  1568. data/spec/fixtures/real_world/frameworks/sproutcore/french.lproj/french-resource.js +0 -0
  1569. data/spec/fixtures/real_world/frameworks/sproutcore/french.lproj/strings.js +1 -0
  1570. data/spec/fixtures/real_world/frameworks/sproutcore/german.lproj/german-resource.js +0 -0
  1571. data/spec/fixtures/real_world/frameworks/sproutcore/german.lproj/strings.js +0 -0
  1572. data/spec/fixtures/real_world/frameworks/sproutcore/has_require.js +4 -0
  1573. data/spec/fixtures/real_world/frameworks/sproutcore/lib/index.html +1 -0
  1574. data/spec/fixtures/real_world/frameworks/sproutcore/no_require.js +1 -0
  1575. data/spec/fixtures/real_world/frameworks/sproutcore/protocols/sample.js +0 -0
  1576. data/spec/fixtures/real_world/frameworks/sproutcore/resources/boo.png +0 -0
  1577. data/spec/fixtures/real_world/frameworks/sproutcore/sc_resource.js +6 -0
  1578. data/spec/fixtures/real_world/frameworks/sproutcore/tests/nested/sample1.js +0 -0
  1579. data/spec/fixtures/real_world/frameworks/sproutcore/tests/nested/sample2.js +0 -0
  1580. data/spec/fixtures/real_world/frameworks/sproutcore/tests/sample.js +0 -0
  1581. data/spec/fixtures/real_world/frameworks/sproutcore/tests/sample.rhtml +1 -0
  1582. data/spec/fixtures/real_world/frameworks/sproutcore/themes/standard_theme/README +0 -0
  1583. data/spec/fixtures/real_world/frameworks/sproutcore/views/view.js +1 -0
  1584. data/spec/fixtures/real_world/generators/sample_custom/Buildfile +0 -0
  1585. data/spec/fixtures/real_world/generators/sample_custom/templates/{filename}.js +1 -0
  1586. data/spec/fixtures/recursive_project/Buildfile +8 -0
  1587. data/spec/fixtures/recursive_project/frameworks/sproutcore/frameworks/costello/PLACEHOLDER +0 -0
  1588. data/spec/lib/builders/bundle_spec.rb +295 -0
  1589. data/spec/lib/builders/combine_spec.rb +67 -0
  1590. data/spec/lib/builders/html_spec.rb +580 -0
  1591. data/spec/lib/builders/javascript_spec.rb +82 -0
  1592. data/spec/lib/builders/less_spec.rb +51 -0
  1593. data/spec/lib/builders/sass_spec.rb +72 -0
  1594. data/spec/lib/builders/spec_helper.rb +30 -0
  1595. data/spec/lib/builders/strings_spec.rb +55 -0
  1596. data/spec/lib/builders/stylesheet_spec.rb +64 -0
  1597. data/spec/lib/builders/test_index_spec.rb +45 -0
  1598. data/spec/lib/builders/test_spec.rb +137 -0
  1599. data/spec/lib/buildfile/config_for_spec.rb +81 -0
  1600. data/spec/lib/buildfile/define_spec.rb +59 -0
  1601. data/spec/lib/buildfile/dup_spec.rb +65 -0
  1602. data/spec/lib/buildfile/invoke_spec.rb +135 -0
  1603. data/spec/lib/buildfile/load_spec.rb +51 -0
  1604. data/spec/lib/buildfile/task/dup_spec.rb +55 -0
  1605. data/spec/lib/buildfile/task_defined_spec.rb +17 -0
  1606. data/spec/lib/buildfile_commands/build_task_spec.rb +19 -0
  1607. data/spec/lib/buildfile_commands/config_spec.rb +97 -0
  1608. data/spec/lib/buildfile_commands/import_spec.rb +17 -0
  1609. data/spec/lib/buildfile_commands/namespace_spec.rb +18 -0
  1610. data/spec/lib/buildfile_commands/proxies_spec.rb +38 -0
  1611. data/spec/lib/buildfile_commands/replace_task_spec.rb +29 -0
  1612. data/spec/lib/buildfile_commands/task_spec.rb +36 -0
  1613. data/spec/lib/helpers/packing_optimizer/optimize_spec.rb +26 -0
  1614. data/spec/lib/models/hash_struct/deep_clone_spec.rb +27 -0
  1615. data/spec/lib/models/hash_struct/has_options_spec.rb +32 -0
  1616. data/spec/lib/models/hash_struct/hash_spec.rb +29 -0
  1617. data/spec/lib/models/hash_struct/merge_spec.rb +19 -0
  1618. data/spec/lib/models/hash_struct/method_missing.rb +41 -0
  1619. data/spec/lib/models/manifest/add_entry_spec.rb +36 -0
  1620. data/spec/lib/models/manifest/add_transform_spec.rb +93 -0
  1621. data/spec/lib/models/manifest/build_spec.rb +78 -0
  1622. data/spec/lib/models/manifest/entry_for_spec.rb +94 -0
  1623. data/spec/lib/models/manifest/find_entry.rb +109 -0
  1624. data/spec/lib/models/manifest/prepare_spec.rb +62 -0
  1625. data/spec/lib/models/manifest_entry/cacheable_url_spec.rb +31 -0
  1626. data/spec/lib/models/manifest_entry/hyperdomain_prefix.rb +34 -0
  1627. data/spec/lib/models/manifest_entry/prepare_spec.rb +54 -0
  1628. data/spec/lib/models/project/add_target_spec.rb +44 -0
  1629. data/spec/lib/models/project/buildfile_spec.rb +35 -0
  1630. data/spec/lib/models/project/find_targets_for_spec.rb +78 -0
  1631. data/spec/lib/models/project/load_nearest_project_spec.rb +23 -0
  1632. data/spec/lib/models/project/target_for_spec.rb +33 -0
  1633. data/spec/lib/models/project/targets_spec.rb +62 -0
  1634. data/spec/lib/models/target/compute_build_number_spec.rb +126 -0
  1635. data/spec/lib/models/target/config_spec.rb +30 -0
  1636. data/spec/lib/models/target/expand_required_targets_spec.rb +48 -0
  1637. data/spec/lib/models/target/installed_languages_spec.rb +47 -0
  1638. data/spec/lib/models/target/lproj_for_spec.rb +38 -0
  1639. data/spec/lib/models/target/manifest_for_spec.rb +42 -0
  1640. data/spec/lib/models/target/parent_target_spec.rb +21 -0
  1641. data/spec/lib/models/target/prepare_spec.rb +53 -0
  1642. data/spec/lib/models/target/required_targets_spec.rb +129 -0
  1643. data/spec/lib/models/target/target_for_spec.rb +56 -0
  1644. data/spec/lib/tools/build_number_spec.rb +35 -0
  1645. data/spec/lib/tools/gen_spec.rb +209 -0
  1646. data/spec/lib/tools/tools_spec.rb +96 -0
  1647. data/spec/spec.opts +4 -0
  1648. data/spec/spec_helper.rb +138 -0
  1649. data/sproutcore.gemspec +51 -0
  1650. metadata +1897 -0
@@ -0,0 +1,28 @@
1
+ /*! @license
2
+ ==========================================================================
3
+ SproutCore -- JavaScript Application Framework
4
+ copyright 2006-2008, Sprout Systems, Inc. and contributors.
5
+
6
+ Permission is hereby granted, free of charge, to any person obtaining a
7
+ copy of this software and associated documentation files (the "Software"),
8
+ to deal in the Software without restriction, including without limitation
9
+ the rights to use, copy, modify, merge, publish, distribute, sublicense,
10
+ and/or sell copies of the Software, and to permit persons to whom the
11
+ Software is furnished to do so, subject to the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be included in
14
+ all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
21
+ FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
22
+ DEALINGS IN THE SOFTWARE.
23
+
24
+ For more information about SproutCore, visit http://www.sproutcore.com
25
+
26
+
27
+ ==========================================================================
28
+ @license */
@@ -0,0 +1,12 @@
1
+ sproutcore/runtime
2
+
3
+ == About SproutCore Runtime
4
+
5
+ The SproutCore Runtime is a library that adds property bindings and observers
6
+ to JavaScript. You can use the runtime in web pages, applications, and
7
+ everything in between to easily manage the state of your page with less code.
8
+
9
+ This library is a part of the SproutCore JavaScript Application Framework,
10
+ which is a full-stack MVC framework for building desktop-like applications on
11
+ the web.
12
+
@@ -0,0 +1,1061 @@
1
+ // ==========================================================================
2
+ // Project: SproutCore Costello - Property Observing Library
3
+ // Copyright: ©2006-2010 Sprout Systems, Inc. and contributors.
4
+ // Portions ©2008-2010 Apple Inc. All rights reserved.
5
+ // License: Licensed under MIT license (see license.js)
6
+ // ==========================================================================
7
+
8
+ /*global NodeList */
9
+ // These commands are used by the build tools to control load order. On the
10
+ // client side these are a no-op.
11
+ var require = require || function require() { } ;
12
+ var sc_require = sc_require || require;
13
+ var sc_resource = sc_resource || function sc_resource() {};
14
+ sc_require('license') ;
15
+
16
+ // ........................................
17
+ // GLOBAL CONSTANTS
18
+ //
19
+ // Most global constants should be defined inside of the SC namespace.
20
+ // However the following two are useful enough and generally benign enough
21
+ // to put into the global object.
22
+ var YES = true ;
23
+ var NO = false ;
24
+
25
+ // prevent a console.log from blowing things up if we are on a browser that
26
+ // does not support it
27
+ if (typeof console === 'undefined') {
28
+ window.console = {} ;
29
+ console.log = console.info = console.warn = console.error = function(){};
30
+ }
31
+
32
+ // ........................................
33
+ // BOOTSTRAP
34
+ //
35
+ // The root namespace and some common utility methods are defined here. The
36
+ // rest of the methods go into the mixin defined below.
37
+
38
+ /**
39
+ @namespace
40
+
41
+ The SproutCore namespace. All SproutCore methods and functions are defined
42
+ inside of this namespace. You generally should not add new properties to
43
+ this namespace as it may be overwritten by future versions of SproutCore.
44
+
45
+ You can also use the shorthand "SC" instead of "SproutCore".
46
+
47
+ SproutCore-Base is a framework that provides core functions for SproutCore
48
+ including cross-platform functions, support for property observing and
49
+ objects. It's focus is on small size and performance. You can use this
50
+ in place of or along-side other cross-platform libraries such as jQuery or
51
+ Prototype.
52
+
53
+ The core Base framework is based on the jQuery API with a number of
54
+ performance optimizations.
55
+ */
56
+ var SC = SC || {} ;
57
+ var SproutCore = SproutCore || SC ;
58
+
59
+ /**
60
+ @private
61
+
62
+ Adds properties to a target object. You must specify whether
63
+ to overwrite a value for a property or not.
64
+
65
+ Used as a base function for the wrapper functions SC.mixin and SC.supplement.
66
+
67
+ @param overwrite {Boolean} if a target has a value for a property, this specifies
68
+ whether or not to overwrite that value with the copyied object's
69
+ property value.
70
+ @param target {Object} the target object to extend
71
+ @param properties {Object} one or more objects with properties to copy.
72
+ @returns {Object} the target object.
73
+ @static
74
+ */
75
+ SC._baseMixin = function (override) {
76
+ var args = Array.prototype.slice.call(arguments, 1), src,
77
+ // copy reference to target object
78
+ target = args[0] || {},
79
+ idx = 1,
80
+ length = args.length ,
81
+ options, copy , key;
82
+
83
+ // Handle case where we have only one item...extend SC
84
+ if (length === 1) {
85
+ target = this || {};
86
+ idx=0;
87
+ }
88
+
89
+ for ( ; idx < length; idx++ ) {
90
+ if (!(options = args[idx])) continue ;
91
+ for(key in options) {
92
+ if (!options.hasOwnProperty(key)) continue ;
93
+ copy = options[key] ;
94
+ if (target===copy) continue ; // prevent never-ending loop
95
+ if (copy !== undefined && ( override || (target[key] === undefined) )) target[key] = copy ;
96
+ }
97
+ }
98
+
99
+ return target;
100
+ } ;
101
+
102
+ /**
103
+ Adds properties to a target object.
104
+
105
+ Takes the root object and adds the attributes for any additional
106
+ arguments passed.
107
+
108
+ @param target {Object} the target object to extend
109
+ @param properties {Object} one or more objects with properties to copy.
110
+ @returns {Object} the target object.
111
+ @static
112
+ */
113
+ SC.mixin = function() {
114
+ var args = Array.prototype.slice.call(arguments);
115
+ args.unshift(true);
116
+ return SC._baseMixin.apply(this, args);
117
+ } ;
118
+
119
+ /**
120
+ Adds properties to a target object. Unlike SC.mixin, however, if the target
121
+ already has a value for a property, it will not be overwritten.
122
+
123
+ Takes the root object and adds the attributes for any additional
124
+ arguments passed.
125
+
126
+ @param target {Object} the target object to extend
127
+ @param properties {Object} one or more objects with properties to copy.
128
+ @returns {Object} the target object.
129
+ @static
130
+ */
131
+ SC.supplement = function() {
132
+ var args = Array.prototype.slice.call(arguments);
133
+ args.unshift(false);
134
+ return SC._baseMixin.apply(this, args);
135
+ } ;
136
+
137
+ /**
138
+ Alternative to mixin. Provided for compatibility with jQuery.
139
+ @function
140
+ */
141
+ SC.extend = SC.mixin ;
142
+
143
+ // ..........................................................
144
+ // CORE FUNCTIONS
145
+ //
146
+ // Enough with the bootstrap code. Let's define some core functions
147
+
148
+ SC.mixin(/** @scope SC */ {
149
+
150
+ // ........................................
151
+ // GLOBAL CONSTANTS
152
+ //
153
+ T_ERROR: 'error',
154
+ T_OBJECT: 'object',
155
+ T_NULL: 'null',
156
+ T_CLASS: 'class',
157
+ T_HASH: 'hash',
158
+ T_FUNCTION: 'function',
159
+ T_UNDEFINED: 'undefined',
160
+ T_NUMBER: 'number',
161
+ T_BOOL: 'boolean',
162
+ T_ARRAY: 'array',
163
+ T_STRING: 'string',
164
+
165
+ // ........................................
166
+ // TYPING & ARRAY MESSAGING
167
+ //
168
+
169
+ /**
170
+ Returns a consistant type for the passed item.
171
+
172
+ Use this instead of the built-in typeOf() to get the type of an item.
173
+ It will return the same result across all browsers and includes a bit
174
+ more detail. Here is what will be returned:
175
+
176
+ | Return Value Constant | Meaning |
177
+ | SC.T_STRING | String primitive |
178
+ | SC.T_NUMBER | Number primitive |
179
+ | SC.T_BOOLEAN | Boolean primitive |
180
+ | SC.T_NULL | Null value |
181
+ | SC.T_UNDEFINED | Undefined value |
182
+ | SC.T_FUNCTION | A function |
183
+ | SC.T_ARRAY | An instance of Array |
184
+ | SC.T_CLASS | A SproutCore class (created using SC.Object.extend()) |
185
+ | SC.T_OBJECT | A SproutCore object instance |
186
+ | SC.T_HASH | A JavaScript object not inheriting from SC.Object |
187
+
188
+ @param item {Object} the item to check
189
+ @returns {String} the type
190
+ */
191
+ typeOf: function(item) {
192
+ if (item === undefined) return SC.T_UNDEFINED ;
193
+ if (item === null) return SC.T_NULL ;
194
+ var ret = typeof(item) ;
195
+ if (ret == "object") {
196
+ if (item instanceof Array) {
197
+ ret = SC.T_ARRAY ;
198
+ } else if (item instanceof Function) {
199
+ ret = item.isClass ? SC.T_CLASS : SC.T_FUNCTION ;
200
+
201
+ // NB: typeOf() may be called before SC.Error has had a chance to load
202
+ // so this code checks for the presence of SC.Error first just to make
203
+ // sure. No error instance can exist before the class loads anyway so
204
+ // this is safe.
205
+ } else if (SC.Error && (item instanceof SC.Error)) {
206
+ ret = SC.T_ERROR ;
207
+ } else if (item instanceof SC.Object) {
208
+ ret = SC.T_OBJECT ;
209
+ } else ret = SC.T_HASH ;
210
+ } else if (ret === SC.T_FUNCTION) ret = (item.isClass) ? SC.T_CLASS : SC.T_FUNCTION;
211
+ return ret ;
212
+ },
213
+
214
+ /**
215
+ Returns YES if the passed value is null or undefined. This avoids errors
216
+ from JSLint complaining about use of ==, which can be technically
217
+ confusing.
218
+
219
+ @param {Object} obj value to test
220
+ @returns {Boolean}
221
+ */
222
+ none: function(obj) {
223
+ return obj===null || obj===undefined;
224
+ },
225
+
226
+ /**
227
+ Verifies that a value is either null or an empty string. Return false if
228
+ the object is not a string.
229
+
230
+ @param {Object} obj value to test
231
+ @returns {Boolean}
232
+ */
233
+ empty: function(obj) {
234
+ return obj===null || obj===undefined || obj==='';
235
+ },
236
+
237
+ /**
238
+ Returns YES if the passed object is an array or array-like. Instances
239
+ of the NodeList class return NO.
240
+
241
+ Unlike SC.typeOf this method returns true even if the passed object is
242
+ not formally array but appears to be array-like (i.e. has a length
243
+ property, responds to .objectAt, etc.)
244
+
245
+ @param obj {Object} the object to test
246
+ @returns {Boolean}
247
+ */
248
+ isArray: function(obj) {
249
+ if (obj && obj.objectAt) return YES ; // fast path
250
+
251
+ var len = (obj ? obj.length : null), type = typeof obj;
252
+ return !((len === undefined) || (len === null) || (obj instanceof Function) || (type === "string") || obj.setInterval);
253
+ },
254
+
255
+ /**
256
+ Makes an object into an Array if it is not array or array-like already.
257
+ Unlike SC.A(), this method will not clone the object if it is already
258
+ an array.
259
+
260
+ @param {Object} obj object to convert
261
+ @returns {Array} Actual array
262
+ */
263
+ makeArray: function(obj) {
264
+ return SC.isArray(obj) ? obj : SC.A(obj);
265
+ },
266
+
267
+ /**
268
+ Converts the passed object to an Array. If the object appears to be
269
+ array-like, a new array will be cloned from it. Otherwise, a new array
270
+ will be created with the item itself as the only item in the array.
271
+
272
+ @param object {Object} any enumerable or array-like object.
273
+ @returns {Array} Array of items
274
+ */
275
+ A: function(obj) {
276
+ // null or undefined -- fast path
277
+ if (obj === null || obj === undefined) return [] ;
278
+
279
+ // primitive -- fast path
280
+ if (obj.slice instanceof Function) {
281
+ // do we have a string?
282
+ if (typeof(obj) === 'string') return [obj] ;
283
+ else return obj.slice() ;
284
+ }
285
+
286
+ // enumerable -- fast path
287
+ if (obj.toArray) return obj.toArray() ;
288
+
289
+ // if not array-like, then just wrap in array.
290
+ if (!SC.isArray(obj)) return [obj];
291
+
292
+ // when all else fails, do a manual convert...
293
+ var ret = [], len = obj.length;
294
+ while(--len >= 0) ret[len] = obj[len];
295
+ return ret ;
296
+ },
297
+
298
+ // ..........................................................
299
+ // GUIDS & HASHES
300
+ //
301
+
302
+ guidKey: "_sc_guid_" + new Date().getTime(),
303
+
304
+ // Used for guid generation...
305
+ _nextGUID: 0, _numberGuids: [], _stringGuids: {}, _keyCache: {},
306
+
307
+ /**
308
+ Returns a unique GUID for the object. If the object does not yet have
309
+ a guid, one will be assigned to it. You can call this on any object,
310
+ SC.Object-based or not, but be aware that it will add a _guid property.
311
+
312
+ You can also use this method on DOM Element objects.
313
+
314
+ @param obj {Object} any object, string, number, Element, or primitive
315
+ @returns {String} the unique guid for this instance.
316
+ */
317
+ guidFor: function(obj) {
318
+
319
+ // special cases where we don't want to add a key to object
320
+ if (obj === undefined) return "(undefined)";
321
+ if (obj === null) return '(null)';
322
+
323
+ var guidKey = this.guidKey;
324
+ if (obj[guidKey]) return obj[guidKey];
325
+
326
+ // More special cases; not as common, so we check for them after the cache
327
+ // lookup
328
+ if (obj === Object) return '(Object)';
329
+ if (obj === Array) return '(Array)';
330
+
331
+ var cache, ret;
332
+
333
+ switch(typeof obj) {
334
+ case SC.T_NUMBER:
335
+ cache = this._numberGuids;
336
+ ret = cache[obj];
337
+ if (!ret) {
338
+ ret = "nu" + obj;
339
+ cache[obj] = ret;
340
+ }
341
+ return ret;
342
+
343
+ case SC.T_STRING:
344
+ cache = this._stringGuids;
345
+ ret = cache[obj];
346
+ if (!ret) {
347
+ ret = "st" + obj;
348
+ cache[obj] = ret;
349
+ }
350
+ return ret;
351
+
352
+ case SC.T_BOOL:
353
+ return (obj) ? "(true)" : "(false)" ;
354
+ default:
355
+ return SC.generateGuid(obj);
356
+ }
357
+ },
358
+
359
+ /**
360
+ Returns a key name that combines the named key + prefix. This is more
361
+ efficient than simply combining strings because it uses a cache
362
+ internally for performance.
363
+
364
+ @param {String} prefix the prefix to attach to the key
365
+ @param {String} key key
366
+ @returns {String} result
367
+ */
368
+ keyFor: function(prefix, key) {
369
+ var ret, pcache = this._keyCache[prefix];
370
+ if (!pcache) pcache = this._keyCache[prefix] = {}; // get cache for prefix
371
+ ret = pcache[key];
372
+ if (!ret) ret = pcache[key] = prefix + '_' + key ;
373
+ return ret ;
374
+ },
375
+
376
+ /**
377
+ Generates a new guid, optionally saving the guid to the object that you
378
+ pass in. You will rarely need to use this method. Instead you should
379
+ call SC.guidFor(obj), which return an existing guid if available.
380
+
381
+ @param {Object} obj the object to assign the guid to
382
+ @returns {String} the guid
383
+ */
384
+ generateGuid: function(obj) {
385
+ var ret = ("sc" + (this._nextGUID++));
386
+ if (obj) obj[this.guidKey] = ret ;
387
+ return ret ;
388
+ },
389
+
390
+ /**
391
+ Returns a unique hash code for the object. If the object implements
392
+ a hash() method, the value of that method will be returned. Otherwise,
393
+ this will return the same value as guidFor().
394
+
395
+ If you pass multiple arguments, hashFor returns a string obtained by
396
+ concatenating the hash code of each argument.
397
+
398
+ Unlike guidFor(), this method allows you to implement logic in your
399
+ code to cause two separate instances of the same object to be treated as
400
+ if they were equal for comparisons and other functions.
401
+
402
+ IMPORTANT: If you implement a hash() method, it MUST NOT return a
403
+ number or a string that contains only a number. Typically hash codes
404
+ are strings that begin with a "%".
405
+
406
+ @param obj {Object} the object(s)
407
+ @returns {String} the hash code for this instance.
408
+ */
409
+ hashFor: function() {
410
+ var len = arguments.length,
411
+ h = '',
412
+ obj, f, i;
413
+
414
+ for (i = 0; i < len; ++i) {
415
+ obj = arguments[i];
416
+ h += (obj && (f = obj.hash) && (typeof f === SC.T_FUNCTION)) ? f.call(obj) : this.guidFor(obj);
417
+ }
418
+
419
+ return h === '' ? null : h;
420
+ },
421
+
422
+ /**
423
+ This will compare the two object values using their hash codes.
424
+
425
+ @param a {Object} first value to compare
426
+ @param b {Object} the second value to compare
427
+ @returns {Boolean} YES if the two have equal hash code values.
428
+
429
+ */
430
+ isEqual: function(a,b) {
431
+ // shortcut a few places.
432
+ if (a === null) {
433
+ return b === null ;
434
+ } else if (a === undefined) {
435
+ return b === undefined ;
436
+
437
+ // finally, check their hash-codes
438
+ } else return this.hashFor(a) === this.hashFor(b) ;
439
+ },
440
+
441
+
442
+ /**
443
+ This will compare two javascript values of possibly different types.
444
+ It will tell you which one is greater than the other by returning
445
+ -1 if the first is smaller than the second,
446
+ 0 if both are equal,
447
+ 1 if the first is greater than the second.
448
+
449
+ The order is calculated based on SC.ORDER_DEFINITION , if types are different.
450
+ In case they have the same type an appropriate comparison for this type is made.
451
+
452
+ @param v {Object} first value to compare
453
+ @param w {Object} the second value to compare
454
+ @returns {NUMBER} -1 if v < w, 0 if v = w and 1 if v > w.
455
+
456
+ */
457
+ compare: function (v, w) {
458
+ // Doing a '===' check is very cheap, so in the case of equality, checking
459
+ // this up-front is a big win.
460
+ if (v === w) return 0;
461
+
462
+ var type1 = SC.typeOf(v);
463
+ var type2 = SC.typeOf(w);
464
+
465
+ // If we haven't yet generated a reverse-mapping of SC.ORDER_DEFINITION,
466
+ // do so now.
467
+ var mapping = SC.ORDER_DEFINITION_MAPPING;
468
+ if (!mapping) {
469
+ var order = SC.ORDER_DEFINITION;
470
+ mapping = SC.ORDER_DEFINITION_MAPPING = {};
471
+ var idx, len;
472
+ for (idx = 0, len = order.length; idx < len; ++idx) {
473
+ mapping[order[idx]] = idx;
474
+ }
475
+
476
+ // We no longer need SC.ORDER_DEFINITION.
477
+ delete SC.ORDER_DEFINITION;
478
+ }
479
+
480
+ var type1Index = mapping[type1];
481
+ var type2Index = mapping[type2];
482
+
483
+ if (type1Index < type2Index) return -1;
484
+ if (type1Index > type2Index) return 1;
485
+
486
+ // ok - types are equal - so we have to check values now
487
+ switch (type1) {
488
+ case SC.T_BOOL:
489
+ case SC.T_NUMBER:
490
+ if (v<w) return -1;
491
+ if (v>w) return 1;
492
+ return 0;
493
+
494
+ case SC.T_STRING:
495
+ var comp = v.localeCompare(w);
496
+ if (comp<0) return -1;
497
+ if (comp>0) return 1;
498
+ return 0;
499
+
500
+ case SC.T_ARRAY:
501
+ var vLen = v.length;
502
+ var wLen = w.length;
503
+ var l = Math.min(vLen, wLen);
504
+ var r = 0;
505
+ var i = 0;
506
+ var thisFunc = arguments.callee;
507
+ while (r===0 && i < l) {
508
+ r = thisFunc(v[i],w[i]);
509
+ i++;
510
+ }
511
+ if (r !== 0) return r;
512
+
513
+ // all elements are equal now
514
+ // shorter array should be ordered first
515
+ if (vLen < wLen) return -1;
516
+ if (vLen > wLen) return 1;
517
+ // arrays are equal now
518
+ return 0;
519
+
520
+ case SC.T_OBJECT:
521
+ if (v.constructor.isComparable === YES) return v.constructor.compare(v, w);
522
+ return 0;
523
+
524
+ default:
525
+ return 0;
526
+ }
527
+ },
528
+
529
+ // ..........................................................
530
+ // OBJECT MANAGEMENT
531
+ //
532
+
533
+ /**
534
+ Empty function. Useful for some operations.
535
+
536
+ @returns {Object}
537
+ */
538
+ K: function() { return this; },
539
+
540
+ /**
541
+ Empty array. Useful for some optimizations.
542
+
543
+ @property {Array}
544
+ */
545
+ EMPTY_ARRAY: [],
546
+
547
+ /**
548
+ Empty hash. Useful for some optimizations.
549
+
550
+ @property {Hash}
551
+ */
552
+ EMPTY_HASH: {},
553
+
554
+ /**
555
+ Empty range. Useful for some optimizations.
556
+
557
+ @property {Range}
558
+ */
559
+ EMPTY_RANGE: {start: 0, length: 0},
560
+
561
+ /**
562
+ Creates a new object with the passed object as its prototype.
563
+
564
+ This method uses JavaScript's native inheritence method to create a new
565
+ object.
566
+
567
+ You cannot use beget() to create new SC.Object-based objects, but you
568
+ can use it to beget Arrays, Hashes, Sets and objects you build yourself.
569
+ Note that when you beget() a new object, this method will also call the
570
+ didBeget() method on the object you passed in if it is defined. You can
571
+ use this method to perform any other setup needed.
572
+
573
+ In general, you will not use beget() often as SC.Object is much more
574
+ useful, but for certain rare algorithms, this method can be very useful.
575
+
576
+ For more information on using beget(), see the section on beget() in
577
+ Crockford's JavaScript: The Good Parts.
578
+
579
+ @param obj {Object} the object to beget
580
+ @returns {Object} the new object.
581
+ */
582
+ beget: function(obj) {
583
+ if (obj === null || obj === undefined) return null ;
584
+ var K = SC.K; K.prototype = obj ;
585
+ var ret = new K();
586
+ K.prototype = null ; // avoid leaks
587
+ if (typeof obj.didBeget === "function") ret = obj.didBeget(ret);
588
+ return ret ;
589
+ },
590
+
591
+ /**
592
+ Creates a clone of the passed object. This function can take just about
593
+ any type of object and create a clone of it, including primitive values
594
+ (which are not actually cloned because they are immutable).
595
+
596
+ If the passed object implements the clone() method, then this function
597
+ will simply call that method and return the result.
598
+
599
+ @param object {Object} the object to clone
600
+ @returns {Object} the cloned object
601
+ */
602
+ copy: function(object) {
603
+ var ret = object ;
604
+
605
+ // fast path
606
+ if (object && object.isCopyable) return object.copy();
607
+
608
+ switch (SC.typeOf(object)) {
609
+ case SC.T_ARRAY:
610
+ if (object.clone && SC.typeOf(object.clone) === SC.T_FUNCTION) {
611
+ ret = object.clone() ;
612
+ } else ret = object.slice() ;
613
+ break ;
614
+
615
+ case SC.T_HASH:
616
+ case SC.T_OBJECT:
617
+ if (object.clone && SC.typeOf(object.clone) === SC.T_FUNCTION) {
618
+ ret = object.clone() ;
619
+ } else {
620
+ ret = {} ;
621
+ for(var key in object) ret[key] = object[key] ;
622
+ }
623
+ }
624
+
625
+ return ret ;
626
+ },
627
+
628
+ /**
629
+ Returns a new object combining the values of all passed hashes.
630
+
631
+ @param object {Object} one or more objects
632
+ @returns {Object} new Object
633
+ */
634
+ merge: function() {
635
+ var ret = {}, len = arguments.length, idx;
636
+ for(idx=0;idx<len;idx++) SC.mixin(ret, arguments[idx]);
637
+ return ret ;
638
+ },
639
+
640
+ /**
641
+ Returns all of the keys defined on an object or hash. This is useful
642
+ when inspecting objects for debugging.
643
+
644
+ @param {Object} obj
645
+ @returns {Array} array of keys
646
+ */
647
+ keys: function(obj) {
648
+ var ret = [];
649
+ for(var key in obj) ret.push(key);
650
+ return ret;
651
+ },
652
+
653
+ /**
654
+ Convenience method to inspect an object. This method will attempt to
655
+ convert the object into a useful string description.
656
+ */
657
+ inspect: function(obj) {
658
+ var v, ret = [] ;
659
+ for(var key in obj) {
660
+ v = obj[key] ;
661
+ if (v === 'toString') continue ; // ignore useless items
662
+ if (SC.typeOf(v) === SC.T_FUNCTION) v = "function() { ... }" ;
663
+ ret.push(key + ": " + v) ;
664
+ }
665
+ return "{" + ret.join(" , ") + "}" ;
666
+ },
667
+
668
+ /**
669
+ Returns a tuple containing the object and key for the specified property
670
+ path. If no object could be found to match the property path, then
671
+ returns null.
672
+
673
+ This is the standard method used throughout SproutCore to resolve property
674
+ paths.
675
+
676
+ @param path {String} the property path
677
+ @param root {Object} optional parameter specifying the place to start
678
+ @returns {Array} array with [object, property] if found or null
679
+ */
680
+ tupleForPropertyPath: function(path, root) {
681
+
682
+ // if the passed path is itself a tuple, return it
683
+ if (typeof path === "object" && (path instanceof Array)) return path ;
684
+
685
+ // find the key. It is the last . or first *
686
+ var key ;
687
+ var stopAt = path.indexOf('*') ;
688
+ if (stopAt < 0) stopAt = path.lastIndexOf('.') ;
689
+ key = (stopAt >= 0) ? path.slice(stopAt+1) : path ;
690
+
691
+ // convert path to object.
692
+ var obj = this.objectForPropertyPath(path, root, stopAt) ;
693
+ return (obj && key) ? [obj,key] : null ;
694
+ },
695
+
696
+ /**
697
+ Finds the object for the passed path or array of path components. This is
698
+ the standard method used in SproutCore to traverse object paths.
699
+
700
+ @param path {String} the path
701
+ @param root {Object} optional root object. window is used otherwise
702
+ @param stopAt {Integer} optional point to stop searching the path.
703
+ @returns {Object} the found object or undefined.
704
+ */
705
+ objectForPropertyPath: function(path, root, stopAt) {
706
+
707
+ var loc, nextDotAt, key, max ;
708
+
709
+ if (!root) root = window ;
710
+
711
+ // faster method for strings
712
+ if (SC.typeOf(path) === SC.T_STRING) {
713
+ if (stopAt === undefined) stopAt = path.length ;
714
+ loc = 0 ;
715
+ while((root) && (loc < stopAt)) {
716
+ nextDotAt = path.indexOf('.', loc) ;
717
+ if ((nextDotAt < 0) || (nextDotAt > stopAt)) nextDotAt = stopAt;
718
+ key = path.slice(loc, nextDotAt);
719
+ root = root.get ? root.get(key) : root[key] ;
720
+ loc = nextDotAt+1;
721
+ }
722
+ if (loc < stopAt) root = undefined; // hit a dead end. :(
723
+
724
+ // older method using an array
725
+ } else {
726
+
727
+ loc = 0; max = path.length; key = null;
728
+ while((loc < max) && root) {
729
+ key = path[loc++];
730
+ if (key) root = (root.get) ? root.get(key) : root[key] ;
731
+ }
732
+ if (loc < max) root = undefined ;
733
+ }
734
+
735
+ return root ;
736
+ },
737
+
738
+
739
+ // ..........................................................
740
+ // LOCALIZATION SUPPORT
741
+ //
742
+
743
+ /**
744
+ Known loc strings
745
+
746
+ @property {Hash}
747
+ */
748
+ STRINGS: {},
749
+
750
+ /**
751
+ This is a simplified handler for installing a bunch of strings. This
752
+ ignores the language name and simply applies the passed strings hash.
753
+
754
+ @param {String} lang the language the strings are for
755
+ @param {Hash} strings hash of strings
756
+ @returns {SC} receiver
757
+ */
758
+ stringsFor: function(lang, strings) {
759
+ SC.mixin(SC.STRINGS, strings);
760
+ return this ;
761
+ }
762
+
763
+
764
+ }); // end mixin
765
+
766
+ /** @private Aliasn for SC.clone() */
767
+ SC.clone = SC.copy ;
768
+
769
+ /** @private Alias for SC.A() */
770
+ SC.$A = SC.A;
771
+
772
+ /** @private Provided for compatibility with old HTML templates. */
773
+ SC.didLoad = SC.K ;
774
+
775
+ /** @private Used by SC.compare */
776
+ SC.ORDER_DEFINITION = [ SC.T_ERROR,
777
+ SC.T_UNDEFINED,
778
+ SC.T_NULL,
779
+ SC.T_BOOL,
780
+ SC.T_NUMBER,
781
+ SC.T_STRING,
782
+ SC.T_ARRAY,
783
+ SC.T_HASH,
784
+ SC.T_OBJECT,
785
+ SC.T_FUNCTION,
786
+ SC.T_CLASS ];
787
+
788
+
789
+ // ........................................
790
+ // FUNCTION ENHANCEMENTS
791
+ //
792
+
793
+ SC.mixin(Function.prototype,
794
+ /** @lends Function.prototype */ {
795
+
796
+ /**
797
+ Indicates that the function should be treated as a computed property.
798
+
799
+ Computed properties are methods that you want to treat as if they were
800
+ static properties. When you use get() or set() on a computed property,
801
+ the object will call the property method and return its value instead of
802
+ returning the method itself. This makes it easy to create "virtual
803
+ properties" that are computed dynamically from other properties.
804
+
805
+ Consider the following example:
806
+
807
+ {{{
808
+ contact = SC.Object.create({
809
+
810
+ firstName: "Charles",
811
+ lastName: "Jolley",
812
+
813
+ // This is a computed property!
814
+ fullName: function() {
815
+ return this.getEach('firstName','lastName').compact().join(' ') ;
816
+ }.property('firstName', 'lastName'),
817
+
818
+ // this is not
819
+ getFullName: function() {
820
+ return this.getEach('firstName','lastName').compact().join(' ') ;
821
+ }
822
+ });
823
+
824
+ contact.get('firstName') ;
825
+ --> "Charles"
826
+
827
+ contact.get('fullName') ;
828
+ --> "Charles Jolley"
829
+
830
+ contact.get('getFullName') ;
831
+ --> function()
832
+ }}}
833
+
834
+ Note that when you get the fullName property, SproutCore will call the
835
+ fullName() function and return its value whereas when you get() a property
836
+ that contains a regular method (such as getFullName above), then the
837
+ function itself will be returned instead.
838
+
839
+ h2. Using Dependent Keys
840
+
841
+ Computed properties are often computed dynamically from other member
842
+ properties. Whenever those properties change, you need to notify any
843
+ object that is observing the computed property that the computed property
844
+ has changed also. We call these properties the computed property is based
845
+ upon "dependent keys".
846
+
847
+ For example, in the contact object above, the fullName property depends on
848
+ the firstName and lastName property. If either property value changes,
849
+ any observer watching the fullName property will need to be notified as
850
+ well.
851
+
852
+ You inform SproutCore of these dependent keys by passing the key names
853
+ as parameters to the property() function. Whenever the value of any key
854
+ you name here changes, the computed property will be marked as changed
855
+ also.
856
+
857
+ You should always register dependent keys for computed properties to
858
+ ensure they update.
859
+
860
+ h2. Using Computed Properties as Setters
861
+
862
+ Computed properties can be used to modify the state of an object as well
863
+ as to return a value. Unlike many other key-value system, you use the
864
+ same method to both get and set values on a computed property. To
865
+ write a setter, simply declare two extra parameters: key and value.
866
+
867
+ Whenever your property function is called as a setter, the value
868
+ parameter will be set. Whenever your property is called as a getter the
869
+ value parameter will be undefined.
870
+
871
+ For example, the following object will split any full name that you set
872
+ into a first name and last name components and save them.
873
+
874
+ {{{
875
+ contact = SC.Object.create({
876
+
877
+ fullName: function(key, value) {
878
+ if (value !== undefined) {
879
+ var parts = value.split(' ') ;
880
+ this.beginPropertyChanges()
881
+ .set('firstName', parts[0])
882
+ .set('lastName', parts[1])
883
+ .endPropertyChanges() ;
884
+ }
885
+ return this.getEach('firstName', 'lastName').compact().join(' ');
886
+ }.property('firstName','lastName')
887
+
888
+ }) ;
889
+
890
+ }}}
891
+
892
+ h2. Why Use The Same Method for Getters and Setters?
893
+
894
+ Most property-based frameworks expect you to write two methods for each
895
+ property but SproutCore only uses one. We do this because most of the time
896
+ when you write a setter is is basically a getter plus some extra work.
897
+ There is little added benefit in writing both methods when you can
898
+ conditionally exclude part of it. This helps to keep your code more
899
+ compact and easier to maintain.
900
+
901
+ @param dependentKeys {String...} optional set of dependent keys
902
+ @returns {Function} the declared function instance
903
+ */
904
+ property: function() {
905
+ this.dependentKeys = SC.$A(arguments) ;
906
+ var guid = SC.guidFor(this) ;
907
+ this.cacheKey = "__cache__" + guid ;
908
+ this.lastSetValueKey = "__lastValue__" + guid ;
909
+ this.isProperty = YES ;
910
+ return this ;
911
+ },
912
+
913
+ /**
914
+ You can call this method on a computed property to indicate that the
915
+ property is cacheable (or not cacheable). By default all computed
916
+ properties are not cached. Enabling this feature will allow SproutCore
917
+ to cache the return value of your computed property and to use that
918
+ value until one of your dependent properties changes or until you
919
+ invoke propertyDidChange() and name the computed property itself.
920
+
921
+ If you do not specify this option, computed properties are assumed to be
922
+ not cacheable.
923
+
924
+ @param {Boolean} aFlag optionally indicate cacheable or no, default YES
925
+ @returns {Function} reciever
926
+ */
927
+ cacheable: function(aFlag) {
928
+ this.isProperty = YES ; // also make a property just in case
929
+ if (!this.dependentKeys) this.dependentKeys = [] ;
930
+ this.isCacheable = (aFlag === undefined) ? YES : aFlag ;
931
+ return this ;
932
+ },
933
+
934
+ /**
935
+ Indicates that the computed property is volatile. Normally SproutCore
936
+ assumes that your computed property is idempotent. That is, calling
937
+ set() on your property more than once with the same value has the same
938
+ effect as calling it only once.
939
+
940
+ All non-computed properties are idempotent and normally you should make
941
+ your computed properties behave the same way. However, if you need to
942
+ make your property change its return value everytime your method is
943
+ called, you may chain this to your property to make it volatile.
944
+
945
+ If you do not specify this option, properties are assumed to be
946
+ non-volatile.
947
+
948
+ @param {Boolean} aFlag optionally indicate state, default to YES
949
+ @returns {Function} receiver
950
+ */
951
+ idempotent: function(aFlag) {
952
+ this.isProperty = YES; // also make a property just in case
953
+ if (!this.dependentKeys) this.dependentKeys = [] ;
954
+ this.isVolatile = (aFlag === undefined) ? YES : aFlag ;
955
+ return this ;
956
+ },
957
+
958
+ /**
959
+ Declare that a function should observe an object at the named path. Note
960
+ that the path is used only to construct the observation one time.
961
+
962
+ @returns {Function} receiver
963
+ */
964
+ observes: function(propertyPaths) {
965
+ // sort property paths into local paths (i.e just a property name) and
966
+ // full paths (i.e. those with a . or * in them)
967
+ var loc = arguments.length, local = null, paths = null ;
968
+ while(--loc >= 0) {
969
+ var path = arguments[loc] ;
970
+ // local
971
+ if ((path.indexOf('.')<0) && (path.indexOf('*')<0)) {
972
+ if (!local) local = this.localPropertyPaths = [] ;
973
+ local.push(path);
974
+
975
+ // regular
976
+ } else {
977
+ if (!paths) paths = this.propertyPaths = [] ;
978
+ paths.push(path) ;
979
+ }
980
+ }
981
+ return this ;
982
+ }
983
+
984
+ });
985
+
986
+ // ..........................................................
987
+ // STRING ENHANCEMENT
988
+ //
989
+
990
+ // Interpolate string. looks for %@ or %@1; to control the order of params.
991
+ /**
992
+ Apply formatting options to the string. This will look for occurrences
993
+ of %@ in your string and substitute them with the arguments you pass into
994
+ this method. If you want to control the specific order of replacement,
995
+ you can add a number after the key as well to indicate which argument
996
+ you want to insert.
997
+
998
+ Ordered insertions are most useful when building loc strings where values
999
+ you need to insert may appear in different orders.
1000
+
1001
+ h3. Examples
1002
+
1003
+ {{{
1004
+ "Hello %@ %@".fmt('John', 'Doe') => "Hello John Doe"
1005
+ "Hello %@2, %@1".fmt('John', 'Doe') => "Hello Doe, John"
1006
+ }}}
1007
+
1008
+ @param args {Object...} optional arguments
1009
+ @returns {String} formatted string
1010
+ */
1011
+ String.prototype.fmt = function() {
1012
+ // first, replace any ORDERED replacements.
1013
+ var args = arguments,
1014
+ idx = 0; // the current index for non-numerical replacements
1015
+ return this.replace(/%@([0-9]+)?/g, function(s, argIndex) {
1016
+ argIndex = (argIndex) ? parseInt(argIndex,0)-1 : idx++ ;
1017
+ s =args[argIndex];
1018
+ return ((s===null) ? '(null)' : (s===undefined) ? '' : s).toString();
1019
+ }) ;
1020
+ };
1021
+
1022
+ /**
1023
+ Localizes the string. This will look up the reciever string as a key
1024
+ in the current Strings hash. If the key matches, the loc'd value will be
1025
+ used. The resulting string will also be passed through fmt() to insert
1026
+ any variables.
1027
+
1028
+ @param args {Object...} optional arguments to interpolate also
1029
+ @returns {String} the localized and formatted string.
1030
+ */
1031
+ String.prototype.loc = function() {
1032
+ var str = SC.STRINGS[this] || this;
1033
+ return str.fmt.apply(str,arguments) ;
1034
+ };
1035
+
1036
+
1037
+
1038
+ /**
1039
+ Splits the string into words, separated by spaces. Empty strings are
1040
+ removed from the results.
1041
+
1042
+ @returns {Array} an array of non-empty strings
1043
+ */
1044
+ String.prototype.w = function() {
1045
+ var ary = [], ary2 = this.split(' '), len = ary2.length, str, idx=0;
1046
+ for (idx=0; idx<len; ++idx) {
1047
+ str = ary2[idx] ;
1048
+ if (str.length !== 0) ary.push(str) ; // skip empty strings
1049
+ }
1050
+ return ary ;
1051
+ };
1052
+
1053
+ //
1054
+ // DATE ENHANCEMENT
1055
+ //
1056
+ if (!Date.now) {
1057
+ Date.now = function() {
1058
+ return new Date().getTime() ;
1059
+ };
1060
+ }
1061
+