sproutcore 1.0.1049.pre.2 → 1.4.0.rc
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +1 -1
- data/VERSION.yml +4 -4
- data/lib/Buildfile +1 -1
- data/lib/frameworks/sproutcore/Buildfile +13 -27
- data/lib/frameworks/sproutcore/apps/greenhouse/controllers/library.js +0 -42
- data/lib/frameworks/sproutcore/apps/greenhouse/controllers/view_configs.js +100 -0
- data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/app_page.js +1 -1
- data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/dialogs.js +33 -9
- data/lib/frameworks/sproutcore/apps/greenhouse/english.lproj/strings.js +5 -2
- data/lib/frameworks/sproutcore/apps/greenhouse/states/main.js +1 -0
- data/lib/frameworks/sproutcore/apps/greenhouse/states/modals.js +21 -11
- data/lib/frameworks/sproutcore/apps/welcome/controllers/targets.js +0 -7
- data/lib/frameworks/sproutcore/apps/welcome/english.lproj/main_page.css +6 -24
- data/lib/frameworks/sproutcore/apps/welcome/english.lproj/main_page.js +46 -36
- data/lib/frameworks/sproutcore/frameworks/animation/core.js +32 -50
- data/lib/frameworks/sproutcore/frameworks/animation/tests/core.js +2 -7
- data/lib/frameworks/sproutcore/frameworks/bootstrap/system/browser.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/datastore/models/record.js +66 -42
- data/lib/frameworks/sproutcore/frameworks/datastore/models/record_attribute.js +4 -12
- data/lib/frameworks/sproutcore/frameworks/datastore/models/single_attribute.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/{desktop/tests → datastore/tests/models}/datetime_recordattribute.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/list_item.css +3 -27
- data/lib/frameworks/sproutcore/frameworks/desktop/english.lproj/touch-scroller.css +196 -0
- data/lib/frameworks/sproutcore/frameworks/desktop/mixins/collection_fast_path.js +21 -8
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/alert.js +3 -3
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/menu.js +15 -19
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/panel.js +22 -5
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/picker.js +54 -12
- data/lib/frameworks/sproutcore/frameworks/desktop/panes/select_button.js +45 -18
- data/lib/frameworks/sproutcore/frameworks/desktop/system/drag.js +52 -32
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/button/methods.js +3 -28
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/button/ui.js +10 -30
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/checkbox/methods.js +17 -11
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/date_field/ui.js +2 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list/ui_simple.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/list_item.js +20 -128
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/progress/ui.js +39 -8
- data/lib/frameworks/sproutcore/frameworks/desktop/tests/views/segmented/methods.js +47 -23
- data/lib/frameworks/sproutcore/frameworks/desktop/views/button.js +90 -59
- data/lib/frameworks/sproutcore/frameworks/desktop/views/checkbox.js +39 -29
- data/lib/frameworks/sproutcore/frameworks/desktop/views/collection.js +15 -11
- data/lib/frameworks/sproutcore/frameworks/desktop/views/disclosure.js +16 -17
- data/lib/frameworks/sproutcore/frameworks/desktop/views/list_item.js +278 -457
- data/lib/frameworks/sproutcore/frameworks/desktop/views/menu_item.js +5 -5
- data/lib/frameworks/sproutcore/frameworks/desktop/views/popup_button.js +101 -5
- data/lib/frameworks/sproutcore/frameworks/desktop/views/scroll.js +87 -85
- data/lib/frameworks/sproutcore/frameworks/desktop/views/scroller.js +278 -33
- data/lib/frameworks/sproutcore/frameworks/desktop/views/segmented.js +146 -60
- data/lib/frameworks/sproutcore/frameworks/desktop/views/select.js +80 -211
- data/lib/frameworks/sproutcore/frameworks/desktop/views/select_field.js +10 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/views/slider.js +34 -33
- data/lib/frameworks/sproutcore/frameworks/desktop/views/split.js +248 -331
- data/lib/frameworks/sproutcore/frameworks/desktop/views/static_content.js +12 -1
- data/lib/frameworks/sproutcore/frameworks/desktop/views/web.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/foundation/controllers/object.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/foundation/core.js +2 -33
- data/lib/frameworks/sproutcore/frameworks/foundation/ext/run_loop.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/foundation/license.js +11 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/button.js +6 -12
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/content_display.js +9 -4
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/control.js +1 -83
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/inline_text_field.js +7 -6
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/selection_support.js +4 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/panes/main.js +2 -1
- data/lib/frameworks/sproutcore/frameworks/foundation/panes/pane.js +107 -143
- data/lib/frameworks/sproutcore/frameworks/foundation/system/bundle.js +8 -4
- data/lib/frameworks/sproutcore/frameworks/foundation/system/core_query.js +4 -3
- data/lib/frameworks/sproutcore/frameworks/foundation/system/event.js +44 -33
- data/lib/frameworks/sproutcore/frameworks/foundation/system/exception_handler.js +85 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/system/image_cache.js +9 -9
- data/lib/frameworks/sproutcore/frameworks/foundation/system/platform.js +114 -6
- data/lib/frameworks/sproutcore/frameworks/foundation/system/ready.js +37 -38
- data/lib/frameworks/sproutcore/frameworks/foundation/system/render_context.js +5 -33
- data/lib/frameworks/sproutcore/frameworks/foundation/system/response.js +17 -19
- data/lib/frameworks/sproutcore/frameworks/foundation/system/root_responder.js +311 -255
- data/lib/frameworks/sproutcore/frameworks/foundation/system/routes.js +3 -3
- data/lib/frameworks/sproutcore/frameworks/foundation/system/task_queue.js +10 -10
- data/lib/frameworks/sproutcore/frameworks/foundation/system/utils.js +53 -44
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/button/keyEquivalents.js +17 -16
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/mixins/staticLayout.js +0 -1
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/end.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/helpers_style.js +3 -11
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/render_context/update.js +4 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/timer/invokeLater.js +5 -7
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/pane/sendEvent.js +41 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/text_field/ui.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/clippingFrame.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/createLayer.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/layoutStyle.js +56 -118
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/prepareContext.js +4 -12
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/render.js +5 -48
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/updateLayer.js +3 -3
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/updateLayerLocation.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/viewDidResize.js +2 -24
- data/lib/frameworks/sproutcore/frameworks/foundation/validators/date_time.js +2 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/views/field.js +3 -3
- data/lib/frameworks/sproutcore/frameworks/foundation/views/label.js +49 -21
- data/lib/frameworks/sproutcore/frameworks/foundation/views/text_field.js +85 -54
- data/lib/frameworks/sproutcore/frameworks/foundation/views/view.js +256 -1174
- data/lib/frameworks/sproutcore/frameworks/media/views/audio.js +81 -74
- data/lib/frameworks/sproutcore/frameworks/media/views/controls.js +2 -2
- data/lib/frameworks/sproutcore/frameworks/media/views/miniControls.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/mobile/tests/views/button/ui.js +1 -8
- data/lib/frameworks/sproutcore/frameworks/mobile/views/button.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/runtime/core.js +54 -25
- data/lib/frameworks/sproutcore/frameworks/runtime/mixins/array.js +1 -11
- data/lib/frameworks/sproutcore/frameworks/runtime/mixins/observable.js +8 -5
- data/lib/frameworks/sproutcore/frameworks/runtime/private/observer_queue.js +1 -1
- data/lib/frameworks/sproutcore/frameworks/runtime/private/observer_set.js +24 -25
- data/lib/frameworks/sproutcore/frameworks/runtime/system/binding.js +9 -6
- data/lib/frameworks/sproutcore/frameworks/runtime/system/object.js +13 -6
- data/lib/frameworks/sproutcore/frameworks/runtime/system/run_loop.js +26 -11
- data/lib/frameworks/sproutcore/frameworks/runtime/system/set.js +140 -33
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/core/guidFor.js +33 -0
- data/lib/frameworks/sproutcore/frameworks/runtime/tests/system/object/base.js +48 -1
- data/lib/frameworks/sproutcore/frameworks/statechart/mixins/statechart.js +2 -3
- data/lib/frameworks/sproutcore/frameworks/testing/system/runner.js +1 -1
- data/lib/frameworks/sproutcore/themes/standard_theme/english.lproj/scroller.css +8 -4
- data/lib/sproutcore/helpers/entry_sorter.rb +14 -1
- data/sproutcore.gemspec +0 -2
- metadata +12 -443
- data/lib/frameworks/sproutcore/Gemfile +0 -8
- data/lib/frameworks/sproutcore/Gemfile.lock +0 -33
- data/lib/frameworks/sproutcore/apps/test_controls/Buildfile +0 -0
- data/lib/frameworks/sproutcore/apps/test_controls/controllers/categories.js +0 -108
- data/lib/frameworks/sproutcore/apps/test_controls/controllers/category.js +0 -31
- data/lib/frameworks/sproutcore/apps/test_controls/core.js +0 -29
- data/lib/frameworks/sproutcore/apps/test_controls/main.js +0 -14
- data/lib/frameworks/sproutcore/apps/test_controls/resources/buttons_page.js +0 -124
- data/lib/frameworks/sproutcore/apps/test_controls/resources/checkboxes_page.js +0 -45
- data/lib/frameworks/sproutcore/apps/test_controls/resources/flow_layout_page.js +0 -77
- data/lib/frameworks/sproutcore/apps/test_controls/resources/list_page.js +0 -40
- data/lib/frameworks/sproutcore/apps/test_controls/resources/loading.rhtml +0 -9
- data/lib/frameworks/sproutcore/apps/test_controls/resources/main_page.css +0 -54
- data/lib/frameworks/sproutcore/apps/test_controls/resources/main_page.js +0 -136
- data/lib/frameworks/sproutcore/apps/test_controls/resources/progress_page.js +0 -42
- data/lib/frameworks/sproutcore/apps/test_controls/resources/radio_page.js +0 -41
- data/lib/frameworks/sproutcore/apps/test_controls/resources/scroll_page.js +0 -76
- data/lib/frameworks/sproutcore/apps/test_controls/resources/segmented_page.js +0 -75
- data/lib/frameworks/sproutcore/apps/test_controls/resources/select_page.js +0 -60
- data/lib/frameworks/sproutcore/apps/test_controls/resources/sliders_page.js +0 -53
- data/lib/frameworks/sproutcore/apps/test_controls/resources/strings.js +0 -50
- data/lib/frameworks/sproutcore/apps/test_controls/resources/tab_page.js +0 -15
- data/lib/frameworks/sproutcore/apps/test_controls/resources/text_field_page.js +0 -40
- data/lib/frameworks/sproutcore/apps/welcome/english.lproj/images/main-bg.png +0 -0
- data/lib/frameworks/sproutcore/bin/edit_json.rb +0 -14
- data/lib/frameworks/sproutcore/bin/erubis +0 -14
- data/lib/frameworks/sproutcore/bin/prettify_json.rb +0 -14
- data/lib/frameworks/sproutcore/bin/rackup +0 -14
- data/lib/frameworks/sproutcore/bin/rake2thor +0 -14
- data/lib/frameworks/sproutcore/bin/sc-build +0 -14
- data/lib/frameworks/sproutcore/bin/sc-build-number +0 -14
- data/lib/frameworks/sproutcore/bin/sc-docs +0 -14
- data/lib/frameworks/sproutcore/bin/sc-gen +0 -14
- data/lib/frameworks/sproutcore/bin/sc-init +0 -14
- data/lib/frameworks/sproutcore/bin/sc-manifest +0 -14
- data/lib/frameworks/sproutcore/bin/sc-server +0 -14
- data/lib/frameworks/sproutcore/bin/sproutcore +0 -14
- data/lib/frameworks/sproutcore/bin/thin +0 -14
- data/lib/frameworks/sproutcore/bin/thor +0 -14
- data/lib/frameworks/sproutcore/frameworks/desktop/mixins/navigation_builder.js +0 -130
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/button.js +0 -147
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/checkbox.js +0 -87
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/checkbox_control.js +0 -103
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/disclosure.js +0 -82
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/disclosure_control.js +0 -103
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/image_button.js +0 -33
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/list_item.js +0 -334
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/masterDetail.js +0 -23
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/panel.js +0 -34
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/picker.js +0 -50
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/segment.js +0 -79
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/segmented.js +0 -172
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/slider.js +0 -86
- data/lib/frameworks/sproutcore/frameworks/desktop/renderers/workspace.js +0 -22
- data/lib/frameworks/sproutcore/frameworks/desktop/views/file.js +0 -112
- data/lib/frameworks/sproutcore/frameworks/desktop/views/master_detail.js +0 -249
- data/lib/frameworks/sproutcore/frameworks/desktop/views/navigation.js +0 -237
- data/lib/frameworks/sproutcore/frameworks/desktop/views/navigation_bar.js +0 -181
- data/lib/frameworks/sproutcore/frameworks/desktop/views/workspace.js +0 -270
- data/lib/frameworks/sproutcore/frameworks/documentation/core.js +0 -0
- data/lib/frameworks/sproutcore/frameworks/forms/english.lproj/default_styles.css +0 -5
- data/lib/frameworks/sproutcore/frameworks/forms/english.lproj/strings.js +0 -15
- data/lib/frameworks/sproutcore/frameworks/forms/mixins/auto_hide.js +0 -85
- data/lib/frameworks/sproutcore/frameworks/forms/mixins/edit_mode.js +0 -43
- data/lib/frameworks/sproutcore/frameworks/forms/renderers/form.js +0 -24
- data/lib/frameworks/sproutcore/frameworks/forms/renderers/form_row.js +0 -24
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form.js +0 -15
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_checkbox_field.js +0 -15
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_field.js +0 -15
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_label.js +0 -15
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_radio_field.js +0 -15
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_row.js +0 -15
- data/lib/frameworks/sproutcore/frameworks/forms/tests/views/form_text_field.js +0 -15
- data/lib/frameworks/sproutcore/frameworks/forms/views/form.js +0 -266
- data/lib/frameworks/sproutcore/frameworks/forms/views/form_row.js +0 -188
- data/lib/frameworks/sproutcore/frameworks/foundation/english.lproj/images/sproutcore.png +0 -0
- data/lib/frameworks/sproutcore/frameworks/foundation/gestures/pinch.js +0 -81
- data/lib/frameworks/sproutcore/frameworks/foundation/gestures/swipe.js +0 -142
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/auto_mixin.js +0 -33
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/auto_resize.js +0 -74
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/flowed_layout.js +0 -415
- data/lib/frameworks/sproutcore/frameworks/foundation/mixins/gestureable.js +0 -106
- data/lib/frameworks/sproutcore/frameworks/foundation/renderers/control.js +0 -122
- data/lib/frameworks/sproutcore/frameworks/foundation/renderers/image.js +0 -51
- data/lib/frameworks/sproutcore/frameworks/foundation/renderers/label.js +0 -96
- data/lib/frameworks/sproutcore/frameworks/foundation/renderers/renderer.js +0 -316
- data/lib/frameworks/sproutcore/frameworks/foundation/renderers/title.js +0 -108
- data/lib/frameworks/sproutcore/frameworks/foundation/renderers/view.js +0 -62
- data/lib/frameworks/sproutcore/frameworks/foundation/system/gesture.js +0 -245
- data/lib/frameworks/sproutcore/frameworks/foundation/system/theme.js +0 -108
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/renderers/renderer/base.js +0 -170
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/renderers/renderer/inheritance.js +0 -39
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/system/theme.js +0 -86
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/pane/sendTouchEvent.js +0 -267
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/animation.js +0 -321
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/build.js +0 -85
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/build_children.js +0 -89
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/renderer.js +0 -443
- data/lib/frameworks/sproutcore/frameworks/foundation/tests/views/view/theme.js +0 -41
- data/lib/frameworks/sproutcore/frameworks/jquery/jquery.js +0 -6240
- data/lib/frameworks/sproutcore/frameworks/test +0 -77
- data/lib/frameworks/sproutcore/themes/ace/Buildfile +0 -0
- data/lib/frameworks/sproutcore/themes/ace/README.md +0 -161
- data/lib/frameworks/sproutcore/themes/ace/build +0 -2
- data/lib/frameworks/sproutcore/themes/ace/build-d +0 -2
- data/lib/frameworks/sproutcore/themes/ace/chance/README.md +0 -113
- data/lib/frameworks/sproutcore/themes/ace/chance/chance.rb +0 -203
- data/lib/frameworks/sproutcore/themes/ace/chance/lib/css.rb +0 -202
- data/lib/frameworks/sproutcore/themes/ace/chance/lib/slicedice.rb +0 -391
- data/lib/frameworks/sproutcore/themes/ace/chance/sc-theme.rb +0 -0
- data/lib/frameworks/sproutcore/themes/ace/chance/scripts/setup.rb +0 -126
- data/lib/frameworks/sproutcore/themes/ace/mockups/dark.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/mockups/dark.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/mockups/light.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/mockups/light.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/images/1.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/images/2.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/images/3.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/resources/theme.css +0 -1832
- data/lib/frameworks/sproutcore/themes/ace/scroll_test/resources/images/1.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/scroll_test/resources/images/2.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/scroll_test/resources/images/3.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/scroll_test/resources/theme.css +0 -147
- data/lib/frameworks/sproutcore/themes/ace/scroll_test/scrollbars.html +0 -326
- data/lib/frameworks/sproutcore/themes/ace/src/body.css +0 -13
- data/lib/frameworks/sproutcore/themes/ace/src/collections/list.css +0 -4
- data/lib/frameworks/sproutcore/themes/ace/src/collections/list_item.css +0 -7
- data/lib/frameworks/sproutcore/themes/ace/src/collections/source_list/selection.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/collections/source_list/selection.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/collections/source_list/source_list_view.css +0 -37
- data/lib/frameworks/sproutcore/themes/ace/src/containers/container.css +0 -3
- data/lib/frameworks/sproutcore/themes/ace/src/containers/masterdetail/master-detail.css +0 -26
- data/lib/frameworks/sproutcore/themes/ace/src/containers/split/split.css +0 -4
- data/lib/frameworks/sproutcore/themes/ace/src/containers/tab/tab.css +0 -9
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button.js +0 -23
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/button_view.css +0 -53
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/18px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/active_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/active_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/button_view.css +0 -144
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/normal_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/normal_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/normal_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/normal_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_active_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_active_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/24px/selected_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/button_view_30.css +0 -111
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/normal_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/normal_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/selected_active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/selected_active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/selected_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/30px/selected_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/button_view.css +0 -57
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/44px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/button_view/button_view.css +0 -56
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_closed.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_closed.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_closed_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_closed_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_open.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_open.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_open_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_open_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/buttons/disclosure_view/disclosure_view.css +0 -64
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox.css +0 -25
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_checked.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_checked.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_checked_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_checked_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_mixed.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_mixed.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_mixed_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_mixed_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_unchecked.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_unchecked.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_unchecked_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/14px/checkbox_unchecked_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox.css +0 -25
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_checked.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_checked.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_checked_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_checked_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_mixed.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_mixed.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_mixed_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_mixed_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_unchecked.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_unchecked.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_unchecked_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/16px/checkbox_unchecked_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/checkbox.css +0 -4
- data/lib/frameworks/sproutcore/themes/ace/src/controls/checkboxes/checkbox_control.css +0 -31
- data/lib/frameworks/sproutcore/themes/ace/src/controls/progress/progress_view/progress_view.css +0 -70
- data/lib/frameworks/sproutcore/themes/ace/src/controls/progress/progress_view/progress_view_content.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/progress/progress_view/progress_view_content.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/progress/progress_view/progress_view_indeterminate_content.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/progress/progress_view/progress_view_track.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/progress/progress_view/progress_view_track.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio.css +0 -61
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_mixed.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_mixed.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_mixed_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_mixed_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_unselected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/radio/radio_unselected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/horizontal/horizontal.css +0 -77
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/horizontal/thumb.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/horizontal/thumb.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/horizontal/track_and_arrows.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/horizontal/track_and_arrows.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/horizontal/track_and_arrows_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/horizontal/track_and_arrows_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/vertical.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/vertical/thumb.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/vertical/thumb.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/vertical/track_and_arrows.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/vertical/track_and_arrows.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/vertical/track_and_arrows_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/vertical/track_and_arrows_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/scroll/vertical/vertical.css +0 -74
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented.css +0 -92
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented_normal.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented_normal.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/18px/segmented_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented.css +0 -87
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented_normal.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented_normal.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/24px/segmented_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented.css +0 -93
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented_normal.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented_normal.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/30px/segmented_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented.css +0 -101
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented_normal.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented_normal.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented_selected.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented_selected.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented_selected_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/44px/segmented_selected_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/segmented.css +0 -73
- data/lib/frameworks/sproutcore/themes/ace/src/controls/segmented/segmented.js +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/select/active_select.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/select/active_select.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/select/menu.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/select/normal_select.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/select/normal_select.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/select/select.css +0 -45
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/14px/knob.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/14px/knob.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/14px/knob_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/14px/knob_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/14px/slider.css +0 -43
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/16px/knob.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/16px/knob.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/16px/knob_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/16px/knob_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/16px/slider.css +0 -44
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/22px/knob.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/22px/knob.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/22px/knob_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/22px/knob_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/22px/slider.css +0 -44
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/22px/track.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/22px/track.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/slider.css +0 -3
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/slider.js +0 -27
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/track.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/slider/track.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/switch/24px/switch.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/switch/24px/switch_handle.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/switch/24px/switch_handle.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/switch/24px/switch_off.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/switch/24px/switch_off.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/switch/24px/switch_on.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/controls/switch/24px/switch_on.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/core/loading.css +0 -50
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/active_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/active_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/button_view.css +0 -142
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/normal_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/normal_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/normal_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/normal_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_active_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_active_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_button_capsule.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_button_capsule.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/24px/selected_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/button_view_30.css +0 -111
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/normal_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/normal_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/normal_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/normal_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/selected_active_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/selected_active_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/selected_active_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/selected_active_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/selected_button.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/selected_button.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/selected_button_pointer.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/30px/selected_button_pointer.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/button.css +0 -20
- data/lib/frameworks/sproutcore/themes/ace/src/dark/buttons/button.js +0 -3
- data/lib/frameworks/sproutcore/themes/ace/src/form/iphone/form.js +0 -21
- data/lib/frameworks/sproutcore/themes/ace/src/form/iphone/form_row.js +0 -24
- data/lib/frameworks/sproutcore/themes/ace/src/form/iphone/iphone.css +0 -51
- data/lib/frameworks/sproutcore/themes/ace/src/form/iphone/iphone.js +0 -14
- data/lib/frameworks/sproutcore/themes/ace/src/form/iphone/label.js +0 -32
- data/lib/frameworks/sproutcore/themes/ace/src/panels/pane.css +0 -3
- data/lib/frameworks/sproutcore/themes/ace/src/panels/panel.css +0 -70
- data/lib/frameworks/sproutcore/themes/ace/src/panels/panel.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/panel.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/checkmark.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/checkmark.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/checkmark_active.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/checkmark_active.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/down.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/down.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/menu.css +0 -154
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/menu.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/menu.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/menu_item.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/menu_item.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/up.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/menu/up.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/picker.css +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/picker.js +0 -1
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/picker.js +0 -14
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover.css +0 -271
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover.js +0 -5
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_empty.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_empty.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_notoolbar.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_notoolbar.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_pointers.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_pointers.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_pointers_notoolbar.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_pointers_notoolbar.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/popover_sourcelist.css +0 -5
- data/lib/frameworks/sproutcore/themes/ace/src/panels/picker/popover/workspace.js +0 -51
- data/lib/frameworks/sproutcore/themes/ace/src/theme.js +0 -12
- data/lib/frameworks/sproutcore/themes/ace/src/toolbars/normal/selection.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/toolbars/normal/toolbar.css +0 -8
- data/lib/frameworks/sproutcore/themes/ace/src/toolbars/normal/toolbar.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/toolbars/normal/toolbar.psd +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/toolbars/panel_header/panel_header.png +0 -0
- data/lib/frameworks/sproutcore/themes/ace/src/toolbars/panel_header/panel_header.psd +0 -0
- data/lib/frameworks/sproutcore/themes/empty_theme/theme.js +0 -16
@@ -1,202 +0,0 @@
|
|
1
|
-
require 'set'
|
2
|
-
require 'base64'
|
3
|
-
class CSSParser
|
4
|
-
attr_accessor :images, :contents, :static_images
|
5
|
-
def initialize(directory, file, config)
|
6
|
-
@directory = directory
|
7
|
-
@file = file
|
8
|
-
@theme = ""
|
9
|
-
if !config[:theme_name].nil?
|
10
|
-
@theme = "." + config[:theme_name]
|
11
|
-
end
|
12
|
-
@config = config
|
13
|
-
@images = { }
|
14
|
-
@static_images = { }
|
15
|
-
end
|
16
|
-
|
17
|
-
def parse
|
18
|
-
# first, read file
|
19
|
-
file = File.new(@directory + "/" + @file)
|
20
|
-
contents = ""
|
21
|
-
file.each {|line| contents += line}
|
22
|
-
@contents = contents
|
23
|
-
|
24
|
-
self.parse_rules
|
25
|
-
self.parse_sprites
|
26
|
-
end
|
27
|
-
|
28
|
-
def parse_rules
|
29
|
-
# parses @theme "name"
|
30
|
-
# and @view(viewname)
|
31
|
-
contents = @contents
|
32
|
-
|
33
|
-
view_rule = /(@view|@theme|@end)(\(\s*(["']{2}|["'].*?[^\\]"|[^\s]+)\s*\))?;?/
|
34
|
-
|
35
|
-
theme_name = @theme
|
36
|
-
theme_parts = [theme_name]
|
37
|
-
contents.gsub!(view_rule) do |match|
|
38
|
-
#".sc-view." + $1 + "." + theme_name # If SproutCore changes some
|
39
|
-
if $1 == "@view"
|
40
|
-
tn = ""
|
41
|
-
if @config[:include_sc_theme]
|
42
|
-
tn = ".sc-theme "
|
43
|
-
end
|
44
|
-
tn + ".sc-view" + theme_name + "." + $3
|
45
|
-
elsif $1 == "@theme"
|
46
|
-
theme_parts.push $3
|
47
|
-
theme_name = theme_parts.join "."
|
48
|
-
""
|
49
|
-
elsif $1 == "@end"
|
50
|
-
theme_parts.pop
|
51
|
-
theme_name = theme_parts.join "."
|
52
|
-
""
|
53
|
-
end
|
54
|
-
end
|
55
|
-
|
56
|
-
boxshadow_rule = /\-sc\-box\-shadow:\s*([^;]*)/
|
57
|
-
contents.gsub!(boxshadow_rule) do |match|
|
58
|
-
"-moz-box-shadow: " + $1 + "; -webkit-box-shadow: " + $1 + "; box-shadow: " + $1
|
59
|
-
end
|
60
|
-
|
61
|
-
borderradius_rule = /\-sc\-border\-radius:\s*([^;]*)/
|
62
|
-
contents.gsub!(borderradius_rule) do |match|
|
63
|
-
"-moz-border-radius: " + $1 + "; -webkit-border-radius: " + $1 + "; border-radius: " + $1
|
64
|
-
end
|
65
|
-
|
66
|
-
borderradius_topleft_rule = /\-sc\-border\-top\-left\-radius:\s*([^;]*)/
|
67
|
-
contents.gsub!(borderradius_topleft_rule) do |match|
|
68
|
-
"-moz-border-radius-topleft: " + $1 + "; -webkit-border-top-left-radius: " + $1 + "; border-top-left-radius: " + $1
|
69
|
-
end
|
70
|
-
|
71
|
-
borderradius_topright_rule = /\-sc\-border\-top\-right\-radius:\s*([^;]*)/
|
72
|
-
contents.gsub!(borderradius_topright_rule) do |match|
|
73
|
-
"-moz-border-radius-topright: " + $1 + "; -webkit-border-top-right-radius: " + $1 + "; border-top-right-radius: " + $1
|
74
|
-
end
|
75
|
-
|
76
|
-
borderradius_bottomleft_rule = /\-sc\-border\-bottom\-left\-radius:\s*([^;]*)/
|
77
|
-
contents.gsub!(borderradius_bottomleft_rule) do |match|
|
78
|
-
"-moz-border-radius-bottomleft: " + $1 + "; -webkit-border-bottom-left-radius: " + $1 + "; border-bottom-left-radius: " + $1
|
79
|
-
end
|
80
|
-
|
81
|
-
borderradius_bottomright_rule = /\-sc\-border\-bottom\-right\-radius:\s*([^;]*)/
|
82
|
-
contents.gsub!(borderradius_bottomright_rule) do |match|
|
83
|
-
"-moz-border-radius-bottomright: " + $1 + "; -webkit-border-bottom-right-radius: " + $1 + "; border-bottom-right-radius: " + $1
|
84
|
-
end
|
85
|
-
|
86
|
-
@contents = contents
|
87
|
-
end
|
88
|
-
|
89
|
-
def parse_sprites
|
90
|
-
contents = @contents
|
91
|
-
|
92
|
-
# A whole regexp would include: ([\s,]+(repeat-x|repeat-y))?([\s,]+\[(.*)\])?
|
93
|
-
# but let's keep it simple:
|
94
|
-
sprite_directive = /(sprite|static_url)\(\s*(["']{2}|["'].*?[^\\]['"]|[^\s]+)(.*?)\s*\)/
|
95
|
-
contents = contents.gsub(sprite_directive) do | match |
|
96
|
-
# prepare replacement string
|
97
|
-
replace_with_prefix = "sprite_for("
|
98
|
-
replace_with_suffix = ")"
|
99
|
-
|
100
|
-
# get name and add to replacement
|
101
|
-
type = $1
|
102
|
-
image_name = $2
|
103
|
-
args = $3
|
104
|
-
image_name = $2.sub(/^["'](.*)["']$/, '\1')
|
105
|
-
|
106
|
-
result_hash = {
|
107
|
-
:path => File.expand_path(@directory + "/" + image_name), :image => image_name,
|
108
|
-
:repeat => "no-repeat", :rect => [], :target => "",
|
109
|
-
:anchor => :none, :clear => false, :nosprite => (type == "static_url")
|
110
|
-
}
|
111
|
-
|
112
|
-
# Replacement string is made to be replaced again in a second pass
|
113
|
-
# first pass generates manifest, second pass actually puts sprite info in.
|
114
|
-
|
115
|
-
# match: key words (Separated by whitespace) or rects.
|
116
|
-
args.scan(/(\[.*?\]|[^\s]+)/) {|r|
|
117
|
-
arg = $1.strip
|
118
|
-
|
119
|
-
if arg.match(/^\[/)
|
120
|
-
# A rectangle specifying a slice
|
121
|
-
full_rect = []
|
122
|
-
params = arg.gsub(/^\[|\]$/, "").split(/[,\s]+/)
|
123
|
-
if params.length == 1
|
124
|
-
full_rect = [params[0].to_i, 0, 0, 0]
|
125
|
-
elsif params.length == 2
|
126
|
-
full_rect = [params[0].to_i, 0, params[1].to_i, 0]
|
127
|
-
elsif params.length == 4
|
128
|
-
full_rect = params.map {|e| e.to_i}
|
129
|
-
else
|
130
|
-
|
131
|
-
end
|
132
|
-
|
133
|
-
result_hash[:rect] = full_rect
|
134
|
-
else
|
135
|
-
# a normal keyword, probably.
|
136
|
-
if arg == "repeat-x"
|
137
|
-
result_hash[:repeat] = "repeat-x"
|
138
|
-
elsif arg == "repeat-y"
|
139
|
-
result_hash[:repeat] = "repeat-y"
|
140
|
-
elsif arg == "anchor-right"
|
141
|
-
result_hash[:anchor] = :right
|
142
|
-
elsif arg == "anchor-left"
|
143
|
-
result_hash[:anchor] = :left
|
144
|
-
elsif arg == "clear"
|
145
|
-
result_hash[:clear] = true
|
146
|
-
end
|
147
|
-
end
|
148
|
-
}
|
149
|
-
|
150
|
-
image_key = result_hash[:repeat] + ":" + result_hash[:rect].join(",") + ":" + result_hash[:path]
|
151
|
-
replace_with = replace_with_prefix + image_key + replace_with_suffix
|
152
|
-
@images[image_key] = result_hash
|
153
|
-
|
154
|
-
replace_with
|
155
|
-
end
|
156
|
-
|
157
|
-
@contents = contents
|
158
|
-
end
|
159
|
-
|
160
|
-
def generate
|
161
|
-
contents = @contents
|
162
|
-
contents = contents.gsub(/sprite_for\(\s*(["']{2}|["'].*?[^\\]["']|.*?)\s*\)/) {|match|
|
163
|
-
key = $1
|
164
|
-
result = ""
|
165
|
-
if @images.key? key
|
166
|
-
image = @images[key]
|
167
|
-
|
168
|
-
# if it is not sprited or we are not doing data urls, we use the url template.
|
169
|
-
if image[:nosprite] or not @config[:use_data_url]
|
170
|
-
result = (@config[:url_template] % [image[:sprite_path]])
|
171
|
-
else
|
172
|
-
# otherwise, we need to use a data url.
|
173
|
-
data = image[:image].to_blob
|
174
|
-
data = Base64.encode64(data)
|
175
|
-
data = data.gsub(/[ \n]/, '')
|
176
|
-
|
177
|
-
result = "url(\'data:image/png;base64,#{data}\')"
|
178
|
-
end
|
179
|
-
|
180
|
-
# Only put repeat data if not sprited
|
181
|
-
if not image[:nosprite]
|
182
|
-
result += " #{image[:repeat]}"
|
183
|
-
|
184
|
-
if not @config[:use_data_url]
|
185
|
-
if image[:anchor] == :none
|
186
|
-
result += image[:sprite_x] == 0 ? " #{image[:sprite_x]}" : " -#{image[:sprite_x]}px"
|
187
|
-
else
|
188
|
-
result += (image[:anchor] == :right ? " right" : " left")
|
189
|
-
end
|
190
|
-
result += image[:sprite_y] == 0 ? " #{image[:sprite_y]}" : " -#{image[:sprite_y]}px"
|
191
|
-
end
|
192
|
-
end
|
193
|
-
|
194
|
-
else
|
195
|
-
puts "Did not find image with key: ", key
|
196
|
-
end
|
197
|
-
|
198
|
-
result
|
199
|
-
}
|
200
|
-
return contents
|
201
|
-
end
|
202
|
-
end
|
@@ -1,391 +0,0 @@
|
|
1
|
-
# The Slicer object takes a set of images and slices them as needed, producing a set of images
|
2
|
-
# located in a hierarchy (for debugging purposes) in the output directory.
|
3
|
-
# The name will be: (output)/path/to/image.png_slice_rect_here.png
|
4
|
-
require 'rubygems'
|
5
|
-
require 'RMagick'
|
6
|
-
require 'FileUtils'
|
7
|
-
require 'pp'
|
8
|
-
|
9
|
-
class Slicer
|
10
|
-
attr_accessor :images
|
11
|
-
|
12
|
-
def initialize(config)
|
13
|
-
@config = config
|
14
|
-
@output_dir = config[:output]
|
15
|
-
@optimization_limit = config[:optimization_limit]
|
16
|
-
end
|
17
|
-
|
18
|
-
# slice performs the slicing operations, putting the images in the output directory
|
19
|
-
def slice
|
20
|
-
config = @config
|
21
|
-
|
22
|
-
image_set = []
|
23
|
-
@images.each do |key, definition|
|
24
|
-
path = definition[:path]
|
25
|
-
|
26
|
-
x, y, width, height = 0, 0, 0, 0
|
27
|
-
if definition[:rect].length > 0
|
28
|
-
x, y, width, height = definition[:rect]
|
29
|
-
end
|
30
|
-
|
31
|
-
|
32
|
-
print "Processing " + path + "...\n"
|
33
|
-
|
34
|
-
begin
|
35
|
-
images = Magick::ImageList.new(path)
|
36
|
-
if images.length < 1
|
37
|
-
print "Could not open; length: ", images.length, "\n"
|
38
|
-
next
|
39
|
-
end
|
40
|
-
rescue
|
41
|
-
print "Could not open the file.\n"
|
42
|
-
next
|
43
|
-
end
|
44
|
-
|
45
|
-
image = images[0]
|
46
|
-
|
47
|
-
image_width, image_height = image.columns, image.rows
|
48
|
-
if x < 0 then x = image_width + x end
|
49
|
-
if y < 0 then y = image_height + y end
|
50
|
-
if width == 0 then width = image_width - x end
|
51
|
-
if height == 0 then height = image_height - y end
|
52
|
-
|
53
|
-
# Crop image
|
54
|
-
result = image.crop(x, y, width, height).modulate(config[:brightness], config[:saturation], config[:hue])
|
55
|
-
|
56
|
-
# Write image: Skipped because we never read it back from disk
|
57
|
-
# Besides, not good to put it in resources/, where it will get added to the build.
|
58
|
-
# FileUtils.mkdir_p @output_dir + "slices/" + File.dirname(path)
|
59
|
-
# slice_path = @output_dir + "slices/" + path + "_" + [x, y, width, height].join("_") + ".png"
|
60
|
-
# result.write(slice_path)
|
61
|
-
|
62
|
-
# update definition
|
63
|
-
definition[:width] = width
|
64
|
-
definition[:height] = height
|
65
|
-
definition[:key] = key
|
66
|
-
definition[:image] = result
|
67
|
-
|
68
|
-
# add to new images collection
|
69
|
-
image_set << definition
|
70
|
-
end
|
71
|
-
|
72
|
-
@image_list = image_set
|
73
|
-
end
|
74
|
-
|
75
|
-
# dice seems like it should continue that, but I just named it dice for fun. It really sprites things.
|
76
|
-
def dice
|
77
|
-
# For each target, for each try, plan out normal, x-repeat, and y-repeat.
|
78
|
-
# Write out images for each target named target.png, target-x.png, and target-y.png.
|
79
|
-
|
80
|
-
# Each "try" is a set of settings with which to attempt to generate a plan.
|
81
|
-
# The wasted space that is returned with the plan is used to determine which try to use.
|
82
|
-
# The spriter will usually try a x-repeat with the normal images first, then separate.
|
83
|
-
# A certain amount of leeway should be given when X-repeat and normal are combined (an amount
|
84
|
-
# of wasted space past which it would be impractical to keep them in the same file)
|
85
|
-
#
|
86
|
-
# Settings work as follows: an aim parameter specifies a multiple of a) the image width
|
87
|
-
# b) the least common multiplier of all repeat pattern widths.
|
88
|
-
tries = []
|
89
|
-
10.times {|i| tries << {:aim=>i + 1} }
|
90
|
-
|
91
|
-
images = @image_list
|
92
|
-
|
93
|
-
sprites = images.select {|v| not v[:nosprite] }
|
94
|
-
nonsprites = images.select {|v| v[:nosprite] }
|
95
|
-
|
96
|
-
ximages = sprites.select {|v| v[:repeat] == "repeat-x" }
|
97
|
-
yimages = sprites.select {|v| v[:repeat] == "repeat-y" }
|
98
|
-
nimages = sprites.select {|v| v[:repeat] == "no-repeat" }
|
99
|
-
|
100
|
-
plans = []
|
101
|
-
tries.each {|try|
|
102
|
-
# we will have either 2 or three images in any case. So,
|
103
|
-
# we need to pick the best case: the smallest possible primary image.
|
104
|
-
plans << [self.plan(ximages + nimages, try), self.yplan(yimages)]
|
105
|
-
plans << [self.plan(nimages, try), self.plan(ximages, try), self.yplan(yimages)]
|
106
|
-
|
107
|
-
}
|
108
|
-
|
109
|
-
# sort by wasted space. The least wasted is the one we want.
|
110
|
-
plans.sort! {|a, b|
|
111
|
-
total_wasted_a = 0
|
112
|
-
total_wasted_b = 0
|
113
|
-
a.each {|e| total_wasted_a += e[:wasted] }
|
114
|
-
b.each {|e| total_wasted_b += e[:wasted] }
|
115
|
-
|
116
|
-
total_wasted_a -= @optimization_limit if a.length < 3
|
117
|
-
total_wasted_b -= @optimization_limit if b.length < 3
|
118
|
-
total_wasted_a <=> total_wasted_b
|
119
|
-
}
|
120
|
-
|
121
|
-
# Best plan is plan 0.
|
122
|
-
planset = plans[0]
|
123
|
-
new_image_hash = {}
|
124
|
-
total_wasted = 0
|
125
|
-
i = 0
|
126
|
-
|
127
|
-
FileUtils.mkdir_p @output_dir + "images/"
|
128
|
-
|
129
|
-
# Write static
|
130
|
-
nonsprites.each {|nonsprite|
|
131
|
-
i += 1
|
132
|
-
filename = i.to_s + ".png"
|
133
|
-
nonsprite[:sprite_path] = "images/" + filename
|
134
|
-
new_image_hash[nonsprite[:key]] = nonsprite
|
135
|
-
nonsprite[:image].write(@output_dir + "images/" + filename)
|
136
|
-
}
|
137
|
-
|
138
|
-
# Write plan
|
139
|
-
planset.each {|plan|
|
140
|
-
if not (plan and plan[:width] and plan[:width] > 0)
|
141
|
-
next
|
142
|
-
end
|
143
|
-
target_image = Magick::Image.new(plan[:width], plan[:height]) {
|
144
|
-
self.background_color = "transparent"
|
145
|
-
}
|
146
|
-
|
147
|
-
i += 1
|
148
|
-
filename = i.to_s + ".png"
|
149
|
-
|
150
|
-
plan[:plan].each {|image|
|
151
|
-
cols = image[:image].columns
|
152
|
-
rows = image[:image].rows
|
153
|
-
written_x = 0
|
154
|
-
written_y = 0
|
155
|
-
|
156
|
-
image[:sprite_path] = "images/" + filename
|
157
|
-
image[:sprite_x] = image[:x] # just to be as specific as possible
|
158
|
-
image[:sprite_y] = image[:y]
|
159
|
-
new_image_hash[image[:key]] = image
|
160
|
-
|
161
|
-
# loop through plan
|
162
|
-
while written_y < image[:height] do
|
163
|
-
while written_x < image[:width] do
|
164
|
-
target_image.composite!(image[:image], image[:x] + written_x, image[:y] + written_y, Magick::CopyCompositeOp)
|
165
|
-
written_x += [cols, image[:width]].min
|
166
|
-
end
|
167
|
-
written_y += [rows, image[:height]].min
|
168
|
-
end
|
169
|
-
}
|
170
|
-
|
171
|
-
target_image.write(@output_dir + "images/" + filename)
|
172
|
-
total_wasted += plan[:wasted]
|
173
|
-
}
|
174
|
-
|
175
|
-
print "Wasted pixels: ", total_wasted, "\n"
|
176
|
-
@images = new_image_hash
|
177
|
-
end
|
178
|
-
|
179
|
-
# Plan the y-repeat images
|
180
|
-
def yplan(images)
|
181
|
-
# we go in direction: settings[:direction]. We sort the images first, biggest to smallest
|
182
|
-
# based on their directional size (i.e. width for horizontal).
|
183
|
-
# the first image in the sorted set is used to figure out the width or height of the image
|
184
|
-
# (also using the config's units prop)
|
185
|
-
wasted_pixels = 0
|
186
|
-
plan = [] # images
|
187
|
-
|
188
|
-
# Handle no images
|
189
|
-
if images.length < 1
|
190
|
-
return {:wasted=>0, :plan=>plan}
|
191
|
-
end
|
192
|
-
|
193
|
-
# sort images
|
194
|
-
images = images.sort {|a, b|
|
195
|
-
b[:width] <=> a[:width]
|
196
|
-
}
|
197
|
-
|
198
|
-
lcm = 1
|
199
|
-
images.each {|image|
|
200
|
-
lcm = lcm.lcm image[:height]
|
201
|
-
}
|
202
|
-
|
203
|
-
|
204
|
-
x = 0
|
205
|
-
total_height = lcm
|
206
|
-
|
207
|
-
# loop through images
|
208
|
-
images.each {|image|
|
209
|
-
width = image[:width]
|
210
|
-
height = image[:height]
|
211
|
-
|
212
|
-
img = image.dup
|
213
|
-
|
214
|
-
# Set position
|
215
|
-
img[:x] = x
|
216
|
-
img[:y] = 0
|
217
|
-
|
218
|
-
# handle repeated images
|
219
|
-
img[:height] = total_height
|
220
|
-
wasted_pixels += (total_height - height) * width
|
221
|
-
|
222
|
-
# width!
|
223
|
-
img[:width] = width
|
224
|
-
|
225
|
-
# add to plan
|
226
|
-
plan << img
|
227
|
-
|
228
|
-
|
229
|
-
x += img[:width]
|
230
|
-
}
|
231
|
-
|
232
|
-
return {:plan=>plan, :width => x, :height => total_height, :wasted=>wasted_pixels}
|
233
|
-
end
|
234
|
-
|
235
|
-
# Settings={:direction=>}
|
236
|
-
# Returns: {:wasted=>percent, :plan=>collection of clones of image hashes w/plan setings }
|
237
|
-
# Wasted is the amount of a) empty space and b) extra space used by repeating patterns.
|
238
|
-
# The width of the image is either a) the width of the
|
239
|
-
def plan(images, settings)
|
240
|
-
# the first image in the sorted set is used to figure out the width or height of the image
|
241
|
-
wasted_pixels = 0
|
242
|
-
plan = [] # images
|
243
|
-
|
244
|
-
# Handle no images
|
245
|
-
if images.length < 1
|
246
|
-
return {:wasted=>0, :plan=>plan}
|
247
|
-
end
|
248
|
-
|
249
|
-
# sort images
|
250
|
-
images = images.sort {|a, b|
|
251
|
-
res = b[:repeat] <=> a[:repeat] # keep non-repeats together (at begin).
|
252
|
-
if res == 0
|
253
|
-
res = b[:width] <=> a[:width]
|
254
|
-
if res == 0
|
255
|
-
res = b[:height] <=> a[:height] # sort these to get like ones together
|
256
|
-
end
|
257
|
-
end
|
258
|
-
res
|
259
|
-
}
|
260
|
-
|
261
|
-
# Select images
|
262
|
-
normal_images = images.select {|i|
|
263
|
-
i[:anchor] == :none
|
264
|
-
}
|
265
|
-
anchor_left_images = images.select {|i|
|
266
|
-
i[:anchor] == :left
|
267
|
-
}
|
268
|
-
anchor_right_images = images.select {|i|
|
269
|
-
i[:anchor] == :right #or i[:clear] this was causing duplication if a left anchored image was also cleared :)
|
270
|
-
}
|
271
|
-
|
272
|
-
max = 0
|
273
|
-
lcm = 1
|
274
|
-
images.each {|image|
|
275
|
-
max = [max, image[:width]].max
|
276
|
-
if image[:repeat] == "repeat-x"
|
277
|
-
lcm = lcm.lcm image[:width]
|
278
|
-
end
|
279
|
-
}
|
280
|
-
|
281
|
-
# get unit (row/col) size
|
282
|
-
unit_size = max
|
283
|
-
unit_size = unit_size.lcm lcm
|
284
|
-
|
285
|
-
total_width = unit_size * settings[:aim] # 1 is probably best... but we try many :)
|
286
|
-
x = 0
|
287
|
-
y = 0 # the current total secondary
|
288
|
-
|
289
|
-
# loop through images. Each iteration represents a single row.
|
290
|
-
while normal_images.length > 0 or anchor_left_images.length > 0 or anchor_right_images.length > 0
|
291
|
-
x = 0
|
292
|
-
row_height = 0
|
293
|
-
row_space = total_width
|
294
|
-
|
295
|
-
# Very first thing: handle repeat-x
|
296
|
-
if normal_images.length > 0 and normal_images[0][:repeat] == "repeat-x"
|
297
|
-
img = normal_images.shift.dup
|
298
|
-
normal_width = img[:width]
|
299
|
-
img[:width] = total_width
|
300
|
-
img[:x] = 0
|
301
|
-
img[:y] = y
|
302
|
-
plan << img
|
303
|
-
|
304
|
-
wasted_pixels += (total_width - normal_width) * (img[:height])
|
305
|
-
row_space = 0
|
306
|
-
row_height = img[:height]
|
307
|
-
end
|
308
|
-
|
309
|
-
# fit in anchor left first, if any
|
310
|
-
left = anchor_left_images[0]
|
311
|
-
if left and left[:width] <= row_space
|
312
|
-
left = anchor_left_images.shift
|
313
|
-
left = left.dup
|
314
|
-
left[:x] = 0
|
315
|
-
left[:y] = y
|
316
|
-
plan << left
|
317
|
-
|
318
|
-
x += left[:width]
|
319
|
-
row_height = [row_height, left[:height]].max
|
320
|
-
row_space -= left[:width]
|
321
|
-
|
322
|
-
row_space = 0 if left[:clear]
|
323
|
-
end
|
324
|
-
|
325
|
-
# now anchor right
|
326
|
-
right = anchor_right_images[0]
|
327
|
-
if right and right[:width] <= row_space
|
328
|
-
right = anchor_right_images.shift
|
329
|
-
right = right.dup
|
330
|
-
right[:x] = total_width - right[:width]
|
331
|
-
right[:y] = y
|
332
|
-
plan << right
|
333
|
-
|
334
|
-
row_height = [row_height, right[:height]].max
|
335
|
-
row_space -= right[:width]
|
336
|
-
row_space = 0 if right[:clear]
|
337
|
-
end
|
338
|
-
|
339
|
-
# Find first (largest) image that will fit
|
340
|
-
put_any = false
|
341
|
-
processed = []
|
342
|
-
normal_images.each {|e|
|
343
|
-
# skip those that can't fit
|
344
|
-
if e[:repeat] == "repeat-x" or e[:width] > row_space
|
345
|
-
next
|
346
|
-
end
|
347
|
-
|
348
|
-
# Get image
|
349
|
-
processed.push(e)
|
350
|
-
img = e.dup
|
351
|
-
|
352
|
-
# Set position
|
353
|
-
img[:x] = x
|
354
|
-
img[:y] = y
|
355
|
-
|
356
|
-
# add to plan
|
357
|
-
plan << img
|
358
|
-
|
359
|
-
x += img[:width]
|
360
|
-
row_space -= img[:width]
|
361
|
-
row_space = 0 if img[:clear]
|
362
|
-
row_height = [row_height, img[:height]].max
|
363
|
-
|
364
|
-
# If there isn't ANY space, just stop.
|
365
|
-
break if row_space == 0
|
366
|
-
}
|
367
|
-
processed.each {|e| normal_images.delete(e) }
|
368
|
-
|
369
|
-
while normal_images.length > 0 and normal_images[0][:repeat] != "repeat-x" and normal_images[0][:width] <= row_space
|
370
|
-
img = normal_images.shift.dup
|
371
|
-
|
372
|
-
# Set position
|
373
|
-
img[:x] = x
|
374
|
-
img[:y] = y
|
375
|
-
|
376
|
-
# add to plan
|
377
|
-
plan << img
|
378
|
-
|
379
|
-
x += img[:width]
|
380
|
-
row_space -= img[:width]
|
381
|
-
row_space = 0 if img[:clear]
|
382
|
-
row_height = [row_height, img[:height]].max
|
383
|
-
end
|
384
|
-
|
385
|
-
wasted_pixels += row_height * row_space # empty space: free in PNG? Well, not for now, it isn't.
|
386
|
-
y += row_height
|
387
|
-
end
|
388
|
-
|
389
|
-
return {:plan=>plan, :width => total_width, :height => y, :wasted=>wasted_pixels}
|
390
|
-
end
|
391
|
-
end
|