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.
- data/CHANGELOG +35 -0
- data/VERSION.yml +2 -2
- data/lib/Buildfile +13 -4
- data/lib/buildtasks/build.rake +20 -17
- data/lib/buildtasks/manifest.rake +143 -78
- data/lib/buildtasks/target.rake +1 -0
- data/lib/doc_templates/sproutcore/index.tmpl +18 -4
- data/lib/doc_templates/sproutcore/publish.js +1 -1
- data/lib/frameworks/sproutcore/Buildfile +24 -13
- data/lib/frameworks/sproutcore/{CHANGELOG-1.4.md → CHANGELOG.md} +0 -0
- data/lib/frameworks/sproutcore/apps/greenhouse/controllers/file.js +8 -48
- data/lib/frameworks/sproutcore/apps/greenhouse/core.js +3 -5
- data/lib/frameworks/sproutcore/apps/greenhouse/data_source.js +1 -1
- data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/app_page.js +26 -4
- data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/strings.js +7 -1
- data/lib/frameworks/sproutcore/apps/greenhouse/main.js +1 -1
- data/lib/frameworks/sproutcore/apps/greenhouse/models/design.js +6 -2
- data/lib/frameworks/sproutcore/apps/greenhouse/models/dir.js +8 -7
- data/lib/frameworks/sproutcore/apps/greenhouse/models/file.js +2 -2
- data/lib/frameworks/sproutcore/apps/greenhouse/states/inspector.js +133 -125
- data/lib/frameworks/sproutcore/apps/greenhouse/states/library.js +121 -112
- data/lib/frameworks/sproutcore/apps/greenhouse/states/main.js +233 -191
- data/lib/frameworks/sproutcore/apps/greenhouse/states/modals.js +265 -258
- data/lib/frameworks/sproutcore/apps/greenhouse/states/ready.js +153 -141
- data/lib/frameworks/sproutcore/apps/test_controls/Buildfile +0 -0
- data/lib/frameworks/sproutcore/apps/test_controls/controllers/buttons.js +21 -0
- data/lib/frameworks/sproutcore/apps/test_controls/controllers/categories.js +108 -0
- data/lib/frameworks/sproutcore/apps/test_controls/controllers/category.js +36 -0
- data/lib/frameworks/sproutcore/apps/test_controls/core.js +29 -0
- data/lib/frameworks/sproutcore/apps/test_controls/main.js +14 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/buttons_page.js +142 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/checkboxes_page.js +45 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/flow_layout_page.js +84 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/list_page.js +40 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/loading.rhtml +9 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/main_page.css +60 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/main_page.js +144 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/progress_page.js +42 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/radio_page.js +48 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/scroll_page.js +76 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/segmented_page.js +98 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/select_page.js +60 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/sliders_page.js +53 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/strings.js +50 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/tab_page.js +44 -0
- data/lib/frameworks/sproutcore/apps/test_controls/resources/text_field_page.js +41 -0
- data/lib/frameworks/sproutcore/apps/test_controls/theme.js +34 -0
- data/lib/frameworks/sproutcore/apps/welcome/controllers/targets.js +7 -0
- data/lib/frameworks/sproutcore/apps/welcome/english.lproj/images/main-bg.png +0 -0
- data/lib/frameworks/sproutcore/apps/welcome/english.lproj/main_page.css +24 -6
- data/lib/frameworks/sproutcore/apps/welcome/english.lproj/main_page.js +36 -46
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/controllers/array.js +175 -195
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/controllers/controller.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/controllers/object.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/amber/core.js +201 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/ext/object.js +23 -23
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/ext/run_loop.js +47 -47
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/mixins/delegate_support.js +36 -36
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/mixins/responder_context.js +55 -55
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/mixins/selection_support.js +45 -45
- data/lib/frameworks/sproutcore/frameworks/amber/mixins/string.js +163 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/panes/main.js +4 -3
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/panes/pane.js +123 -9
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/protocols/observable_protocol.js +11 -11
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/protocols/sparse_array_delegate.js +40 -40
- data/lib/frameworks/sproutcore/frameworks/{foundation/english.lproj → amber/resources}/core.css +0 -103
- data/lib/frameworks/sproutcore/frameworks/{foundation/english.lproj → amber/resources}/view.css +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/application.js +0 -2
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/browser.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/builder.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/amber/system/core_query.js +141 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/cursor.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/device.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/event.js +34 -14
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/json.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/locale.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/page.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/platform.js +30 -10
- data/lib/frameworks/sproutcore/frameworks/amber/system/ready.js +77 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/render_context.js +330 -255
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/responder.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/root_responder.js +152 -60
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/system/selection_set.js +140 -145
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/system/sparse_array.js +101 -87
- data/lib/frameworks/sproutcore/frameworks/amber/system/theme.js +316 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/system/timer.js +149 -147
- data/lib/frameworks/sproutcore/frameworks/amber/system/utils.js +174 -0
- data/lib/frameworks/sproutcore/frameworks/amber/system/utils/rect.js +98 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/array_case.js +41 -41
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/enum_case.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/null_case.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/selection_support.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/array/single_case.js +9 -9
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/object/empty_case.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/object/multiple_case.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/object/single_case.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/controllers/object/single_enumerable_case.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/mixins/responder_context.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/amber/tests/mixins/string.js +55 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/builder.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/core_query/within.js +7 -8
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/json.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/locale.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/begin.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/element.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/end.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/get.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/helpers_attr.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/helpers_basic.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/helpers_className.js +0 -2
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/helpers_style.js +11 -3
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/init.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/join.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/push_text.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/tag.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/render_context/update.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/makeKeyPane.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/makeMainPane.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/makeMenuPane.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/root_responder.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/root_responder/targetForAction.js +46 -9
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/add.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/copy.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/indexSetForSource.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/isEqual.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/selection_set/remove.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{runtime → amber}/tests/system/sparse_array.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/amber/tests/system/theme.js +77 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/invalidate.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/invokeLater.js +7 -5
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/isPaused.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/performAction.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/timer/schedule.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/utils/normalizeURL.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/system/utils/rect.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/main_pane.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/append_remove.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/firstResponder.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/keyPane.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/layout.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/pane/sendEvent.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/amber/tests/views/pane/sendTouchEvent.js +267 -0
- data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/animation.js +320 -0
- data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/build.js +85 -0
- data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/build_children.js +89 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/clippingFrame.js +3 -2
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/convertFrames.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/convertLayouts.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/createChildViews.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/createLayer.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/destroyLayer.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/didAppendToDocument.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/findLayerInParentLayer.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/init.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/insertBefore.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/isVisible.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/isVisibleInWindow.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/layer.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/layoutChildViews.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/layoutDidChange.js +22 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/layoutStyle.js +135 -64
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/parentViewDidChange.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/prepareContext.js +16 -8
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/removeChild.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/render.js +37 -5
- data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/render_delegate_support.js +163 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/replaceChild.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/theme.js +43 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/updateLayer.js +12 -10
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/updateLayerLocation.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/amber/tests/views/view/view.js +64 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/tests/views/view/viewDidResize.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/amber/views/base.js +1 -0
- data/lib/frameworks/sproutcore/frameworks/amber/views/layout_style.js +478 -0
- data/lib/frameworks/sproutcore/frameworks/{foundation → amber}/views/view.js +1719 -1029
- data/lib/frameworks/sproutcore/frameworks/animation/core.js +32 -18
- data/lib/frameworks/sproutcore/frameworks/animation/tests/core.js +10 -5
- data/lib/frameworks/sproutcore/frameworks/bootstrap/system/bench.js +14 -0
- data/lib/frameworks/sproutcore/frameworks/bootstrap/system/browser.js +24 -17
- data/lib/frameworks/sproutcore/frameworks/bootstrap/system/loader.js +1 -13
- data/lib/frameworks/sproutcore/frameworks/bootstrap/tests/system/browser.js +72 -0
- data/lib/frameworks/sproutcore/frameworks/datastore/models/child_record.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/datastore/models/record.js +7 -3
- data/lib/frameworks/sproutcore/frameworks/datastore/models/record_attribute.js +66 -4
- data/lib/frameworks/sproutcore/frameworks/datastore/system/many_array.js +4 -1
- data/lib/frameworks/sproutcore/frameworks/datastore/system/record_array.js +58 -10
- data/lib/frameworks/sproutcore/frameworks/datastore/system/store.js +5 -14
- data/lib/frameworks/sproutcore/frameworks/debug/invoke_once_last_debugging.js +4 -5
- data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/list_item.css +27 -3
- data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/segmented.css +5 -8
- data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_fast_path.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_row_delegate.js +30 -4
- data/lib/frameworks/sproutcore/frameworks/desktop/mixins/navigation_builder.js +130 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/alert.js +2 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/menu.js +20 -2
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/panel.js +9 -27
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/picker.js +32 -26
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/select_button.js +57 -11
- data/lib/frameworks/sproutcore/frameworks/desktop/protocols/drop_target.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/button.js +78 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/checkbox.js +74 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/collection.js +24 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/disclosure.js +41 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/helpers/slicing.js +34 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/image_button.js +30 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/master_detail.js +28 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/menu.js +47 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/panel.js +28 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/picker.js +43 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/progress.js +175 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/radio.js +74 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/radio_group.js +109 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/segment.js +70 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/segmented.js +58 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/slider.js +39 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/source_list.js +8 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/toolbar.js +18 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/well.js +29 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/render_delegates/workspace.js +18 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/system/drag.js +79 -53
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/integration/dialog.js +7 -2
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/panes/menu/ui.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/button/methods.js +45 -3
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/button/ui.js +33 -13
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/checkbox/methods.js +11 -17
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/image_button/ui.js +25 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list_item.js +128 -20
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/progress/ui.js +10 -10
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/segmented/methods.js +35 -15
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/segmented/ui.js +162 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/views/button.js +153 -208
- data/lib/frameworks/sproutcore/frameworks/desktop/views/checkbox.js +18 -48
- data/lib/frameworks/sproutcore/frameworks/desktop/views/collection.js +26 -25
- data/lib/frameworks/sproutcore/frameworks/desktop/views/disclosure.js +3 -20
- data/lib/frameworks/sproutcore/frameworks/desktop/views/file.js +112 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/views/image_button.js +74 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/views/list.js +3 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/views/list_item.js +388 -309
- data/lib/frameworks/sproutcore/frameworks/desktop/views/master_detail.js +257 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/views/menu_item.js +8 -3
- data/lib/frameworks/sproutcore/frameworks/desktop/views/navigation.js +237 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/views/navigation_bar.js +181 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/views/popup_button.js +3 -2
- data/lib/frameworks/sproutcore/frameworks/desktop/views/progress.js +14 -76
- data/lib/frameworks/sproutcore/frameworks/desktop/views/radio.js +59 -164
- data/lib/frameworks/sproutcore/frameworks/desktop/views/scroll.js +80 -47
- data/lib/frameworks/sproutcore/frameworks/desktop/views/segment.js +84 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/views/segmented.js +320 -289
- data/lib/frameworks/sproutcore/frameworks/desktop/views/select.js +212 -76
- data/lib/frameworks/sproutcore/frameworks/desktop/views/slider.js +33 -36
- data/lib/frameworks/sproutcore/frameworks/desktop/views/source_list.js +2 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/views/split.js +347 -248
- data/lib/frameworks/sproutcore/frameworks/desktop/views/static_content.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/views/tab.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/views/toolbar.js +41 -9
- data/lib/frameworks/sproutcore/frameworks/desktop/views/web.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/views/well.js +2 -21
- data/lib/frameworks/sproutcore/frameworks/desktop/views/workspace.js +251 -0
- data/lib/frameworks/sproutcore/frameworks/documentation/core.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/forms/english.lproj/default_styles.css +5 -0
- data/lib/frameworks/sproutcore/frameworks/forms/english.lproj/strings.js +15 -0
- data/lib/frameworks/sproutcore/frameworks/forms/mixins/edit_mode.js +43 -0
- data/lib/frameworks/sproutcore/frameworks/forms/mixins/emptiness.js +95 -0
- data/lib/frameworks/sproutcore/frameworks/forms/renderer_delegates/form.js +22 -0
- data/lib/frameworks/sproutcore/frameworks/forms/renderer_delegates/form_row.js +21 -0
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form.js +15 -0
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_checkbox_field.js +15 -0
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_field.js +15 -0
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_label.js +15 -0
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_radio_field.js +15 -0
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_row.js +15 -0
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_text_field.js +15 -0
- data/lib/frameworks/sproutcore/frameworks/forms/views/form.js +280 -0
- data/lib/frameworks/sproutcore/frameworks/forms/views/form_row.js +183 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/controllers/tree.js +5 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/core.js +0 -150
- data/lib/frameworks/sproutcore/frameworks/foundation/debug/control_test_pane.js +0 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/benchmark.css +146 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/bootstrap.rhtml +2 -14
- data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/favicon.ico +0 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore.png +0 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/strings.js +0 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/text_field.css +4 -6
- data/lib/frameworks/sproutcore/frameworks/foundation/gestures/pinch.js +81 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/gestures/swipe.js +144 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/gestures/tap.js +113 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/license.js +24 -26
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/auto_mixin.js +39 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/auto_resize.js +244 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/control.js +68 -23
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/editable.js +8 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/flowed_layout.js +626 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/gestureable.js +214 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/inline_editable.js +89 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/inline_editor_delegate.js +139 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/inline_text_field.js +25 -33
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/string.js +57 -209
- data/lib/frameworks/sproutcore/frameworks/foundation/private/tree_item_observer.js +7 -3
- data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/canvas_image.js +100 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/container.js +18 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/image.js +97 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/label.js +111 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/render_delegates/render_delegate.js +17 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/benchmark.js +360 -156
- data/lib/frameworks/sproutcore/frameworks/{runtime → foundation}/system/cookie.js +35 -35
- data/lib/frameworks/sproutcore/frameworks/foundation/system/core_query.js +19 -2012
- data/lib/frameworks/sproutcore/frameworks/foundation/system/exception_handler.js +3 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/gesture.js +363 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/{image_cache.js → image_queue.js} +19 -22
- data/lib/frameworks/sproutcore/frameworks/foundation/system/module.js +576 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/request.js +19 -22
- data/lib/frameworks/sproutcore/frameworks/foundation/system/response.js +73 -61
- data/lib/frameworks/sproutcore/frameworks/foundation/system/routes.js +122 -23
- data/lib/frameworks/sproutcore/frameworks/foundation/system/staticqueue.js +53 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/task_queue.js +18 -15
- data/lib/frameworks/sproutcore/frameworks/foundation/system/user_defaults.js +82 -90
- data/lib/frameworks/sproutcore/frameworks/foundation/system/utils/colors.js +80 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/utils/misc.js +76 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/utils/range.js +64 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/utils/string_measurement.js +247 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/tasks/preload_bundle.js +3 -3
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/inline_text_field/beginEditing.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/staticLayout.js +2 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/string.js +2 -57
- data/lib/frameworks/sproutcore/frameworks/{runtime → foundation}/tests/system/cookie.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/setClass.js +13 -3
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/request.js +99 -49
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/routes.js +24 -20
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/container/methods.js +9 -1
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/container/ui.js +31 -6
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/image/ui.js +454 -44
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/label/ui.js +10 -1
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/{view → text_field}/nextValidKeyView.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/validators/number.js +1 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/views/container.js +9 -8
- data/lib/frameworks/sproutcore/frameworks/foundation/views/field.js +1 -3
- data/lib/frameworks/sproutcore/frameworks/foundation/views/image.js +381 -105
- data/lib/frameworks/sproutcore/frameworks/foundation/views/label.js +44 -171
- data/lib/frameworks/sproutcore/frameworks/foundation/views/text_field.js +69 -16
- data/lib/frameworks/sproutcore/frameworks/jquery/jquery-buffer.js +376 -0
- data/lib/frameworks/sproutcore/frameworks/jquery/jquery-buffered.js +205 -0
- data/lib/frameworks/sproutcore/frameworks/jquery/jquery-sc.js +7 -0
- data/lib/frameworks/sproutcore/frameworks/jquery/jquery.js +7179 -0
- data/lib/frameworks/sproutcore/frameworks/media/views/audio.js +4 -2
- data/lib/frameworks/sproutcore/frameworks/media/views/controls.js +1 -3
- data/lib/frameworks/sproutcore/frameworks/media/views/simple_controls.js +1 -2
- data/lib/frameworks/sproutcore/frameworks/mini/license.js +29 -28
- data/lib/frameworks/sproutcore/frameworks/runtime/core.js +366 -333
- data/lib/frameworks/sproutcore/frameworks/runtime/debug/test_suites/array/rangeObserver.js +73 -73
- data/lib/frameworks/sproutcore/frameworks/runtime/license.js +29 -28
- data/lib/frameworks/sproutcore/frameworks/runtime/mixins/array.js +160 -150
- data/lib/frameworks/sproutcore/frameworks/runtime/mixins/comparable.js +9 -9
- data/lib/frameworks/sproutcore/frameworks/runtime/mixins/copyable.js +15 -15
- data/lib/frameworks/sproutcore/frameworks/runtime/mixins/enumerable.js +228 -220
- data/lib/frameworks/sproutcore/frameworks/runtime/mixins/freezable.js +27 -27
- data/lib/frameworks/sproutcore/frameworks/runtime/mixins/observable.js +355 -305
- data/lib/frameworks/sproutcore/frameworks/runtime/private/chain_observer.js +32 -32
- data/lib/frameworks/sproutcore/frameworks/runtime/private/observer_queue.js +53 -51
- data/lib/frameworks/sproutcore/frameworks/runtime/private/observer_set.js +49 -106
- data/lib/frameworks/sproutcore/frameworks/runtime/system/binding.js +252 -252
- data/lib/frameworks/sproutcore/frameworks/runtime/system/enumerator.js +22 -22
- data/lib/frameworks/sproutcore/frameworks/runtime/system/error.js +31 -31
- data/lib/frameworks/sproutcore/frameworks/runtime/system/index_set.js +234 -234
- data/lib/frameworks/sproutcore/frameworks/runtime/system/logger.js +4 -4
- data/lib/frameworks/sproutcore/frameworks/runtime/system/object.js +167 -157
- data/lib/frameworks/sproutcore/frameworks/runtime/system/range_observer.js +84 -85
- data/lib/frameworks/sproutcore/frameworks/runtime/system/run_loop.js +104 -91
- data/lib/frameworks/sproutcore/frameworks/runtime/system/set.js +102 -98
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/IsEqual.js +19 -49
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/guidFor.js +53 -126
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/itemType.js +62 -33
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/enumerable.js +41 -5
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/mixins/observable/observable.js +133 -98
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/observer_set.js +50 -0
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/range_observer/create.js +11 -11
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/set.js +71 -45
- data/lib/frameworks/sproutcore/frameworks/statechart/core.js +3 -9
- data/lib/frameworks/sproutcore/frameworks/statechart/debug/monitor.js +136 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/system/state.js +636 -99
- data/lib/frameworks/sproutcore/frameworks/statechart/system/statechart.js +951 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/async.js +94 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/event_handling/advanced_event_handling.js +310 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/namespace/access_substates.js +252 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/state/is_current_state.js +64 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_history_state.js +88 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_state_advanced.js +234 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_state_async.js +123 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_state_basic.js +139 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/goto_state_intermediate.js +119 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/with_concurrent_states/send_event.js +183 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/default_responder.js +90 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/goto_history_state.js +200 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/goto_state.js +256 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/goto_state_async.js +187 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/send_event.js +122 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/state_plugin.js +99 -0
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/without_concurrent_states/transient.js +162 -0
- data/lib/frameworks/sproutcore/frameworks/table/views/table_cell.js +2 -1
- data/lib/frameworks/sproutcore/frameworks/table/views/table_head.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/table/views/table_row.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/testing/system/runner.js +2 -1
- data/lib/frameworks/sproutcore/lib/index.rhtml +24 -1
- data/lib/frameworks/sproutcore/license.js +31 -30
- data/lib/frameworks/sproutcore/themes/ace/designs/dark.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/dark.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/light.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/light.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/18px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/18px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/18px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/18px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/active_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/normal_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/normal_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_active_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/24px/selected_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/normal_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/selected_active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/30px/selected_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/44px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/44px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/44px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/ace/44px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/active_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/normal_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/normal_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_active_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/24px/selected_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/normal_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/selected_active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/dark/30px/selected_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/popup/active_select.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/button/popup/normal_select.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_checked.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_checked_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_mixed.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_mixed_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_unchecked.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/14px/checkbox_unchecked_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_checked.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_checked_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_mixed.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_mixed_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_unchecked.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/checkbox/ace/16px/checkbox_unchecked_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/collection/source-list/selection.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/disclosure/ace/disclosure_closed.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/disclosure/ace/disclosure_closed_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/disclosure/ace/disclosure_open.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/disclosure/ace/disclosure_open_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/checkmark.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/checkmark_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/down.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/menu.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/menu_item.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/menu/up.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/panel/panel.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover_empty.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover_notoolbar.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover_pointers.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/picker/popover/popover_pointers_notoolbar.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/progress/ace/progress_view_content.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/progress/ace/progress_view_indeterminate_content.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/progress/ace/progress_view_track.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_mixed.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_mixed_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/radio/radio_unselected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/horizontal/thumb.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/horizontal/track_and_arrows.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/horizontal/track_and_arrows_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/vertical/thumb.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/vertical/track_and_arrows.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/scroller/vertical/track_and_arrows_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/18px/segmented_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/18px/segmented_normal.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/18px/segmented_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/18px/segmented_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/24px/segmented_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/24px/segmented_normal.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/24px/segmented_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/24px/segmented_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/30px/segmented_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/30px/segmented_normal.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/30px/segmented_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/30px/segmented_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/44px/segmented_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/44px/segmented_normal.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/44px/segmented_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/segmented/44px/segmented_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/14px/knob.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/14px/knob_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/16px/knob.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/16px/knob_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/22px/knob.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/22px/knob_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/22px/track.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/slider/ace/track.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/psds/toolbar/toolbar.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_handle.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_handle.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_off.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_off.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_on.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/designs/switch/switch_on.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/body.css +13 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/button.css +27 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/18px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/active_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/button.css +84 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/normal_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/normal_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_active_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/24px/selected_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/button.css +66 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/normal_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/selected_active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/30px/selected_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/button.css +34 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/44px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/ace/button.css +28 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/button.js +69 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/active_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/button.css +84 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/normal_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/normal_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_active_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/24px/selected_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/button.css +66 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/normal_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/selected_active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/30px/selected_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/button.css +17 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/dark/button.js +3 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/popup/active_select.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/popup/normal_select.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/button/popup/select.css +20 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox.css +40 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_checked.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_checked_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_mixed.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_mixed_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_unchecked.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/14px/checkbox_unchecked_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox.css +40 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_checked.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_checked_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_mixed.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_mixed_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_unchecked.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/16px/checkbox_unchecked_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/checkbox/ace/checkbox.css +7 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/collection/normal/list.css +4 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/collection/normal/list_item.css +17 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/collection/source-list/selection.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/collection/source-list/source-list.js +3 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/collection/source-list/source_list_view.css +36 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure.css +24 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure_closed.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure_closed_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure_open.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/disclosure/ace/disclosure_open_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/loading.css +50 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/master-detail/master-detail.css +27 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/menu/checkmark.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/menu/checkmark_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/menu/down.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/menu/menu.css +76 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/menu/menu.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/menu/menu_item.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/menu/up.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/pane/pane.css +3 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/panel/panel.css +13 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/panel/panel.js +20 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/panel/panel.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/ace/picker.js +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/picker.js +32 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover.css +111 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover.js +12 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover_empty.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover_notoolbar.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover_pointers.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/popover_pointers_notoolbar.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/picker/popover/workspace.js +28 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/progress/ace/progress.css +27 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/progress/ace/progress_view_content.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/progress/ace/progress_view_track.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/progress/progress.js +78 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio.css +63 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_mixed.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_mixed_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/radio/radio_unselected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/horizontal.css +78 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/horizontal_touch.css +91 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/thumb.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/track_and_arrows.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/horizontal/track_and_arrows_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/thumb.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/track_and_arrows.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/track_and_arrows_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/vertical.css +80 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/scroller/vertical/vertical_touch.css +92 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented.css +91 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented_normal.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/18px/segmented_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented.css +91 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented_normal.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/24px/segmented_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented.css +91 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented_normal.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/30px/segmented_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented.css +95 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented_normal.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/44px/segmented_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/segmented/segmented.css +79 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/14px/knob.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/14px/knob_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/14px/slider.css +27 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/16px/knob.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/16px/knob_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/16px/slider.css +27 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/22px/knob.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/22px/knob_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/22px/slider.css +27 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/22px/track.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/slider.css +3 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/slider.js +48 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/slider/ace/track.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/split/split.css +5 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/tab/tab.css +3 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/toolbar/toolbar.css +8 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/toolbar/toolbar.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/well/well.css +8 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/well/well.js +19 -0
- data/lib/frameworks/sproutcore/themes/ace/theme.js +14 -0
- data/lib/frameworks/sproutcore/themes/empty_theme/theme.js +16 -0
- data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/segmented.css +16 -21
- data/lib/sproutcore.rb +9 -2
- data/lib/sproutcore/builders.rb +2 -1
- data/lib/sproutcore/builders/base.rb +7 -2
- data/lib/sproutcore/builders/combine.rb +49 -1
- data/lib/sproutcore/builders/html.rb +2 -0
- data/lib/sproutcore/builders/javascript.rb +1 -1
- data/lib/sproutcore/builders/minify.rb +12 -12
- data/lib/sproutcore/builders/module.rb +72 -0
- data/lib/sproutcore/builders/string_wrapper.rb +43 -0
- data/lib/sproutcore/helpers/entry_sorter.rb +5 -9
- data/lib/sproutcore/helpers/static_helper.rb +13 -9
- data/lib/sproutcore/models/manifest_entry.rb +2 -2
- data/lib/sproutcore/models/target.rb +25 -11
- data/lib/sproutcore/rack/dev.rb +3 -3
- data/lib/sproutcore/tools.rb +51 -2
- data/lib/sproutcore/tools/build.rb +35 -7
- data/lib/sproutcore/version.rb +1 -0
- data/spec/buildtasks/manifest/prepare_build_tasks/bundle_spec.rb +5 -5
- data/spec/fixtures/builder_tests/Buildfile +2 -2
- data/spec/lib/builders/bundle_spec.rb +8 -8
- data/spec/lib/builders/strings_spec.rb +1 -0
- data/sproutcore.gemspec +9 -2
- data/vendor/chance/.gitignore +5 -0
- data/vendor/chance/Gemfile +4 -0
- data/vendor/chance/Rakefile +2 -0
- data/vendor/chance/bin/chance +72 -0
- data/vendor/chance/chance.gemspec +28 -0
- data/vendor/chance/lib/chance.rb +139 -0
- data/vendor/chance/lib/chance/imager.rb +13 -0
- data/vendor/chance/lib/chance/imagers/data_url.rb +34 -0
- data/vendor/chance/lib/chance/importer.rb +64 -0
- data/vendor/chance/lib/chance/instance.rb +225 -0
- data/vendor/chance/lib/chance/parser.rb +831 -0
- data/vendor/chance/lib/chance/perf.rb +17 -0
- data/vendor/chance/lib/chance/sass_extensions.rb +24 -0
- data/vendor/chance/lib/chance/slicing.rb +104 -0
- data/vendor/chance/lib/chance/version.rb +3 -0
- data/vendor/chance/test/case/abc.png +0 -0
- data/vendor/chance/test/case/more/abc.png +0 -0
- data/vendor/chance/test/case/more/another.css +4 -0
- data/vendor/chance/test/case/test1.css +22 -0
- data/vendor/chance/test/case/test2.css +6 -0
- data/vendor/sproutcore/SCCompiler.jar +0 -0
- data/vendor/sproutcore/lib/args4j-2.0.12.jar +0 -0
- data/vendor/sproutcore/lib/htmlcompressor-0.9.3.jar +0 -0
- data/{lib/sproutcore/vendor/yui-compressor → vendor/sproutcore/lib}/yuicompressor-2.4.2.jar +0 -0
- data/vendor/sproutcore/src/SCCompiler/build.xml +74 -0
- data/vendor/sproutcore/src/SCCompiler/lib/args4j-2.0.12.jar +0 -0
- data/vendor/sproutcore/src/SCCompiler/lib/htmlcompressor-0.9.3.jar +0 -0
- data/{lib/sproutcore/vendor/yui-compressor/SCyuicompressor-2.4.2.jar → vendor/sproutcore/src/SCCompiler/lib/yuicompressor-2.4.2.jar} +0 -0
- data/vendor/sproutcore/src/SCCompiler/lib/yuicompressor-2.4.4.jar +0 -0
- data/vendor/sproutcore/src/SCCompiler/manifest.mf +3 -0
- data/vendor/sproutcore/src/SCCompiler/nbproject/build-impl.xml +894 -0
- data/vendor/sproutcore/src/SCCompiler/nbproject/genfiles.properties +8 -0
- data/vendor/sproutcore/src/SCCompiler/nbproject/private/config.properties +0 -0
- data/vendor/sproutcore/src/SCCompiler/nbproject/private/private.properties +10 -0
- data/vendor/sproutcore/src/SCCompiler/nbproject/private/private.xml +4 -0
- data/vendor/sproutcore/src/SCCompiler/nbproject/project.properties +90 -0
- data/vendor/sproutcore/src/SCCompiler/nbproject/project.xml +15 -0
- data/vendor/sproutcore/src/SCCompiler/src/com/sproutcore/Main.java +348 -0
- metadata +686 -177
- data/lib/frameworks/sproutcore/CHANGELOG +0 -93
- data/lib/frameworks/sproutcore/frameworks/datejs/core.js +0 -865
- data/lib/frameworks/sproutcore/frameworks/datejs/english.lproj/en-US.js +0 -186
- data/lib/frameworks/sproutcore/frameworks/datejs/extras.js +0 -332
- data/lib/frameworks/sproutcore/frameworks/datejs/license.js +0 -25
- data/lib/frameworks/sproutcore/frameworks/datejs/parser.js +0 -1116
- data/lib/frameworks/sproutcore/frameworks/datejs/spanish.lproj/es-CO.js +0 -186
- data/lib/frameworks/sproutcore/frameworks/datejs/sugarpak.js +0 -475
- data/lib/frameworks/sproutcore/frameworks/datejs/time.js +0 -269
- data/lib/frameworks/sproutcore/frameworks/datejs/validators/datejs.js +0 -34
- data/lib/frameworks/sproutcore/frameworks/foundation/protocols/inline_editor_delegate.js +0 -84
- data/lib/frameworks/sproutcore/frameworks/foundation/system/bundle.js +0 -337
- data/lib/frameworks/sproutcore/frameworks/foundation/system/ready.js +0 -197
- data/lib/frameworks/sproutcore/frameworks/foundation/system/utils.js +0 -710
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_core.js +0 -1334
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_dimensions.js +0 -387
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/core_query/jquery_selector.js +0 -405
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/isArray.js +0 -25
- data/lib/frameworks/sproutcore/frameworks/statechart/mixins/statechart.js +0 -336
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/basic.js +0 -90
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/history.js +0 -71
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/nested.js +0 -59
- data/lib/frameworks/sproutcore/frameworks/statechart/tests/transient.js +0 -148
- data/lib/sproutcore/builders/bundle.rb +0 -63
@@ -10,28 +10,28 @@
|
|
10
10
|
sc_require('debug/test_suites/array/base');
|
11
11
|
|
12
12
|
SC.ArraySuite.define(function(T) {
|
13
|
-
|
13
|
+
|
14
14
|
var expected, array, observer, rangeObserver ;
|
15
15
|
|
16
16
|
// ..........................................................
|
17
|
-
// MODULE: isDeep = YES
|
18
|
-
//
|
17
|
+
// MODULE: isDeep = YES
|
18
|
+
//
|
19
19
|
module(T.desc("RangeObserver Methods"), {
|
20
20
|
setup: function() {
|
21
21
|
expected = T.objects(10);
|
22
22
|
array = T.newObject(expected);
|
23
23
|
|
24
24
|
observer = T.observer();
|
25
|
-
rangeObserver = array.addRangeObserver(SC.IndexSet.create(2,3),
|
25
|
+
rangeObserver = array.addRangeObserver(SC.IndexSet.create(2,3),
|
26
26
|
observer, observer.rangeDidChange, null, NO);
|
27
|
-
|
27
|
+
|
28
28
|
},
|
29
|
-
|
29
|
+
|
30
30
|
teardown: function() {
|
31
31
|
T.destroyObject(array);
|
32
32
|
}
|
33
33
|
});
|
34
|
-
|
34
|
+
|
35
35
|
test("returns RangeObserver object", function() {
|
36
36
|
ok(rangeObserver && rangeObserver.isRangeObserver, 'returns a range observer object');
|
37
37
|
});
|
@@ -40,49 +40,49 @@ SC.ArraySuite.define(function(T) {
|
|
40
40
|
//
|
41
41
|
// // ..........................................................
|
42
42
|
// // EDIT PROPERTIES
|
43
|
-
// //
|
43
|
+
// //
|
44
44
|
//
|
45
45
|
// test("editing property on object in range should fire observer", function() {
|
46
46
|
// var obj = array.objectAt(3);
|
47
47
|
// obj.set('foo', 'BAR');
|
48
48
|
// observer.expectRangeChange(array, obj, 'foo', SC.IndexSet.create(3));
|
49
49
|
// });
|
50
|
-
//
|
50
|
+
//
|
51
51
|
// test("editing property on object outside of range should NOT fire observer", function() {
|
52
52
|
// var obj = array.objectAt(0);
|
53
53
|
// obj.set('foo', 'BAR');
|
54
54
|
// equals(observer.callCount, 0, 'observer should not fire');
|
55
55
|
// });
|
56
|
-
//
|
57
|
-
//
|
56
|
+
//
|
57
|
+
//
|
58
58
|
// test("updating property after changing observer range", function() {
|
59
59
|
// array.updateRangeObserver(rangeObserver, SC.IndexSet.create(8,2));
|
60
60
|
// observer.callCount = 0 ;// reset b/c callback should happen here
|
61
|
-
//
|
61
|
+
//
|
62
62
|
// var obj = array.objectAt(3);
|
63
63
|
// obj.set('foo', 'BAR');
|
64
64
|
// equals(observer.callCount, 0, 'modifying object in old range should not fire observer');
|
65
|
-
//
|
65
|
+
//
|
66
66
|
// obj = array.objectAt(9);
|
67
67
|
// obj.set('foo', 'BAR');
|
68
68
|
// observer.expectRangeChange(array, obj, 'foo', SC.IndexSet.create(9));
|
69
|
-
//
|
69
|
+
//
|
70
70
|
// });
|
71
|
-
//
|
71
|
+
//
|
72
72
|
// test("updating a property after removing an range should not longer update", function() {
|
73
73
|
// array.removeRangeObserver(rangeObserver);
|
74
|
-
//
|
74
|
+
//
|
75
75
|
// observer.callCount = 0 ;// reset b/c callback should happen here
|
76
|
-
//
|
76
|
+
//
|
77
77
|
// var obj = array.objectAt(3);
|
78
78
|
// obj.set('foo', 'BAR');
|
79
79
|
// equals(observer.callCount, 0, 'modifying object in old range should not fire observer');
|
80
|
-
//
|
80
|
+
//
|
81
81
|
// });
|
82
82
|
|
83
83
|
// ..........................................................
|
84
84
|
// REPLACE
|
85
|
-
//
|
85
|
+
//
|
86
86
|
|
87
87
|
test("replacing object in range fires observer with index set covering only the effected item", function() {
|
88
88
|
array.replace(2, 1, T.objects(1));
|
@@ -101,7 +101,7 @@ SC.ArraySuite.define(function(T) {
|
|
101
101
|
|
102
102
|
test("updating range should be reflected by replace operations", function() {
|
103
103
|
array.updateRangeObserver(rangeObserver, SC.IndexSet.create(9,1));
|
104
|
-
|
104
|
+
|
105
105
|
observer.callCount = 0 ;
|
106
106
|
array.replace(2, 1, T.objects(1));
|
107
107
|
equals(observer.callCount, 0, 'observer should not fire');
|
@@ -117,7 +117,7 @@ SC.ArraySuite.define(function(T) {
|
|
117
117
|
|
118
118
|
test("removing range should no longer fire observers", function() {
|
119
119
|
array.removeRangeObserver(rangeObserver);
|
120
|
-
|
120
|
+
|
121
121
|
observer.callCount = 0 ;
|
122
122
|
array.replace(2, 1, T.objects(1));
|
123
123
|
equals(observer.callCount, 0, 'observer should not fire');
|
@@ -133,32 +133,32 @@ SC.ArraySuite.define(function(T) {
|
|
133
133
|
|
134
134
|
// ..........................................................
|
135
135
|
// GROUPED CHANGES
|
136
|
-
//
|
137
|
-
|
136
|
+
//
|
137
|
+
|
138
138
|
test("grouping property changes should notify observer only once at end with single IndexSet", function() {
|
139
|
-
|
139
|
+
|
140
140
|
array.beginPropertyChanges();
|
141
141
|
array.replace(2, 1, T.objects(1));
|
142
142
|
array.replace(4, 1, T.objects(1));
|
143
143
|
array.endPropertyChanges();
|
144
|
-
|
144
|
+
|
145
145
|
var set = SC.IndexSet.create().add(2).add(4); // both edits
|
146
146
|
observer.expectRangeChange(array, null, '[]', set);
|
147
147
|
});
|
148
148
|
|
149
149
|
test("should notify observer when some but not all grouped changes are inside range", function() {
|
150
|
-
|
150
|
+
|
151
151
|
array.beginPropertyChanges();
|
152
152
|
array.replace(2, 1, T.objects(1));
|
153
153
|
array.replace(9, 1, T.objects(1));
|
154
154
|
array.endPropertyChanges();
|
155
|
-
|
155
|
+
|
156
156
|
var set = SC.IndexSet.create().add(2).add(9); // both edits
|
157
157
|
observer.expectRangeChange(array, null, '[]', set);
|
158
158
|
});
|
159
|
-
|
159
|
+
|
160
160
|
test("should NOT notify observer when grouping changes all outside of observer", function() {
|
161
|
-
|
161
|
+
|
162
162
|
array.beginPropertyChanges();
|
163
163
|
array.replace(0, 1, T.objects(1));
|
164
164
|
array.replace(9, 1, T.objects(1));
|
@@ -166,15 +166,15 @@ SC.ArraySuite.define(function(T) {
|
|
166
166
|
|
167
167
|
equals(observer.callCount, 0, 'observer should not fire');
|
168
168
|
});
|
169
|
-
|
169
|
+
|
170
170
|
// ..........................................................
|
171
171
|
// INSERTING
|
172
|
-
//
|
173
|
-
|
172
|
+
//
|
173
|
+
|
174
174
|
test("insertAt in range fires observer with index set covering edit to end of array", function() {
|
175
175
|
var newItem = T.objects(1)[0],
|
176
176
|
set = SC.IndexSet.create(3,array.get('length')-2);
|
177
|
-
|
177
|
+
|
178
178
|
array.insertAt(3, newItem);
|
179
179
|
observer.expectRangeChange(array, null, '[]', set);
|
180
180
|
});
|
@@ -182,22 +182,22 @@ SC.ArraySuite.define(function(T) {
|
|
182
182
|
test("insertAt BEFORE range fires observer with index set covering edit to end of array", function() {
|
183
183
|
var newItem = T.objects(1)[0],
|
184
184
|
set = SC.IndexSet.create(0,array.get('length')+1);
|
185
|
-
|
185
|
+
|
186
186
|
array.insertAt(0, newItem);
|
187
187
|
observer.expectRangeChange(array, null, '[]', set);
|
188
188
|
});
|
189
189
|
|
190
190
|
test("insertAt AFTER range does not fire observer", function() {
|
191
191
|
var newItem = T.objects(1)[0];
|
192
|
-
|
192
|
+
|
193
193
|
array.insertAt(9, newItem);
|
194
194
|
equals(observer.callCount, 0, 'observer should not fire');
|
195
195
|
});
|
196
|
-
|
196
|
+
|
197
197
|
// ..........................................................
|
198
198
|
// REMOVING
|
199
|
-
//
|
200
|
-
|
199
|
+
//
|
200
|
+
|
201
201
|
test("removeAt IN range fires observer with index set covering edit to end of array plus delta", function() {
|
202
202
|
var set = SC.IndexSet.create(3,array.get('length')-3);
|
203
203
|
array.removeAt(3);
|
@@ -214,36 +214,36 @@ SC.ArraySuite.define(function(T) {
|
|
214
214
|
array.removeAt(9);
|
215
215
|
equals(observer.callCount, 0, 'observer should not fire');
|
216
216
|
});
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
217
|
+
|
218
|
+
|
219
|
+
|
220
|
+
|
221
221
|
// ..........................................................
|
222
222
|
// MODULE: No explicit range
|
223
|
-
//
|
223
|
+
//
|
224
224
|
module(T.desc("RangeObserver Methods - No explicit range"), {
|
225
225
|
setup: function() {
|
226
226
|
expected = T.objects(10);
|
227
227
|
array = T.newObject(expected);
|
228
228
|
|
229
229
|
observer = T.observer();
|
230
|
-
rangeObserver = array.addRangeObserver(null, observer,
|
230
|
+
rangeObserver = array.addRangeObserver(null, observer,
|
231
231
|
observer.rangeDidChange, null, NO);
|
232
|
-
|
232
|
+
|
233
233
|
},
|
234
|
-
|
234
|
+
|
235
235
|
teardown: function() {
|
236
236
|
T.destroyObject(array);
|
237
237
|
}
|
238
238
|
});
|
239
|
-
|
239
|
+
|
240
240
|
test("returns RangeObserver object", function() {
|
241
241
|
ok(rangeObserver && rangeObserver.isRangeObserver, 'returns a range observer object');
|
242
242
|
});
|
243
243
|
|
244
244
|
// ..........................................................
|
245
245
|
// REPLACE
|
246
|
-
//
|
246
|
+
//
|
247
247
|
|
248
248
|
test("replacing object in range fires observer with index set covering only the effected item", function() {
|
249
249
|
array.replace(2, 1, T.objects(1));
|
@@ -262,7 +262,7 @@ SC.ArraySuite.define(function(T) {
|
|
262
262
|
|
263
263
|
test("removing range should no longer fire observers", function() {
|
264
264
|
array.removeRangeObserver(rangeObserver);
|
265
|
-
|
265
|
+
|
266
266
|
observer.callCount = 0 ;
|
267
267
|
array.replace(2, 1, T.objects(1));
|
268
268
|
equals(observer.callCount, 0, 'observer should not fire');
|
@@ -278,27 +278,27 @@ SC.ArraySuite.define(function(T) {
|
|
278
278
|
|
279
279
|
// ..........................................................
|
280
280
|
// GROUPED CHANGES
|
281
|
-
//
|
282
|
-
|
281
|
+
//
|
282
|
+
|
283
283
|
test("grouping property changes should notify observer only once at end with single IndexSet", function() {
|
284
|
-
|
284
|
+
|
285
285
|
array.beginPropertyChanges();
|
286
286
|
array.replace(2, 1, T.objects(1));
|
287
287
|
array.replace(4, 1, T.objects(1));
|
288
288
|
array.endPropertyChanges();
|
289
|
-
|
289
|
+
|
290
290
|
var set = SC.IndexSet.create().add(2).add(4); // both edits
|
291
291
|
observer.expectRangeChange(array, null, '[]', set);
|
292
292
|
});
|
293
293
|
|
294
294
|
// ..........................................................
|
295
295
|
// INSERTING
|
296
|
-
//
|
297
|
-
|
296
|
+
//
|
297
|
+
|
298
298
|
test("insertAt in range fires observer with index set covering edit to end of array", function() {
|
299
299
|
var newItem = T.objects(1)[0],
|
300
300
|
set = SC.IndexSet.create(3,array.get('length')-2);
|
301
|
-
|
301
|
+
|
302
302
|
array.insertAt(3, newItem);
|
303
303
|
observer.expectRangeChange(array, null, '[]', set);
|
304
304
|
});
|
@@ -310,11 +310,11 @@ SC.ArraySuite.define(function(T) {
|
|
310
310
|
array.pushObject(newItem);
|
311
311
|
observer.expectRangeChange(array, null, '[]', set);
|
312
312
|
});
|
313
|
-
|
313
|
+
|
314
314
|
// ..........................................................
|
315
315
|
// REMOVING
|
316
|
-
//
|
317
|
-
|
316
|
+
//
|
317
|
+
|
318
318
|
test("removeAt fires observer with index set covering edit to end of array", function() {
|
319
319
|
var set = SC.IndexSet.create(3,array.get('length')-3);
|
320
320
|
array.removeAt(3);
|
@@ -326,33 +326,33 @@ SC.ArraySuite.define(function(T) {
|
|
326
326
|
array.popObject();
|
327
327
|
observer.expectRangeChange(array, null, '[]', set);
|
328
328
|
});
|
329
|
-
|
330
|
-
|
329
|
+
|
330
|
+
|
331
331
|
// ..........................................................
|
332
|
-
// MODULE: isDeep = NO
|
333
|
-
//
|
332
|
+
// MODULE: isDeep = NO
|
333
|
+
//
|
334
334
|
module(T.desc("RangeObserver Methods - isDeep NO"), {
|
335
335
|
setup: function() {
|
336
336
|
expected = T.objects(10);
|
337
337
|
array = T.newObject(expected);
|
338
338
|
|
339
339
|
observer = T.observer();
|
340
|
-
rangeObserver = array.addRangeObserver(SC.IndexSet.create(2,3),
|
340
|
+
rangeObserver = array.addRangeObserver(SC.IndexSet.create(2,3),
|
341
341
|
observer, observer.rangeDidChange, null, NO);
|
342
|
-
|
342
|
+
|
343
343
|
},
|
344
|
-
|
344
|
+
|
345
345
|
teardown: function() {
|
346
346
|
T.destroyObject(array);
|
347
347
|
}
|
348
348
|
});
|
349
|
-
|
349
|
+
|
350
350
|
test("editing property on object at any point should not fire observer", function() {
|
351
|
-
|
352
|
-
var indexes = [0,3,9],
|
351
|
+
|
352
|
+
var indexes = [0,3,9],
|
353
353
|
loc = 3,
|
354
354
|
obj,idx;
|
355
|
-
|
355
|
+
|
356
356
|
while(--loc>=0) {
|
357
357
|
idx = indexes[loc];
|
358
358
|
obj = array.objectAt(idx);
|
@@ -360,12 +360,12 @@ SC.ArraySuite.define(function(T) {
|
|
360
360
|
equals(observer.callCount, 0, 'observer should not fire when editing object at index %@'.fmt(idx));
|
361
361
|
}
|
362
362
|
});
|
363
|
-
|
363
|
+
|
364
364
|
test("replacing object in range fires observer with index set", function() {
|
365
365
|
array.replace(2, 1, T.objects(1));
|
366
366
|
observer.expectRangeChange(array, null, '[]', SC.IndexSet.create(2,1));
|
367
367
|
});
|
368
|
-
|
369
|
-
|
368
|
+
|
369
|
+
|
370
370
|
});
|
371
371
|
|
@@ -1,28 +1,29 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
1
|
+
/**
|
2
|
+
* @license
|
3
|
+
* ==========================================================================
|
4
|
+
* SproutCore Costello -- Property Observing Library
|
5
|
+
* Copyright ©2006-2011, Strobe Inc. and contributors.
|
6
|
+
* Portions copyright ©2008-2010 Apple Inc. All rights reserved.
|
7
|
+
*
|
8
|
+
* Permission is hereby granted, free of charge, to any person obtaining a
|
9
|
+
* copy of this software and associated documentation files (the "Software"),
|
10
|
+
* to deal in the Software without restriction, including without limitation
|
11
|
+
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
12
|
+
* and/or sell copies of the Software, and to permit persons to whom the
|
13
|
+
* Software is furnished to do so, subject to the following conditions:
|
14
|
+
*
|
15
|
+
* The above copyright notice and this permission notice shall be included in
|
16
|
+
* all copies or substantial portions of the Software.
|
17
|
+
*
|
18
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
19
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
20
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
21
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
22
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
23
|
+
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
24
|
+
* DEALINGS IN THE SOFTWARE.
|
25
|
+
*
|
26
|
+
* For more information about SproutCore, visit http://www.sproutcore.com
|
27
|
+
*
|
28
|
+
* ==========================================================================
|
29
|
+
*/
|
@@ -15,80 +15,80 @@ SC.OUT_OF_RANGE_EXCEPTION = "Index out of range" ;
|
|
15
15
|
|
16
16
|
/**
|
17
17
|
@namespace
|
18
|
-
|
19
|
-
This module implements Observer-friendly Array-like behavior. This mixin is
|
20
|
-
picked up by the Array class as well as other controllers, etc. that want to
|
18
|
+
|
19
|
+
This module implements Observer-friendly Array-like behavior. This mixin is
|
20
|
+
picked up by the Array class as well as other controllers, etc. that want to
|
21
21
|
appear to be arrays.
|
22
|
-
|
23
|
-
Unlike SC.Enumerable, this mixin defines methods specifically for
|
22
|
+
|
23
|
+
Unlike SC.Enumerable, this mixin defines methods specifically for
|
24
24
|
collections that provide index-ordered access to their contents. When you
|
25
25
|
are designing code that needs to accept any kind of Array-like object, you
|
26
|
-
should use these methods instead of Array primitives because these will
|
27
|
-
properly notify observers of changes to the array.
|
28
|
-
|
26
|
+
should use these methods instead of Array primitives because these will
|
27
|
+
properly notify observers of changes to the array.
|
28
|
+
|
29
29
|
Although these methods are efficient, they do add a layer of indirection to
|
30
|
-
your application so it is a good idea to use them only when you need the
|
30
|
+
your application so it is a good idea to use them only when you need the
|
31
31
|
flexibility of using both true JavaScript arrays and "virtual" arrays such
|
32
32
|
as controllers and collections.
|
33
|
-
|
34
|
-
You can use the methods defined in this module to access and modify array
|
35
|
-
contents in a KVO-friendly way. You can also be notified whenever the
|
33
|
+
|
34
|
+
You can use the methods defined in this module to access and modify array
|
35
|
+
contents in a KVO-friendly way. You can also be notified whenever the
|
36
36
|
membership if an array changes by changing the syntax of the property to
|
37
37
|
.observes('*myProperty.[]') .
|
38
|
-
|
38
|
+
|
39
39
|
To support SC.Array in your own class, you must override two
|
40
|
-
primitives to use it: replace() and objectAt().
|
41
|
-
|
40
|
+
primitives to use it: replace() and objectAt().
|
41
|
+
|
42
42
|
Note that the SC.Array mixin also incorporates the SC.Enumerable mixin. All
|
43
43
|
SC.Array-like objects are also enumerable.
|
44
|
-
|
44
|
+
|
45
45
|
@extends SC.Enumerable
|
46
46
|
@since SproutCore 0.9.0
|
47
47
|
*/
|
48
48
|
SC.Array = {
|
49
|
-
|
49
|
+
|
50
50
|
/**
|
51
51
|
Walk like a duck - use isSCArray to avoid conflicts
|
52
52
|
*/
|
53
53
|
isSCArray: YES,
|
54
|
-
|
54
|
+
|
55
55
|
/**
|
56
56
|
@field {Number} length
|
57
|
-
|
57
|
+
|
58
58
|
Your array must support the length property. Your replace methods should
|
59
59
|
set this property whenever it changes.
|
60
60
|
*/
|
61
61
|
// length: 0,
|
62
|
-
|
62
|
+
|
63
63
|
/**
|
64
|
-
This is one of the primitves you must implement to support SC.Array. You
|
65
|
-
should replace amt objects started at idx with the objects in the passed
|
64
|
+
This is one of the primitves you must implement to support SC.Array. You
|
65
|
+
should replace amt objects started at idx with the objects in the passed
|
66
66
|
array. You should also call this.enumerableContentDidChange() ;
|
67
|
-
|
68
|
-
@param {Number} idx
|
69
|
-
Starting index in the array to replace. If idx >= length, then append to
|
67
|
+
|
68
|
+
@param {Number} idx
|
69
|
+
Starting index in the array to replace. If idx >= length, then append to
|
70
70
|
the end of the array.
|
71
|
-
|
72
|
-
@param {Number} amt
|
73
|
-
Number of elements that should be removed from the array, starting at
|
71
|
+
|
72
|
+
@param {Number} amt
|
73
|
+
Number of elements that should be removed from the array, starting at
|
74
74
|
*idx*.
|
75
|
-
|
76
|
-
@param {Array} objects
|
77
|
-
An array of zero or more objects that should be inserted into the array at
|
78
|
-
*idx*
|
75
|
+
|
76
|
+
@param {Array} objects
|
77
|
+
An array of zero or more objects that should be inserted into the array at
|
78
|
+
*idx*
|
79
79
|
*/
|
80
80
|
replace: function(idx, amt, objects) {
|
81
81
|
throw "replace() must be implemented to support SC.Array" ;
|
82
82
|
},
|
83
|
-
|
83
|
+
|
84
84
|
/**
|
85
|
-
This is one of the primitives you must implement to support SC.Array.
|
86
|
-
Returns the object at the named index. If your object supports retrieving
|
85
|
+
This is one of the primitives you must implement to support SC.Array.
|
86
|
+
Returns the object at the named index. If your object supports retrieving
|
87
87
|
the value of an array item using get() (i.e. myArray.get(0)), then you do
|
88
88
|
not need to implement this method yourself.
|
89
|
-
|
89
|
+
|
90
90
|
@param {Number} idx
|
91
|
-
The index of the item to return. If idx exceeds the current length,
|
91
|
+
The index of the item to return. If idx exceeds the current length,
|
92
92
|
return null.
|
93
93
|
*/
|
94
94
|
objectAt: function(idx) {
|
@@ -96,27 +96,27 @@ SC.Array = {
|
|
96
96
|
if (idx >= this.get('length')) return undefined;
|
97
97
|
return this.get(idx);
|
98
98
|
},
|
99
|
-
|
99
|
+
|
100
100
|
/**
|
101
101
|
@field []
|
102
|
-
|
102
|
+
|
103
103
|
This is the handler for the special array content property. If you get
|
104
|
-
this property, it will return this. If you set this property it a new
|
104
|
+
this property, it will return this. If you set this property it a new
|
105
105
|
array, it will replace the current content.
|
106
|
-
|
106
|
+
|
107
107
|
This property overrides the default property defined in SC.Enumerable.
|
108
108
|
*/
|
109
109
|
'[]': function(key, value) {
|
110
110
|
if (value !== undefined) {
|
111
111
|
this.replace(0, this.get('length'), value) ;
|
112
|
-
}
|
112
|
+
}
|
113
113
|
return this ;
|
114
114
|
}.property(),
|
115
|
-
|
115
|
+
|
116
116
|
/**
|
117
|
-
This will use the primitive replace() method to insert an object at the
|
117
|
+
This will use the primitive replace() method to insert an object at the
|
118
118
|
specified index.
|
119
|
-
|
119
|
+
|
120
120
|
@param {Number} idx index of insert the object at.
|
121
121
|
@param {Object} object object to insert
|
122
122
|
*/
|
@@ -125,30 +125,30 @@ SC.Array = {
|
|
125
125
|
this.replace(idx,0,[object]) ;
|
126
126
|
return this ;
|
127
127
|
},
|
128
|
-
|
128
|
+
|
129
129
|
/**
|
130
|
-
Remove an object at the specified index using the replace() primitive
|
130
|
+
Remove an object at the specified index using the replace() primitive
|
131
131
|
method. You can pass either a single index, a start and a length or an
|
132
132
|
index set.
|
133
|
-
|
134
|
-
If you pass a single index or a start and length that is beyond the
|
133
|
+
|
134
|
+
If you pass a single index or a start and length that is beyond the
|
135
135
|
length this method will throw an SC.OUT_OF_RANGE_EXCEPTION
|
136
|
-
|
136
|
+
|
137
137
|
@param {Number|SC.IndexSet} start index, start of range, or index set
|
138
138
|
@param {Number} length length of passing range
|
139
139
|
@returns {Object} receiver
|
140
140
|
*/
|
141
141
|
removeAt: function(start, length) {
|
142
|
-
|
142
|
+
|
143
143
|
var delta = 0, // used to shift range
|
144
144
|
empty = [];
|
145
|
-
|
145
|
+
|
146
146
|
if (typeof start === SC.T_NUMBER) {
|
147
|
-
|
147
|
+
|
148
148
|
if ((start < 0) || (start >= this.get('length'))) {
|
149
149
|
throw SC.OUT_OF_RANGE_EXCEPTION;
|
150
150
|
}
|
151
|
-
|
151
|
+
|
152
152
|
// fast case
|
153
153
|
if (length === undefined) {
|
154
154
|
this.replace(start,1,empty);
|
@@ -157,7 +157,7 @@ SC.Array = {
|
|
157
157
|
start = SC.IndexSet.create(start, length);
|
158
158
|
}
|
159
159
|
}
|
160
|
-
|
160
|
+
|
161
161
|
this.beginPropertyChanges();
|
162
162
|
start.forEachRange(function(start, length) {
|
163
163
|
start -= delta ;
|
@@ -165,10 +165,10 @@ SC.Array = {
|
|
165
165
|
this.replace(start, length, empty); // remove!
|
166
166
|
}, this);
|
167
167
|
this.endPropertyChanges();
|
168
|
-
|
168
|
+
|
169
169
|
return this ;
|
170
170
|
},
|
171
|
-
|
171
|
+
|
172
172
|
/**
|
173
173
|
Search the array of this object, removing any occurrences of it.
|
174
174
|
@param {object} obj object to remove
|
@@ -181,11 +181,11 @@ SC.Array = {
|
|
181
181
|
}
|
182
182
|
return this ;
|
183
183
|
},
|
184
|
-
|
184
|
+
|
185
185
|
/**
|
186
186
|
Search the array for the passed set of objects and remove any occurrences
|
187
|
-
of the.
|
188
|
-
|
187
|
+
of the.
|
188
|
+
|
189
189
|
@param {SC.Enumerable} objects the objects to remove
|
190
190
|
@returns {SC.Array} receiver
|
191
191
|
*/
|
@@ -195,21 +195,21 @@ SC.Array = {
|
|
195
195
|
this.endPropertyChanges();
|
196
196
|
return this;
|
197
197
|
},
|
198
|
-
|
198
|
+
|
199
199
|
/**
|
200
|
-
Push the object onto the end of the array. Works just like push() but it
|
200
|
+
Push the object onto the end of the array. Works just like push() but it
|
201
201
|
is KVO-compliant.
|
202
202
|
*/
|
203
203
|
pushObject: function(obj) {
|
204
204
|
this.insertAt(this.get('length'), obj) ;
|
205
205
|
return obj ;
|
206
206
|
},
|
207
|
-
|
208
|
-
|
207
|
+
|
208
|
+
|
209
209
|
/**
|
210
210
|
Add the objects in the passed numerable to the end of the array. Defers
|
211
211
|
notifying observers of the change until all objects are added.
|
212
|
-
|
212
|
+
|
213
213
|
@param {SC.Enumerable} objects the objects to add
|
214
214
|
@returns {SC.Array} receiver
|
215
215
|
*/
|
@@ -221,20 +221,20 @@ SC.Array = {
|
|
221
221
|
},
|
222
222
|
|
223
223
|
/**
|
224
|
-
Pop object from array or nil if none are left. Works just like pop() but
|
224
|
+
Pop object from array or nil if none are left. Works just like pop() but
|
225
225
|
it is KVO-compliant.
|
226
226
|
*/
|
227
227
|
popObject: function() {
|
228
228
|
var len = this.get('length') ;
|
229
229
|
if (len === 0) return null ;
|
230
|
-
|
230
|
+
|
231
231
|
var ret = this.objectAt(len-1) ;
|
232
232
|
this.removeAt(len-1) ;
|
233
233
|
return ret ;
|
234
234
|
},
|
235
|
-
|
235
|
+
|
236
236
|
/**
|
237
|
-
Shift an object from start of array or nil if none are left. Works just
|
237
|
+
Shift an object from start of array or nil if none are left. Works just
|
238
238
|
like shift() but it is KVO-compliant.
|
239
239
|
*/
|
240
240
|
shiftObject: function() {
|
@@ -243,9 +243,9 @@ SC.Array = {
|
|
243
243
|
this.removeAt(0) ;
|
244
244
|
return ret ;
|
245
245
|
},
|
246
|
-
|
246
|
+
|
247
247
|
/**
|
248
|
-
Unshift an object to start of array. Works just like unshift() but it is
|
248
|
+
Unshift an object to start of array. Works just like unshift() but it is
|
249
249
|
KVO-compliant.
|
250
250
|
*/
|
251
251
|
unshiftObject: function(obj) {
|
@@ -253,11 +253,11 @@ SC.Array = {
|
|
253
253
|
return obj ;
|
254
254
|
},
|
255
255
|
|
256
|
-
|
256
|
+
|
257
257
|
/**
|
258
258
|
Adds the named objects to the beginning of the array. Defers notifying
|
259
259
|
observers until all objects have been added.
|
260
|
-
|
260
|
+
|
261
261
|
@param {SC.Enumerable} objects the objects to add
|
262
262
|
@returns {SC.Array} receiver
|
263
263
|
*/
|
@@ -267,14 +267,14 @@ SC.Array = {
|
|
267
267
|
this.endPropertyChanges();
|
268
268
|
return this;
|
269
269
|
},
|
270
|
-
|
271
|
-
/**
|
270
|
+
|
271
|
+
/**
|
272
272
|
Compares each item in the array. Returns true if they are equal.
|
273
273
|
*/
|
274
274
|
isEqual: function(ary) {
|
275
275
|
if (!ary) return false ;
|
276
276
|
if (ary == this) return true;
|
277
|
-
|
277
|
+
|
278
278
|
var loc = ary.get('length') ;
|
279
279
|
if (loc != this.get('length')) return false ;
|
280
280
|
|
@@ -283,27 +283,27 @@ SC.Array = {
|
|
283
283
|
}
|
284
284
|
return true ;
|
285
285
|
},
|
286
|
-
|
286
|
+
|
287
287
|
/**
|
288
288
|
Generates a new array with the contents of the old array, sans any null
|
289
289
|
values.
|
290
|
-
|
290
|
+
|
291
291
|
@returns {Array}
|
292
292
|
*/
|
293
293
|
compact: function() { return this.without(null); },
|
294
|
-
|
294
|
+
|
295
295
|
/**
|
296
296
|
Generates a new array with the contents of the old array, sans the passed
|
297
297
|
value.
|
298
|
-
|
298
|
+
|
299
299
|
@param {Object} value
|
300
300
|
@returns {Array}
|
301
301
|
*/
|
302
302
|
without: function(value) {
|
303
303
|
if (this.indexOf(value)<0) return this; // value not present.
|
304
304
|
var ret = [] ;
|
305
|
-
this.forEach(function(k) {
|
306
|
-
if (k !== value) ret[ret.length] = k;
|
305
|
+
this.forEach(function(k) {
|
306
|
+
if (k !== value) ret[ret.length] = k;
|
307
307
|
}) ;
|
308
308
|
return ret ;
|
309
309
|
},
|
@@ -311,7 +311,7 @@ SC.Array = {
|
|
311
311
|
/**
|
312
312
|
Generates a new array with only unique values from the contents of the
|
313
313
|
old array.
|
314
|
-
|
314
|
+
|
315
315
|
@returns {Array}
|
316
316
|
*/
|
317
317
|
uniq: function() {
|
@@ -321,51 +321,61 @@ SC.Array = {
|
|
321
321
|
});
|
322
322
|
return ret ;
|
323
323
|
},
|
324
|
-
|
324
|
+
|
325
325
|
/**
|
326
326
|
Returns the largest Number in an array of Numbers. Make sure the array
|
327
327
|
only contains values of type Number to get expected result.
|
328
|
-
|
328
|
+
|
329
329
|
Note: This only works for dense arrays.
|
330
|
-
|
330
|
+
|
331
331
|
@returns {Number}
|
332
332
|
*/
|
333
333
|
max: function() {
|
334
334
|
return Math.max.apply(Math, this);
|
335
335
|
},
|
336
|
-
|
336
|
+
|
337
337
|
/**
|
338
338
|
Returns the smallest Number in an array of Numbers. Make sure the array
|
339
339
|
only contains values of type Number to get expected result.
|
340
|
-
|
340
|
+
|
341
341
|
Note: This only works for dense arrays.
|
342
|
-
|
342
|
+
|
343
343
|
@returns {Number}
|
344
344
|
*/
|
345
345
|
min: function() {
|
346
346
|
return Math.min.apply(Math, this);
|
347
347
|
},
|
348
|
-
|
348
|
+
|
349
349
|
rangeObserverClass: SC.RangeObserver,
|
350
|
-
|
350
|
+
|
351
|
+
/**
|
352
|
+
Returns YES if object is in the array
|
353
|
+
|
354
|
+
@param {Object} object to look for
|
355
|
+
@returns {Boolean}
|
356
|
+
*/
|
357
|
+
contains: function(obj){
|
358
|
+
return this.indexOf(obj) >= 0;
|
359
|
+
},
|
360
|
+
|
351
361
|
/**
|
352
362
|
Creates a new range observer on the receiver. The target/method callback
|
353
|
-
you provide will be invoked anytime any property on the objects in the
|
363
|
+
you provide will be invoked anytime any property on the objects in the
|
354
364
|
specified range changes. It will also be invoked if the objects in the
|
355
365
|
range itself changes also.
|
356
|
-
|
366
|
+
|
357
367
|
The callback for a range observer should have the signature:
|
358
|
-
|
368
|
+
|
359
369
|
{{{
|
360
370
|
function rangePropertyDidChange(array, objects, key, indexes, conext)
|
361
371
|
}}}
|
362
|
-
|
372
|
+
|
363
373
|
If the passed key is '[]' it means that the object itself changed.
|
364
|
-
|
365
|
-
The return value from this method is an opaque reference to the
|
366
|
-
range observer object. You can use this reference to destroy the
|
374
|
+
|
375
|
+
The return value from this method is an opaque reference to the
|
376
|
+
range observer object. You can use this reference to destroy the
|
367
377
|
range observer when you are done with it or to update its range.
|
368
|
-
|
378
|
+
|
369
379
|
@param {SC.IndexSet} indexes indexes to observe
|
370
380
|
@param {Object} target object to invoke on change
|
371
381
|
@param {String|Function} method the method to invoke
|
@@ -381,29 +391,29 @@ SC.Array = {
|
|
381
391
|
if (this._array_oldLength===undefined) {
|
382
392
|
this._array_oldLength = this.get('length') ;
|
383
393
|
}
|
384
|
-
|
394
|
+
|
385
395
|
var C = this.rangeObserverClass ;
|
386
396
|
var isDeep = NO; //disable this feature for now
|
387
397
|
var ret = C.create(this, indexes, target, method, context, isDeep) ;
|
388
398
|
rangeob.add(ret);
|
389
|
-
|
399
|
+
|
390
400
|
// first time a range observer is added, begin observing the [] property
|
391
401
|
if (!this._array_isNotifyingRangeObservers) {
|
392
402
|
this._array_isNotifyingRangeObservers = YES ;
|
393
403
|
this.addObserver('[]', this, this._array_notifyRangeObservers);
|
394
404
|
}
|
395
|
-
|
405
|
+
|
396
406
|
return ret ;
|
397
407
|
},
|
398
|
-
|
408
|
+
|
399
409
|
/**
|
400
|
-
Moves a range observer so that it observes a new range of objects on the
|
410
|
+
Moves a range observer so that it observes a new range of objects on the
|
401
411
|
array. You must have an existing range observer object from a call to
|
402
412
|
addRangeObserver().
|
403
|
-
|
413
|
+
|
404
414
|
The return value should replace the old range observer object that you
|
405
415
|
pass in.
|
406
|
-
|
416
|
+
|
407
417
|
@param {SC.RangeObserver} rangeObserver the range observer
|
408
418
|
@param {SC.IndexSet} indexes new indexes to observe
|
409
419
|
@returns {SC.RangeObserver} the range observer (or a new one)
|
@@ -411,14 +421,14 @@ SC.Array = {
|
|
411
421
|
updateRangeObserver: function(rangeObserver, indexes) {
|
412
422
|
return rangeObserver.update(this, indexes);
|
413
423
|
},
|
414
|
-
|
424
|
+
|
415
425
|
/**
|
416
426
|
Removes a range observer from the receiver. The range observer must
|
417
427
|
already be active on the array.
|
418
|
-
|
428
|
+
|
419
429
|
The return value should replace the old range observer object. It will
|
420
430
|
usually be null.
|
421
|
-
|
431
|
+
|
422
432
|
@param {SC.RangeObserver} rangeObserver the range observer
|
423
433
|
@returns {SC.RangeObserver} updated range observer or null
|
424
434
|
*/
|
@@ -428,12 +438,12 @@ SC.Array = {
|
|
428
438
|
if (rangeob) rangeob.remove(rangeObserver) ; // clear
|
429
439
|
return ret ;
|
430
440
|
},
|
431
|
-
|
441
|
+
|
432
442
|
/**
|
433
|
-
Updates observers with content change. To support range observers,
|
443
|
+
Updates observers with content change. To support range observers,
|
434
444
|
you must pass three change parameters to this method. Otherwise this
|
435
445
|
method will assume the entire range has changed.
|
436
|
-
|
446
|
+
|
437
447
|
This also assumes you have already updated the length property.
|
438
448
|
@param {Number} start the starting index of the change
|
439
449
|
@param {Number} amt the final range of objects changed
|
@@ -441,22 +451,22 @@ SC.Array = {
|
|
441
451
|
@returns {SC.Array} receiver
|
442
452
|
*/
|
443
453
|
enumerableContentDidChange: function(start, amt, delta) {
|
444
|
-
var rangeob = this._array_rangeObservers,
|
454
|
+
var rangeob = this._array_rangeObservers,
|
445
455
|
oldlen = this._array_oldLength,
|
446
456
|
newlen, length, changes ;
|
447
457
|
|
448
|
-
this.beginPropertyChanges();
|
458
|
+
this.beginPropertyChanges();
|
449
459
|
this.notifyPropertyChange('length'); // flush caches
|
450
460
|
|
451
461
|
// schedule info for range observers
|
452
462
|
if (rangeob && rangeob.length>0) {
|
453
463
|
|
454
464
|
// if no oldLength has been cached, just assume 0
|
455
|
-
if (oldlen === undefined) oldlen = 0;
|
465
|
+
if (oldlen === undefined) oldlen = 0;
|
456
466
|
this._array_oldLength = newlen = this.get('length');
|
457
|
-
|
467
|
+
|
458
468
|
// normalize input parameters
|
459
|
-
// if delta was not passed, assume it is the different between the
|
469
|
+
// if delta was not passed, assume it is the different between the
|
460
470
|
// new and old length.
|
461
471
|
if (start === undefined) start = 0;
|
462
472
|
if (delta === undefined) delta = newlen - oldlen ;
|
@@ -466,53 +476,53 @@ SC.Array = {
|
|
466
476
|
} else {
|
467
477
|
length = amt ;
|
468
478
|
}
|
469
|
-
|
479
|
+
|
470
480
|
changes = this._array_rangeChanges;
|
471
481
|
if (!changes) changes = this._array_rangeChanges = SC.IndexSet.create();
|
472
482
|
changes.add(start, length);
|
473
483
|
}
|
474
|
-
|
484
|
+
|
475
485
|
this.notifyPropertyChange('[]') ;
|
476
486
|
this.endPropertyChanges();
|
477
|
-
|
487
|
+
|
478
488
|
return this ;
|
479
489
|
},
|
480
|
-
|
490
|
+
|
481
491
|
/** @private
|
482
|
-
Observer fires whenever the '[]' property changes. If there are
|
492
|
+
Observer fires whenever the '[]' property changes. If there are
|
483
493
|
range observers, will notify observers of change.
|
484
494
|
*/
|
485
495
|
_array_notifyRangeObservers: function() {
|
486
496
|
var rangeob = this._array_rangeObservers,
|
487
497
|
changes = this._array_rangeChanges,
|
488
|
-
len = rangeob ? rangeob.length : 0,
|
498
|
+
len = rangeob ? rangeob.length : 0,
|
489
499
|
idx, cur;
|
490
|
-
|
500
|
+
|
491
501
|
if (len > 0 && changes && changes.length > 0) {
|
492
502
|
for(idx=0;idx<len;idx++) rangeob[idx].rangeDidChange(changes);
|
493
503
|
changes.clear(); // reset for later notifications
|
494
504
|
}
|
495
505
|
}
|
496
|
-
|
506
|
+
|
497
507
|
} ;
|
498
508
|
|
499
509
|
// Add SC.Array to the built-in array before we add SC.Enumerable to SC.Array
|
500
510
|
// since built-in Array's are already enumerable.
|
501
|
-
SC.mixin(Array.prototype, SC.Array) ;
|
511
|
+
SC.mixin(Array.prototype, SC.Array) ;
|
502
512
|
SC.Array = SC.mixin({}, SC.Enumerable, SC.Array) ;
|
503
513
|
|
504
514
|
// Add any extra methods to SC.Array that are native to the built-in Array.
|
505
515
|
/**
|
506
516
|
Returns a new array that is a slice of the receiver. This implementation
|
507
|
-
uses the observable array methods to retrieve the objects for the new
|
517
|
+
uses the observable array methods to retrieve the objects for the new
|
508
518
|
slice.
|
509
|
-
|
510
|
-
@param beginIndex {Integer} (Optional) index to begin slicing from.
|
519
|
+
|
520
|
+
@param beginIndex {Integer} (Optional) index to begin slicing from.
|
511
521
|
@param endIndex {Integer} (Optional) index to end the slice at.
|
512
522
|
@returns {Array} New array with specified slice
|
513
523
|
*/
|
514
524
|
SC.Array.slice = function(beginIndex, endIndex) {
|
515
|
-
var ret = [];
|
525
|
+
var ret = [];
|
516
526
|
var length = this.get('length') ;
|
517
527
|
if (SC.none(beginIndex)) beginIndex = 0 ;
|
518
528
|
if (SC.none(endIndex) || (endIndex > length)) endIndex = length ;
|
@@ -522,20 +532,20 @@ SC.Array.slice = function(beginIndex, endIndex) {
|
|
522
532
|
|
523
533
|
/**
|
524
534
|
Returns the index for a particular object in the index.
|
525
|
-
|
535
|
+
|
526
536
|
@param {Object} object the item to search for
|
527
537
|
@param {NUmber} startAt optional starting location to search, default 0
|
528
538
|
@returns {Number} index of -1 if not found
|
529
539
|
*/
|
530
540
|
SC.Array.indexOf = function(object, startAt) {
|
531
541
|
var idx, len = this.get('length');
|
532
|
-
|
542
|
+
|
533
543
|
if (startAt === undefined) startAt = 0;
|
534
544
|
else startAt = (startAt < 0) ? Math.ceil(startAt) : Math.floor(startAt);
|
535
545
|
if (startAt < 0) startAt += len;
|
536
|
-
|
546
|
+
|
537
547
|
for(idx=startAt;idx<len;idx++) {
|
538
|
-
if (this.objectAt(idx) === object) return idx ;
|
548
|
+
if (this.objectAt(idx, YES) === object) return idx ;
|
539
549
|
}
|
540
550
|
return -1;
|
541
551
|
};
|
@@ -545,18 +555,18 @@ if (!Array.prototype.indexOf) Array.prototype.indexOf = SC.Array.indexOf;
|
|
545
555
|
|
546
556
|
/**
|
547
557
|
Returns the last index for a particular object in the index.
|
548
|
-
|
558
|
+
|
549
559
|
@param {Object} object the item to search for
|
550
560
|
@param {NUmber} startAt optional starting location to search, default 0
|
551
561
|
@returns {Number} index of -1 if not found
|
552
562
|
*/
|
553
563
|
SC.Array.lastIndexOf = function(object, startAt) {
|
554
564
|
var idx, len = this.get('length');
|
555
|
-
|
565
|
+
|
556
566
|
if (startAt === undefined) startAt = len-1;
|
557
567
|
else startAt = (startAt < 0) ? Math.ceil(startAt) : Math.floor(startAt);
|
558
568
|
if (startAt < 0) startAt += len;
|
559
|
-
|
569
|
+
|
560
570
|
for(idx=startAt;idx>=0;idx--) {
|
561
571
|
if (this.objectAt(idx) === object) return idx ;
|
562
572
|
}
|
@@ -575,7 +585,7 @@ if (!Array.prototype.lastIndexOf) {
|
|
575
585
|
// because working with arrays are so common.
|
576
586
|
(function() {
|
577
587
|
SC.mixin(Array.prototype, {
|
578
|
-
|
588
|
+
|
579
589
|
// primitive for array support.
|
580
590
|
replace: function(idx, amt, objects) {
|
581
591
|
if (this.isFrozen) throw SC.FROZEN_ERROR ;
|
@@ -585,15 +595,15 @@ if (!Array.prototype.lastIndexOf) {
|
|
585
595
|
var args = [idx, amt].concat(objects) ;
|
586
596
|
this.splice.apply(this,args) ;
|
587
597
|
}
|
588
|
-
|
598
|
+
|
589
599
|
// if we replaced exactly the same number of items, then pass only the
|
590
|
-
// replaced range. Otherwise, pass the full remaining array length
|
600
|
+
// replaced range. Otherwise, pass the full remaining array length
|
591
601
|
// since everything has shifted
|
592
602
|
var len = objects ? (objects.get ? objects.get('length') : objects.length) : 0;
|
593
603
|
this.enumerableContentDidChange(idx, amt, len - amt) ;
|
594
604
|
return this ;
|
595
605
|
},
|
596
|
-
|
606
|
+
|
597
607
|
// If you ask for an unknown property, then try to collect the value
|
598
608
|
// from member items.
|
599
609
|
unknownProperty: function(key, value) {
|
@@ -603,41 +613,41 @@ if (!Array.prototype.lastIndexOf) {
|
|
603
613
|
}
|
604
614
|
return ret ;
|
605
615
|
}
|
606
|
-
|
616
|
+
|
607
617
|
});
|
608
|
-
|
618
|
+
|
609
619
|
// If browser did not implement indexOf natively, then override with
|
610
620
|
// specialized version
|
611
621
|
var indexOf = Array.prototype.indexOf;
|
612
622
|
if (!indexOf || (indexOf === SC.Array.indexOf)) {
|
613
623
|
Array.prototype.indexOf = function(object, startAt) {
|
614
624
|
var idx, len = this.length;
|
615
|
-
|
625
|
+
|
616
626
|
if (startAt === undefined) startAt = 0;
|
617
627
|
else startAt = (startAt < 0) ? Math.ceil(startAt) : Math.floor(startAt);
|
618
628
|
if (startAt < 0) startAt += len;
|
619
|
-
|
629
|
+
|
620
630
|
for(idx=startAt;idx<len;idx++) {
|
621
631
|
if (this[idx] === object) return idx ;
|
622
632
|
}
|
623
633
|
return -1;
|
624
|
-
} ;
|
634
|
+
} ;
|
625
635
|
}
|
626
|
-
|
636
|
+
|
627
637
|
var lastIndexOf = Array.prototype.lastIndexOf ;
|
628
638
|
if (!lastIndexOf || (lastIndexOf === SC.Array.lastIndexOf)) {
|
629
639
|
Array.prototype.lastIndexOf = function(object, startAt) {
|
630
640
|
var idx, len = this.length;
|
631
|
-
|
641
|
+
|
632
642
|
if (startAt === undefined) startAt = len-1;
|
633
643
|
else startAt = (startAt < 0) ? Math.ceil(startAt) : Math.floor(startAt);
|
634
644
|
if (startAt < 0) startAt += len;
|
635
|
-
|
645
|
+
|
636
646
|
for(idx=startAt;idx>=0;idx--) {
|
637
647
|
if (this[idx] === object) return idx ;
|
638
648
|
}
|
639
649
|
return -1;
|
640
650
|
};
|
641
651
|
}
|
642
|
-
|
652
|
+
|
643
653
|
})();
|