sproutcore 1.4.5 → 1.5.0.pre.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (792) hide show
  1. data/CHANGELOG +35 -0
  2. data/VERSION.yml +2 -2
  3. data/lib/Buildfile +13 -4
  4. data/lib/buildtasks/build.rake +20 -17
  5. data/lib/buildtasks/manifest.rake +143 -78
  6. data/lib/buildtasks/target.rake +1 -0
  7. data/lib/doc_templates/sproutcore/index.tmpl +18 -4
  8. data/lib/doc_templates/sproutcore/publish.js +1 -1
  9. data/lib/frameworks/sproutcore/Buildfile +24 -13
  10. data/lib/frameworks/sproutcore/{CHANGELOG-1.4.md → CHANGELOG.md} +0 -0
  11. data/lib/frameworks/sproutcore/apps/greenhouse/controllers/file.js +8 -48
  12. data/lib/frameworks/sproutcore/apps/greenhouse/core.js +3 -5
  13. data/lib/frameworks/sproutcore/apps/greenhouse/data_source.js +1 -1
  14. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/app_page.js +26 -4
  15. data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/strings.js +7 -1
  16. data/lib/frameworks/sproutcore/apps/greenhouse/main.js +1 -1
  17. data/lib/frameworks/sproutcore/apps/greenhouse/models/design.js +6 -2
  18. data/lib/frameworks/sproutcore/apps/greenhouse/models/dir.js +8 -7
  19. data/lib/frameworks/sproutcore/apps/greenhouse/models/file.js +2 -2
  20. data/lib/frameworks/sproutcore/apps/greenhouse/states/inspector.js +133 -125
  21. data/lib/frameworks/sproutcore/apps/greenhouse/states/library.js +121 -112
  22. data/lib/frameworks/sproutcore/apps/greenhouse/states/main.js +233 -191
  23. data/lib/frameworks/sproutcore/apps/greenhouse/states/modals.js +265 -258
  24. data/lib/frameworks/sproutcore/apps/greenhouse/states/ready.js +153 -141
  25. data/lib/frameworks/sproutcore/apps/test_controls/Buildfile +0 -0
  26. data/lib/frameworks/sproutcore/apps/test_controls/controllers/buttons.js +21 -0
  27. data/lib/frameworks/sproutcore/apps/test_controls/controllers/categories.js +108 -0
  28. data/lib/frameworks/sproutcore/apps/test_controls/controllers/category.js +36 -0
  29. data/lib/frameworks/sproutcore/apps/test_controls/core.js +29 -0
  30. data/lib/frameworks/sproutcore/apps/test_controls/main.js +14 -0
  31. data/lib/frameworks/sproutcore/apps/test_controls/resources/buttons_page.js +142 -0
  32. data/lib/frameworks/sproutcore/apps/test_controls/resources/checkboxes_page.js +45 -0
  33. data/lib/frameworks/sproutcore/apps/test_controls/resources/flow_layout_page.js +84 -0
  34. data/lib/frameworks/sproutcore/apps/test_controls/resources/list_page.js +40 -0
  35. data/lib/frameworks/sproutcore/apps/test_controls/resources/loading.rhtml +9 -0
  36. data/lib/frameworks/sproutcore/apps/test_controls/resources/main_page.css +60 -0
  37. data/lib/frameworks/sproutcore/apps/test_controls/resources/main_page.js +144 -0
  38. data/lib/frameworks/sproutcore/apps/test_controls/resources/progress_page.js +42 -0
  39. data/lib/frameworks/sproutcore/apps/test_controls/resources/radio_page.js +48 -0
  40. data/lib/frameworks/sproutcore/apps/test_controls/resources/scroll_page.js +76 -0
  41. data/lib/frameworks/sproutcore/apps/test_controls/resources/segmented_page.js +98 -0
  42. data/lib/frameworks/sproutcore/apps/test_controls/resources/select_page.js +60 -0
  43. data/lib/frameworks/sproutcore/apps/test_controls/resources/sliders_page.js +53 -0
  44. data/lib/frameworks/sproutcore/apps/test_controls/resources/strings.js +50 -0
  45. data/lib/frameworks/sproutcore/apps/test_controls/resources/tab_page.js +44 -0
  46. data/lib/frameworks/sproutcore/apps/test_controls/resources/text_field_page.js +41 -0
  47. data/lib/frameworks/sproutcore/apps/test_controls/theme.js +34 -0
  48. data/lib/frameworks/sproutcore/apps/welcome/controllers/targets.js +7 -0
  49. data/lib/frameworks/sproutcore/apps/welcome/english.lproj/images/main-bg.png +0 -0
  50. data/lib/frameworks/sproutcore/apps/welcome/english.lproj/main_page.css +24 -6
  51. data/lib/frameworks/sproutcore/apps/welcome/english.lproj/main_page.js +36 -46
  52. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/controllers/array.js +175 -195
  53. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/controllers/controller.js +0 -0
  54. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/controllers/object.js +0 -0
  55. data/lib/frameworks/sproutcore/frameworks/amber/core.js +201 -0
  56. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/ext/object.js +23 -23
  57. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/ext/run_loop.js +47 -47
  58. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/mixins/delegate_support.js +36 -36
  59. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/mixins/responder_context.js +55 -55
  60. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/mixins/selection_support.js +45 -45
  61. data/lib/frameworks/sproutcore/frameworks/amber/mixins/string.js +163 -0
  62. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/panes/main.js +4 -3
  63. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/panes/pane.js +123 -9
  64. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/protocols/observable_protocol.js +11 -11
  65. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/protocols/sparse_array_delegate.js +40 -40
  66. data/lib/frameworks/sproutcore/frameworks/{foundation/english.lproj → amber/resources}/core.css +0 -103
  67. data/lib/frameworks/sproutcore/frameworks/{foundation/english.lproj → amber/resources}/view.css +0 -0
  68. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/application.js +0 -2
  69. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/browser.js +0 -0
  70. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/builder.js +0 -0
  71. data/lib/frameworks/sproutcore/frameworks/amber/system/core_query.js +141 -0
  72. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/cursor.js +0 -0
  73. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/device.js +0 -0
  74. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/event.js +34 -14
  75. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/json.js +0 -0
  76. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/locale.js +0 -0
  77. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/page.js +0 -0
  78. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/platform.js +30 -10
  79. data/lib/frameworks/sproutcore/frameworks/amber/system/ready.js +77 -0
  80. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/render_context.js +330 -255
  81. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/responder.js +0 -0
  82. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/root_responder.js +152 -60
  83. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/system/selection_set.js +140 -145
  84. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/system/sparse_array.js +101 -87
  85. data/lib/frameworks/sproutcore/frameworks/amber/system/theme.js +316 -0
  86. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/timer.js +149 -147
  87. data/lib/frameworks/sproutcore/frameworks/amber/system/utils.js +174 -0
  88. data/lib/frameworks/sproutcore/frameworks/amber/system/utils/rect.js +98 -0
  89. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/array_case.js +41 -41
  90. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/enum_case.js +0 -0
  91. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/null_case.js +0 -0
  92. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/selection_support.js +0 -0
  93. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/single_case.js +9 -9
  94. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/object/empty_case.js +0 -0
  95. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/object/multiple_case.js +0 -0
  96. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/object/single_case.js +0 -0
  97. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/object/single_enumerable_case.js +0 -0
  98. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/mixins/responder_context.js +0 -0
  99. data/lib/frameworks/sproutcore/frameworks/amber/tests/mixins/string.js +55 -0
  100. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/builder.js +0 -0
  101. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/core_query/within.js +7 -8
  102. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/json.js +0 -0
  103. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/locale.js +0 -0
  104. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/begin.js +0 -0
  105. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/element.js +0 -0
  106. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/end.js +1 -1
  107. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/get.js +0 -0
  108. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/helpers_attr.js +0 -0
  109. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/helpers_basic.js +0 -0
  110. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/helpers_className.js +0 -2
  111. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/helpers_style.js +11 -3
  112. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/init.js +0 -0
  113. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/join.js +0 -0
  114. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/push_text.js +0 -0
  115. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/tag.js +0 -0
  116. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/update.js +0 -0
  117. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/makeKeyPane.js +0 -0
  118. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/makeMainPane.js +0 -0
  119. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/makeMenuPane.js +0 -0
  120. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/root_responder.js +0 -0
  121. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/targetForAction.js +46 -9
  122. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/add.js +0 -0
  123. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/copy.js +0 -0
  124. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/indexSetForSource.js +0 -0
  125. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/isEqual.js +0 -0
  126. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/remove.js +0 -0
  127. data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/sparse_array.js +0 -0
  128. data/lib/frameworks/sproutcore/frameworks/amber/tests/system/theme.js +77 -0
  129. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/invalidate.js +0 -0
  130. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/invokeLater.js +7 -5
  131. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/isPaused.js +0 -0
  132. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/performAction.js +0 -0
  133. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/schedule.js +0 -0
  134. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/utils/normalizeURL.js +0 -0
  135. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/utils/rect.js +0 -0
  136. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/main_pane.js +0 -0
  137. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/append_remove.js +0 -0
  138. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/firstResponder.js +0 -0
  139. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/keyPane.js +0 -0
  140. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/layout.js +0 -0
  141. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/sendEvent.js +0 -0
  142. data/lib/frameworks/sproutcore/frameworks/amber/tests/views/pane/sendTouchEvent.js +267 -0
  143. data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/animation.js +320 -0
  144. data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/build.js +85 -0
  145. data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/build_children.js +89 -0
  146. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/clippingFrame.js +3 -2
  147. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/convertFrames.js +0 -0
  148. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/convertLayouts.js +0 -0
  149. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/createChildViews.js +0 -0
  150. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/createLayer.js +2 -2
  151. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/destroyLayer.js +0 -0
  152. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/didAppendToDocument.js +0 -0
  153. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/findLayerInParentLayer.js +0 -0
  154. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/init.js +0 -0
  155. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/insertBefore.js +0 -0
  156. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/isVisible.js +0 -0
  157. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/isVisibleInWindow.js +0 -0
  158. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/layer.js +0 -0
  159. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/layoutChildViews.js +0 -0
  160. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/layoutDidChange.js +22 -0
  161. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/layoutStyle.js +135 -64
  162. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/parentViewDidChange.js +0 -0
  163. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/prepareContext.js +16 -8
  164. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/removeChild.js +0 -0
  165. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/render.js +37 -5
  166. data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/render_delegate_support.js +163 -0
  167. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/replaceChild.js +0 -0
  168. data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/theme.js +43 -0
  169. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/updateLayer.js +12 -10
  170. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/updateLayerLocation.js +0 -0
  171. data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/view.js +64 -0
  172. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/viewDidResize.js +0 -0
  173. data/lib/frameworks/sproutcore/frameworks/amber/views/base.js +1 -0
  174. data/lib/frameworks/sproutcore/frameworks/amber/views/layout_style.js +478 -0
  175. data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/views/view.js +1719 -1029
  176. data/lib/frameworks/sproutcore/frameworks/animation/core.js +32 -18
  177. data/lib/frameworks/sproutcore/frameworks/animation/tests/core.js +10 -5
  178. data/lib/frameworks/sproutcore/frameworks/bootstrap/system/bench.js +14 -0
  179. data/lib/frameworks/sproutcore/frameworks/bootstrap/system/browser.js +24 -17
  180. data/lib/frameworks/sproutcore/frameworks/bootstrap/system/loader.js +1 -13
  181. data/lib/frameworks/sproutcore/frameworks/bootstrap/tests/system/browser.js +72 -0
  182. data/lib/frameworks/sproutcore/frameworks/datastore/models/child_record.js +2 -2
  183. data/lib/frameworks/sproutcore/frameworks/datastore/models/record.js +7 -3
  184. data/lib/frameworks/sproutcore/frameworks/datastore/models/record_attribute.js +66 -4
  185. data/lib/frameworks/sproutcore/frameworks/datastore/system/many_array.js +4 -1
  186. data/lib/frameworks/sproutcore/frameworks/datastore/system/record_array.js +58 -10
  187. data/lib/frameworks/sproutcore/frameworks/datastore/system/store.js +5 -14
  188. data/lib/frameworks/sproutcore/frameworks/debug/invoke_once_last_debugging.js +4 -5
  189. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/list_item.css +27 -3
  190. data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/segmented.css +5 -8
  191. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_fast_path.js +1 -1
  192. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_row_delegate.js +30 -4
  193. data/lib/frameworks/sproutcore/frameworks/desktop/mixins/navigation_builder.js +130 -0
  194. data/lib/frameworks/sproutcore/frameworks/desktop/panes/alert.js +2 -0
  195. data/lib/frameworks/sproutcore/frameworks/desktop/panes/menu.js +20 -2
  196. data/lib/frameworks/sproutcore/frameworks/desktop/panes/panel.js +9 -27
  197. data/lib/frameworks/sproutcore/frameworks/desktop/panes/picker.js +32 -26
  198. data/lib/frameworks/sproutcore/frameworks/desktop/panes/select_button.js +57 -11
  199. data/lib/frameworks/sproutcore/frameworks/desktop/protocols/drop_target.js +2 -2
  200. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/button.js +78 -0
  201. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/checkbox.js +74 -0
  202. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/collection.js +24 -0
  203. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/disclosure.js +41 -0
  204. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/helpers/slicing.js +34 -0
  205. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/image_button.js +30 -0
  206. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/master_detail.js +28 -0
  207. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/menu.js +47 -0
  208. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/panel.js +28 -0
  209. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/picker.js +43 -0
  210. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/progress.js +175 -0
  211. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/radio.js +74 -0
  212. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/radio_group.js +109 -0
  213. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/segment.js +70 -0
  214. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/segmented.js +58 -0
  215. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/slider.js +39 -0
  216. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/source_list.js +8 -0
  217. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/toolbar.js +18 -0
  218. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/well.js +29 -0
  219. data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/workspace.js +18 -0
  220. data/lib/frameworks/sproutcore/frameworks/desktop/system/drag.js +79 -53
  221. data/lib/frameworks/sproutcore/frameworks/desktop/tests/integration/dialog.js +7 -2
  222. data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/menu/ui.js +1 -1
  223. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/button/methods.js +45 -3
  224. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/button/ui.js +33 -13
  225. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/checkbox/methods.js +11 -17
  226. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/image_button/ui.js +25 -0
  227. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list_item.js +128 -20
  228. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/progress/ui.js +10 -10
  229. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/segmented/methods.js +35 -15
  230. data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/segmented/ui.js +162 -0
  231. data/lib/frameworks/sproutcore/frameworks/desktop/views/button.js +153 -208
  232. data/lib/frameworks/sproutcore/frameworks/desktop/views/checkbox.js +18 -48
  233. data/lib/frameworks/sproutcore/frameworks/desktop/views/collection.js +26 -25
  234. data/lib/frameworks/sproutcore/frameworks/desktop/views/disclosure.js +3 -20
  235. data/lib/frameworks/sproutcore/frameworks/desktop/views/file.js +112 -0
  236. data/lib/frameworks/sproutcore/frameworks/desktop/views/image_button.js +74 -0
  237. data/lib/frameworks/sproutcore/frameworks/desktop/views/list.js +3 -1
  238. data/lib/frameworks/sproutcore/frameworks/desktop/views/list_item.js +388 -309
  239. data/lib/frameworks/sproutcore/frameworks/desktop/views/master_detail.js +257 -0
  240. data/lib/frameworks/sproutcore/frameworks/desktop/views/menu_item.js +8 -3
  241. data/lib/frameworks/sproutcore/frameworks/desktop/views/navigation.js +237 -0
  242. data/lib/frameworks/sproutcore/frameworks/desktop/views/navigation_bar.js +181 -0
  243. data/lib/frameworks/sproutcore/frameworks/desktop/views/popup_button.js +3 -2
  244. data/lib/frameworks/sproutcore/frameworks/desktop/views/progress.js +14 -76
  245. data/lib/frameworks/sproutcore/frameworks/desktop/views/radio.js +59 -164
  246. data/lib/frameworks/sproutcore/frameworks/desktop/views/scroll.js +80 -47
  247. data/lib/frameworks/sproutcore/frameworks/desktop/views/segment.js +84 -0
  248. data/lib/frameworks/sproutcore/frameworks/desktop/views/segmented.js +320 -289
  249. data/lib/frameworks/sproutcore/frameworks/desktop/views/select.js +212 -76
  250. data/lib/frameworks/sproutcore/frameworks/desktop/views/slider.js +33 -36
  251. data/lib/frameworks/sproutcore/frameworks/desktop/views/source_list.js +2 -0
  252. data/lib/frameworks/sproutcore/frameworks/desktop/views/split.js +347 -248
  253. data/lib/frameworks/sproutcore/frameworks/desktop/views/static_content.js +1 -1
  254. data/lib/frameworks/sproutcore/frameworks/desktop/views/tab.js +1 -1
  255. data/lib/frameworks/sproutcore/frameworks/desktop/views/toolbar.js +41 -9
  256. data/lib/frameworks/sproutcore/frameworks/desktop/views/web.js +1 -1
  257. data/lib/frameworks/sproutcore/frameworks/desktop/views/well.js +2 -21
  258. data/lib/frameworks/sproutcore/frameworks/desktop/views/workspace.js +251 -0
  259. data/lib/frameworks/sproutcore/frameworks/documentation/core.js +0 -0
  260. data/lib/frameworks/sproutcore/frameworks/forms/english.lproj/default_styles.css +5 -0
  261. data/lib/frameworks/sproutcore/frameworks/forms/english.lproj/strings.js +15 -0
  262. data/lib/frameworks/sproutcore/frameworks/forms/mixins/edit_mode.js +43 -0
  263. data/lib/frameworks/sproutcore/frameworks/forms/mixins/emptiness.js +95 -0
  264. data/lib/frameworks/sproutcore/frameworks/forms/renderer_delegates/form.js +22 -0
  265. data/lib/frameworks/sproutcore/frameworks/forms/renderer_delegates/form_row.js +21 -0
  266. data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form.js +15 -0
  267. data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_checkbox_field.js +15 -0
  268. data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_field.js +15 -0
  269. data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_label.js +15 -0
  270. data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_radio_field.js +15 -0
  271. data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_row.js +15 -0
  272. data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_text_field.js +15 -0
  273. data/lib/frameworks/sproutcore/frameworks/forms/views/form.js +280 -0
  274. data/lib/frameworks/sproutcore/frameworks/forms/views/form_row.js +183 -0
  275. data/lib/frameworks/sproutcore/frameworks/foundation/controllers/tree.js +5 -2
  276. data/lib/frameworks/sproutcore/frameworks/foundation/core.js +0 -150
  277. data/lib/frameworks/sproutcore/frameworks/foundation/debug/control_test_pane.js +0 -2
  278. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/benchmark.css +146 -0
  279. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/bootstrap.rhtml +2 -14
  280. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/favicon.ico +0 -0
  281. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore.png +0 -0
  282. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/strings.js +0 -2
  283. data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/text_field.css +4 -6
  284. data/lib/frameworks/sproutcore/frameworks/foundation/gestures/pinch.js +81 -0
  285. data/lib/frameworks/sproutcore/frameworks/foundation/gestures/swipe.js +144 -0
  286. data/lib/frameworks/sproutcore/frameworks/foundation/gestures/tap.js +113 -0
  287. data/lib/frameworks/sproutcore/frameworks/foundation/license.js +24 -26
  288. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/auto_mixin.js +39 -0
  289. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/auto_resize.js +244 -0
  290. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/control.js +68 -23
  291. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/editable.js +8 -2
  292. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/flowed_layout.js +626 -0
  293. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/gestureable.js +214 -0
  294. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/inline_editable.js +89 -0
  295. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/inline_editor_delegate.js +139 -0
  296. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/inline_text_field.js +25 -33
  297. data/lib/frameworks/sproutcore/frameworks/foundation/mixins/string.js +57 -209
  298. data/lib/frameworks/sproutcore/frameworks/foundation/private/tree_item_observer.js +7 -3
  299. data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/canvas_image.js +100 -0
  300. data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/container.js +18 -0
  301. data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/image.js +97 -0
  302. data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/label.js +111 -0
  303. data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/render_delegate.js +17 -0
  304. data/lib/frameworks/sproutcore/frameworks/foundation/system/benchmark.js +360 -156
  305. data/lib/frameworks/sproutcore/frameworks/{runtime → foundation}/system/cookie.js +35 -35
  306. data/lib/frameworks/sproutcore/frameworks/foundation/system/core_query.js +19 -2012
  307. data/lib/frameworks/sproutcore/frameworks/foundation/system/exception_handler.js +3 -0
  308. data/lib/frameworks/sproutcore/frameworks/foundation/system/gesture.js +363 -0
  309. data/lib/frameworks/sproutcore/frameworks/foundation/system/{image_cache.js → image_queue.js} +19 -22
  310. data/lib/frameworks/sproutcore/frameworks/foundation/system/module.js +576 -0
  311. data/lib/frameworks/sproutcore/frameworks/foundation/system/request.js +19 -22
  312. data/lib/frameworks/sproutcore/frameworks/foundation/system/response.js +73 -61
  313. data/lib/frameworks/sproutcore/frameworks/foundation/system/routes.js +122 -23
  314. data/lib/frameworks/sproutcore/frameworks/foundation/system/staticqueue.js +53 -0
  315. data/lib/frameworks/sproutcore/frameworks/foundation/system/task_queue.js +18 -15
  316. data/lib/frameworks/sproutcore/frameworks/foundation/system/user_defaults.js +82 -90
  317. data/lib/frameworks/sproutcore/frameworks/foundation/system/utils/colors.js +80 -0
  318. data/lib/frameworks/sproutcore/frameworks/foundation/system/utils/misc.js +76 -0
  319. data/lib/frameworks/sproutcore/frameworks/foundation/system/utils/range.js +64 -0
  320. data/lib/frameworks/sproutcore/frameworks/foundation/system/utils/string_measurement.js +247 -0
  321. data/lib/frameworks/sproutcore/frameworks/foundation/tasks/preload_bundle.js +3 -3
  322. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/inline_text_field/beginEditing.js +2 -2
  323. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/staticLayout.js +2 -0
  324. data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/string.js +2 -57
  325. data/lib/frameworks/sproutcore/frameworks/{runtime → foundation}/tests/system/cookie.js +0 -0
  326. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/setClass.js +13 -3
  327. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/request.js +99 -49
  328. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/routes.js +24 -20
  329. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/container/methods.js +9 -1
  330. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/container/ui.js +31 -6
  331. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/image/ui.js +454 -44
  332. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/label/ui.js +10 -1
  333. data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/{view → text_field}/nextValidKeyView.js +0 -0
  334. data/lib/frameworks/sproutcore/frameworks/foundation/validators/number.js +1 -0
  335. data/lib/frameworks/sproutcore/frameworks/foundation/views/container.js +9 -8
  336. data/lib/frameworks/sproutcore/frameworks/foundation/views/field.js +1 -3
  337. data/lib/frameworks/sproutcore/frameworks/foundation/views/image.js +381 -105
  338. data/lib/frameworks/sproutcore/frameworks/foundation/views/label.js +44 -171
  339. data/lib/frameworks/sproutcore/frameworks/foundation/views/text_field.js +69 -16
  340. data/lib/frameworks/sproutcore/frameworks/jquery/jquery-buffer.js +376 -0
  341. data/lib/frameworks/sproutcore/frameworks/jquery/jquery-buffered.js +205 -0
  342. data/lib/frameworks/sproutcore/frameworks/jquery/jquery-sc.js +7 -0
  343. data/lib/frameworks/sproutcore/frameworks/jquery/jquery.js +7179 -0
  344. data/lib/frameworks/sproutcore/frameworks/media/views/audio.js +4 -2
  345. data/lib/frameworks/sproutcore/frameworks/media/views/controls.js +1 -3
  346. data/lib/frameworks/sproutcore/frameworks/media/views/simple_controls.js +1 -2
  347. data/lib/frameworks/sproutcore/frameworks/mini/license.js +29 -28
  348. data/lib/frameworks/sproutcore/frameworks/runtime/core.js +366 -333
  349. data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/rangeObserver.js +73 -73
  350. data/lib/frameworks/sproutcore/frameworks/runtime/license.js +29 -28
  351. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/array.js +160 -150
  352. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/comparable.js +9 -9
  353. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/copyable.js +15 -15
  354. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/enumerable.js +228 -220
  355. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/freezable.js +27 -27
  356. data/lib/frameworks/sproutcore/frameworks/runtime/mixins/observable.js +355 -305
  357. data/lib/frameworks/sproutcore/frameworks/runtime/private/chain_observer.js +32 -32
  358. data/lib/frameworks/sproutcore/frameworks/runtime/private/observer_queue.js +53 -51
  359. data/lib/frameworks/sproutcore/frameworks/runtime/private/observer_set.js +49 -106
  360. data/lib/frameworks/sproutcore/frameworks/runtime/system/binding.js +252 -252
  361. data/lib/frameworks/sproutcore/frameworks/runtime/system/enumerator.js +22 -22
  362. data/lib/frameworks/sproutcore/frameworks/runtime/system/error.js +31 -31
  363. data/lib/frameworks/sproutcore/frameworks/runtime/system/index_set.js +234 -234
  364. data/lib/frameworks/sproutcore/frameworks/runtime/system/logger.js +4 -4
  365. data/lib/frameworks/sproutcore/frameworks/runtime/system/object.js +167 -157
  366. data/lib/frameworks/sproutcore/frameworks/runtime/system/range_observer.js +84 -85
  367. data/lib/frameworks/sproutcore/frameworks/runtime/system/run_loop.js +104 -91
  368. data/lib/frameworks/sproutcore/frameworks/runtime/system/set.js +102 -98
  369. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/IsEqual.js +19 -49
  370. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/guidFor.js +53 -126
  371. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/itemType.js +62 -33
  372. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/enumerable.js +41 -5
  373. data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/observable/observable.js +133 -98
  374. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/observer_set.js +50 -0
  375. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/range_observer/create.js +11 -11
  376. data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/set.js +71 -45
  377. data/lib/frameworks/sproutcore/frameworks/statechart/core.js +3 -9
  378. data/lib/frameworks/sproutcore/frameworks/statechart/debug/monitor.js +136 -0
  379. data/lib/frameworks/sproutcore/frameworks/statechart/system/state.js +636 -99
  380. data/lib/frameworks/sproutcore/frameworks/statechart/system/statechart.js +951 -0
  381. data/lib/frameworks/sproutcore/frameworks/statechart/tests/async.js +94 -0
  382. data/lib/frameworks/sproutcore/frameworks/statechart/tests/event_handling/advanced_event_handling.js +310 -0
  383. data/lib/frameworks/sproutcore/frameworks/statechart/tests/namespace/access_substates.js +252 -0
  384. data/lib/frameworks/sproutcore/frameworks/statechart/tests/state/is_current_state.js +64 -0
  385. data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_history_state.js +88 -0
  386. data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_state_advanced.js +234 -0
  387. data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_state_async.js +123 -0
  388. data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_state_basic.js +139 -0
  389. data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_state_intermediate.js +119 -0
  390. data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/send_event.js +183 -0
  391. data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/default_responder.js +90 -0
  392. data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/goto_history_state.js +200 -0
  393. data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/goto_state.js +256 -0
  394. data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/goto_state_async.js +187 -0
  395. data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/send_event.js +122 -0
  396. data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/state_plugin.js +99 -0
  397. data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/transient.js +162 -0
  398. data/lib/frameworks/sproutcore/frameworks/table/views/table_cell.js +2 -1
  399. data/lib/frameworks/sproutcore/frameworks/table/views/table_head.js +1 -1
  400. data/lib/frameworks/sproutcore/frameworks/table/views/table_row.js +1 -1
  401. data/lib/frameworks/sproutcore/frameworks/testing/system/runner.js +2 -1
  402. data/lib/frameworks/sproutcore/lib/index.rhtml +24 -1
  403. data/lib/frameworks/sproutcore/license.js +31 -30
  404. data/lib/frameworks/sproutcore/themes/ace/designs/dark.png +0 -0
  405. data/lib/frameworks/sproutcore/themes/ace/designs/dark.psd +0 -0
  406. data/lib/frameworks/sproutcore/themes/ace/designs/light.png +0 -0
  407. data/lib/frameworks/sproutcore/themes/ace/designs/light.psd +0 -0
  408. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/18px/active_button.psd +0 -0
  409. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/18px/normal_button.psd +0 -0
  410. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/18px/selected_active_button.psd +0 -0
  411. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/18px/selected_button.psd +0 -0
  412. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/active_button.psd +0 -0
  413. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/active_button_capsule.psd +0 -0
  414. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/active_button_pointer.psd +0 -0
  415. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/normal_button.psd +0 -0
  416. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/normal_button_capsule.psd +0 -0
  417. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/normal_button_pointer.psd +0 -0
  418. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_active_button.psd +0 -0
  419. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_active_button_capsule.psd +0 -0
  420. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_active_button_pointer.psd +0 -0
  421. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_button.psd +0 -0
  422. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_button_capsule.psd +0 -0
  423. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_button_pointer.psd +0 -0
  424. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/active_button.psd +0 -0
  425. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/active_button_pointer.psd +0 -0
  426. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/normal_button.psd +0 -0
  427. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/normal_button_pointer.psd +0 -0
  428. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/selected_active_button.psd +0 -0
  429. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/selected_active_button_pointer.psd +0 -0
  430. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/selected_button.psd +0 -0
  431. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/selected_button_pointer.psd +0 -0
  432. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/44px/active_button.psd +0 -0
  433. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/44px/normal_button.psd +0 -0
  434. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/44px/selected_active_button.psd +0 -0
  435. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/44px/selected_button.psd +0 -0
  436. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/active_button.psd +0 -0
  437. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/active_button_capsule.psd +0 -0
  438. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/active_button_pointer.psd +0 -0
  439. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/normal_button.psd +0 -0
  440. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/normal_button_capsule.psd +0 -0
  441. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/normal_button_pointer.psd +0 -0
  442. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_active_button.psd +0 -0
  443. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_active_button_capsule.psd +0 -0
  444. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_active_button_pointer.psd +0 -0
  445. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_button.psd +0 -0
  446. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_button_capsule.psd +0 -0
  447. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_button_pointer.psd +0 -0
  448. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/active_button.psd +0 -0
  449. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/active_button_pointer.psd +0 -0
  450. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/normal_button.psd +0 -0
  451. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/normal_button_pointer.psd +0 -0
  452. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/selected_active_button.psd +0 -0
  453. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/selected_active_button_pointer.psd +0 -0
  454. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/selected_button.psd +0 -0
  455. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/selected_button_pointer.psd +0 -0
  456. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/popup/active_select.psd +0 -0
  457. data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/popup/normal_select.psd +0 -0
  458. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_checked.psd +0 -0
  459. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_checked_active.psd +0 -0
  460. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_mixed.psd +0 -0
  461. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_mixed_active.psd +0 -0
  462. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_unchecked.psd +0 -0
  463. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_unchecked_active.psd +0 -0
  464. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_checked.psd +0 -0
  465. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_checked_active.psd +0 -0
  466. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_mixed.psd +0 -0
  467. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_mixed_active.psd +0 -0
  468. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_unchecked.psd +0 -0
  469. data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_unchecked_active.psd +0 -0
  470. data/lib/frameworks/sproutcore/themes/ace/designs/psds/collection/source-list/selection.psd +0 -0
  471. data/lib/frameworks/sproutcore/themes/ace/designs/psds/disclosure/ace/disclosure_closed.psd +0 -0
  472. data/lib/frameworks/sproutcore/themes/ace/designs/psds/disclosure/ace/disclosure_closed_active.psd +0 -0
  473. data/lib/frameworks/sproutcore/themes/ace/designs/psds/disclosure/ace/disclosure_open.psd +0 -0
  474. data/lib/frameworks/sproutcore/themes/ace/designs/psds/disclosure/ace/disclosure_open_active.psd +0 -0
  475. data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/checkmark.psd +0 -0
  476. data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/checkmark_active.psd +0 -0
  477. data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/down.psd +0 -0
  478. data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/menu.psd +0 -0
  479. data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/menu_item.psd +0 -0
  480. data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/up.psd +0 -0
  481. data/lib/frameworks/sproutcore/themes/ace/designs/psds/panel/panel.psd +0 -0
  482. data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover.psd +0 -0
  483. data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover_empty.psd +0 -0
  484. data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover_notoolbar.psd +0 -0
  485. data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover_pointers.psd +0 -0
  486. data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover_pointers_notoolbar.psd +0 -0
  487. data/lib/frameworks/sproutcore/themes/ace/designs/psds/progress/ace/progress_view_content.psd +0 -0
  488. data/lib/frameworks/sproutcore/themes/ace/designs/psds/progress/ace/progress_view_indeterminate_content.psd +0 -0
  489. data/lib/frameworks/sproutcore/themes/ace/designs/psds/progress/ace/progress_view_track.psd +0 -0
  490. data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_active.psd +0 -0
  491. data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_mixed.psd +0 -0
  492. data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_mixed_active.psd +0 -0
  493. data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_selected.psd +0 -0
  494. data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_selected_active.psd +0 -0
  495. data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_unselected.psd +0 -0
  496. data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/horizontal/thumb.psd +0 -0
  497. data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/horizontal/track_and_arrows.psd +0 -0
  498. data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/horizontal/track_and_arrows_active.psd +0 -0
  499. data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/vertical/thumb.psd +0 -0
  500. data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/vertical/track_and_arrows.psd +0 -0
  501. data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/vertical/track_and_arrows_active.psd +0 -0
  502. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/18px/segmented_active.psd +0 -0
  503. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/18px/segmented_normal.psd +0 -0
  504. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/18px/segmented_selected.psd +0 -0
  505. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/18px/segmented_selected_active.psd +0 -0
  506. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/24px/segmented_active.psd +0 -0
  507. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/24px/segmented_normal.psd +0 -0
  508. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/24px/segmented_selected.psd +0 -0
  509. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/24px/segmented_selected_active.psd +0 -0
  510. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/30px/segmented_active.psd +0 -0
  511. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/30px/segmented_normal.psd +0 -0
  512. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/30px/segmented_selected.psd +0 -0
  513. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/30px/segmented_selected_active.psd +0 -0
  514. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/44px/segmented_active.psd +0 -0
  515. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/44px/segmented_normal.psd +0 -0
  516. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/44px/segmented_selected.psd +0 -0
  517. data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/44px/segmented_selected_active.psd +0 -0
  518. data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/14px/knob.psd +0 -0
  519. data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/14px/knob_active.psd +0 -0
  520. data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/16px/knob.psd +0 -0
  521. data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/16px/knob_active.psd +0 -0
  522. data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/22px/knob.psd +0 -0
  523. data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/22px/knob_active.psd +0 -0
  524. data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/22px/track.psd +0 -0
  525. data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/track.psd +0 -0
  526. data/lib/frameworks/sproutcore/themes/ace/designs/psds/toolbar/toolbar.psd +0 -0
  527. data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch.psd +0 -0
  528. data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_handle.png +0 -0
  529. data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_handle.psd +0 -0
  530. data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_off.png +0 -0
  531. data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_off.psd +0 -0
  532. data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_on.png +0 -0
  533. data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_on.psd +0 -0
  534. data/lib/frameworks/sproutcore/themes/ace/resources/body.css +13 -0
  535. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/active_button.png +0 -0
  536. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/button.css +27 -0
  537. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/normal_button.png +0 -0
  538. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/selected_active_button.png +0 -0
  539. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/selected_button.png +0 -0
  540. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/active_button.png +0 -0
  541. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/active_button_capsule.png +0 -0
  542. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/active_button_pointer.png +0 -0
  543. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/button.css +84 -0
  544. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/normal_button.png +0 -0
  545. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/normal_button_capsule.png +0 -0
  546. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/normal_button_pointer.png +0 -0
  547. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_active_button.png +0 -0
  548. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_active_button_capsule.png +0 -0
  549. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_active_button_pointer.png +0 -0
  550. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_button.png +0 -0
  551. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_button_capsule.png +0 -0
  552. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_button_pointer.png +0 -0
  553. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/active_button.png +0 -0
  554. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/active_button_pointer.png +0 -0
  555. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/button.css +66 -0
  556. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/normal_button.png +0 -0
  557. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/normal_button_pointer.png +0 -0
  558. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/selected_active_button.png +0 -0
  559. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/selected_active_button_pointer.png +0 -0
  560. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/selected_button.png +0 -0
  561. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/selected_button_pointer.png +0 -0
  562. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/active_button.png +0 -0
  563. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/button.css +34 -0
  564. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/normal_button.png +0 -0
  565. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/selected_active_button.png +0 -0
  566. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/selected_button.png +0 -0
  567. data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/button.css +28 -0
  568. data/lib/frameworks/sproutcore/themes/ace/resources/button/button.js +69 -0
  569. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/active_button.png +0 -0
  570. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/active_button_capsule.png +0 -0
  571. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/active_button_pointer.png +0 -0
  572. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/button.css +84 -0
  573. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/normal_button.png +0 -0
  574. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/normal_button_capsule.png +0 -0
  575. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/normal_button_pointer.png +0 -0
  576. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_active_button.png +0 -0
  577. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_active_button_capsule.png +0 -0
  578. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_active_button_pointer.png +0 -0
  579. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_button.png +0 -0
  580. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_button_capsule.png +0 -0
  581. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_button_pointer.png +0 -0
  582. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/active_button.png +0 -0
  583. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/active_button_pointer.png +0 -0
  584. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/button.css +66 -0
  585. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/normal_button.png +0 -0
  586. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/normal_button_pointer.png +0 -0
  587. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/selected_active_button.png +0 -0
  588. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/selected_active_button_pointer.png +0 -0
  589. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/selected_button.png +0 -0
  590. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/selected_button_pointer.png +0 -0
  591. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/button.css +17 -0
  592. data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/button.js +3 -0
  593. data/lib/frameworks/sproutcore/themes/ace/resources/button/popup/active_select.png +0 -0
  594. data/lib/frameworks/sproutcore/themes/ace/resources/button/popup/normal_select.png +0 -0
  595. data/lib/frameworks/sproutcore/themes/ace/resources/button/popup/select.css +20 -0
  596. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox.css +40 -0
  597. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_checked.png +0 -0
  598. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_checked_active.png +0 -0
  599. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_mixed.png +0 -0
  600. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_mixed_active.png +0 -0
  601. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_unchecked.png +0 -0
  602. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_unchecked_active.png +0 -0
  603. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox.css +40 -0
  604. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_checked.png +0 -0
  605. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_checked_active.png +0 -0
  606. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_mixed.png +0 -0
  607. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_mixed_active.png +0 -0
  608. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_unchecked.png +0 -0
  609. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_unchecked_active.png +0 -0
  610. data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/checkbox.css +7 -0
  611. data/lib/frameworks/sproutcore/themes/ace/resources/collection/normal/list.css +4 -0
  612. data/lib/frameworks/sproutcore/themes/ace/resources/collection/normal/list_item.css +17 -0
  613. data/lib/frameworks/sproutcore/themes/ace/resources/collection/source-list/selection.png +0 -0
  614. data/lib/frameworks/sproutcore/themes/ace/resources/collection/source-list/source-list.js +3 -0
  615. data/lib/frameworks/sproutcore/themes/ace/resources/collection/source-list/source_list_view.css +36 -0
  616. data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure.css +24 -0
  617. data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure_closed.png +0 -0
  618. data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure_closed_active.png +0 -0
  619. data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure_open.png +0 -0
  620. data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure_open_active.png +0 -0
  621. data/lib/frameworks/sproutcore/themes/ace/resources/loading.css +50 -0
  622. data/lib/frameworks/sproutcore/themes/ace/resources/master-detail/master-detail.css +27 -0
  623. data/lib/frameworks/sproutcore/themes/ace/resources/menu/checkmark.png +0 -0
  624. data/lib/frameworks/sproutcore/themes/ace/resources/menu/checkmark_active.png +0 -0
  625. data/lib/frameworks/sproutcore/themes/ace/resources/menu/down.png +0 -0
  626. data/lib/frameworks/sproutcore/themes/ace/resources/menu/menu.css +76 -0
  627. data/lib/frameworks/sproutcore/themes/ace/resources/menu/menu.png +0 -0
  628. data/lib/frameworks/sproutcore/themes/ace/resources/menu/menu_item.png +0 -0
  629. data/lib/frameworks/sproutcore/themes/ace/resources/menu/up.png +0 -0
  630. data/lib/frameworks/sproutcore/themes/ace/resources/pane/pane.css +3 -0
  631. data/lib/frameworks/sproutcore/themes/ace/resources/panel/panel.css +13 -0
  632. data/lib/frameworks/sproutcore/themes/ace/resources/panel/panel.js +20 -0
  633. data/lib/frameworks/sproutcore/themes/ace/resources/panel/panel.png +0 -0
  634. data/lib/frameworks/sproutcore/themes/ace/resources/picker/ace/picker.js +0 -0
  635. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/picker.js +32 -0
  636. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover.css +111 -0
  637. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover.js +12 -0
  638. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover.png +0 -0
  639. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover_empty.png +0 -0
  640. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover_notoolbar.png +0 -0
  641. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover_pointers.png +0 -0
  642. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover_pointers_notoolbar.png +0 -0
  643. data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/workspace.js +28 -0
  644. data/lib/frameworks/sproutcore/themes/ace/resources/progress/ace/progress.css +27 -0
  645. data/lib/frameworks/sproutcore/themes/ace/resources/progress/ace/progress_view_content.png +0 -0
  646. data/lib/frameworks/sproutcore/themes/ace/resources/progress/ace/progress_view_track.png +0 -0
  647. data/lib/frameworks/sproutcore/themes/ace/resources/progress/progress.js +78 -0
  648. data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio.css +63 -0
  649. data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_active.png +0 -0
  650. data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_mixed.png +0 -0
  651. data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_mixed_active.png +0 -0
  652. data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_selected.png +0 -0
  653. data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_selected_active.png +0 -0
  654. data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_unselected.png +0 -0
  655. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/horizontal.css +78 -0
  656. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/horizontal_touch.css +91 -0
  657. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/thumb.png +0 -0
  658. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/track_and_arrows.png +0 -0
  659. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/track_and_arrows_active.png +0 -0
  660. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/thumb.png +0 -0
  661. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/track_and_arrows.png +0 -0
  662. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/track_and_arrows_active.png +0 -0
  663. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/vertical.css +80 -0
  664. data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/vertical_touch.css +92 -0
  665. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented.css +91 -0
  666. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented_active.png +0 -0
  667. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented_normal.png +0 -0
  668. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented_selected.png +0 -0
  669. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented_selected_active.png +0 -0
  670. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented.css +91 -0
  671. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented_active.png +0 -0
  672. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented_normal.png +0 -0
  673. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented_selected.png +0 -0
  674. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented_selected_active.png +0 -0
  675. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented.css +91 -0
  676. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented_active.png +0 -0
  677. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented_normal.png +0 -0
  678. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented_selected.png +0 -0
  679. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented_selected_active.png +0 -0
  680. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented.css +95 -0
  681. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented_active.png +0 -0
  682. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented_normal.png +0 -0
  683. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented_selected.png +0 -0
  684. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented_selected_active.png +0 -0
  685. data/lib/frameworks/sproutcore/themes/ace/resources/segmented/segmented.css +79 -0
  686. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/14px/knob.png +0 -0
  687. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/14px/knob_active.png +0 -0
  688. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/14px/slider.css +27 -0
  689. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/16px/knob.png +0 -0
  690. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/16px/knob_active.png +0 -0
  691. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/16px/slider.css +27 -0
  692. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/22px/knob.png +0 -0
  693. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/22px/knob_active.png +0 -0
  694. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/22px/slider.css +27 -0
  695. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/22px/track.png +0 -0
  696. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/slider.css +3 -0
  697. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/slider.js +48 -0
  698. data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/track.png +0 -0
  699. data/lib/frameworks/sproutcore/themes/ace/resources/split/split.css +5 -0
  700. data/lib/frameworks/sproutcore/themes/ace/resources/tab/tab.css +3 -0
  701. data/lib/frameworks/sproutcore/themes/ace/resources/toolbar/toolbar.css +8 -0
  702. data/lib/frameworks/sproutcore/themes/ace/resources/toolbar/toolbar.png +0 -0
  703. data/lib/frameworks/sproutcore/themes/ace/resources/well/well.css +8 -0
  704. data/lib/frameworks/sproutcore/themes/ace/resources/well/well.js +19 -0
  705. data/lib/frameworks/sproutcore/themes/ace/theme.js +14 -0
  706. data/lib/frameworks/sproutcore/themes/empty_theme/theme.js +16 -0
  707. data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/segmented.css +16 -21
  708. data/lib/sproutcore.rb +9 -2
  709. data/lib/sproutcore/builders.rb +2 -1
  710. data/lib/sproutcore/builders/base.rb +7 -2
  711. data/lib/sproutcore/builders/combine.rb +49 -1
  712. data/lib/sproutcore/builders/html.rb +2 -0
  713. data/lib/sproutcore/builders/javascript.rb +1 -1
  714. data/lib/sproutcore/builders/minify.rb +12 -12
  715. data/lib/sproutcore/builders/module.rb +72 -0
  716. data/lib/sproutcore/builders/string_wrapper.rb +43 -0
  717. data/lib/sproutcore/helpers/entry_sorter.rb +5 -9
  718. data/lib/sproutcore/helpers/static_helper.rb +13 -9
  719. data/lib/sproutcore/models/manifest_entry.rb +2 -2
  720. data/lib/sproutcore/models/target.rb +25 -11
  721. data/lib/sproutcore/rack/dev.rb +3 -3
  722. data/lib/sproutcore/tools.rb +51 -2
  723. data/lib/sproutcore/tools/build.rb +35 -7
  724. data/lib/sproutcore/version.rb +1 -0
  725. data/spec/buildtasks/manifest/prepare_build_tasks/bundle_spec.rb +5 -5
  726. data/spec/fixtures/builder_tests/Buildfile +2 -2
  727. data/spec/lib/builders/bundle_spec.rb +8 -8
  728. data/spec/lib/builders/strings_spec.rb +1 -0
  729. data/sproutcore.gemspec +9 -2
  730. data/vendor/chance/.gitignore +5 -0
  731. data/vendor/chance/Gemfile +4 -0
  732. data/vendor/chance/Rakefile +2 -0
  733. data/vendor/chance/bin/chance +72 -0
  734. data/vendor/chance/chance.gemspec +28 -0
  735. data/vendor/chance/lib/chance.rb +139 -0
  736. data/vendor/chance/lib/chance/imager.rb +13 -0
  737. data/vendor/chance/lib/chance/imagers/data_url.rb +34 -0
  738. data/vendor/chance/lib/chance/importer.rb +64 -0
  739. data/vendor/chance/lib/chance/instance.rb +225 -0
  740. data/vendor/chance/lib/chance/parser.rb +831 -0
  741. data/vendor/chance/lib/chance/perf.rb +17 -0
  742. data/vendor/chance/lib/chance/sass_extensions.rb +24 -0
  743. data/vendor/chance/lib/chance/slicing.rb +104 -0
  744. data/vendor/chance/lib/chance/version.rb +3 -0
  745. data/vendor/chance/test/case/abc.png +0 -0
  746. data/vendor/chance/test/case/more/abc.png +0 -0
  747. data/vendor/chance/test/case/more/another.css +4 -0
  748. data/vendor/chance/test/case/test1.css +22 -0
  749. data/vendor/chance/test/case/test2.css +6 -0
  750. data/vendor/sproutcore/SCCompiler.jar +0 -0
  751. data/vendor/sproutcore/lib/args4j-2.0.12.jar +0 -0
  752. data/vendor/sproutcore/lib/htmlcompressor-0.9.3.jar +0 -0
  753. data/{lib/sproutcore/vendor/yui-compressor → vendor/sproutcore/lib}/yuicompressor-2.4.2.jar +0 -0
  754. data/vendor/sproutcore/src/SCCompiler/build.xml +74 -0
  755. data/vendor/sproutcore/src/SCCompiler/lib/args4j-2.0.12.jar +0 -0
  756. data/vendor/sproutcore/src/SCCompiler/lib/htmlcompressor-0.9.3.jar +0 -0
  757. data/{lib/sproutcore/vendor/yui-compressor/SCyuicompressor-2.4.2.jar → vendor/sproutcore/src/SCCompiler/lib/yuicompressor-2.4.2.jar} +0 -0
  758. data/vendor/sproutcore/src/SCCompiler/lib/yuicompressor-2.4.4.jar +0 -0
  759. data/vendor/sproutcore/src/SCCompiler/manifest.mf +3 -0
  760. data/vendor/sproutcore/src/SCCompiler/nbproject/build-impl.xml +894 -0
  761. data/vendor/sproutcore/src/SCCompiler/nbproject/genfiles.properties +8 -0
  762. data/vendor/sproutcore/src/SCCompiler/nbproject/private/config.properties +0 -0
  763. data/vendor/sproutcore/src/SCCompiler/nbproject/private/private.properties +10 -0
  764. data/vendor/sproutcore/src/SCCompiler/nbproject/private/private.xml +4 -0
  765. data/vendor/sproutcore/src/SCCompiler/nbproject/project.properties +90 -0
  766. data/vendor/sproutcore/src/SCCompiler/nbproject/project.xml +15 -0
  767. data/vendor/sproutcore/src/SCCompiler/src/com/sproutcore/Main.java +348 -0
  768. metadata +686 -177
  769. data/lib/frameworks/sproutcore/CHANGELOG +0 -93
  770. data/lib/frameworks/sproutcore/frameworks/datejs/core.js +0 -865
  771. data/lib/frameworks/sproutcore/frameworks/datejs/english.lproj/en-US.js +0 -186
  772. data/lib/frameworks/sproutcore/frameworks/datejs/extras.js +0 -332
  773. data/lib/frameworks/sproutcore/frameworks/datejs/license.js +0 -25
  774. data/lib/frameworks/sproutcore/frameworks/datejs/parser.js +0 -1116
  775. data/lib/frameworks/sproutcore/frameworks/datejs/spanish.lproj/es-CO.js +0 -186
  776. data/lib/frameworks/sproutcore/frameworks/datejs/sugarpak.js +0 -475
  777. data/lib/frameworks/sproutcore/frameworks/datejs/time.js +0 -269
  778. data/lib/frameworks/sproutcore/frameworks/datejs/validators/datejs.js +0 -34
  779. data/lib/frameworks/sproutcore/frameworks/foundation/protocols/inline_editor_delegate.js +0 -84
  780. data/lib/frameworks/sproutcore/frameworks/foundation/system/bundle.js +0 -337
  781. data/lib/frameworks/sproutcore/frameworks/foundation/system/ready.js +0 -197
  782. data/lib/frameworks/sproutcore/frameworks/foundation/system/utils.js +0 -710
  783. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_core.js +0 -1334
  784. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_dimensions.js +0 -387
  785. data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_selector.js +0 -405
  786. data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/isArray.js +0 -25
  787. data/lib/frameworks/sproutcore/frameworks/statechart/mixins/statechart.js +0 -336
  788. data/lib/frameworks/sproutcore/frameworks/statechart/tests/basic.js +0 -90
  789. data/lib/frameworks/sproutcore/frameworks/statechart/tests/history.js +0 -71
  790. data/lib/frameworks/sproutcore/frameworks/statechart/tests/nested.js +0 -59
  791. data/lib/frameworks/sproutcore/frameworks/statechart/tests/transient.js +0 -148
  792. data/lib/sproutcore/builders/bundle.rb +0 -63
@@ -25,13 +25,6 @@ SC.SliderView = SC.View.extend(SC.Control,
25
25
 
26
26
  classNames: 'sc-slider-view',
27
27
 
28
- /**
29
- The DOM element that displays the handle. This element will have its
30
- top-left corner updated to reflect the current state of the slider. Use
31
- margin-offsets to properly position your handle over this location.
32
- */
33
- handleSelector: 'img.sc-handle',
34
-
35
28
  /**
36
29
  Bind this to the current value of the progress bar. Note that by default
37
30
  an empty value will disable the progress bar and a multiple value too make
@@ -81,11 +74,13 @@ SC.SliderView = SC.View.extend(SC.Control,
81
74
  // INTERNAL PROPERTIES
82
75
  //
83
76
 
84
- displayProperties: 'value minimum maximum'.w(),
77
+ displayProperties: 'displayValue minimum maximum step frame'.w(),
78
+
79
+ // The name of the render delegate which is creating and maintaining
80
+ // the DOM associated with instances of this view
81
+ renderDelegateName: 'sliderRenderDelegate',
85
82
 
86
- render: function(context, firstTime) {
87
- sc_super();
88
-
83
+ displayValue: function() {
89
84
  var min = this.get('minimum'),
90
85
  max = this.get('maximum'),
91
86
  value = this.get('value'),
@@ -102,20 +97,8 @@ SC.SliderView = SC.View.extend(SC.Control,
102
97
  // determine the percent across
103
98
  if(value!==0) value = Math.floor((value - min) / (max - min) * 100);
104
99
 
105
- if(firstTime) {
106
- var blankImage = SC.BLANK_IMAGE_URL;
107
- context.push('<span class="sc-inner">',
108
- '<span class="sc-leftcap"></span>',
109
- '<span class="sc-rightcap"></span>',
110
- '<img src="', blankImage,
111
- '" class="sc-handle" style="left: ', value, '%" />',
112
- '</span>');
113
- }
114
- else {
115
- this.$(this.get('handleSelector')).css('left', value + "%");
116
- }
117
-
118
- },
100
+ return value;
101
+ }.property('value', 'minimum', 'maximum', 'step').cacheable(),
119
102
 
120
103
  _isMouseDown: NO,
121
104
 
@@ -123,7 +106,7 @@ SC.SliderView = SC.View.extend(SC.Control,
123
106
  if (!this.get('isEnabled')) return YES; // nothing to do...
124
107
  this.set('isActive', YES);
125
108
  this._isMouseDown = YES ;
126
- return this._triggerHandle(evt, true);
109
+ return this._triggerHandle(evt, YES);
127
110
  },
128
111
 
129
112
  // mouseDragged uses same technique as mouseDown.
@@ -170,7 +153,7 @@ SC.SliderView = SC.View.extend(SC.Control,
170
153
  */
171
154
  _triggerHandle: function(evt, firstEvent) {
172
155
  var width = this.get('frame').width,
173
- min = this.get('minimum'), max=this.get('maximum'),
156
+ min = this.get('minimum'), max=this.get('maximum'),
174
157
  step = this.get('step'), v=this.get('value'), loc;
175
158
 
176
159
  if(firstEvent){
@@ -180,19 +163,33 @@ SC.SliderView = SC.View.extend(SC.Control,
180
163
  loc = evt.pageX-this._evtDiff;
181
164
  }
182
165
 
183
- // constrain loc to 8px on either side (left to allow knob overhang)
184
- loc = Math.max(Math.min(loc,width-8), 8) - 8;
185
- width -= 16 ; // reduce by margin
186
-
187
166
  // convert to percentage
188
- loc = loc / width ;
167
+ loc = Math.max(0, Math.min(loc / width, 1));
168
+
169
+ // if the location is NOT in the general vicinity of the slider, we assume
170
+ // that the mouse pointer or touch is in the center of where the knob should be.
171
+ // otherwise, if we are starting, we need to do extra to add an offset
172
+ if (firstEvent) {
173
+ var value = this.get("value");
174
+ value = (value - min) / (max - min);
175
+
176
+ // if the value and the loc are within 16px
177
+ if (Math.abs(value * width - loc * width) < 16) this._offset = value - loc;
178
+ else this._offset = 0;
179
+ }
189
180
 
181
+ // add offset and constrain
182
+ loc = Math.max(0, Math.min(loc + this._offset, 1));
183
+
190
184
  // convert to value using minimum/maximum then constrain to steps
191
185
  loc = min + ((max-min)*loc);
192
186
  if (step !== 0) loc = Math.round(loc / step) * step ;
193
-
187
+
194
188
  // if changes by more than a rounding amount, set v.
195
- if (Math.abs(v-loc)>=0.01) this.set('value', loc); // adjust
189
+ if (Math.abs(v-loc)>=0.01) {
190
+ this.set('value', loc); // adjust
191
+ }
192
+
196
193
  return YES ;
197
194
  },
198
195
 
@@ -208,7 +205,7 @@ SC.SliderView = SC.View.extend(SC.Control,
208
205
  this._isFocused = YES ;
209
206
  this.becomeFirstResponder();
210
207
  if (this.get('isVisibleInWindow')) {
211
- this.$()[0].focus();
208
+ this.$().focus();
212
209
  }
213
210
  }
214
211
  },
@@ -220,7 +217,7 @@ SC.SliderView = SC.View.extend(SC.Control,
220
217
  keyDown: function(evt) {
221
218
 
222
219
  // handle tab key
223
- if (evt.which === 9) {
220
+ if (evt.which === 9 || evt.keyCode === 9) {
224
221
  var view = evt.shiftKey ? this.get('previousValidKeyView') : this.get('nextValidKeyView');
225
222
  if(view) view.becomeFirstResponder();
226
223
  else evt.allowDefault();
@@ -21,6 +21,8 @@ SC.BENCHMARK_SOURCE_LIST_VIEW = YES ;
21
21
  */
22
22
  SC.SourceListView = SC.ListView.extend(
23
23
  /** @scope SC.SourceListView.prototype */ {
24
+
25
+ theme: 'source-list',
24
26
 
25
27
  /**
26
28
  Add class name to HTML for styling.
@@ -5,6 +5,8 @@
5
5
  // License: Licensed under MIT license (see license.js)
6
6
  // ==========================================================================
7
7
 
8
+ sc_require('views/split_divider');
9
+
8
10
  SC.RESIZE_BOTH = 'resize-both';
9
11
  SC.RESIZE_TOP_LEFT = 'resize-top-left';
10
12
  SC.RESIZE_BOTTOM_RIGHT = 'resize-bottom-right';
@@ -58,13 +60,6 @@ SC.RESIZE_BOTTOM_RIGHT = 'resize-bottom-right';
58
60
  This property should be set when the view is created. Changing it
59
61
  dynamically will have an unknown effect.
60
62
 
61
- @property {Boolean} layoutDirection Either SC.HORIZONTAL or SC.VERTICAL.
62
- Defaults to SC.HORIZONTAL. Use the :direction option with the split_view
63
- viewhelper.
64
-
65
- @property {Boolean} canCollapseViews Set to NO when you don't want any of
66
- the child views to collapse. Defaults to YES.
67
-
68
63
  In addition, the top/left and bottom/right child views can have these
69
64
  properties:
70
65
 
@@ -91,11 +86,15 @@ SC.SplitView = SC.View.extend(
91
86
  Direction of layout. Must be SC.LAYOUT_HORIZONTAL or SC.LAYOUT_VERTICAL.
92
87
 
93
88
  @property {String}
89
+ @default SC.LAYOUT_HORIZONTAL
94
90
  */
95
91
  layoutDirection: SC.LAYOUT_HORIZONTAL,
96
92
 
97
93
  /**
98
94
  Set to NO to disable collapsing for all views.
95
+
96
+ @property {Boolean}
97
+ @default YES
99
98
  */
100
99
  canCollapseViews: YES,
101
100
 
@@ -106,6 +105,8 @@ SC.SplitView = SC.View.extend(
106
105
  | SC.RESIZE_BOTTOM_RIGHT | (default) resizes bottomRightView |
107
106
  | SC.RESIZE_TOP_LEFT | resized topLeftView |
108
107
 
108
+ @property {String}
109
+ @default SC.RESIZE_BOTTOM_RIGHT
109
110
  */
110
111
  autoresizeBehavior: SC.RESIZE_BOTTOM_RIGHT,
111
112
 
@@ -118,21 +119,87 @@ SC.SplitView = SC.View.extend(
118
119
  autoresizeBehavior.
119
120
 
120
121
  @property {Number}
122
+ @default 0.5
121
123
  */
122
124
  defaultThickness: 0.5,
123
-
125
+
126
+ /**
127
+ Sets minimum thickness of topLeft view.
128
+
129
+ @property {Number}
130
+ @default null
131
+ */
132
+ topLeftMinThickness: null,
133
+
134
+ /**
135
+ Sets maximum thickness of topLeft view.
136
+
137
+ @property {Number}
138
+ @default null
139
+ */
140
+ topLeftMaxThickness: null,
141
+
142
+ /**
143
+ Sets minimum thickness of bottomRight view.
144
+
145
+ @property {Number}
146
+ @default null
147
+ */
148
+ bottomRightMinThickness: null,
149
+
150
+ /**
151
+ Sets maximum thickness of bottomRight view.
152
+
153
+ @property {Number}
154
+ @default null
155
+ */
156
+ bottomRightMaxThickness: null,
157
+
158
+ /**
159
+ Sets thickness of divider.
160
+
161
+ @property {Number}
162
+ @default null
163
+ */
164
+ dividerThickness: null,
165
+
124
166
  /**
125
167
  Yes, we're a split view.
168
+
169
+ @property {Boolean}
170
+ @default YES
126
171
  */
127
172
  isSplitView: YES,
128
173
 
129
- // add default views
174
+ /**
175
+ The view to use for the top left
176
+
177
+ @property {SC.View}
178
+ @default SC.View
179
+ */
130
180
  topLeftView: SC.View,
181
+
182
+ /**
183
+ The view to use for the divider
184
+
185
+ @property {SC.View}
186
+ @default SC.SplitDividerView
187
+ */
131
188
  dividerView: SC.SplitDividerView,
189
+
190
+ /**
191
+ The view to use for the bottom right
192
+
193
+ @property {SC.View}
194
+ @default SC.View
195
+ */
132
196
  bottomRightView: SC.View,
133
197
 
134
198
  /**
135
199
  The current thickness for the topLeftView
200
+
201
+ @property {Number}
202
+ @isReadOnly
136
203
  */
137
204
  topLeftThickness: function() {
138
205
  var view = this.get('topLeftView');
@@ -141,6 +208,9 @@ SC.SplitView = SC.View.extend(
141
208
 
142
209
  /**
143
210
  The current thickness for the bottomRightView
211
+
212
+ @property {Number}
213
+ @isReadOnly
144
214
  */
145
215
  bottomRightThickness: function() {
146
216
  var view = this.get('bottomRightView');
@@ -148,16 +218,21 @@ SC.SplitView = SC.View.extend(
148
218
  }.property('bottomRightView').cacheable(),
149
219
 
150
220
  /**
151
- @property {SC.Cursor} the cursor thumb view should use for themselves
221
+ The cursor thumb views should use for themselves
222
+
223
+ @property {SC.Cursor}
224
+ @default null
152
225
  */
153
226
  thumbViewCursor: null,
154
227
 
155
228
  /**
156
229
  Used by split divider to decide if the view can be collapsed.
230
+
231
+ @property {Boolean}
232
+ @isReadOnly
157
233
  */
158
234
  canCollapseView: function(view) {
159
- return this.invokeDelegateMethod(this.delegate, 'splitViewCanCollapse',
160
- this, view) ;
235
+ return this.invokeDelegateMethod(this.delegate, 'splitViewCanCollapse', this, view);
161
236
  },
162
237
 
163
238
  /**
@@ -167,28 +242,35 @@ SC.SplitView = SC.View.extend(
167
242
  @returns the view with the width.
168
243
  */
169
244
  thicknessForView: function(view) {
170
- var direction = this.get('layoutDirection') ,
171
- ret = view.get('frame') ;
172
- return (direction === SC.LAYOUT_HORIZONTAL) ? ret.width : ret.height ;
245
+ var direction = this.get('layoutDirection'),
246
+ ret = view.get('frame');
247
+ return (direction === SC.LAYOUT_HORIZONTAL) ? ret.width : ret.height;
173
248
  },
174
249
 
175
- createChildViews: function() {
176
- var childViews = [] ,
177
- viewAry = ['topLeftView', 'dividerView', 'bottomRightView'] ,
178
- view, idx, len ;
250
+ /**
251
+ Creates the topLeftView/dividerView/bottomRightView and adds them to the
252
+ childViews array
179
253
 
180
- for (idx=0, len=viewAry.length; idx<len; ++idx) {
181
- if (view = this.get(viewAry[idx])) {
182
- view = this[viewAry[idx]] = this.createChildView(view, {
254
+ @returns SC.View the SplitDivider view (this)
255
+ */
256
+ createChildViews: function() {
257
+ var childViews = [],
258
+ views = ['topLeftView', 'dividerView', 'bottomRightView'],
259
+ l = views.length,
260
+ view, i;
261
+
262
+ for (i=0; i<l; ++i) {
263
+ if (view = this.get(views[i])) {
264
+ view = this[views[i]] = this.createChildView(view, {
183
265
  layoutView: this,
184
- rootElementPath: [idx]
185
- }) ;
186
- childViews.push(view) ;
266
+ rootElementPath: [i]
267
+ });
268
+ childViews.push(view);
187
269
  }
188
270
  }
189
271
 
190
- this.set('childViews', childViews) ;
191
- return this ;
272
+ this.set('childViews', childViews);
273
+ return this;
192
274
  },
193
275
 
194
276
  /**
@@ -199,56 +281,60 @@ SC.SplitView = SC.View.extend(
199
281
  that they can resize appropriately.
200
282
  */
201
283
  updateChildLayout: function() {
202
- var topLeftView = this.get('topLeftView') ,
203
- bottomRightView = this.get('bottomRightView') ,
204
- dividerView = this.get('dividerView') ,
205
- direction = this.get('layoutDirection') ,
206
- topLeftThickness = this._desiredTopLeftThickness ;
207
- var dividerThickness = this.get('dividerThickness') ;
208
- dividerThickness = (!SC.none(dividerThickness)) ? dividerThickness : 7 ;
209
- var splitViewThickness = (direction === SC.LAYOUT_HORIZONTAL) ? this.get('frame').width : this.get('frame').height ,
210
- bottomRightThickness = splitViewThickness - dividerThickness - topLeftThickness ,
211
- autoresizeBehavior = this.get('autoresizeBehavior') ,
212
- layout , isCollapsed ;
213
-
284
+ var topLeftView = this.get('topLeftView'),
285
+ bottomRightView = this.get('bottomRightView'),
286
+ dividerView = this.get('dividerView'),
287
+ autoresizeBehavior = this.get('autoresizeBehavior'),
288
+ direction = this.get('layoutDirection'),
289
+ frame = this.get('frame'),
290
+ topLeftThickness = this._desiredTopLeftThickness,
291
+ dividerThickness = this.get('dividerThickness'),
292
+ splitViewThickness = (direction === SC.LAYOUT_HORIZONTAL) ? frame.width : frame.height,
293
+ bottomRightThickness = splitViewThickness - dividerThickness - topLeftThickness,
294
+ layout, isCollapsed;
295
+
296
+ dividerThickness = (!SC.none(dividerThickness)) ? dividerThickness : 7;
214
297
 
215
298
  // top/left view
216
- isCollapsed = topLeftView.get('isCollapsed') || NO ;
217
- topLeftView.setIfChanged('isVisible', !isCollapsed) ;
299
+ isCollapsed = topLeftView.get('isCollapsed') || NO;
300
+ topLeftView.setIfChanged('isVisible', !isCollapsed);
218
301
  layout = SC.clone(topLeftView.get('layout'));
302
+
219
303
  if (direction === SC.LAYOUT_HORIZONTAL) {
220
- layout.top = 0 ;
221
- layout.left = 0 ;
222
- layout.bottom = 0 ;
304
+ layout.top = 0;
305
+ layout.left = 0;
306
+ layout.bottom = 0;
307
+
223
308
  switch (autoresizeBehavior) {
224
309
  case SC.RESIZE_BOTH:
225
310
  throw "SC.RESIZE_BOTH is currently unsupported.";
226
311
  case SC.RESIZE_TOP_LEFT:
227
- layout.right = bottomRightThickness + dividerThickness ;
228
- delete layout.width ;
229
- break ;
312
+ layout.right = bottomRightThickness + dividerThickness;
313
+ delete layout.width;
314
+ break;
230
315
  case SC.RESIZE_BOTTOM_RIGHT:
231
- delete layout.right ;
232
- delete layout.height ;
233
- layout.width = topLeftThickness ;
234
- break ;
316
+ delete layout.right;
317
+ delete layout.height;
318
+ layout.width = topLeftThickness;
319
+ break;
235
320
  }
236
321
  } else {
237
322
  layout.top = 0;
238
- layout.left = 0 ;
239
- layout.right = 0 ;
323
+ layout.left = 0;
324
+ layout.right = 0;
325
+
240
326
  switch (autoresizeBehavior) {
241
327
  case SC.RESIZE_BOTH:
242
328
  throw "SC.RESIZE_BOTH is currently unsupported.";
243
329
  case SC.RESIZE_TOP_LEFT:
244
- layout.bottom = bottomRightThickness + dividerThickness ;
245
- delete layout.height ;
246
- break ;
330
+ layout.bottom = bottomRightThickness + dividerThickness;
331
+ delete layout.height;
332
+ break;
247
333
  case SC.RESIZE_BOTTOM_RIGHT:
248
- delete layout.bottom ;
249
- delete layout.width ;
250
- layout.height = topLeftThickness ;
251
- break ;
334
+ layout.height = topLeftThickness;
335
+ delete layout.bottom;
336
+ delete layout.width;
337
+ break;
252
338
  }
253
339
  }
254
340
  topLeftView.set('layout', layout);
@@ -256,11 +342,13 @@ SC.SplitView = SC.View.extend(
256
342
  // split divider view
257
343
  if (dividerView) {
258
344
  layout = SC.clone(dividerView.get('layout'));
345
+
259
346
  if (direction === SC.LAYOUT_HORIZONTAL) {
260
347
  layout.width = dividerThickness;
261
- delete layout.height ;
262
- layout.top = 0 ;
263
- layout.bottom = 0 ;
348
+ layout.top = 0;
349
+ layout.bottom = 0;
350
+ delete layout.height;
351
+
264
352
  switch (autoresizeBehavior) {
265
353
  case SC.RESIZE_BOTH:
266
354
  throw "SC.RESIZE_BOTH is currently unsupported.";
@@ -270,23 +358,24 @@ SC.SplitView = SC.View.extend(
270
358
  // delete layout.centerY ;
271
359
  //break ;
272
360
  case SC.RESIZE_TOP_LEFT:
273
- delete layout.left ;
274
- layout.right = bottomRightThickness ;
275
- delete layout.centerX ;
276
- delete layout.centerY ;
277
- break ;
361
+ layout.right = bottomRightThickness;
362
+ delete layout.left;
363
+ delete layout.centerX;
364
+ delete layout.centerY;
365
+ break;
278
366
  case SC.RESIZE_BOTTOM_RIGHT:
279
- layout.left = topLeftThickness ;
280
- delete layout.right ;
281
- delete layout.centerX ;
282
- delete layout.centerY ;
283
- break ;
367
+ layout.left = topLeftThickness;
368
+ delete layout.right;
369
+ delete layout.centerX;
370
+ delete layout.centerY;
371
+ break;
284
372
  }
285
373
  } else {
286
- delete layout.width ;
287
- layout.height = dividerThickness ;
288
- layout.left = 0 ;
289
- layout.right = 0 ;
374
+ layout.height = dividerThickness;
375
+ layout.left = 0;
376
+ layout.right = 0;
377
+ delete layout.width;
378
+
290
379
  switch (autoresizeBehavior) {
291
380
  case SC.RESIZE_BOTH:
292
381
  throw "SC.RESIZE_BOTH is currently unsupported.";
@@ -296,16 +385,16 @@ SC.SplitView = SC.View.extend(
296
385
  // layout.centerY = topLeftThickness + (dividerThickness / 2) ;
297
386
  //break ;
298
387
  case SC.RESIZE_TOP_LEFT:
299
- delete layout.top ;
300
- layout.bottom = bottomRightThickness ;
301
- delete layout.centerX ;
302
- delete layout.centerY ;
388
+ layout.bottom = bottomRightThickness;
389
+ delete layout.top;
390
+ delete layout.centerX;
391
+ delete layout.centerY;
303
392
  break ;
304
393
  case SC.RESIZE_BOTTOM_RIGHT:
305
- layout.top = topLeftThickness ;
306
- delete layout.bottom ;
307
- delete layout.centerX ;
308
- delete layout.centerY ;
394
+ layout.top = topLeftThickness;
395
+ delete layout.bottom;
396
+ delete layout.centerX;
397
+ delete layout.centerY;
309
398
  break ;
310
399
  }
311
400
  }
@@ -313,123 +402,126 @@ SC.SplitView = SC.View.extend(
313
402
  }
314
403
 
315
404
  // bottom/right view
316
- isCollapsed = bottomRightView.get('isCollapsed') || NO ;
317
- bottomRightView.setIfChanged('isVisible', !isCollapsed) ;
405
+ isCollapsed = bottomRightView.get('isCollapsed') || NO;
406
+ bottomRightView.setIfChanged('isVisible', !isCollapsed);
318
407
  layout = SC.clone(bottomRightView.get('layout'));
408
+
319
409
  if (direction === SC.LAYOUT_HORIZONTAL) {
320
- layout.top = 0 ;
321
- layout.bottom = 0 ;
322
- layout.right = 0 ;
410
+ layout.top = 0;
411
+ layout.bottom = 0;
412
+ layout.right = 0;
413
+
323
414
  switch (autoresizeBehavior) {
324
415
  case SC.RESIZE_BOTH:
325
416
  throw "SC.RESIZE_BOTH is currently unsupported.";
326
- //break ;
327
417
  case SC.RESIZE_BOTTOM_RIGHT:
328
- layout.left = topLeftThickness + dividerThickness ;
329
- delete layout.width ;
330
- break ;
418
+ layout.left = topLeftThickness + dividerThickness;
419
+ delete layout.width;
420
+ break;
331
421
  case SC.RESIZE_TOP_LEFT:
332
- delete layout.left ;
333
- layout.width = bottomRightThickness ;
334
- break ;
422
+ layout.width = bottomRightThickness;
423
+ delete layout.left;
424
+ break;
335
425
  }
336
426
  } else {
337
- layout.left = 0 ;
338
- layout.right = 0 ;
339
- layout.bottom = 0 ;
427
+ layout.left = 0;
428
+ layout.right = 0;
429
+ layout.bottom = 0;
430
+
340
431
  switch (autoresizeBehavior) {
341
432
  case SC.RESIZE_BOTH:
342
433
  throw "SC.RESIZE_BOTH is currently unsupported.";
343
- //break ;
344
434
  case SC.RESIZE_BOTTOM_RIGHT:
345
- layout.top = topLeftThickness + dividerThickness ;
346
- delete layout.height ;
347
- break ;
435
+ layout.top = topLeftThickness + dividerThickness;
436
+ delete layout.height;
437
+ break;
348
438
  case SC.RESIZE_TOP_LEFT:
349
- delete layout.top ;
350
- layout.height = bottomRightThickness ;
351
- break ;
439
+ delete layout.top;
440
+ layout.height = bottomRightThickness;
441
+ break;
352
442
  }
353
443
  }
354
444
  bottomRightView.set('layout', layout);
355
445
 
356
- this.notifyPropertyChange('topLeftThickness')
357
- .notifyPropertyChange('bottomRightThickness');
446
+ this
447
+ .notifyPropertyChange('topLeftThickness')
448
+ .notifyPropertyChange('bottomRightThickness');
358
449
  },
359
450
 
360
451
  /** @private */
361
452
  renderLayout: function(context, firstTime) {
362
453
  if (firstTime || this._recalculateDivider) {
454
+
455
+ var layoutDirection = this.get('layoutDirection'),
456
+ frame = this.get('frame'),
457
+ elem = this.$(),
458
+ desiredThickness = this.get('defaultThickness') ,
459
+ autoResizeBehavior = this.get('autoresizeBehavior'),
460
+ dividerThickness = this.get('dividerThickness'),
461
+ splitViewThickness;
462
+
363
463
  if (!this.get('thumbViewCursor')) {
364
- this.set('thumbViewCursor', SC.Cursor.create()) ;
464
+ this.set('thumbViewCursor', SC.Cursor.create());
365
465
  }
366
466
 
367
- var layoutDirection = this.get('layoutDirection') ,
368
- fr = this.get('frame'),
369
- splitViewThickness, elemRendered = this.$(),
370
- desiredThickness = this.get('defaultThickness') ,
371
- autoResizeBehavior = this.get('autoresizeBehavior') ;
372
- var dividerThickness = this.get('dividerThickness') ;
373
- dividerThickness = (!SC.none(dividerThickness)) ? dividerThickness : 7 ;
467
+ dividerThickness = !SC.none(dividerThickness) ? dividerThickness : 7;
468
+
374
469
  // Turn a flag on to recalculate the spliting if the desired thickness
375
470
  // is a percentage
376
- if(this._recalculateDivider===undefined && desiredThickness<1) {
377
- this._recalculateDivider=YES;
471
+ if (this._recalculateDivider === undefined && desiredThickness < 1) {
472
+ this._recalculateDivider = YES;
473
+ } else if (this._recalculateDivider) {
474
+ this._recalculateDivider = NO;
378
475
  }
379
- else if(this._recalculateDivider) this._recalculateDivider=NO;
380
-
381
476
 
382
- if(elemRendered[0]) {
383
- splitViewThickness = (layoutDirection === SC.LAYOUT_HORIZONTAL) ?
384
- elemRendered[0].offsetWidth : elemRendered[0].offsetHeight ;
385
- }else{
386
- splitViewThickness = (layoutDirection === SC.LAYOUT_HORIZONTAL) ?
387
- fr.width : fr.height ;
477
+ if (elem[0]) {
478
+ splitViewThickness = (layoutDirection === SC.LAYOUT_HORIZONTAL) ? elem[0].offsetWidth : elem[0].offsetHeight;
479
+ } else {
480
+ splitViewThickness = (layoutDirection === SC.LAYOUT_HORIZONTAL) ? frame.width : frame.height;
388
481
  }
482
+
389
483
  // if default thickness is < 1, convert from percentage to absolute
390
- if (SC.none(desiredThickness) ||
391
- (desiredThickness > 0 && desiredThickness < 1)) {
392
- desiredThickness = Math.floor((splitViewThickness -
393
- (dividerThickness))* (desiredThickness || 0.5)) ;
484
+ if (SC.none(desiredThickness) || (desiredThickness > 0 && desiredThickness < 1)) {
485
+ desiredThickness = Math.floor((splitViewThickness - (dividerThickness)) * (desiredThickness || 0.5));
394
486
  }
487
+
395
488
  if (autoResizeBehavior === SC.RESIZE_BOTTOM_RIGHT) {
396
- this._desiredTopLeftThickness = desiredThickness ;
397
- } else { // (autoResizeBehavior === SC.RESIZE_TOP_LEFT)
398
- this._desiredTopLeftThickness = splitViewThickness
399
- - dividerThickness - desiredThickness ;
489
+ this._desiredTopLeftThickness = desiredThickness;
490
+ } else {
491
+ this._desiredTopLeftThickness = splitViewThickness - dividerThickness - desiredThickness ;
400
492
  }
401
493
 
402
494
  // make sure we don't exceed our min and max values, and that collapse
403
495
  // settings are respected
404
496
  // cached values are required by _updateTopLeftThickness() below...
405
- this._topLeftView = this.get('topLeftView') ;
406
- this._bottomRightView = this.get('bottomRightView') ;
497
+ this._topLeftView = this.get('topLeftView');
498
+ this._bottomRightView = this.get('bottomRightView');
407
499
  this._topLeftViewThickness = this.thicknessForView(this.get('topLeftView'));
408
500
  this._bottomRightThickness = this.thicknessForView(this.get('bottomRightView'));
409
- this._dividerThickness = this.get('dividerThickness') ;
410
- this._layoutDirection = this.get('layoutDirection') ;
501
+ this._dividerThickness = this.get('dividerThickness');
502
+ this._layoutDirection = this.get('layoutDirection');
411
503
 
412
504
  // this handles min-max settings and collapse parameters
413
- this._updateTopLeftThickness(0) ;
505
+ this._updateTopLeftThickness(0);
414
506
 
415
507
  // update the cursor used by thumb views
416
- this._setCursorStyle() ;
508
+ this._setCursorStyle();
417
509
 
418
510
  // actually set layout for our child views
419
- this.updateChildLayout() ;
511
+ this.updateChildLayout();
420
512
  }
421
- sc_super() ;
513
+
514
+ sc_super();
422
515
  },
423
516
 
424
517
  /** @private */
425
518
  render: function(context, firstTime) {
426
- sc_super() ;
519
+ sc_super();
427
520
 
428
- if (this._inLiveResize) this._setCursorStyle() ;
521
+ if (this._inLiveResize) this._setCursorStyle();
429
522
 
430
- var dir = this.get('layoutDirection') ;
431
- if (dir===SC.LAYOUT_HORIZONTAL) context.addClass('sc-horizontal') ;
432
- else context.addClass('sc-vertical') ;
523
+ if (this.get('layoutDirection') === SC.LAYOUT_HORIZONTAL) context.addClass('sc-horizontal');
524
+ else context.addClass('sc-vertical');
433
525
  },
434
526
 
435
527
  /**
@@ -442,45 +534,44 @@ SC.SplitView = SC.View.extend(
442
534
  @returns {Boolean}
443
535
  */
444
536
  mouseDownInThumbView: function(evt, thumbView) {
445
- var responder = this.getPath('pane.rootResponder') ;
446
- if (!responder) return NO ; // nothing to do
537
+ var responder = this.getPath('pane.rootResponder');
538
+ if (!responder) return NO; // nothing to do
447
539
 
448
540
  // we're not the source view of the mouseDown:, so we need to capture events manually to receive them
449
- responder.dragDidStart(this) ;
541
+ responder.dragDidStart(this);
450
542
 
451
543
  // cache for later
452
- this._mouseDownX = evt.pageX ;
453
- this._mouseDownY = evt.pageY ;
454
- this._thumbView = thumbView ;
455
- this._topLeftView = this.get('topLeftView') ;
456
- this._bottomRightView = this.get('bottomRightView') ;
544
+ this._mouseDownX = evt.pageX;
545
+ this._mouseDownY = evt.pageY;
546
+ this._thumbView = thumbView;
547
+ this._topLeftView = this.get('topLeftView');
548
+ this._bottomRightView = this.get('bottomRightView');
457
549
  this._topLeftViewThickness = this.thicknessForView(this.get('topLeftView'));
458
550
  this._bottomRightThickness = this.thicknessForView(this.get('bottomRightView'));
459
- this._dividerThickness = this.get('dividerThickness') ;
460
- this._layoutDirection = this.get('layoutDirection') ;
551
+ this._dividerThickness = this.get('dividerThickness');
552
+ this._layoutDirection = this.get('layoutDirection');
461
553
 
462
- this.beginLiveResize() ;
463
- this._inLiveResize = YES ;
554
+ this.beginLiveResize();
555
+ this._inLiveResize = YES;
464
556
 
465
- return YES ;
557
+ return YES;
466
558
  },
467
559
 
468
560
  mouseDragged: function(evt) {
469
- var offset = (this._layoutDirection === SC.LAYOUT_HORIZONTAL) ? evt.pageX
470
- - this._mouseDownX : evt.pageY - this._mouseDownY ;
471
- this._updateTopLeftThickness(offset) ;
561
+ var offset = (this._layoutDirection === SC.LAYOUT_HORIZONTAL) ? evt.pageX - this._mouseDownX : evt.pageY - this._mouseDownY ;
562
+ this._updateTopLeftThickness(offset);
472
563
  return YES;
473
564
  },
474
565
 
475
566
  mouseUp: function(evt) {
476
567
  if (this._inLiveResize === YES) {
477
- this._thumbView = null ; // avoid memory leaks
478
- this._inLiveResize = NO ;
479
- this.endLiveResize() ;
480
- return YES ;
568
+ this._thumbView = null; // avoid memory leaks
569
+ this._inLiveResize = NO;
570
+ this.endLiveResize();
571
+ return YES;
481
572
  }
482
573
 
483
- return NO ;
574
+ return NO;
484
575
  },
485
576
 
486
577
  touchesDragged: function(evt){
@@ -491,25 +582,25 @@ SC.SplitView = SC.View.extend(
491
582
  return this.mouseUp(evt);
492
583
  },
493
584
 
494
-
495
585
  doubleClickInThumbView: function(evt, thumbView) {
496
586
  var view = this._topLeftView,
497
- isCollapsed = view.get('isCollapsed') || NO ;
587
+ isCollapsed = view.get('isCollapsed') || NO;
588
+
498
589
  if (!isCollapsed && !this.canCollapseView(view)) {
499
- view = this._bottomRightView ;
500
- isCollapsed = view.get('isCollapsed') || NO ;
590
+ view = this._bottomRightView;
591
+ isCollapsed = view.get('isCollapsed') || NO;
501
592
  if (!isCollapsed && !this.canCollapseView(view)) return NO;
502
593
  }
503
594
 
504
595
  if (!isCollapsed) {
505
596
  // remember thickness in it's uncollapsed state
506
- this._uncollapsedThickness = this.thicknessForView(view) ;
597
+ this._uncollapsedThickness = this.thicknessForView(view);
507
598
  // and collapse
508
599
  // this.setThicknessForView(view, 0) ;
509
600
  if (view === this._topLeftView) {
510
- this._updateTopLeftThickness(this.topLeftThickness()*-1) ;
601
+ this._updateTopLeftThickness(this.topLeftThickness()*-1);
511
602
  } else {
512
- this._updateBottomRightThickness(this.bottomRightThickness()*-1) ;
603
+ this._updateBottomRightThickness(this.bottomRightThickness()*-1);
513
604
  }
514
605
 
515
606
  // if however the splitview decided not to collapse, clear:
@@ -519,24 +610,24 @@ SC.SplitView = SC.View.extend(
519
610
  } else {
520
611
  // uncollapse to the last thickness in it's uncollapsed state
521
612
  if (view === this._topLeftView) {
522
- this._updateTopLeftThickness(this._uncollapsedThickness) ;
613
+ this._updateTopLeftThickness(this._uncollapsedThickness);
523
614
  } else {
524
- this._updateBottomRightThickness(this._uncollapsedThickness) ;
615
+ this._updateBottomRightThickness(this._uncollapsedThickness);
525
616
  }
526
- view._uncollapsedThickness = null ;
617
+ view._uncollapsedThickness = null;
527
618
  }
528
- this._setCursorStyle() ;
529
- return true ;
619
+ this._setCursorStyle();
620
+ return true;
530
621
  },
531
622
 
532
623
  /** @private */
533
624
  _updateTopLeftThickness: function(offset) {
534
- var topLeftView = this._topLeftView ,
625
+ var topLeftView = this._topLeftView,
535
626
  bottomRightView = this._bottomRightView,
536
627
  // the current thickness, not the original thickness
537
628
  topLeftViewThickness = this.thicknessForView(topLeftView),
538
629
  bottomRightViewThickness = this.thicknessForView(bottomRightView),
539
- minAvailable = this._dividerThickness ,
630
+ minAvailable = this._dividerThickness,
540
631
  maxAvailable = 0,
541
632
  proposedThickness = this._topLeftViewThickness + offset,
542
633
  direction = this._layoutDirection,
@@ -548,53 +639,50 @@ SC.SplitView = SC.View.extend(
548
639
  bottomRightThickness, tlCollapseAtThickness, brCollapseAtThickness;
549
640
 
550
641
  if (!topLeftView.get("isCollapsed")) {
551
- maxAvailable += topLeftViewThickness ;
642
+ maxAvailable += topLeftViewThickness;
552
643
  }
553
644
  if (!bottomRightView.get("isCollapsed")) {
554
- maxAvailable += bottomRightViewThickness ;
645
+ maxAvailable += bottomRightViewThickness;
555
646
  }
556
647
 
557
- if (!SC.none(max)) thickness = Math.min(max, thickness) ;
558
- if (!SC.none(min)) thickness = Math.max(min, thickness) ;
648
+ if (!SC.none(max)) thickness = Math.min(max, thickness);
649
+ if (!SC.none(min)) thickness = Math.max(min, thickness);
559
650
 
560
651
  // constrain to thickness set on bottom/right
561
- max = this.get('bottomRightMaxThickness') ;
562
- min = this.get('bottomRightMinThickness') ;
563
- bottomRightThickness = maxAvailable - thickness ;
652
+ max = this.get('bottomRightMaxThickness');
653
+ min = this.get('bottomRightMinThickness');
654
+ bottomRightThickness = maxAvailable - thickness;
564
655
  if (!SC.none(max)) {
565
- bottomRightThickness = Math.min(max, bottomRightThickness) ;
656
+ bottomRightThickness = Math.min(max, bottomRightThickness);
566
657
  }
567
658
  if (!SC.none(min)) {
568
- bottomRightThickness = Math.max(min, bottomRightThickness) ;
659
+ bottomRightThickness = Math.max(min, bottomRightThickness);
569
660
  }
570
- thickness = maxAvailable - bottomRightThickness ;
661
+ thickness = maxAvailable - bottomRightThickness;
571
662
 
572
663
  // constrain to thickness determined by delegate.
573
664
  thickness = this.invokeDelegateMethod(this.delegate,
574
- 'splitViewConstrainThickness', this, topLeftView, thickness) ;
665
+ 'splitViewConstrainThickness', this, topLeftView, thickness);
575
666
 
576
667
  // cannot be more than what's available
577
- thickness = Math.min(thickness, maxAvailable) ;
668
+ thickness = Math.min(thickness, maxAvailable);
578
669
 
579
670
  // cannot be less than zero
580
- thickness = Math.max(0, thickness) ;
671
+ thickness = Math.max(0, thickness);
581
672
 
582
- tlCollapseAtThickness = topLeftView.get('collapseAtThickness') ;
583
- if (!tlCollapseAtThickness) tlCollapseAtThickness = 0 ;
584
- brCollapseAtThickness = bottomRightView.get('collapseAtThickness') ;
585
- brCollapseAtThickness = SC.none(brCollapseAtThickness) ?
586
- maxAvailable : (maxAvailable - brCollapseAtThickness);
673
+ tlCollapseAtThickness = topLeftView.get('collapseAtThickness');
674
+ if (!tlCollapseAtThickness) tlCollapseAtThickness = 0;
675
+ brCollapseAtThickness = bottomRightView.get('collapseAtThickness');
676
+ brCollapseAtThickness = SC.none(brCollapseAtThickness) ? maxAvailable : (maxAvailable - brCollapseAtThickness);
587
677
 
588
- if ((proposedThickness <= tlCollapseAtThickness) &&
589
- this.canCollapseView(topLeftView)) {
678
+ if ((proposedThickness <= tlCollapseAtThickness) && this.canCollapseView(topLeftView)) {
590
679
  // want to collapse top/left, check if this doesn't violate the max thickness of bottom/right
591
680
  max = bottomRightView.get('maxThickness');
592
681
  if (!max || (minAvailable + maxAvailable) <= max) {
593
682
  // collapse top/left view, even if it has a minThickness
594
- thickness = 0 ;
683
+ thickness = 0;
595
684
  }
596
- } else if (proposedThickness >= brCollapseAtThickness &&
597
- this.canCollapseView(bottomRightView)) {
685
+ } else if (proposedThickness >= brCollapseAtThickness && this.canCollapseView(bottomRightView)) {
598
686
  // want to collapse bottom/right, check if this doesn't violate the max thickness of top/left
599
687
  max = topLeftView.get('maxThickness');
600
688
  if (!max || (minAvailable + maxAvailable) <= max) {
@@ -605,11 +693,11 @@ SC.SplitView = SC.View.extend(
605
693
 
606
694
  // now apply constrained value
607
695
  if (thickness != this.thicknessForView(topLeftView)) {
608
- this._desiredTopLeftThickness = thickness ;
696
+ this._desiredTopLeftThickness = thickness;
609
697
 
610
698
  // un-collapse if needed.
611
- topLeftView.set('isCollapsed', thickness === 0) ;
612
- bottomRightView.set('isCollapsed', thickness >= maxAvailable) ;
699
+ topLeftView.set('isCollapsed', thickness === 0);
700
+ bottomRightView.set('isCollapsed', thickness >= maxAvailable);
613
701
 
614
702
  this.updateChildLayout(); // updates child layouts
615
703
  this.displayDidChange(); // updates cursor
@@ -622,7 +710,7 @@ SC.SplitView = SC.View.extend(
622
710
  bottomRightView = this._bottomRightView,
623
711
  topLeftViewThickness = this.thicknessForView(topLeftView), // the current thickness, not the original thickness
624
712
  bottomRightViewThickness = this.thicknessForView(bottomRightView),
625
- minAvailable = this._dividerThickness ,
713
+ minAvailable = this._dividerThickness,
626
714
  maxAvailable = 0,
627
715
  proposedThickness = this._topLeftViewThickness + offset,
628
716
  direction = this._layoutDirection,
@@ -633,32 +721,32 @@ SC.SplitView = SC.View.extend(
633
721
  min = this.get('topLeftMinThickness'),
634
722
  bottomRightThickness, tlCollapseAtThickness, brCollapseAtThickness;
635
723
 
636
- if (!topLeftView.get("isCollapsed")) maxAvailable += topLeftViewThickness ;
637
- if (!bottomRightView.get("isCollapsed")) maxAvailable += bottomRightViewThickness ;
724
+ if (!topLeftView.get("isCollapsed")) maxAvailable += topLeftViewThickness;
725
+ if (!bottomRightView.get("isCollapsed")) maxAvailable += bottomRightViewThickness;
638
726
 
639
- if (!SC.none(max)) thickness = Math.min(max, thickness) ;
640
- if (!SC.none(min)) thickness = Math.max(min, thickness) ;
727
+ if (!SC.none(max)) thickness = Math.min(max, thickness);
728
+ if (!SC.none(min)) thickness = Math.max(min, thickness);
641
729
 
642
730
  // constrain to thickness set on bottom/right
643
- max = this.get('bottomRightMaxThickness') ;
644
- min = this.get('bottomRightMinThickness') ;
731
+ max = this.get('bottomRightMaxThickness');
732
+ min = this.get('bottomRightMinThickness');
645
733
  bottomRightThickness = maxAvailable - thickness ;
646
- if (!SC.none(max)) bottomRightThickness = Math.min(max, bottomRightThickness) ;
647
- if (!SC.none(min)) bottomRightThickness = Math.max(min, bottomRightThickness) ;
648
- thickness = maxAvailable - bottomRightThickness ;
734
+ if (!SC.none(max)) bottomRightThickness = Math.min(max, bottomRightThickness);
735
+ if (!SC.none(min)) bottomRightThickness = Math.max(min, bottomRightThickness);
736
+ thickness = maxAvailable - bottomRightThickness;
649
737
 
650
738
  // constrain to thickness determined by delegate.
651
- thickness = this.invokeDelegateMethod(this.delegate, 'splitViewConstrainThickness', this, topLeftView, thickness) ;
739
+ thickness = this.invokeDelegateMethod(this.delegate, 'splitViewConstrainThickness', this, topLeftView, thickness);
652
740
 
653
741
  // cannot be more than what's available
654
- thickness = Math.min(thickness, maxAvailable) ;
742
+ thickness = Math.min(thickness, maxAvailable);
655
743
 
656
744
  // cannot be less than zero
657
- thickness = Math.max(0, thickness) ;
745
+ thickness = Math.max(0, thickness);
658
746
 
659
- tlCollapseAtThickness = topLeftView.get('collapseAtThickness') ;
660
- if (!tlCollapseAtThickness) tlCollapseAtThickness = 0 ;
661
- brCollapseAtThickness = bottomRightView.get('collapseAtThickness') ;
747
+ tlCollapseAtThickness = topLeftView.get('collapseAtThickness');
748
+ if (!tlCollapseAtThickness) tlCollapseAtThickness = 0;
749
+ brCollapseAtThickness = bottomRightView.get('collapseAtThickness');
662
750
  brCollapseAtThickness = SC.none(brCollapseAtThickness) ? maxAvailable : (maxAvailable - brCollapseAtThickness);
663
751
 
664
752
  if ((proposedThickness <= tlCollapseAtThickness) && this.canCollapseView(topLeftView)) {
@@ -666,7 +754,7 @@ SC.SplitView = SC.View.extend(
666
754
  max = bottomRightView.get('maxThickness');
667
755
  if (!max || (minAvailable + maxAvailable) <= max) {
668
756
  // collapse top/left view, even if it has a minThickness
669
- thickness = 0 ;
757
+ thickness = 0;
670
758
  }
671
759
  } else if (proposedThickness >= brCollapseAtThickness && this.canCollapseView(bottomRightView)) {
672
760
  // want to collapse bottom/right, check if this doesn't violate the max thickness of top/left
@@ -679,11 +767,11 @@ SC.SplitView = SC.View.extend(
679
767
 
680
768
  // now apply constrained value
681
769
  if (thickness != this.thicknessForView(topLeftView)) {
682
- this._desiredTopLeftThickness = thickness ;
770
+ this._desiredTopLeftThickness = thickness;
683
771
 
684
772
  // un-collapse if needed.
685
- topLeftView.set('isCollapsed', thickness === 0) ;
686
- bottomRightView.set('isCollapsed', thickness >= maxAvailable) ;
773
+ topLeftView.set('isCollapsed', thickness === 0);
774
+ bottomRightView.set('isCollapsed', thickness >= maxAvailable);
687
775
 
688
776
  this.updateChildLayout(); // updates child layouts
689
777
  this.displayDidChange(); // updates cursor
@@ -704,25 +792,21 @@ SC.SplitView = SC.View.extend(
704
792
  // mouseDownInThumbView() to reflect the status of the drag
705
793
  tlThickness = this.thicknessForView(topLeftView),
706
794
  brThickness = this.thicknessForView(bottomRightView);
707
- this._layoutDirection = this.get('layoutDirection') ;
795
+ this._layoutDirection = this.get('layoutDirection');
708
796
  if (topLeftView.get('isCollapsed') ||
709
- tlThickness === this.get("topLeftMinThickness") ||
710
- brThickness == this.get("bottomRightMaxThickness")) {
711
- thumbViewCursor.set('cursorStyle',
712
- this._layoutDirection === SC.LAYOUT_HORIZONTAL ? "e-resize" : "s-resize") ;
797
+ tlThickness === this.get("topLeftMinThickness") ||
798
+ brThickness == this.get("bottomRightMaxThickness")) {
799
+ thumbViewCursor.set('cursorStyle', this._layoutDirection === SC.LAYOUT_HORIZONTAL ? "e-resize" : "s-resize");
713
800
  } else if (bottomRightView.get('isCollapsed') ||
714
- tlThickness === this.get("topLeftMaxThickness") ||
715
- brThickness == this.get("bottomRightMinThickness")) {
716
- thumbViewCursor.set('cursorStyle',
717
- this._layoutDirection === SC.LAYOUT_HORIZONTAL ? "w-resize" : "n-resize") ;
801
+ tlThickness === this.get("topLeftMaxThickness") ||
802
+ brThickness == this.get("bottomRightMinThickness")) {
803
+ thumbViewCursor.set('cursorStyle', this._layoutDirection === SC.LAYOUT_HORIZONTAL ? "w-resize" : "n-resize");
718
804
  } else {
719
805
  if(SC.browser.msie) {
720
- thumbViewCursor.set('cursorStyle',
721
- this._layoutDirection === SC.LAYOUT_HORIZONTAL ? "e-resize" : "n-resize") ;
806
+ thumbViewCursor.set('cursorStyle', this._layoutDirection === SC.LAYOUT_HORIZONTAL ? "e-resize" : "n-resize");
722
807
  }
723
808
  else {
724
- thumbViewCursor.set('cursorStyle',
725
- this._layoutDirection === SC.LAYOUT_HORIZONTAL ? "ew-resize" : "ns-resize") ;
809
+ thumbViewCursor.set('cursorStyle', this._layoutDirection === SC.LAYOUT_HORIZONTAL ? "ew-resize" : "ns-resize");
726
810
  }
727
811
  }
728
812
  }.observes('layoutDirection'),
@@ -739,9 +823,9 @@ SC.SplitView = SC.View.extend(
739
823
  @returns {Boolean} YES to allow collapse.
740
824
  */
741
825
  splitViewCanCollapse: function(splitView, view) {
742
- if (splitView.get('canCollapseViews') === NO) return NO ;
743
- if (view.get('canCollapse') === NO) return NO ;
744
- return YES ;
826
+ if (splitView.get('canCollapseViews') === NO) return NO;
827
+ if (view.get('canCollapse') === NO) return NO;
828
+ return YES;
745
829
  },
746
830
 
747
831
  /**
@@ -773,9 +857,24 @@ SC.SplitView = SC.View.extend(
773
857
  @returns {void}
774
858
  */
775
859
  viewDidResize: function() {
776
- sc_super();
777
- this.notifyPropertyChange('topLeftThickness')
778
- .notifyPropertyChange('bottomRightThickness');
860
+ sc_super();
861
+ this
862
+ .notifyPropertyChange('topLeftThickness')
863
+ .notifyPropertyChange('bottomRightThickness');
779
864
  }.observes('layout')
780
865
 
781
866
  });
867
+
868
+ // TODO: This should be a mixin to the few classes that need it
869
+ SC.mixin(SC.View.prototype, {
870
+ /**
871
+ The current split view this view is embedded in (may be null).
872
+ @property {SC.SplitView}
873
+ */
874
+ splitView: function() {
875
+ var view = this ;
876
+ while (view && !view.isSplitView) view = view.get('parentView') ;
877
+ return view ;
878
+ }.property('parentView').cacheable()
879
+ });
880
+