k4compiler 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +20 -0
- data/.gitmodules +3 -0
- data/.rspec +2 -0
- data/Gemfile +4 -0
- data/Guardfile +8 -0
- data/LICENSE.txt +22 -0
- data/README.md +29 -0
- data/Rakefile +1 -0
- data/k4compiler.gemspec +50 -0
- data/lib/k4compiler.rb +26 -0
- data/lib/k4compiler/compiler.rb +41 -0
- data/lib/k4compiler/compiler/base.rb +24 -0
- data/lib/k4compiler/compiler/closure.rb +96 -0
- data/lib/k4compiler/compiler/markdown.rb +78 -0
- data/lib/k4compiler/compiler/scss.rb +31 -0
- data/lib/k4compiler/config.rb +59 -0
- data/lib/k4compiler/version.rb +3 -0
- data/spec/k4compiler/compiler/base_spec.rb +40 -0
- data/spec/k4compiler/compiler/closure/compiled-src/hello-with-closure-compiled-script.js +18317 -0
- data/spec/k4compiler/compiler/closure/src/hello-compiled-script.js +15 -0
- data/spec/k4compiler/compiler/closure/src/hello-with-closure.js +15 -0
- data/spec/k4compiler/compiler/closure/src/hello.js +15 -0
- data/spec/k4compiler/compiler/closure_spec.rb +159 -0
- data/spec/k4compiler/compiler/markdown_spec.rb +153 -0
- data/spec/k4compiler/compiler/scss/_body.scss +5 -0
- data/spec/k4compiler/compiler/scss/sample.scss +9 -0
- data/spec/k4compiler/compiler/scss_spec.rb +70 -0
- data/spec/k4compiler/compiler_spec.rb +75 -0
- data/spec/k4compiler/config_spec.rb +116 -0
- data/spec/k4compiler_spec.rb +17 -0
- data/spec/spec_helper.rb +8 -0
- data/third_party/.gitkeep +1 -0
- data/third_party/closure-compiler-20130603/COPYING +202 -0
- data/third_party/closure-compiler-20130603/README +292 -0
- data/third_party/closure-compiler-20130603/compiler.jar +0 -0
- data/third_party/closure-library/.gitignore +12 -0
- data/third_party/closure-library/AUTHORS +17 -0
- data/third_party/closure-library/CONTRIBUTING +5 -0
- data/third_party/closure-library/LICENSE +176 -0
- data/third_party/closure-library/README +6 -0
- data/third_party/closure-library/all_tests.html +113 -0
- data/third_party/closure-library/alltests.js +16 -0
- data/third_party/closure-library/closure/bin/build/closurebuilder.py +262 -0
- data/third_party/closure-library/closure/bin/build/depstree.py +189 -0
- data/third_party/closure-library/closure/bin/build/depstree_test.py +127 -0
- data/third_party/closure-library/closure/bin/build/depswriter.py +202 -0
- data/third_party/closure-library/closure/bin/build/jscompiler.py +135 -0
- data/third_party/closure-library/closure/bin/build/jscompiler_test.py +120 -0
- data/third_party/closure-library/closure/bin/build/source.py +121 -0
- data/third_party/closure-library/closure/bin/build/source_test.py +134 -0
- data/third_party/closure-library/closure/bin/build/treescan.py +78 -0
- data/third_party/closure-library/closure/bin/calcdeps.py +590 -0
- data/third_party/closure-library/closure/bin/labs/code/generate_jsdoc.py +171 -0
- data/third_party/closure-library/closure/bin/labs/code/generate_jsdoc_test.py +167 -0
- data/third_party/closure-library/closure/bin/labs/code/run_py_tests.sh +28 -0
- data/third_party/closure-library/closure/bin/scopify.py +211 -0
- data/third_party/closure-library/closure/css/inlay/g-base.css +82 -0
- data/third_party/closure-library/closure/css/inlay/g-fixed.css +173 -0
- data/third_party/closure-library/closure/css/inlay/g-ratio.css +253 -0
- data/third_party/closure-library/closure/goog/a11y/aria/announcer.js +108 -0
- data/third_party/closure-library/closure/goog/a11y/aria/announcer_test.html +97 -0
- data/third_party/closure-library/closure/goog/a11y/aria/aria.js +362 -0
- data/third_party/closure-library/closure/goog/a11y/aria/aria_test.html +263 -0
- data/third_party/closure-library/closure/goog/a11y/aria/attributes.js +389 -0
- data/third_party/closure-library/closure/goog/a11y/aria/datatables.js +68 -0
- data/third_party/closure-library/closure/goog/a11y/aria/roles.js +216 -0
- data/third_party/closure-library/closure/goog/array/array.js +1507 -0
- data/third_party/closure-library/closure/goog/array/array_test.html +1674 -0
- data/third_party/closure-library/closure/goog/asserts/asserts.js +293 -0
- data/third_party/closure-library/closure/goog/asserts/asserts_test.html +178 -0
- data/third_party/closure-library/closure/goog/async/animationdelay.js +270 -0
- data/third_party/closure-library/closure/goog/async/animationdelay_test.html +93 -0
- data/third_party/closure-library/closure/goog/async/conditionaldelay.js +235 -0
- data/third_party/closure-library/closure/goog/async/conditionaldelay_test.html +227 -0
- data/third_party/closure-library/closure/goog/async/delay.js +177 -0
- data/third_party/closure-library/closure/goog/async/delay_test.html +148 -0
- data/third_party/closure-library/closure/goog/async/nexttick.js +174 -0
- data/third_party/closure-library/closure/goog/async/nexttick_test.html +137 -0
- data/third_party/closure-library/closure/goog/async/throttle.js +189 -0
- data/third_party/closure-library/closure/goog/async/throttle_test.html +102 -0
- data/third_party/closure-library/closure/goog/base.js +1593 -0
- data/third_party/closure-library/closure/goog/base_test.html +1206 -0
- data/third_party/closure-library/closure/goog/bootstrap/nodejs.js +91 -0
- data/third_party/closure-library/closure/goog/bootstrap/webworkers.js +37 -0
- data/third_party/closure-library/closure/goog/color/alpha.js +467 -0
- data/third_party/closure-library/closure/goog/color/alpha_test.html +301 -0
- data/third_party/closure-library/closure/goog/color/color.js +773 -0
- data/third_party/closure-library/closure/goog/color/color_test.html +661 -0
- data/third_party/closure-library/closure/goog/color/names.js +176 -0
- data/third_party/closure-library/closure/goog/crypt/aes.js +1027 -0
- data/third_party/closure-library/closure/goog/crypt/aes_test.html +593 -0
- data/third_party/closure-library/closure/goog/crypt/arc4.js +162 -0
- data/third_party/closure-library/closure/goog/crypt/arc4_test.html +63 -0
- data/third_party/closure-library/closure/goog/crypt/base64.js +272 -0
- data/third_party/closure-library/closure/goog/crypt/base64_test.html +117 -0
- data/third_party/closure-library/closure/goog/crypt/basen.js +242 -0
- data/third_party/closure-library/closure/goog/crypt/basen_test.html +167 -0
- data/third_party/closure-library/closure/goog/crypt/blobhasher.js +284 -0
- data/third_party/closure-library/closure/goog/crypt/blobhasher_test.html +385 -0
- data/third_party/closure-library/closure/goog/crypt/blockcipher.js +52 -0
- data/third_party/closure-library/closure/goog/crypt/cbc.js +150 -0
- data/third_party/closure-library/closure/goog/crypt/cbc_test.html +18 -0
- data/third_party/closure-library/closure/goog/crypt/cbc_test.js +100 -0
- data/third_party/closure-library/closure/goog/crypt/crypt.js +155 -0
- data/third_party/closure-library/closure/goog/crypt/crypt_perf.html +85 -0
- data/third_party/closure-library/closure/goog/crypt/crypt_test.html +98 -0
- data/third_party/closure-library/closure/goog/crypt/hash.js +62 -0
- data/third_party/closure-library/closure/goog/crypt/hash32.js +184 -0
- data/third_party/closure-library/closure/goog/crypt/hash32_test.html +287 -0
- data/third_party/closure-library/closure/goog/crypt/hashtester.js +243 -0
- data/third_party/closure-library/closure/goog/crypt/hmac.js +162 -0
- data/third_party/closure-library/closure/goog/crypt/hmac_test.html +113 -0
- data/third_party/closure-library/closure/goog/crypt/md5.js +429 -0
- data/third_party/closure-library/closure/goog/crypt/md5_perf.html +39 -0
- data/third_party/closure-library/closure/goog/crypt/md5_test.html +152 -0
- data/third_party/closure-library/closure/goog/crypt/pbkdf2.js +127 -0
- data/third_party/closure-library/closure/goog/crypt/pbkdf2_test.html +68 -0
- data/third_party/closure-library/closure/goog/crypt/sha1.js +275 -0
- data/third_party/closure-library/closure/goog/crypt/sha1_perf.html +40 -0
- data/third_party/closure-library/closure/goog/crypt/sha1_test.html +79 -0
- data/third_party/closure-library/closure/goog/crypt/sha2.js +275 -0
- data/third_party/closure-library/closure/goog/crypt/sha224.js +53 -0
- data/third_party/closure-library/closure/goog/crypt/sha224_perf.html +40 -0
- data/third_party/closure-library/closure/goog/crypt/sha224_test.html +57 -0
- data/third_party/closure-library/closure/goog/crypt/sha256.js +53 -0
- data/third_party/closure-library/closure/goog/crypt/sha256_perf.html +40 -0
- data/third_party/closure-library/closure/goog/crypt/sha256_test.html +66 -0
- data/third_party/closure-library/closure/goog/css/autocomplete.css +43 -0
- data/third_party/closure-library/closure/goog/css/bubble.css +84 -0
- data/third_party/closure-library/closure/goog/css/button.css +38 -0
- data/third_party/closure-library/closure/goog/css/charpicker.css +206 -0
- data/third_party/closure-library/closure/goog/css/checkbox.css +38 -0
- data/third_party/closure-library/closure/goog/css/colormenubutton.css +25 -0
- data/third_party/closure-library/closure/goog/css/colorpalette.css +54 -0
- data/third_party/closure-library/closure/goog/css/colorpicker-simplegrid.css +49 -0
- data/third_party/closure-library/closure/goog/css/combobox.css +54 -0
- data/third_party/closure-library/closure/goog/css/common.css +41 -0
- data/third_party/closure-library/closure/goog/css/css3button.css +77 -0
- data/third_party/closure-library/closure/goog/css/css3menubutton.css +23 -0
- data/third_party/closure-library/closure/goog/css/custombutton.css +164 -0
- data/third_party/closure-library/closure/goog/css/datepicker.css +148 -0
- data/third_party/closure-library/closure/goog/css/dialog.css +72 -0
- data/third_party/closure-library/closure/goog/css/dimensionpicker.css +47 -0
- data/third_party/closure-library/closure/goog/css/dragdropdetector.css +48 -0
- data/third_party/closure-library/closure/goog/css/editor/bubble.css +73 -0
- data/third_party/closure-library/closure/goog/css/editor/dialog.css +66 -0
- data/third_party/closure-library/closure/goog/css/editor/equationeditor.css +113 -0
- data/third_party/closure-library/closure/goog/css/editor/linkdialog.css +36 -0
- data/third_party/closure-library/closure/goog/css/editortoolbar.css +225 -0
- data/third_party/closure-library/closure/goog/css/filteredmenu.css +30 -0
- data/third_party/closure-library/closure/goog/css/filterobservingmenuitem.css +25 -0
- data/third_party/closure-library/closure/goog/css/flatbutton.css +64 -0
- data/third_party/closure-library/closure/goog/css/flatmenubutton.css +63 -0
- data/third_party/closure-library/closure/goog/css/hovercard.css +51 -0
- data/third_party/closure-library/closure/goog/css/hsvapalette.css +231 -0
- data/third_party/closure-library/closure/goog/css/hsvpalette.css +179 -0
- data/third_party/closure-library/closure/goog/css/imagelessbutton.css +160 -0
- data/third_party/closure-library/closure/goog/css/imagelessmenubutton.css +23 -0
- data/third_party/closure-library/closure/goog/css/inputdatepicker.css +12 -0
- data/third_party/closure-library/closure/goog/css/linkbutton.css +26 -0
- data/third_party/closure-library/closure/goog/css/menu.css +27 -0
- data/third_party/closure-library/closure/goog/css/menubar.css +57 -0
- data/third_party/closure-library/closure/goog/css/menubutton.css +169 -0
- data/third_party/closure-library/closure/goog/css/menuitem.css +148 -0
- data/third_party/closure-library/closure/goog/css/menuseparator.css +19 -0
- data/third_party/closure-library/closure/goog/css/multitestrunner.css +121 -0
- data/third_party/closure-library/closure/goog/css/offline.css +147 -0
- data/third_party/closure-library/closure/goog/css/palette.css +36 -0
- data/third_party/closure-library/closure/goog/css/popupdatepicker.css +17 -0
- data/third_party/closure-library/closure/goog/css/roundedpanel.css +29 -0
- data/third_party/closure-library/closure/goog/css/roundedtab.css +158 -0
- data/third_party/closure-library/closure/goog/css/submenu.css +38 -0
- data/third_party/closure-library/closure/goog/css/tab.css +105 -0
- data/third_party/closure-library/closure/goog/css/tabbar.css +52 -0
- data/third_party/closure-library/closure/goog/css/tablesorter.css +14 -0
- data/third_party/closure-library/closure/goog/css/toolbar.css +400 -0
- data/third_party/closure-library/closure/goog/css/tooltip.css +14 -0
- data/third_party/closure-library/closure/goog/css/tree.css +146 -0
- data/third_party/closure-library/closure/goog/css/tristatemenuitem.css +43 -0
- data/third_party/closure-library/closure/goog/cssom/cssom.js +449 -0
- data/third_party/closure-library/closure/goog/cssom/cssom_test.html +343 -0
- data/third_party/closure-library/closure/goog/cssom/cssom_test_import_1.css +11 -0
- data/third_party/closure-library/closure/goog/cssom/cssom_test_import_2.css +10 -0
- data/third_party/closure-library/closure/goog/cssom/cssom_test_link_1.css +10 -0
- data/third_party/closure-library/closure/goog/cssom/iframe/style.js +1023 -0
- data/third_party/closure-library/closure/goog/cssom/iframe/style_test.html +391 -0
- data/third_party/closure-library/closure/goog/cssom/iframe/style_test_import.css +10 -0
- data/third_party/closure-library/closure/goog/datasource/datamanager.js +559 -0
- data/third_party/closure-library/closure/goog/datasource/datasource.js +656 -0
- data/third_party/closure-library/closure/goog/datasource/datasource_test.html +265 -0
- data/third_party/closure-library/closure/goog/datasource/expr.js +544 -0
- data/third_party/closure-library/closure/goog/datasource/expr_test.html +97 -0
- data/third_party/closure-library/closure/goog/datasource/fastdatanode.js +811 -0
- data/third_party/closure-library/closure/goog/datasource/fastdatanode_test.html +254 -0
- data/third_party/closure-library/closure/goog/datasource/jsdatasource.js +460 -0
- data/third_party/closure-library/closure/goog/datasource/jsondatasource.js +148 -0
- data/third_party/closure-library/closure/goog/datasource/jsxmlhttpdatasource.js +195 -0
- data/third_party/closure-library/closure/goog/datasource/jsxmlhttpdatasource_test.html +94 -0
- data/third_party/closure-library/closure/goog/datasource/xmldatasource.js +415 -0
- data/third_party/closure-library/closure/goog/date/date.js +1718 -0
- data/third_party/closure-library/closure/goog/date/date_test.html +1392 -0
- data/third_party/closure-library/closure/goog/date/datelike.js +27 -0
- data/third_party/closure-library/closure/goog/date/daterange.js +413 -0
- data/third_party/closure-library/closure/goog/date/daterange_test.html +253 -0
- data/third_party/closure-library/closure/goog/date/relative.js +465 -0
- data/third_party/closure-library/closure/goog/date/relative_test.html +267 -0
- data/third_party/closure-library/closure/goog/date/utcdatetime.js +179 -0
- data/third_party/closure-library/closure/goog/date/utcdatetime_test.html +124 -0
- data/third_party/closure-library/closure/goog/db/cursor.js +214 -0
- data/third_party/closure-library/closure/goog/db/db.js +182 -0
- data/third_party/closure-library/closure/goog/db/db_test.html +1657 -0
- data/third_party/closure-library/closure/goog/db/error.js +359 -0
- data/third_party/closure-library/closure/goog/db/index.js +245 -0
- data/third_party/closure-library/closure/goog/db/indexeddb.js +337 -0
- data/third_party/closure-library/closure/goog/db/keyrange.js +117 -0
- data/third_party/closure-library/closure/goog/db/objectstore.js +399 -0
- data/third_party/closure-library/closure/goog/db/old_db_test.html +1244 -0
- data/third_party/closure-library/closure/goog/db/transaction.js +218 -0
- data/third_party/closure-library/closure/goog/debug/console.js +207 -0
- data/third_party/closure-library/closure/goog/debug/console_test.html +195 -0
- data/third_party/closure-library/closure/goog/debug/debug.js +501 -0
- data/third_party/closure-library/closure/goog/debug/debug_test.html +68 -0
- data/third_party/closure-library/closure/goog/debug/debugwindow.js +615 -0
- data/third_party/closure-library/closure/goog/debug/debugwindow_test.html +29 -0
- data/third_party/closure-library/closure/goog/debug/devcss/devcss.js +444 -0
- data/third_party/closure-library/closure/goog/debug/devcss/devcss_test.html +365 -0
- data/third_party/closure-library/closure/goog/debug/devcss/devcssrunner.js +26 -0
- data/third_party/closure-library/closure/goog/debug/divconsole.js +141 -0
- data/third_party/closure-library/closure/goog/debug/enhanceerror_test.html +138 -0
- data/third_party/closure-library/closure/goog/debug/entrypointregistry.js +158 -0
- data/third_party/closure-library/closure/goog/debug/entrypointregistry_test.html +87 -0
- data/third_party/closure-library/closure/goog/debug/error.js +51 -0
- data/third_party/closure-library/closure/goog/debug/error_test.html +101 -0
- data/third_party/closure-library/closure/goog/debug/errorhandler.js +363 -0
- data/third_party/closure-library/closure/goog/debug/errorhandler_async_test.html +112 -0
- data/third_party/closure-library/closure/goog/debug/errorhandler_test.html +292 -0
- data/third_party/closure-library/closure/goog/debug/errorhandlerweakdep.js +38 -0
- data/third_party/closure-library/closure/goog/debug/errorreporter.js +376 -0
- data/third_party/closure-library/closure/goog/debug/errorreporter_test.html +351 -0
- data/third_party/closure-library/closure/goog/debug/fancywindow.js +362 -0
- data/third_party/closure-library/closure/goog/debug/formatter.js +316 -0
- data/third_party/closure-library/closure/goog/debug/fpsdisplay.js +162 -0
- data/third_party/closure-library/closure/goog/debug/fpsdisplay_test.html +53 -0
- data/third_party/closure-library/closure/goog/debug/gcdiagnostics.js +143 -0
- data/third_party/closure-library/closure/goog/debug/logbuffer.js +147 -0
- data/third_party/closure-library/closure/goog/debug/logbuffer_test.html +105 -0
- data/third_party/closure-library/closure/goog/debug/logger.js +853 -0
- data/third_party/closure-library/closure/goog/debug/logger_test.html +208 -0
- data/third_party/closure-library/closure/goog/debug/logrecord.js +271 -0
- data/third_party/closure-library/closure/goog/debug/logrecordserializer.js +121 -0
- data/third_party/closure-library/closure/goog/debug/logrecordserializer_test.html +96 -0
- data/third_party/closure-library/closure/goog/debug/reflect.js +178 -0
- data/third_party/closure-library/closure/goog/debug/reflect_test.html +101 -0
- data/third_party/closure-library/closure/goog/debug/relativetimeprovider.js +83 -0
- data/third_party/closure-library/closure/goog/debug/tracer.js +724 -0
- data/third_party/closure-library/closure/goog/debug/tracer_test.html +57 -0
- data/third_party/closure-library/closure/goog/demos/advancedtooltip.html +78 -0
- data/third_party/closure-library/closure/goog/demos/animationqueue.html +149 -0
- data/third_party/closure-library/closure/goog/demos/autocomplete-basic.html +56 -0
- data/third_party/closure-library/closure/goog/demos/autocompleteremote.html +40 -0
- data/third_party/closure-library/closure/goog/demos/autocompleteremotedata.js +18 -0
- data/third_party/closure-library/closure/goog/demos/autocompleterichremote.html +137 -0
- data/third_party/closure-library/closure/goog/demos/autocompleterichremotedata.js +33 -0
- data/third_party/closure-library/closure/goog/demos/bidiinput.html +72 -0
- data/third_party/closure-library/closure/goog/demos/blobhasher.html +61 -0
- data/third_party/closure-library/closure/goog/demos/bubble.html +250 -0
- data/third_party/closure-library/closure/goog/demos/button.html +395 -0
- data/third_party/closure-library/closure/goog/demos/charcounter.html +57 -0
- data/third_party/closure-library/closure/goog/demos/charpicker.html +66 -0
- data/third_party/closure-library/closure/goog/demos/checkbox.html +122 -0
- data/third_party/closure-library/closure/goog/demos/color-contrast.html +60 -0
- data/third_party/closure-library/closure/goog/demos/colormenubutton.html +221 -0
- data/third_party/closure-library/closure/goog/demos/colorpicker.html +43 -0
- data/third_party/closure-library/closure/goog/demos/combobox.html +160 -0
- data/third_party/closure-library/closure/goog/demos/container.html +670 -0
- data/third_party/closure-library/closure/goog/demos/control.html +477 -0
- data/third_party/closure-library/closure/goog/demos/css/demo.css +75 -0
- data/third_party/closure-library/closure/goog/demos/css/emojipicker.css +36 -0
- data/third_party/closure-library/closure/goog/demos/css/emojisprite.css +92 -0
- data/third_party/closure-library/closure/goog/demos/css3button.html +166 -0
- data/third_party/closure-library/closure/goog/demos/css3menubutton.html +285 -0
- data/third_party/closure-library/closure/goog/demos/cssspriteanimation.html +80 -0
- data/third_party/closure-library/closure/goog/demos/datepicker.html +183 -0
- data/third_party/closure-library/closure/goog/demos/debug.html +118 -0
- data/third_party/closure-library/closure/goog/demos/depsgraph.html +220 -0
- data/third_party/closure-library/closure/goog/demos/dialog.html +156 -0
- data/third_party/closure-library/closure/goog/demos/dimensionpicker.html +108 -0
- data/third_party/closure-library/closure/goog/demos/dimensionpicker_rtl.html +123 -0
- data/third_party/closure-library/closure/goog/demos/dom_selection.html +88 -0
- data/third_party/closure-library/closure/goog/demos/drag.html +191 -0
- data/third_party/closure-library/closure/goog/demos/dragdrop.html +263 -0
- data/third_party/closure-library/closure/goog/demos/dragdropdetector.html +46 -0
- data/third_party/closure-library/closure/goog/demos/dragdropdetector_target.html +17 -0
- data/third_party/closure-library/closure/goog/demos/dragger.html +83 -0
- data/third_party/closure-library/closure/goog/demos/draglistgroup.html +273 -0
- data/third_party/closure-library/closure/goog/demos/dragscrollsupport.html +133 -0
- data/third_party/closure-library/closure/goog/demos/drilldownrow.html +78 -0
- data/third_party/closure-library/closure/goog/demos/editor/deps.js +21 -0
- data/third_party/closure-library/closure/goog/demos/editor/editor.html +139 -0
- data/third_party/closure-library/closure/goog/demos/editor/equationeditor.html +36 -0
- data/third_party/closure-library/closure/goog/demos/editor/equationeditor.js +40 -0
- data/third_party/closure-library/closure/goog/demos/editor/field_basic.html +74 -0
- data/third_party/closure-library/closure/goog/demos/editor/helloworld.html +91 -0
- data/third_party/closure-library/closure/goog/demos/editor/helloworld.js +81 -0
- data/third_party/closure-library/closure/goog/demos/editor/helloworld_test.html +75 -0
- data/third_party/closure-library/closure/goog/demos/editor/helloworlddialog.js +171 -0
- data/third_party/closure-library/closure/goog/demos/editor/helloworlddialog_test.html +100 -0
- data/third_party/closure-library/closure/goog/demos/editor/helloworlddialogplugin.js +116 -0
- data/third_party/closure-library/closure/goog/demos/editor/helloworlddialogplugin_test.html +198 -0
- data/third_party/closure-library/closure/goog/demos/editor/seamlessfield.html +106 -0
- data/third_party/closure-library/closure/goog/demos/editor/tableeditor.html +93 -0
- data/third_party/closure-library/closure/goog/demos/effects.html +162 -0
- data/third_party/closure-library/closure/goog/demos/emoji/200.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/201.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/202.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/203.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/204.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/205.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/206.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2BC.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2BD.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2BE.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2BF.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C0.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C1.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C2.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C3.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C4.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C5.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C6.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C7.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C8.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2C9.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2CA.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2CB.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2CC.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2CD.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2CE.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2CF.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D0.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D1.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D2.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D3.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D4.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D5.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D6.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D7.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D8.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2D9.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2DA.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2DB.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2DC.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2DD.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2DE.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2DF.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E0.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E1.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E2.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E3.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E4.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E5.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E6.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E7.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E8.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2E9.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2EA.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2EB.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2EC.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2ED.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2EE.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2EF.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F0.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F1.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F2.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F3.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F4.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F5.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F6.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F7.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F8.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2F9.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2FA.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2FB.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2FC.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2FD.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2FE.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/2FF.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/none.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/sprite.png +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/sprite2.png +0 -0
- data/third_party/closure-library/closure/goog/demos/emoji/unknown.gif +0 -0
- data/third_party/closure-library/closure/goog/demos/event-propagation.html +192 -0
- data/third_party/closure-library/closure/goog/demos/events.html +99 -0
- data/third_party/closure-library/closure/goog/demos/eventtarget.html +70 -0
- data/third_party/closure-library/closure/goog/demos/filedrophandler.html +65 -0
- data/third_party/closure-library/closure/goog/demos/filteredmenu.html +118 -0
- data/third_party/closure-library/closure/goog/demos/focushandler.html +58 -0
- data/third_party/closure-library/closure/goog/demos/fpsdisplay.html +50 -0
- data/third_party/closure-library/closure/goog/demos/fx/css3/transition.html +222 -0
- data/third_party/closure-library/closure/goog/demos/gauge.html +158 -0
- data/third_party/closure-library/closure/goog/demos/graphics/advancedcoordinates.html +141 -0
- data/third_party/closure-library/closure/goog/demos/graphics/advancedcoordinates2.html +130 -0
- data/third_party/closure-library/closure/goog/demos/graphics/basicelements.html +264 -0
- data/third_party/closure-library/closure/goog/demos/graphics/events.html +114 -0
- data/third_party/closure-library/closure/goog/demos/graphics/modifyelements.html +195 -0
- data/third_party/closure-library/closure/goog/demos/graphics/subpixel.html +80 -0
- data/third_party/closure-library/closure/goog/demos/graphics/tiger.html +105 -0
- data/third_party/closure-library/closure/goog/demos/graphics/tigerdata.js +2841 -0
- data/third_party/closure-library/closure/goog/demos/history1.html +132 -0
- data/third_party/closure-library/closure/goog/demos/history2.html +119 -0
- data/third_party/closure-library/closure/goog/demos/history3.html +116 -0
- data/third_party/closure-library/closure/goog/demos/history3js.html +48 -0
- data/third_party/closure-library/closure/goog/demos/history_blank.html +26 -0
- data/third_party/closure-library/closure/goog/demos/hovercard.html +177 -0
- data/third_party/closure-library/closure/goog/demos/hsvapalette.html +55 -0
- data/third_party/closure-library/closure/goog/demos/hsvpalette.html +56 -0
- data/third_party/closure-library/closure/goog/demos/html5history.html +87 -0
- data/third_party/closure-library/closure/goog/demos/imagelessbutton.html +221 -0
- data/third_party/closure-library/closure/goog/demos/imagelessmenubutton.html +285 -0
- data/third_party/closure-library/closure/goog/demos/index.html +20 -0
- data/third_party/closure-library/closure/goog/demos/index_nav.html +255 -0
- data/third_party/closure-library/closure/goog/demos/index_splash.html +27 -0
- data/third_party/closure-library/closure/goog/demos/inline_block_quirks.html +125 -0
- data/third_party/closure-library/closure/goog/demos/inline_block_standards.html +126 -0
- data/third_party/closure-library/closure/goog/demos/inputdatepicker.html +60 -0
- data/third_party/closure-library/closure/goog/demos/inputhandler.html +88 -0
- data/third_party/closure-library/closure/goog/demos/jsonprettyprinter.html +80 -0
- data/third_party/closure-library/closure/goog/demos/keyboardshortcuts.html +112 -0
- data/third_party/closure-library/closure/goog/demos/keyhandler.html +118 -0
- data/third_party/closure-library/closure/goog/demos/labelinput.html +42 -0
- data/third_party/closure-library/closure/goog/demos/menu.html +220 -0
- data/third_party/closure-library/closure/goog/demos/menubar.html +211 -0
- data/third_party/closure-library/closure/goog/demos/menubutton.html +380 -0
- data/third_party/closure-library/closure/goog/demos/menubutton_frame.html +27 -0
- data/third_party/closure-library/closure/goog/demos/menuitem.html +164 -0
- data/third_party/closure-library/closure/goog/demos/mousewheelhandler.html +109 -0
- data/third_party/closure-library/closure/goog/demos/offline.html +268 -0
- data/third_party/closure-library/closure/goog/demos/onlinehandler.html +79 -0
- data/third_party/closure-library/closure/goog/demos/palette.html +302 -0
- data/third_party/closure-library/closure/goog/demos/pastehandler.html +54 -0
- data/third_party/closure-library/closure/goog/demos/pixeldensitymonitor.html +51 -0
- data/third_party/closure-library/closure/goog/demos/plaintextspellchecker.html +106 -0
- data/third_party/closure-library/closure/goog/demos/popup.html +206 -0
- data/third_party/closure-library/closure/goog/demos/popupcolorpicker.html +49 -0
- data/third_party/closure-library/closure/goog/demos/popupdatepicker.html +53 -0
- data/third_party/closure-library/closure/goog/demos/popupemojipicker.html +407 -0
- data/third_party/closure-library/closure/goog/demos/popupmenu.html +116 -0
- data/third_party/closure-library/closure/goog/demos/progressbar.html +97 -0
- data/third_party/closure-library/closure/goog/demos/prompt.html +92 -0
- data/third_party/closure-library/closure/goog/demos/quadtree.html +107 -0
- data/third_party/closure-library/closure/goog/demos/ratings.html +121 -0
- data/third_party/closure-library/closure/goog/demos/richtextspellchecker.html +92 -0
- data/third_party/closure-library/closure/goog/demos/roundedpanel.html +139 -0
- data/third_party/closure-library/closure/goog/demos/samplecomponent.html +75 -0
- data/third_party/closure-library/closure/goog/demos/samplecomponent.js +197 -0
- data/third_party/closure-library/closure/goog/demos/scrollfloater.html +113 -0
- data/third_party/closure-library/closure/goog/demos/select.html +324 -0
- data/third_party/closure-library/closure/goog/demos/selectionmenubutton.html +186 -0
- data/third_party/closure-library/closure/goog/demos/serverchart.html +122 -0
- data/third_party/closure-library/closure/goog/demos/slider.html +128 -0
- data/third_party/closure-library/closure/goog/demos/splitbehavior.html +163 -0
- data/third_party/closure-library/closure/goog/demos/splitpane.html +243 -0
- data/third_party/closure-library/closure/goog/demos/stopevent.html +171 -0
- data/third_party/closure-library/closure/goog/demos/submenus.html +130 -0
- data/third_party/closure-library/closure/goog/demos/submenus2.html +150 -0
- data/third_party/closure-library/closure/goog/demos/tabbar.html +289 -0
- data/third_party/closure-library/closure/goog/demos/tablesorter.html +116 -0
- data/third_party/closure-library/closure/goog/demos/tabpane.html +302 -0
- data/third_party/closure-library/closure/goog/demos/textarea.html +128 -0
- data/third_party/closure-library/closure/goog/demos/timers.html +291 -0
- data/third_party/closure-library/closure/goog/demos/toolbar.html +703 -0
- data/third_party/closure-library/closure/goog/demos/tooltip.html +91 -0
- data/third_party/closure-library/closure/goog/demos/tracer.html +92 -0
- data/third_party/closure-library/closure/goog/demos/tree/demo.html +126 -0
- data/third_party/closure-library/closure/goog/demos/tree/testdata.js +260 -0
- data/third_party/closure-library/closure/goog/demos/tweakui.html +121 -0
- data/third_party/closure-library/closure/goog/demos/twothumbslider.html +121 -0
- data/third_party/closure-library/closure/goog/demos/useragent.html +214 -0
- data/third_party/closure-library/closure/goog/demos/viewportsizemonitor.html +71 -0
- data/third_party/closure-library/closure/goog/demos/xpc/blank.html +7 -0
- data/third_party/closure-library/closure/goog/demos/xpc/index.html +89 -0
- data/third_party/closure-library/closure/goog/demos/xpc/inner.html +58 -0
- data/third_party/closure-library/closure/goog/demos/xpc/minimal/blank.html +7 -0
- data/third_party/closure-library/closure/goog/demos/xpc/minimal/index.html +105 -0
- data/third_party/closure-library/closure/goog/demos/xpc/minimal/inner.html +75 -0
- data/third_party/closure-library/closure/goog/demos/xpc/minimal/relay.html +7 -0
- data/third_party/closure-library/closure/goog/demos/xpc/relay.html +16 -0
- data/third_party/closure-library/closure/goog/demos/xpc/xpcdemo.js +307 -0
- data/third_party/closure-library/closure/goog/demos/zippy.html +149 -0
- data/third_party/closure-library/closure/goog/deps.js +911 -0
- data/third_party/closure-library/closure/goog/disposable/disposable.js +294 -0
- data/third_party/closure-library/closure/goog/disposable/disposable_test.html +307 -0
- data/third_party/closure-library/closure/goog/disposable/idisposable.js +45 -0
- data/third_party/closure-library/closure/goog/dom/a11y.js +169 -0
- data/third_party/closure-library/closure/goog/dom/abstractmultirange.js +77 -0
- data/third_party/closure-library/closure/goog/dom/abstractrange.js +528 -0
- data/third_party/closure-library/closure/goog/dom/abstractrange_test.html +73 -0
- data/third_party/closure-library/closure/goog/dom/annotate.js +355 -0
- data/third_party/closure-library/closure/goog/dom/annotate_test.html +215 -0
- data/third_party/closure-library/closure/goog/dom/browserfeature.js +67 -0
- data/third_party/closure-library/closure/goog/dom/browserrange/abstractrange.js +352 -0
- data/third_party/closure-library/closure/goog/dom/browserrange/browserrange.js +150 -0
- data/third_party/closure-library/closure/goog/dom/browserrange/browserrange_test.html +638 -0
- data/third_party/closure-library/closure/goog/dom/browserrange/geckorange.js +86 -0
- data/third_party/closure-library/closure/goog/dom/browserrange/ierange.js +952 -0
- data/third_party/closure-library/closure/goog/dom/browserrange/operarange.js +83 -0
- data/third_party/closure-library/closure/goog/dom/browserrange/w3crange.js +365 -0
- data/third_party/closure-library/closure/goog/dom/browserrange/webkitrange.js +112 -0
- data/third_party/closure-library/closure/goog/dom/bufferedviewportsizemonitor.js +202 -0
- data/third_party/closure-library/closure/goog/dom/bufferedviewportsizemonitor_test.html +17 -0
- data/third_party/closure-library/closure/goog/dom/bufferedviewportsizemonitor_test.js +130 -0
- data/third_party/closure-library/closure/goog/dom/classes.js +227 -0
- data/third_party/closure-library/closure/goog/dom/classes_quirks_test.html +63 -0
- data/third_party/closure-library/closure/goog/dom/classes_test.html +64 -0
- data/third_party/closure-library/closure/goog/dom/classes_test.js +231 -0
- data/third_party/closure-library/closure/goog/dom/classlist.js +271 -0
- data/third_party/closure-library/closure/goog/dom/classlist_test.html +26 -0
- data/third_party/closure-library/closure/goog/dom/classlist_test.js +244 -0
- data/third_party/closure-library/closure/goog/dom/controlrange.js +505 -0
- data/third_party/closure-library/closure/goog/dom/controlrange_test.html +246 -0
- data/third_party/closure-library/closure/goog/dom/dataset.js +135 -0
- data/third_party/closure-library/closure/goog/dom/dataset_test.html +117 -0
- data/third_party/closure-library/closure/goog/dom/dom.js +2700 -0
- data/third_party/closure-library/closure/goog/dom/dom_quirks_test.html +113 -0
- data/third_party/closure-library/closure/goog/dom/dom_test.html +113 -0
- data/third_party/closure-library/closure/goog/dom/dom_test.js +1421 -0
- data/third_party/closure-library/closure/goog/dom/fontsizemonitor.js +159 -0
- data/third_party/closure-library/closure/goog/dom/fontsizemonitor_test.html +284 -0
- data/third_party/closure-library/closure/goog/dom/forms.js +414 -0
- data/third_party/closure-library/closure/goog/dom/forms_test.html +501 -0
- data/third_party/closure-library/closure/goog/dom/fullscreen.js +124 -0
- data/third_party/closure-library/closure/goog/dom/iframe.js +163 -0
- data/third_party/closure-library/closure/goog/dom/iframe_test.html +88 -0
- data/third_party/closure-library/closure/goog/dom/iter.js +127 -0
- data/third_party/closure-library/closure/goog/dom/iter_test.html +97 -0
- data/third_party/closure-library/closure/goog/dom/multirange.js +519 -0
- data/third_party/closure-library/closure/goog/dom/multirange_test.html +67 -0
- data/third_party/closure-library/closure/goog/dom/nodeiterator.js +86 -0
- data/third_party/closure-library/closure/goog/dom/nodeiterator_test.html +49 -0
- data/third_party/closure-library/closure/goog/dom/nodeoffset.js +112 -0
- data/third_party/closure-library/closure/goog/dom/nodeoffset_test.html +88 -0
- data/third_party/closure-library/closure/goog/dom/pattern/abstractpattern.js +60 -0
- data/third_party/closure-library/closure/goog/dom/pattern/allchildren.js +75 -0
- data/third_party/closure-library/closure/goog/dom/pattern/callback/callback.js +82 -0
- data/third_party/closure-library/closure/goog/dom/pattern/callback/counter.js +72 -0
- data/third_party/closure-library/closure/goog/dom/pattern/callback/test.js +77 -0
- data/third_party/closure-library/closure/goog/dom/pattern/childmatches.js +154 -0
- data/third_party/closure-library/closure/goog/dom/pattern/endtag.js +53 -0
- data/third_party/closure-library/closure/goog/dom/pattern/fulltag.js +93 -0
- data/third_party/closure-library/closure/goog/dom/pattern/matcher.js +150 -0
- data/third_party/closure-library/closure/goog/dom/pattern/matcher_test.html +204 -0
- data/third_party/closure-library/closure/goog/dom/pattern/nodetype.js +58 -0
- data/third_party/closure-library/closure/goog/dom/pattern/pattern.js +93 -0
- data/third_party/closure-library/closure/goog/dom/pattern/pattern_test.html +614 -0
- data/third_party/closure-library/closure/goog/dom/pattern/repeat.js +190 -0
- data/third_party/closure-library/closure/goog/dom/pattern/sequence.js +141 -0
- data/third_party/closure-library/closure/goog/dom/pattern/starttag.js +53 -0
- data/third_party/closure-library/closure/goog/dom/pattern/tag.js +150 -0
- data/third_party/closure-library/closure/goog/dom/pattern/text.js +70 -0
- data/third_party/closure-library/closure/goog/dom/range.js +226 -0
- data/third_party/closure-library/closure/goog/dom/range_test.html +735 -0
- data/third_party/closure-library/closure/goog/dom/rangeendpoint.js +32 -0
- data/third_party/closure-library/closure/goog/dom/savedcaretrange.js +215 -0
- data/third_party/closure-library/closure/goog/dom/savedcaretrange_test.html +257 -0
- data/third_party/closure-library/closure/goog/dom/savedrange.js +74 -0
- data/third_party/closure-library/closure/goog/dom/savedrange_test.html +61 -0
- data/third_party/closure-library/closure/goog/dom/selection.js +470 -0
- data/third_party/closure-library/closure/goog/dom/selection_test.html +329 -0
- data/third_party/closure-library/closure/goog/dom/tagiterator.js +367 -0
- data/third_party/closure-library/closure/goog/dom/tagiterator_test.html +589 -0
- data/third_party/closure-library/closure/goog/dom/tagname.js +159 -0
- data/third_party/closure-library/closure/goog/dom/tagname_test.html +37 -0
- data/third_party/closure-library/closure/goog/dom/textrange.js +630 -0
- data/third_party/closure-library/closure/goog/dom/textrange_test.html +342 -0
- data/third_party/closure-library/closure/goog/dom/textrangeiterator.js +244 -0
- data/third_party/closure-library/closure/goog/dom/textrangeiterator_test.html +142 -0
- data/third_party/closure-library/closure/goog/dom/vendor.js +62 -0
- data/third_party/closure-library/closure/goog/dom/vendor_test.html +202 -0
- data/third_party/closure-library/closure/goog/dom/viewportsizemonitor.js +180 -0
- data/third_party/closure-library/closure/goog/dom/viewportsizemonitor_test.html +138 -0
- data/third_party/closure-library/closure/goog/dom/xml.js +204 -0
- data/third_party/closure-library/closure/goog/dom/xml_test.html +103 -0
- data/third_party/closure-library/closure/goog/editor/browserfeature.js +273 -0
- data/third_party/closure-library/closure/goog/editor/browserfeature_test.html +124 -0
- data/third_party/closure-library/closure/goog/editor/clicktoeditwrapper.js +435 -0
- data/third_party/closure-library/closure/goog/editor/clicktoeditwrapper_test.html +137 -0
- data/third_party/closure-library/closure/goog/editor/command.js +76 -0
- data/third_party/closure-library/closure/goog/editor/contenteditablefield.js +110 -0
- data/third_party/closure-library/closure/goog/editor/contenteditablefield_test.html +62 -0
- data/third_party/closure-library/closure/goog/editor/defines.js +34 -0
- data/third_party/closure-library/closure/goog/editor/field.js +2725 -0
- data/third_party/closure-library/closure/goog/editor/field_test.html +32 -0
- data/third_party/closure-library/closure/goog/editor/field_test.js +1278 -0
- data/third_party/closure-library/closure/goog/editor/focus.js +32 -0
- data/third_party/closure-library/closure/goog/editor/focus_test.html +66 -0
- data/third_party/closure-library/closure/goog/editor/icontent.js +296 -0
- data/third_party/closure-library/closure/goog/editor/icontent_test.html +232 -0
- data/third_party/closure-library/closure/goog/editor/link.js +359 -0
- data/third_party/closure-library/closure/goog/editor/link_test.html +252 -0
- data/third_party/closure-library/closure/goog/editor/node.js +483 -0
- data/third_party/closure-library/closure/goog/editor/node_test.html +631 -0
- data/third_party/closure-library/closure/goog/editor/plugin.js +463 -0
- data/third_party/closure-library/closure/goog/editor/plugin_test.html +187 -0
- data/third_party/closure-library/closure/goog/editor/plugins/abstractbubbleplugin.js +630 -0
- data/third_party/closure-library/closure/goog/editor/plugins/abstractbubbleplugin_test.html +313 -0
- data/third_party/closure-library/closure/goog/editor/plugins/abstractdialogplugin.js +334 -0
- data/third_party/closure-library/closure/goog/editor/plugins/abstractdialogplugin_test.html +404 -0
- data/third_party/closure-library/closure/goog/editor/plugins/abstracttabhandler.js +78 -0
- data/third_party/closure-library/closure/goog/editor/plugins/abstracttabhandler_test.html +91 -0
- data/third_party/closure-library/closure/goog/editor/plugins/basictextformatter.js +1750 -0
- data/third_party/closure-library/closure/goog/editor/plugins/basictextformatter_test.html +1171 -0
- data/third_party/closure-library/closure/goog/editor/plugins/blockquote.js +479 -0
- data/third_party/closure-library/closure/goog/editor/plugins/blockquote_test.html +212 -0
- data/third_party/closure-library/closure/goog/editor/plugins/emoticons.js +88 -0
- data/third_party/closure-library/closure/goog/editor/plugins/emoticons_test.html +92 -0
- data/third_party/closure-library/closure/goog/editor/plugins/enterhandler.js +767 -0
- data/third_party/closure-library/closure/goog/editor/plugins/enterhandler_test.html +754 -0
- data/third_party/closure-library/closure/goog/editor/plugins/equationeditorbubble.js +153 -0
- data/third_party/closure-library/closure/goog/editor/plugins/equationeditorplugin.js +215 -0
- data/third_party/closure-library/closure/goog/editor/plugins/equationeditorplugin_test.html +120 -0
- data/third_party/closure-library/closure/goog/editor/plugins/firststrong.js +326 -0
- data/third_party/closure-library/closure/goog/editor/plugins/firststrong_test.html +411 -0
- data/third_party/closure-library/closure/goog/editor/plugins/headerformatter.js +95 -0
- data/third_party/closure-library/closure/goog/editor/plugins/headerformatter_test.html +100 -0
- data/third_party/closure-library/closure/goog/editor/plugins/linkbubble.js +562 -0
- data/third_party/closure-library/closure/goog/editor/plugins/linkbubble_test.html +375 -0
- data/third_party/closure-library/closure/goog/editor/plugins/linkdialogplugin.js +437 -0
- data/third_party/closure-library/closure/goog/editor/plugins/linkdialogplugin_test.html +740 -0
- data/third_party/closure-library/closure/goog/editor/plugins/linkshortcutplugin.js +63 -0
- data/third_party/closure-library/closure/goog/editor/plugins/linkshortcutplugin_test.html +70 -0
- data/third_party/closure-library/closure/goog/editor/plugins/listtabhandler.js +66 -0
- data/third_party/closure-library/closure/goog/editor/plugins/listtabhandler_test.html +177 -0
- data/third_party/closure-library/closure/goog/editor/plugins/loremipsum.js +188 -0
- data/third_party/closure-library/closure/goog/editor/plugins/loremipsum_test.html +169 -0
- data/third_party/closure-library/closure/goog/editor/plugins/removeformatting.js +779 -0
- data/third_party/closure-library/closure/goog/editor/plugins/removeformatting_test.html +961 -0
- data/third_party/closure-library/closure/goog/editor/plugins/spacestabhandler.js +93 -0
- data/third_party/closure-library/closure/goog/editor/plugins/spacestabhandler_test.html +186 -0
- data/third_party/closure-library/closure/goog/editor/plugins/tableeditor.js +472 -0
- data/third_party/closure-library/closure/goog/editor/plugins/tableeditor_test.html +299 -0
- data/third_party/closure-library/closure/goog/editor/plugins/tagonenterhandler.js +742 -0
- data/third_party/closure-library/closure/goog/editor/plugins/tagonenterhandler_test.html +549 -0
- data/third_party/closure-library/closure/goog/editor/plugins/undoredo.js +1015 -0
- data/third_party/closure-library/closure/goog/editor/plugins/undoredo_test.html +525 -0
- data/third_party/closure-library/closure/goog/editor/plugins/undoredomanager.js +337 -0
- data/third_party/closure-library/closure/goog/editor/plugins/undoredomanager_test.html +394 -0
- data/third_party/closure-library/closure/goog/editor/plugins/undoredostate.js +86 -0
- data/third_party/closure-library/closure/goog/editor/plugins/undoredostate_test.html +44 -0
- data/third_party/closure-library/closure/goog/editor/range.js +632 -0
- data/third_party/closure-library/closure/goog/editor/range_test.html +1004 -0
- data/third_party/closure-library/closure/goog/editor/seamlessfield.js +738 -0
- data/third_party/closure-library/closure/goog/editor/seamlessfield_quirks_test.html +28 -0
- data/third_party/closure-library/closure/goog/editor/seamlessfield_test.html +32 -0
- data/third_party/closure-library/closure/goog/editor/seamlessfield_test.js +472 -0
- data/third_party/closure-library/closure/goog/editor/style.js +222 -0
- data/third_party/closure-library/closure/goog/editor/style_test.html +177 -0
- data/third_party/closure-library/closure/goog/editor/table.js +567 -0
- data/third_party/closure-library/closure/goog/editor/table_test.html +529 -0
- data/third_party/closure-library/closure/goog/events/actioneventwrapper.js +136 -0
- data/third_party/closure-library/closure/goog/events/actioneventwrapper_test.html +211 -0
- data/third_party/closure-library/closure/goog/events/actionhandler.js +181 -0
- data/third_party/closure-library/closure/goog/events/actionhandler_test.html +82 -0
- data/third_party/closure-library/closure/goog/events/browserevent.js +411 -0
- data/third_party/closure-library/closure/goog/events/browserevent_test.html +161 -0
- data/third_party/closure-library/closure/goog/events/browserfeature.js +85 -0
- data/third_party/closure-library/closure/goog/events/event.js +154 -0
- data/third_party/closure-library/closure/goog/events/event_test.html +66 -0
- data/third_party/closure-library/closure/goog/events/eventhandler.js +291 -0
- data/third_party/closure-library/closure/goog/events/eventhandler_test.html +254 -0
- data/third_party/closure-library/closure/goog/events/events.js +1095 -0
- data/third_party/closure-library/closure/goog/events/events_test.html +659 -0
- data/third_party/closure-library/closure/goog/events/eventtarget.js +401 -0
- data/third_party/closure-library/closure/goog/events/eventtarget_test.html +70 -0
- data/third_party/closure-library/closure/goog/events/eventtarget_via_googevents_test.html +85 -0
- data/third_party/closure-library/closure/goog/events/eventtarget_via_w3cinterface_test.html +49 -0
- data/third_party/closure-library/closure/goog/events/eventtargettester.js +1028 -0
- data/third_party/closure-library/closure/goog/events/eventtype.js +165 -0
- data/third_party/closure-library/closure/goog/events/eventwrapper.js +66 -0
- data/third_party/closure-library/closure/goog/events/filedrophandler.js +221 -0
- data/third_party/closure-library/closure/goog/events/filedrophandler_test.html +258 -0
- data/third_party/closure-library/closure/goog/events/focushandler.js +106 -0
- data/third_party/closure-library/closure/goog/events/imehandler.js +363 -0
- data/third_party/closure-library/closure/goog/events/imehandler_test.html +269 -0
- data/third_party/closure-library/closure/goog/events/inputhandler.js +213 -0
- data/third_party/closure-library/closure/goog/events/keycodes.js +377 -0
- data/third_party/closure-library/closure/goog/events/keycodes_test.html +125 -0
- data/third_party/closure-library/closure/goog/events/keyhandler.js +556 -0
- data/third_party/closure-library/closure/goog/events/keyhandler_test.html +727 -0
- data/third_party/closure-library/closure/goog/events/keynames.js +132 -0
- data/third_party/closure-library/closure/goog/events/listenable.js +323 -0
- data/third_party/closure-library/closure/goog/events/listenable_test.html +31 -0
- data/third_party/closure-library/closure/goog/events/listener.js +131 -0
- data/third_party/closure-library/closure/goog/events/listenermap.js +299 -0
- data/third_party/closure-library/closure/goog/events/listenermap_test.html +19 -0
- data/third_party/closure-library/closure/goog/events/listenermap_test.js +116 -0
- data/third_party/closure-library/closure/goog/events/mousewheelhandler.js +295 -0
- data/third_party/closure-library/closure/goog/events/mousewheelhandler_test.html +385 -0
- data/third_party/closure-library/closure/goog/events/onlinehandler.js +162 -0
- data/third_party/closure-library/closure/goog/events/onlinelistener_test.html +160 -0
- data/third_party/closure-library/closure/goog/events/pastehandler.js +515 -0
- data/third_party/closure-library/closure/goog/events/pastehandler_test.html +414 -0
- data/third_party/closure-library/closure/goog/format/emailaddress.js +332 -0
- data/third_party/closure-library/closure/goog/format/emailaddress_test.html +192 -0
- data/third_party/closure-library/closure/goog/format/format.js +491 -0
- data/third_party/closure-library/closure/goog/format/format_test.html +302 -0
- data/third_party/closure-library/closure/goog/format/htmlprettyprinter.js +407 -0
- data/third_party/closure-library/closure/goog/format/htmlprettyprinter_test.html +205 -0
- data/third_party/closure-library/closure/goog/format/jsonprettyprinter.js +413 -0
- data/third_party/closure-library/closure/goog/format/jsonprettyprinter_test.html +111 -0
- data/third_party/closure-library/closure/goog/fs/entry.js +272 -0
- data/third_party/closure-library/closure/goog/fs/entryimpl.js +399 -0
- data/third_party/closure-library/closure/goog/fs/error.js +102 -0
- data/third_party/closure-library/closure/goog/fs/filereader.js +288 -0
- data/third_party/closure-library/closure/goog/fs/filesaver.js +176 -0
- data/third_party/closure-library/closure/goog/fs/filesystem.js +41 -0
- data/third_party/closure-library/closure/goog/fs/filesystemimpl.js +64 -0
- data/third_party/closure-library/closure/goog/fs/filewriter.js +110 -0
- data/third_party/closure-library/closure/goog/fs/fs.js +253 -0
- data/third_party/closure-library/closure/goog/fs/fs_test.html +754 -0
- data/third_party/closure-library/closure/goog/fs/progressevent.js +68 -0
- data/third_party/closure-library/closure/goog/functions/functions.js +255 -0
- data/third_party/closure-library/closure/goog/functions/functions_test.html +223 -0
- data/third_party/closure-library/closure/goog/fx/abstractdragdrop.js +1517 -0
- data/third_party/closure-library/closure/goog/fx/abstractdragdrop_test.html +663 -0
- data/third_party/closure-library/closure/goog/fx/anim/anim.js +210 -0
- data/third_party/closure-library/closure/goog/fx/anim/anim_test.html +225 -0
- data/third_party/closure-library/closure/goog/fx/animation.js +530 -0
- data/third_party/closure-library/closure/goog/fx/animation_test.html +117 -0
- data/third_party/closure-library/closure/goog/fx/animationqueue.js +307 -0
- data/third_party/closure-library/closure/goog/fx/animationqueue_test.html +316 -0
- data/third_party/closure-library/closure/goog/fx/css3/fx.js +62 -0
- data/third_party/closure-library/closure/goog/fx/css3/transition.js +196 -0
- data/third_party/closure-library/closure/goog/fx/css3/transition_test.html +224 -0
- data/third_party/closure-library/closure/goog/fx/cssspriteanimation.js +113 -0
- data/third_party/closure-library/closure/goog/fx/cssspriteanimation_test.html +126 -0
- data/third_party/closure-library/closure/goog/fx/dom.js +653 -0
- data/third_party/closure-library/closure/goog/fx/dragdrop.js +50 -0
- data/third_party/closure-library/closure/goog/fx/dragdropgroup.js +109 -0
- data/third_party/closure-library/closure/goog/fx/dragdropgroup_test.html +234 -0
- data/third_party/closure-library/closure/goog/fx/dragger.js +795 -0
- data/third_party/closure-library/closure/goog/fx/dragger_test.html +449 -0
- data/third_party/closure-library/closure/goog/fx/draglistgroup.js +1301 -0
- data/third_party/closure-library/closure/goog/fx/draglistgroup_test.html +403 -0
- data/third_party/closure-library/closure/goog/fx/dragscrollsupport.js +299 -0
- data/third_party/closure-library/closure/goog/fx/dragscrollsupport_test.html +354 -0
- data/third_party/closure-library/closure/goog/fx/easing.js +50 -0
- data/third_party/closure-library/closure/goog/fx/fx.js +32 -0
- data/third_party/closure-library/closure/goog/fx/fx_test.html +100 -0
- data/third_party/closure-library/closure/goog/fx/transition.js +75 -0
- data/third_party/closure-library/closure/goog/fx/transitionbase.js +237 -0
- data/third_party/closure-library/closure/goog/gears/basestore.js +521 -0
- data/third_party/closure-library/closure/goog/gears/basestore_test.html +247 -0
- data/third_party/closure-library/closure/goog/gears/database.js +934 -0
- data/third_party/closure-library/closure/goog/gears/database_test.html +699 -0
- data/third_party/closure-library/closure/goog/gears/gears.js +228 -0
- data/third_party/closure-library/closure/goog/gears/gears_test.html +78 -0
- data/third_party/closure-library/closure/goog/gears/httprequest.js +80 -0
- data/third_party/closure-library/closure/goog/gears/loggerclient.js +130 -0
- data/third_party/closure-library/closure/goog/gears/loggerclient_test.html +172 -0
- data/third_party/closure-library/closure/goog/gears/loggerserver.js +157 -0
- data/third_party/closure-library/closure/goog/gears/loggerserver_test.html +119 -0
- data/third_party/closure-library/closure/goog/gears/logstore.js +478 -0
- data/third_party/closure-library/closure/goog/gears/logstore_test.html +600 -0
- data/third_party/closure-library/closure/goog/gears/managedresourcestore.js +555 -0
- data/third_party/closure-library/closure/goog/gears/managedresourcestore_test.html +453 -0
- data/third_party/closure-library/closure/goog/gears/multipartformdata.js +204 -0
- data/third_party/closure-library/closure/goog/gears/multipartformdata_test.html +221 -0
- data/third_party/closure-library/closure/goog/gears/statustype.js +37 -0
- data/third_party/closure-library/closure/goog/gears/urlcapture.js +370 -0
- data/third_party/closure-library/closure/goog/gears/urlcapture_test.html +392 -0
- data/third_party/closure-library/closure/goog/gears/worker.js +200 -0
- data/third_party/closure-library/closure/goog/gears/workerchannel.js +205 -0
- data/third_party/closure-library/closure/goog/gears/workerchannel_test.html +207 -0
- data/third_party/closure-library/closure/goog/gears/workerpool.js +240 -0
- data/third_party/closure-library/closure/goog/gears/workerpool_test.html +204 -0
- data/third_party/closure-library/closure/goog/graphics/abstractgraphics.js +441 -0
- data/third_party/closure-library/closure/goog/graphics/affinetransform.js +587 -0
- data/third_party/closure-library/closure/goog/graphics/affinetransform_test.html +360 -0
- data/third_party/closure-library/closure/goog/graphics/canvaselement.js +792 -0
- data/third_party/closure-library/closure/goog/graphics/canvasgraphics.js +665 -0
- data/third_party/closure-library/closure/goog/graphics/element.js +151 -0
- data/third_party/closure-library/closure/goog/graphics/ellipseelement.js +64 -0
- data/third_party/closure-library/closure/goog/graphics/ext/coordinates.js +159 -0
- data/third_party/closure-library/closure/goog/graphics/ext/coordinates_test.html +74 -0
- data/third_party/closure-library/closure/goog/graphics/ext/element.js +968 -0
- data/third_party/closure-library/closure/goog/graphics/ext/element_test.html +144 -0
- data/third_party/closure-library/closure/goog/graphics/ext/ellipse.js +59 -0
- data/third_party/closure-library/closure/goog/graphics/ext/ext.js +29 -0
- data/third_party/closure-library/closure/goog/graphics/ext/graphics.js +215 -0
- data/third_party/closure-library/closure/goog/graphics/ext/group.js +215 -0
- data/third_party/closure-library/closure/goog/graphics/ext/image.js +63 -0
- data/third_party/closure-library/closure/goog/graphics/ext/path.js +142 -0
- data/third_party/closure-library/closure/goog/graphics/ext/path_test.html +46 -0
- data/third_party/closure-library/closure/goog/graphics/ext/rectangle.js +54 -0
- data/third_party/closure-library/closure/goog/graphics/ext/shape.js +146 -0
- data/third_party/closure-library/closure/goog/graphics/ext/strokeandfillelement.js +70 -0
- data/third_party/closure-library/closure/goog/graphics/fill.js +46 -0
- data/third_party/closure-library/closure/goog/graphics/font.js +63 -0
- data/third_party/closure-library/closure/goog/graphics/graphics.js +135 -0
- data/third_party/closure-library/closure/goog/graphics/groupelement.js +59 -0
- data/third_party/closure-library/closure/goog/graphics/imageelement.js +70 -0
- data/third_party/closure-library/closure/goog/graphics/lineargradient.js +174 -0
- data/third_party/closure-library/closure/goog/graphics/path.js +512 -0
- data/third_party/closure-library/closure/goog/graphics/path_test.html +359 -0
- data/third_party/closure-library/closure/goog/graphics/pathelement.js +55 -0
- data/third_party/closure-library/closure/goog/graphics/paths.js +86 -0
- data/third_party/closure-library/closure/goog/graphics/paths_test.html +98 -0
- data/third_party/closure-library/closure/goog/graphics/rectelement.js +64 -0
- data/third_party/closure-library/closure/goog/graphics/solidfill.js +74 -0
- data/third_party/closure-library/closure/goog/graphics/solidfill_test.html +53 -0
- data/third_party/closure-library/closure/goog/graphics/stroke.js +67 -0
- data/third_party/closure-library/closure/goog/graphics/strokeandfillelement.js +115 -0
- data/third_party/closure-library/closure/goog/graphics/svgelement.js +279 -0
- data/third_party/closure-library/closure/goog/graphics/svggraphics.js +857 -0
- data/third_party/closure-library/closure/goog/graphics/svggraphics_test.html +83 -0
- data/third_party/closure-library/closure/goog/graphics/textelement.js +56 -0
- data/third_party/closure-library/closure/goog/graphics/vmlelement.js +433 -0
- data/third_party/closure-library/closure/goog/graphics/vmlgraphics.js +893 -0
- data/third_party/closure-library/closure/goog/history/event.js +54 -0
- data/third_party/closure-library/closure/goog/history/eventtype.js +30 -0
- data/third_party/closure-library/closure/goog/history/history.js +998 -0
- data/third_party/closure-library/closure/goog/history/history_test.html +19 -0
- data/third_party/closure-library/closure/goog/history/history_test.js +54 -0
- data/third_party/closure-library/closure/goog/history/html5history.js +303 -0
- data/third_party/closure-library/closure/goog/history/html5history_test.html +163 -0
- data/third_party/closure-library/closure/goog/i18n/bidi.js +806 -0
- data/third_party/closure-library/closure/goog/i18n/bidi_test.html +425 -0
- data/third_party/closure-library/closure/goog/i18n/bidiformatter.js +490 -0
- data/third_party/closure-library/closure/goog/i18n/bidiformatter_test.html +343 -0
- data/third_party/closure-library/closure/goog/i18n/charlistdecompressor.js +157 -0
- data/third_party/closure-library/closure/goog/i18n/charlistdecompressor_test.html +65 -0
- data/third_party/closure-library/closure/goog/i18n/charpickerdata.js +3185 -0
- data/third_party/closure-library/closure/goog/i18n/collation.js +58 -0
- data/third_party/closure-library/closure/goog/i18n/collation_test.html +63 -0
- data/third_party/closure-library/closure/goog/i18n/compactnumberformatsymbols.js +7973 -0
- data/third_party/closure-library/closure/goog/i18n/compactnumberformatsymbols_ext.js +27549 -0
- data/third_party/closure-library/closure/goog/i18n/currency.js +424 -0
- data/third_party/closure-library/closure/goog/i18n/currency_test.html +204 -0
- data/third_party/closure-library/closure/goog/i18n/currencycodemap.js +210 -0
- data/third_party/closure-library/closure/goog/i18n/datetimeformat.js +673 -0
- data/third_party/closure-library/closure/goog/i18n/datetimeformat_test.html +532 -0
- data/third_party/closure-library/closure/goog/i18n/datetimeparse.js +1129 -0
- data/third_party/closure-library/closure/goog/i18n/datetimeparse_test.html +766 -0
- data/third_party/closure-library/closure/goog/i18n/datetimepatterns.js +1854 -0
- data/third_party/closure-library/closure/goog/i18n/datetimepatternsext.js +10947 -0
- data/third_party/closure-library/closure/goog/i18n/datetimesymbols.js +3713 -0
- data/third_party/closure-library/closure/goog/i18n/datetimesymbolsext.js +21152 -0
- data/third_party/closure-library/closure/goog/i18n/graphemebreak.js +214 -0
- data/third_party/closure-library/closure/goog/i18n/graphemebreak_test.html +80 -0
- data/third_party/closure-library/closure/goog/i18n/messageformat.js +771 -0
- data/third_party/closure-library/closure/goog/i18n/messageformat_test.html +471 -0
- data/third_party/closure-library/closure/goog/i18n/mime.js +111 -0
- data/third_party/closure-library/closure/goog/i18n/mime_test.html +51 -0
- data/third_party/closure-library/closure/goog/i18n/numberformat.js +1228 -0
- data/third_party/closure-library/closure/goog/i18n/numberformat_test.html +985 -0
- data/third_party/closure-library/closure/goog/i18n/numberformatsymbols.js +3416 -0
- data/third_party/closure-library/closure/goog/i18n/numberformatsymbolsext.js +11887 -0
- data/third_party/closure-library/closure/goog/i18n/ordinalrules.js +589 -0
- data/third_party/closure-library/closure/goog/i18n/pluralrules.js +859 -0
- data/third_party/closure-library/closure/goog/i18n/timezone.js +340 -0
- data/third_party/closure-library/closure/goog/i18n/timezone_test.html +163 -0
- data/third_party/closure-library/closure/goog/i18n/uchar.js +1368 -0
- data/third_party/closure-library/closure/goog/i18n/uchar/localnamefetcher.js +73 -0
- data/third_party/closure-library/closure/goog/i18n/uchar/localnamefetcher_test.html +62 -0
- data/third_party/closure-library/closure/goog/i18n/uchar/namefetcher.js +70 -0
- data/third_party/closure-library/closure/goog/i18n/uchar/remotenamefetcher.js +281 -0
- data/third_party/closure-library/closure/goog/i18n/uchar/remotenamefetcher_test.html +111 -0
- data/third_party/closure-library/closure/goog/i18n/uchar_test.html +133 -0
- data/third_party/closure-library/closure/goog/images/blank.gif +0 -0
- data/third_party/closure-library/closure/goog/images/bubble_close.jpg +0 -0
- data/third_party/closure-library/closure/goog/images/bubble_left.gif +0 -0
- data/third_party/closure-library/closure/goog/images/bubble_right.gif +0 -0
- data/third_party/closure-library/closure/goog/images/button-bg.gif +0 -0
- data/third_party/closure-library/closure/goog/images/check-outline.gif +0 -0
- data/third_party/closure-library/closure/goog/images/check-sprite.gif +0 -0
- data/third_party/closure-library/closure/goog/images/check.gif +0 -0
- data/third_party/closure-library/closure/goog/images/close_box.gif +0 -0
- data/third_party/closure-library/closure/goog/images/color-swatch-tick.gif +0 -0
- data/third_party/closure-library/closure/goog/images/dialog_close_box.gif +0 -0
- data/third_party/closure-library/closure/goog/images/dimension-highlighted.png +0 -0
- data/third_party/closure-library/closure/goog/images/dimension-unhighlighted.png +0 -0
- data/third_party/closure-library/closure/goog/images/dropdn.gif +0 -0
- data/third_party/closure-library/closure/goog/images/dropdn_disabled.gif +0 -0
- data/third_party/closure-library/closure/goog/images/dropdown.gif +0 -0
- data/third_party/closure-library/closure/goog/images/gears_bluedot.gif +0 -0
- data/third_party/closure-library/closure/goog/images/gears_offline.gif +0 -0
- data/third_party/closure-library/closure/goog/images/gears_online.gif +0 -0
- data/third_party/closure-library/closure/goog/images/gears_paused.gif +0 -0
- data/third_party/closure-library/closure/goog/images/gears_syncing.gif +0 -0
- data/third_party/closure-library/closure/goog/images/hsv-sprite-sm.gif +0 -0
- data/third_party/closure-library/closure/goog/images/hsv-sprite-sm.png +0 -0
- data/third_party/closure-library/closure/goog/images/hsv-sprite.gif +0 -0
- data/third_party/closure-library/closure/goog/images/hsv-sprite.png +0 -0
- data/third_party/closure-library/closure/goog/images/hsva-sprite-sm.gif +0 -0
- data/third_party/closure-library/closure/goog/images/hsva-sprite-sm.png +0 -0
- data/third_party/closure-library/closure/goog/images/hsva-sprite.gif +0 -0
- data/third_party/closure-library/closure/goog/images/hsva-sprite.png +0 -0
- data/third_party/closure-library/closure/goog/images/left_anchor_bubble_bot.gif +0 -0
- data/third_party/closure-library/closure/goog/images/left_anchor_bubble_top.gif +0 -0
- data/third_party/closure-library/closure/goog/images/menu-arrows.gif +0 -0
- data/third_party/closure-library/closure/goog/images/minus.png +0 -0
- data/third_party/closure-library/closure/goog/images/no_anchor_bubble_bot.gif +0 -0
- data/third_party/closure-library/closure/goog/images/no_anchor_bubble_top.gif +0 -0
- data/third_party/closure-library/closure/goog/images/offlineicons.png +0 -0
- data/third_party/closure-library/closure/goog/images/plus.png +0 -0
- data/third_party/closure-library/closure/goog/images/ratingstars.gif +0 -0
- data/third_party/closure-library/closure/goog/images/right_anchor_bubble_bot.gif +0 -0
- data/third_party/closure-library/closure/goog/images/right_anchor_bubble_top.gif +0 -0
- data/third_party/closure-library/closure/goog/images/toolbar-bg.png +0 -0
- data/third_party/closure-library/closure/goog/images/toolbar-separator.gif +0 -0
- data/third_party/closure-library/closure/goog/images/toolbar_icons.gif +0 -0
- data/third_party/closure-library/closure/goog/images/tree/I.png +0 -0
- data/third_party/closure-library/closure/goog/images/tree/cleardot.gif +0 -0
- data/third_party/closure-library/closure/goog/images/tree/tree.gif +0 -0
- data/third_party/closure-library/closure/goog/images/tree/tree.png +0 -0
- data/third_party/closure-library/closure/goog/images/ui_controls.jpg +0 -0
- data/third_party/closure-library/closure/goog/iter/iter.js +702 -0
- data/third_party/closure-library/closure/goog/iter/iter_test.html +479 -0
- data/third_party/closure-library/closure/goog/json/evaljsonprocessor.js +66 -0
- data/third_party/closure-library/closure/goog/json/json.js +349 -0
- data/third_party/closure-library/closure/goog/json/json_perf.html +116 -0
- data/third_party/closure-library/closure/goog/json/json_test.html +569 -0
- data/third_party/closure-library/closure/goog/json/nativejsonprocessor.js +73 -0
- data/third_party/closure-library/closure/goog/json/processor.js +33 -0
- data/third_party/closure-library/closure/goog/json/processor_test.html +89 -0
- data/third_party/closure-library/closure/goog/labs/classdef/classdef.js +162 -0
- data/third_party/closure-library/closure/goog/labs/classdef/classdef_test.html +103 -0
- data/third_party/closure-library/closure/goog/labs/events/touch.js +82 -0
- data/third_party/closure-library/closure/goog/labs/events/touch_test.html +19 -0
- data/third_party/closure-library/closure/goog/labs/events/touch_test.js +96 -0
- data/third_party/closure-library/closure/goog/labs/format/csv.js +391 -0
- data/third_party/closure-library/closure/goog/labs/format/csv_test.html +20 -0
- data/third_party/closure-library/closure/goog/labs/format/csv_test.js +169 -0
- data/third_party/closure-library/closure/goog/labs/mock/mock.js +733 -0
- data/third_party/closure-library/closure/goog/labs/mock/mock_test.html +416 -0
- data/third_party/closure-library/closure/goog/labs/net/image.js +93 -0
- data/third_party/closure-library/closure/goog/labs/net/image_test.html +21 -0
- data/third_party/closure-library/closure/goog/labs/net/image_test.js +128 -0
- data/third_party/closure-library/closure/goog/labs/net/testdata/cleardot.gif +0 -0
- data/third_party/closure-library/closure/goog/labs/net/testdata/xhr_test_json.data +2 -0
- data/third_party/closure-library/closure/goog/labs/net/testdata/xhr_test_text.data +1 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel.js +188 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/basetestchannel.js +639 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/channel.js +195 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/requeststats.js +391 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/webchannelbase.js +2171 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/webchannelbase_test.html +22 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/webchannelbase_test.js +1400 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/webchannelbasetransport.js +274 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/webchannelbasetransport_test.html +228 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/webchanneldebug.js +298 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/webchannelrequest.js +1291 -0
- data/third_party/closure-library/closure/goog/labs/net/webchannel/webchannelrequest_test.html +287 -0
- data/third_party/closure-library/closure/goog/labs/net/webchanneltransport.js +74 -0
- data/third_party/closure-library/closure/goog/labs/net/webchanneltransportfactory.js +35 -0
- data/third_party/closure-library/closure/goog/labs/net/xhr.js +449 -0
- data/third_party/closure-library/closure/goog/labs/net/xhr_test.html +455 -0
- data/third_party/closure-library/closure/goog/labs/object/object.js +46 -0
- data/third_party/closure-library/closure/goog/labs/object/object_test.html +56 -0
- data/third_party/closure-library/closure/goog/labs/observe/notice.js +63 -0
- data/third_party/closure-library/closure/goog/labs/observe/observable.js +77 -0
- data/third_party/closure-library/closure/goog/labs/observe/observableset.js +180 -0
- data/third_party/closure-library/closure/goog/labs/observe/observableset_test.html +207 -0
- data/third_party/closure-library/closure/goog/labs/observe/observationset.js +156 -0
- data/third_party/closure-library/closure/goog/labs/observe/observationset_test.html +252 -0
- data/third_party/closure-library/closure/goog/labs/observe/observer.js +100 -0
- data/third_party/closure-library/closure/goog/labs/observe/observer_test.html +65 -0
- data/third_party/closure-library/closure/goog/labs/observe/simpleobservable.js +129 -0
- data/third_party/closure-library/closure/goog/labs/observe/simpleobservable_test.html +196 -0
- data/third_party/closure-library/closure/goog/labs/structs/map.js +339 -0
- data/third_party/closure-library/closure/goog/labs/structs/map_perf.js +201 -0
- data/third_party/closure-library/closure/goog/labs/structs/map_test.html +434 -0
- data/third_party/closure-library/closure/goog/labs/structs/multimap.js +279 -0
- data/third_party/closure-library/closure/goog/labs/structs/multimap_test.html +332 -0
- data/third_party/closure-library/closure/goog/labs/style/pixeldensitymonitor.js +178 -0
- data/third_party/closure-library/closure/goog/labs/style/pixeldensitymonitor_test.html +17 -0
- data/third_party/closure-library/closure/goog/labs/style/pixeldensitymonitor_test.js +146 -0
- data/third_party/closure-library/closure/goog/labs/testing/assertthat.js +59 -0
- data/third_party/closure-library/closure/goog/labs/testing/assertthat_test.html +73 -0
- data/third_party/closure-library/closure/goog/labs/testing/decoratormatcher.js +94 -0
- data/third_party/closure-library/closure/goog/labs/testing/decoratormatcher_test.html +43 -0
- data/third_party/closure-library/closure/goog/labs/testing/dictionarymatcher.js +266 -0
- data/third_party/closure-library/closure/goog/labs/testing/dictionarymatcher_test.html +70 -0
- data/third_party/closure-library/closure/goog/labs/testing/logicmatcher.js +206 -0
- data/third_party/closure-library/closure/goog/labs/testing/logicmatcher_test.html +59 -0
- data/third_party/closure-library/closure/goog/labs/testing/matcher.js +51 -0
- data/third_party/closure-library/closure/goog/labs/testing/numbermatcher.js +334 -0
- data/third_party/closure-library/closure/goog/labs/testing/numbermatcher_test.html +79 -0
- data/third_party/closure-library/closure/goog/labs/testing/objectmatcher.js +306 -0
- data/third_party/closure-library/closure/goog/labs/testing/objectmatcher_test.html +102 -0
- data/third_party/closure-library/closure/goog/labs/testing/stringmatcher.js +402 -0
- data/third_party/closure-library/closure/goog/labs/testing/stringmatcher_test.html +101 -0
- data/third_party/closure-library/closure/goog/labs/useragent/browser.js +189 -0
- data/third_party/closure-library/closure/goog/labs/useragent/browser_test.html +21 -0
- data/third_party/closure-library/closure/goog/labs/useragent/browser_test.js +193 -0
- data/third_party/closure-library/closure/goog/labs/useragent/device.js +64 -0
- data/third_party/closure-library/closure/goog/labs/useragent/device_test.html +21 -0
- data/third_party/closure-library/closure/goog/labs/useragent/device_test.js +88 -0
- data/third_party/closure-library/closure/goog/labs/useragent/engine.js +144 -0
- data/third_party/closure-library/closure/goog/labs/useragent/engine_test.html +21 -0
- data/third_party/closure-library/closure/goog/labs/useragent/engine_test.js +164 -0
- data/third_party/closure-library/closure/goog/labs/useragent/platform.js +193 -0
- data/third_party/closure-library/closure/goog/labs/useragent/platform_test.html +21 -0
- data/third_party/closure-library/closure/goog/labs/useragent/platform_test.js +256 -0
- data/third_party/closure-library/closure/goog/labs/useragent/test_agents.js +272 -0
- data/third_party/closure-library/closure/goog/labs/useragent/util.js +89 -0
- data/third_party/closure-library/closure/goog/labs/useragent/util_test.html +22 -0
- data/third_party/closure-library/closure/goog/labs/useragent/util_test.js +60 -0
- data/third_party/closure-library/closure/goog/locale/countries.js +291 -0
- data/third_party/closure-library/closure/goog/locale/countrylanguagenames_test.html +237 -0
- data/third_party/closure-library/closure/goog/locale/defaultlocalenameconstants.js +907 -0
- data/third_party/closure-library/closure/goog/locale/genericfontnames.js +73 -0
- data/third_party/closure-library/closure/goog/locale/genericfontnames_test.html +97 -0
- data/third_party/closure-library/closure/goog/locale/genericfontnamesdata.js +327 -0
- data/third_party/closure-library/closure/goog/locale/locale.js +403 -0
- data/third_party/closure-library/closure/goog/locale/nativenameconstants.js +1354 -0
- data/third_party/closure-library/closure/goog/locale/scriptToLanguages.js +482 -0
- data/third_party/closure-library/closure/goog/locale/timezonedetection.js +117 -0
- data/third_party/closure-library/closure/goog/locale/timezonedetection_test.html +130 -0
- data/third_party/closure-library/closure/goog/locale/timezonefingerprint.js +248 -0
- data/third_party/closure-library/closure/goog/locale/timezonelist.js +131 -0
- data/third_party/closure-library/closure/goog/locale/timezonelist_test.html +165 -0
- data/third_party/closure-library/closure/goog/log/log.js +183 -0
- data/third_party/closure-library/closure/goog/log/log_test.js +169 -0
- data/third_party/closure-library/closure/goog/math/bezier.js +311 -0
- data/third_party/closure-library/closure/goog/math/bezier_test.html +112 -0
- data/third_party/closure-library/closure/goog/math/box.js +369 -0
- data/third_party/closure-library/closure/goog/math/box_test.html +298 -0
- data/third_party/closure-library/closure/goog/math/coordinate.js +233 -0
- data/third_party/closure-library/closure/goog/math/coordinate3.js +169 -0
- data/third_party/closure-library/closure/goog/math/coordinate3_test.html +204 -0
- data/third_party/closure-library/closure/goog/math/coordinate_test.html +159 -0
- data/third_party/closure-library/closure/goog/math/exponentialbackoff.js +103 -0
- data/third_party/closure-library/closure/goog/math/exponentialbackoff_test.html +67 -0
- data/third_party/closure-library/closure/goog/math/integer.js +737 -0
- data/third_party/closure-library/closure/goog/math/integer_test.html +1653 -0
- data/third_party/closure-library/closure/goog/math/interpolator/interpolator1.js +64 -0
- data/third_party/closure-library/closure/goog/math/interpolator/linear1.js +82 -0
- data/third_party/closure-library/closure/goog/math/interpolator/linear1_test.html +87 -0
- data/third_party/closure-library/closure/goog/math/interpolator/pchip1.js +81 -0
- data/third_party/closure-library/closure/goog/math/interpolator/pchip1_test.html +74 -0
- data/third_party/closure-library/closure/goog/math/interpolator/spline1.js +202 -0
- data/third_party/closure-library/closure/goog/math/interpolator/spline1_test.html +103 -0
- data/third_party/closure-library/closure/goog/math/line.js +177 -0
- data/third_party/closure-library/closure/goog/math/line_test.html +62 -0
- data/third_party/closure-library/closure/goog/math/long.js +802 -0
- data/third_party/closure-library/closure/goog/math/long_test.html +1571 -0
- data/third_party/closure-library/closure/goog/math/math.js +387 -0
- data/third_party/closure-library/closure/goog/math/math_test.html +292 -0
- data/third_party/closure-library/closure/goog/math/matrix.js +675 -0
- data/third_party/closure-library/closure/goog/math/matrix_test.html +434 -0
- data/third_party/closure-library/closure/goog/math/range.js +144 -0
- data/third_party/closure-library/closure/goog/math/range_test.html +103 -0
- data/third_party/closure-library/closure/goog/math/rangeset.js +394 -0
- data/third_party/closure-library/closure/goog/math/rangeset_test.html +664 -0
- data/third_party/closure-library/closure/goog/math/rect.js +463 -0
- data/third_party/closure-library/closure/goog/math/rect_test.html +444 -0
- data/third_party/closure-library/closure/goog/math/size.js +206 -0
- data/third_party/closure-library/closure/goog/math/size_test.html +180 -0
- data/third_party/closure-library/closure/goog/math/tdma.js +73 -0
- data/third_party/closure-library/closure/goog/math/tdma_test.html +33 -0
- data/third_party/closure-library/closure/goog/math/vec2.js +283 -0
- data/third_party/closure-library/closure/goog/math/vec2_test.html +225 -0
- data/third_party/closure-library/closure/goog/math/vec3.js +308 -0
- data/third_party/closure-library/closure/goog/math/vec3_test.html +221 -0
- data/third_party/closure-library/closure/goog/memoize/memoize.js +102 -0
- data/third_party/closure-library/closure/goog/memoize/memoize_test.html +157 -0
- data/third_party/closure-library/closure/goog/messaging/abstractchannel.js +210 -0
- data/third_party/closure-library/closure/goog/messaging/abstractchannel_test.html +89 -0
- data/third_party/closure-library/closure/goog/messaging/bufferedchannel.js +287 -0
- data/third_party/closure-library/closure/goog/messaging/bufferedchannel_test.html +283 -0
- data/third_party/closure-library/closure/goog/messaging/deferredchannel.js +98 -0
- data/third_party/closure-library/closure/goog/messaging/deferredchannel_test.html +113 -0
- data/third_party/closure-library/closure/goog/messaging/loggerclient.js +131 -0
- data/third_party/closure-library/closure/goog/messaging/loggerclient_test.html +102 -0
- data/third_party/closure-library/closure/goog/messaging/loggerserver.js +98 -0
- data/third_party/closure-library/closure/goog/messaging/loggerserver_test.html +101 -0
- data/third_party/closure-library/closure/goog/messaging/messagechannel.js +116 -0
- data/third_party/closure-library/closure/goog/messaging/messaging.js +34 -0
- data/third_party/closure-library/closure/goog/messaging/messaging_test.html +42 -0
- data/third_party/closure-library/closure/goog/messaging/multichannel.js +302 -0
- data/third_party/closure-library/closure/goog/messaging/multichannel_test.html +122 -0
- data/third_party/closure-library/closure/goog/messaging/portcaller.js +151 -0
- data/third_party/closure-library/closure/goog/messaging/portcaller_test.html +65 -0
- data/third_party/closure-library/closure/goog/messaging/portchannel.js +401 -0
- data/third_party/closure-library/closure/goog/messaging/portchannel_test.html +392 -0
- data/third_party/closure-library/closure/goog/messaging/portnetwork.js +78 -0
- data/third_party/closure-library/closure/goog/messaging/portnetwork_test.html +74 -0
- data/third_party/closure-library/closure/goog/messaging/portoperator.js +197 -0
- data/third_party/closure-library/closure/goog/messaging/portoperator_test.html +112 -0
- data/third_party/closure-library/closure/goog/messaging/respondingchannel.js +236 -0
- data/third_party/closure-library/closure/goog/messaging/respondingchannel_test.html +161 -0
- data/third_party/closure-library/closure/goog/messaging/testdata/portchannel_inner.html +28 -0
- data/third_party/closure-library/closure/goog/messaging/testdata/portchannel_worker.js +37 -0
- data/third_party/closure-library/closure/goog/messaging/testdata/portchannel_wrong_origin_inner.html +29 -0
- data/third_party/closure-library/closure/goog/messaging/testdata/portnetwork_inner.html +34 -0
- data/third_party/closure-library/closure/goog/messaging/testdata/portnetwork_worker1.js +32 -0
- data/third_party/closure-library/closure/goog/messaging/testdata/portnetwork_worker2.js +32 -0
- data/third_party/closure-library/closure/goog/module/abstractmoduleloader.js +56 -0
- data/third_party/closure-library/closure/goog/module/basemodule.js +45 -0
- data/third_party/closure-library/closure/goog/module/loader.js +269 -0
- data/third_party/closure-library/closure/goog/module/module.js +166 -0
- data/third_party/closure-library/closure/goog/module/moduleinfo.js +335 -0
- data/third_party/closure-library/closure/goog/module/moduleinfo_test.html +108 -0
- data/third_party/closure-library/closure/goog/module/moduleloadcallback.js +84 -0
- data/third_party/closure-library/closure/goog/module/moduleloadcallback_test.html +57 -0
- data/third_party/closure-library/closure/goog/module/moduleloader.js +462 -0
- data/third_party/closure-library/closure/goog/module/moduleloader_test.html +30 -0
- data/third_party/closure-library/closure/goog/module/moduleloader_test.js +438 -0
- data/third_party/closure-library/closure/goog/module/modulemanager.js +1370 -0
- data/third_party/closure-library/closure/goog/module/modulemanager_test.html +2143 -0
- data/third_party/closure-library/closure/goog/module/testdata/modA_1.js +23 -0
- data/third_party/closure-library/closure/goog/module/testdata/modA_2.js +27 -0
- data/third_party/closure-library/closure/goog/module/testdata/modB_1.js +31 -0
- data/third_party/closure-library/closure/goog/net/browserchannel.js +2757 -0
- data/third_party/closure-library/closure/goog/net/browserchannel_test.html +1328 -0
- data/third_party/closure-library/closure/goog/net/browsertestchannel.js +618 -0
- data/third_party/closure-library/closure/goog/net/bulkloader.js +181 -0
- data/third_party/closure-library/closure/goog/net/bulkloader_test.html +233 -0
- data/third_party/closure-library/closure/goog/net/bulkloaderhelper.js +127 -0
- data/third_party/closure-library/closure/goog/net/channeldebug.js +300 -0
- data/third_party/closure-library/closure/goog/net/channelrequest.js +1312 -0
- data/third_party/closure-library/closure/goog/net/channelrequest_test.html +280 -0
- data/third_party/closure-library/closure/goog/net/cookies.js +370 -0
- data/third_party/closure-library/closure/goog/net/cookies_test.html +266 -0
- data/third_party/closure-library/closure/goog/net/crossdomainrpc.js +849 -0
- data/third_party/closure-library/closure/goog/net/crossdomainrpc_test.css +7 -0
- data/third_party/closure-library/closure/goog/net/crossdomainrpc_test.gif +0 -0
- data/third_party/closure-library/closure/goog/net/crossdomainrpc_test.html +120 -0
- data/third_party/closure-library/closure/goog/net/crossdomainrpc_test_response.html +59 -0
- data/third_party/closure-library/closure/goog/net/errorcode.js +130 -0
- data/third_party/closure-library/closure/goog/net/eventtype.js +37 -0
- data/third_party/closure-library/closure/goog/net/filedownloader.js +743 -0
- data/third_party/closure-library/closure/goog/net/filedownloader_test.html +372 -0
- data/third_party/closure-library/closure/goog/net/httpstatus.js +111 -0
- data/third_party/closure-library/closure/goog/net/iframe_xhr_test.html +147 -0
- data/third_party/closure-library/closure/goog/net/iframe_xhr_test_response.html +17 -0
- data/third_party/closure-library/closure/goog/net/iframeio.js +1355 -0
- data/third_party/closure-library/closure/goog/net/iframeio_different_base_test.data +2 -0
- data/third_party/closure-library/closure/goog/net/iframeio_different_base_test.html +44 -0
- data/third_party/closure-library/closure/goog/net/iframeio_test.html +402 -0
- data/third_party/closure-library/closure/goog/net/iframeloadmonitor.js +200 -0
- data/third_party/closure-library/closure/goog/net/iframeloadmonitor_test.html +113 -0
- data/third_party/closure-library/closure/goog/net/iframeloadmonitor_test_frame.html +12 -0
- data/third_party/closure-library/closure/goog/net/iframeloadmonitor_test_frame2.html +12 -0
- data/third_party/closure-library/closure/goog/net/iframeloadmonitor_test_frame3.html +12 -0
- data/third_party/closure-library/closure/goog/net/imageloader.js +292 -0
- data/third_party/closure-library/closure/goog/net/imageloader_test.html +302 -0
- data/third_party/closure-library/closure/goog/net/imageloader_testimg1.gif +0 -0
- data/third_party/closure-library/closure/goog/net/imageloader_testimg2.gif +0 -0
- data/third_party/closure-library/closure/goog/net/imageloader_testimg3.gif +0 -0
- data/third_party/closure-library/closure/goog/net/ipaddress.js +511 -0
- data/third_party/closure-library/closure/goog/net/ipaddress_test.html +227 -0
- data/third_party/closure-library/closure/goog/net/jsloader.js +366 -0
- data/third_party/closure-library/closure/goog/net/jsloader_test.html +142 -0
- data/third_party/closure-library/closure/goog/net/jsonp.js +338 -0
- data/third_party/closure-library/closure/goog/net/jsonp_test.html +327 -0
- data/third_party/closure-library/closure/goog/net/mockiframeio.js +319 -0
- data/third_party/closure-library/closure/goog/net/multiiframeloadmonitor.js +117 -0
- data/third_party/closure-library/closure/goog/net/multiiframeloadmonitor_test.html +172 -0
- data/third_party/closure-library/closure/goog/net/networkstatusmonitor.js +47 -0
- data/third_party/closure-library/closure/goog/net/networktester.js +383 -0
- data/third_party/closure-library/closure/goog/net/networktester_test.html +227 -0
- data/third_party/closure-library/closure/goog/net/testdata/jsloader_test1.js +23 -0
- data/third_party/closure-library/closure/goog/net/testdata/jsloader_test2.js +23 -0
- data/third_party/closure-library/closure/goog/net/testdata/jsloader_test3.js +23 -0
- data/third_party/closure-library/closure/goog/net/testdata/jsloader_test4.js +23 -0
- data/third_party/closure-library/closure/goog/net/tmpnetwork.js +164 -0
- data/third_party/closure-library/closure/goog/net/websocket.js +505 -0
- data/third_party/closure-library/closure/goog/net/websocket_test.html +367 -0
- data/third_party/closure-library/closure/goog/net/wrapperxmlhttpfactory.js +68 -0
- data/third_party/closure-library/closure/goog/net/xhrio.js +1191 -0
- data/third_party/closure-library/closure/goog/net/xhrio_test.html +732 -0
- data/third_party/closure-library/closure/goog/net/xhriopool.js +80 -0
- data/third_party/closure-library/closure/goog/net/xhrmanager.js +787 -0
- data/third_party/closure-library/closure/goog/net/xhrmanager_test.html +123 -0
- data/third_party/closure-library/closure/goog/net/xmlhttp.js +228 -0
- data/third_party/closure-library/closure/goog/net/xmlhttpfactory.js +64 -0
- data/third_party/closure-library/closure/goog/net/xpc/crosspagechannel.js +805 -0
- data/third_party/closure-library/closure/goog/net/xpc/crosspagechannel_test.html +1024 -0
- data/third_party/closure-library/closure/goog/net/xpc/crosspagechannelrole.js +30 -0
- data/third_party/closure-library/closure/goog/net/xpc/frameelementmethodtransport.js +254 -0
- data/third_party/closure-library/closure/goog/net/xpc/iframepollingtransport.js +921 -0
- data/third_party/closure-library/closure/goog/net/xpc/iframepollingtransport_test.html +295 -0
- data/third_party/closure-library/closure/goog/net/xpc/iframerelaytransport.js +394 -0
- data/third_party/closure-library/closure/goog/net/xpc/nativemessagingtransport.js +649 -0
- data/third_party/closure-library/closure/goog/net/xpc/nativemessagingtransport_test.html +304 -0
- data/third_party/closure-library/closure/goog/net/xpc/nixtransport.js +479 -0
- data/third_party/closure-library/closure/goog/net/xpc/relay.js +72 -0
- data/third_party/closure-library/closure/goog/net/xpc/testdata/access_checker.html +29 -0
- data/third_party/closure-library/closure/goog/net/xpc/testdata/inner_peer.html +96 -0
- data/third_party/closure-library/closure/goog/net/xpc/transport.js +105 -0
- data/third_party/closure-library/closure/goog/net/xpc/xpc.js +293 -0
- data/third_party/closure-library/closure/goog/object/object.js +635 -0
- data/third_party/closure-library/closure/goog/object/object_test.html +466 -0
- data/third_party/closure-library/closure/goog/positioning/absoluteposition.js +74 -0
- data/third_party/closure-library/closure/goog/positioning/abstractposition.js +48 -0
- data/third_party/closure-library/closure/goog/positioning/anchoredposition.js +92 -0
- data/third_party/closure-library/closure/goog/positioning/anchoredposition_test.html +77 -0
- data/third_party/closure-library/closure/goog/positioning/anchoredviewportposition.js +191 -0
- data/third_party/closure-library/closure/goog/positioning/anchoredviewportposition_test.html +174 -0
- data/third_party/closure-library/closure/goog/positioning/anchoredviewportposition_test_iframe.html +35 -0
- data/third_party/closure-library/closure/goog/positioning/clientposition.js +88 -0
- data/third_party/closure-library/closure/goog/positioning/clientposition_test.html +22 -0
- data/third_party/closure-library/closure/goog/positioning/clientposition_test.js +122 -0
- data/third_party/closure-library/closure/goog/positioning/menuanchoredposition.js +71 -0
- data/third_party/closure-library/closure/goog/positioning/menuanchoredposition_test.html +119 -0
- data/third_party/closure-library/closure/goog/positioning/positioning.js +557 -0
- data/third_party/closure-library/closure/goog/positioning/positioning_test.html +199 -0
- data/third_party/closure-library/closure/goog/positioning/positioning_test.js +1168 -0
- data/third_party/closure-library/closure/goog/positioning/positioning_test_iframe1.html +16 -0
- data/third_party/closure-library/closure/goog/positioning/positioning_test_iframe2.html +13 -0
- data/third_party/closure-library/closure/goog/positioning/positioning_test_quirk.html +9 -0
- data/third_party/closure-library/closure/goog/positioning/positioning_test_standard.html +13 -0
- data/third_party/closure-library/closure/goog/positioning/viewportclientposition.js +121 -0
- data/third_party/closure-library/closure/goog/positioning/viewportclientposition_test.html +189 -0
- data/third_party/closure-library/closure/goog/positioning/viewportposition.js +64 -0
- data/third_party/closure-library/closure/goog/proto/proto.js +44 -0
- data/third_party/closure-library/closure/goog/proto/serializer.js +69 -0
- data/third_party/closure-library/closure/goog/proto/serializer_test.html +43 -0
- data/third_party/closure-library/closure/goog/proto2/descriptor.js +200 -0
- data/third_party/closure-library/closure/goog/proto2/descriptor_test.html +60 -0
- data/third_party/closure-library/closure/goog/proto2/fielddescriptor.js +291 -0
- data/third_party/closure-library/closure/goog/proto2/fielddescriptor_test.html +132 -0
- data/third_party/closure-library/closure/goog/proto2/lazydeserializer.js +70 -0
- data/third_party/closure-library/closure/goog/proto2/message.js +840 -0
- data/third_party/closure-library/closure/goog/proto2/message_test.html +467 -0
- data/third_party/closure-library/closure/goog/proto2/objectserializer.js +159 -0
- data/third_party/closure-library/closure/goog/proto2/objectserializer_test.html +489 -0
- data/third_party/closure-library/closure/goog/proto2/package_test.pb.js +166 -0
- data/third_party/closure-library/closure/goog/proto2/pbliteserializer.js +193 -0
- data/third_party/closure-library/closure/goog/proto2/pbliteserializer_test.html +504 -0
- data/third_party/closure-library/closure/goog/proto2/proto_test.html +693 -0
- data/third_party/closure-library/closure/goog/proto2/serializer.js +174 -0
- data/third_party/closure-library/closure/goog/proto2/test.pb.js +2876 -0
- data/third_party/closure-library/closure/goog/proto2/textformatserializer.js +995 -0
- data/third_party/closure-library/closure/goog/proto2/textformatserializer_test.html +21 -0
- data/third_party/closure-library/closure/goog/proto2/textformatserializer_test.js +629 -0
- data/third_party/closure-library/closure/goog/proto2/util.js +54 -0
- data/third_party/closure-library/closure/goog/pubsub/pubsub.js +326 -0
- data/third_party/closure-library/closure/goog/pubsub/pubsub_perf.html +298 -0
- data/third_party/closure-library/closure/goog/pubsub/pubsub_test.html +635 -0
- data/third_party/closure-library/closure/goog/reflect/reflect.js +77 -0
- data/third_party/closure-library/closure/goog/result/chain_test.html +236 -0
- data/third_party/closure-library/closure/goog/result/combine_test.html +229 -0
- data/third_party/closure-library/closure/goog/result/deferredadaptor.js +57 -0
- data/third_party/closure-library/closure/goog/result/deferredadaptor_test.html +86 -0
- data/third_party/closure-library/closure/goog/result/dependentresult.js +44 -0
- data/third_party/closure-library/closure/goog/result/result_interface.js +109 -0
- data/third_party/closure-library/closure/goog/result/resultutil.js +550 -0
- data/third_party/closure-library/closure/goog/result/resultutil_test.html +46 -0
- data/third_party/closure-library/closure/goog/result/simpleresult.js +217 -0
- data/third_party/closure-library/closure/goog/result/simpleresult_test.html +271 -0
- data/third_party/closure-library/closure/goog/result/transform_test.html +153 -0
- data/third_party/closure-library/closure/goog/result/wait_test.html +211 -0
- data/third_party/closure-library/closure/goog/soy/data.js +132 -0
- data/third_party/closure-library/closure/goog/soy/renderer.js +266 -0
- data/third_party/closure-library/closure/goog/soy/renderer_test.html +172 -0
- data/third_party/closure-library/closure/goog/soy/soy.js +205 -0
- data/third_party/closure-library/closure/goog/soy/soy_test.html +230 -0
- data/third_party/closure-library/closure/goog/soy/soy_test.js +175 -0
- data/third_party/closure-library/closure/goog/spell/spellcheck.js +475 -0
- data/third_party/closure-library/closure/goog/spell/spellcheck_test.html +112 -0
- data/third_party/closure-library/closure/goog/stats/basicstat.js +271 -0
- data/third_party/closure-library/closure/goog/stats/basicstat_test.html +167 -0
- data/third_party/closure-library/closure/goog/storage/collectablestorage.js +100 -0
- data/third_party/closure-library/closure/goog/storage/collectablestorage_test.html +76 -0
- data/third_party/closure-library/closure/goog/storage/encryptedstorage.js +201 -0
- data/third_party/closure-library/closure/goog/storage/encryptedstorage_test.html +160 -0
- data/third_party/closure-library/closure/goog/storage/errorcode.js +30 -0
- data/third_party/closure-library/closure/goog/storage/expiringstorage.js +142 -0
- data/third_party/closure-library/closure/goog/storage/expiringstorage_test.html +90 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/errorcode.js +31 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/errorhandlingmechanism.js +128 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/errorhandlingmechanism_test.html +83 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/html5localstorage.js +45 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/html5localstorage_test.html +60 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/html5sessionstorage.js +46 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/html5sessionstorage_test.html +61 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/html5webstorage.js +176 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/html5webstorage_test.html +122 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/ieuserdata.js +283 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/ieuserdata_test.html +78 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/iterablemechanism.js +86 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/iterablemechanismtester.js +117 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/mechanism.js +56 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/mechanismfactory.js +113 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/mechanismfactory_test.html +58 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/mechanismseparationtester.js +91 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/mechanismsharingtester.js +87 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/mechanismtester.js +200 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/prefixedmechanism.js +97 -0
- data/third_party/closure-library/closure/goog/storage/mechanism/prefixedmechanism_test.html +66 -0
- data/third_party/closure-library/closure/goog/storage/richstorage.js +149 -0
- data/third_party/closure-library/closure/goog/storage/richstorage_test.html +87 -0
- data/third_party/closure-library/closure/goog/storage/storage.js +111 -0
- data/third_party/closure-library/closure/goog/storage/storage_test.html +64 -0
- data/third_party/closure-library/closure/goog/storage/storage_test.js +60 -0
- data/third_party/closure-library/closure/goog/string/linkify.js +236 -0
- data/third_party/closure-library/closure/goog/string/linkify_test.html +441 -0
- data/third_party/closure-library/closure/goog/string/newlines.js +153 -0
- data/third_party/closure-library/closure/goog/string/newlines_test.html +19 -0
- data/third_party/closure-library/closure/goog/string/newlines_test.js +87 -0
- data/third_party/closure-library/closure/goog/string/parser.js +38 -0
- data/third_party/closure-library/closure/goog/string/path.js +169 -0
- data/third_party/closure-library/closure/goog/string/path_test.html +111 -0
- data/third_party/closure-library/closure/goog/string/string.js +1378 -0
- data/third_party/closure-library/closure/goog/string/string_test.html +19 -0
- data/third_party/closure-library/closure/goog/string/string_test.js +1173 -0
- data/third_party/closure-library/closure/goog/string/stringbuffer.js +103 -0
- data/third_party/closure-library/closure/goog/string/stringbuffer_test.html +101 -0
- data/third_party/closure-library/closure/goog/string/stringformat.js +251 -0
- data/third_party/closure-library/closure/goog/string/stringformat_test.html +223 -0
- data/third_party/closure-library/closure/goog/string/stringifier.js +38 -0
- data/third_party/closure-library/closure/goog/structs/avltree.js +835 -0
- data/third_party/closure-library/closure/goog/structs/avltree_test.html +303 -0
- data/third_party/closure-library/closure/goog/structs/circularbuffer.js +223 -0
- data/third_party/closure-library/closure/goog/structs/circularbuffer_test.html +105 -0
- data/third_party/closure-library/closure/goog/structs/collection.js +55 -0
- data/third_party/closure-library/closure/goog/structs/collection_test.html +57 -0
- data/third_party/closure-library/closure/goog/structs/heap.js +333 -0
- data/third_party/closure-library/closure/goog/structs/heap_test.html +220 -0
- data/third_party/closure-library/closure/goog/structs/inversionmap.js +159 -0
- data/third_party/closure-library/closure/goog/structs/inversionmap_test.html +157 -0
- data/third_party/closure-library/closure/goog/structs/linkedmap.js +473 -0
- data/third_party/closure-library/closure/goog/structs/linkedmap_test.html +300 -0
- data/third_party/closure-library/closure/goog/structs/map.js +449 -0
- data/third_party/closure-library/closure/goog/structs/map_test.html +430 -0
- data/third_party/closure-library/closure/goog/structs/node.js +74 -0
- data/third_party/closure-library/closure/goog/structs/pool.js +381 -0
- data/third_party/closure-library/closure/goog/structs/pool_test.html +291 -0
- data/third_party/closure-library/closure/goog/structs/prioritypool.js +184 -0
- data/third_party/closure-library/closure/goog/structs/prioritypool_test.html +588 -0
- data/third_party/closure-library/closure/goog/structs/priorityqueue.js +64 -0
- data/third_party/closure-library/closure/goog/structs/priorityqueue_test.html +179 -0
- data/third_party/closure-library/closure/goog/structs/quadtree.js +571 -0
- data/third_party/closure-library/closure/goog/structs/quadtree_test.html +179 -0
- data/third_party/closure-library/closure/goog/structs/queue.js +157 -0
- data/third_party/closure-library/closure/goog/structs/queue_test.html +140 -0
- data/third_party/closure-library/closure/goog/structs/set.js +274 -0
- data/third_party/closure-library/closure/goog/structs/set_perf.html +271 -0
- data/third_party/closure-library/closure/goog/structs/set_test.html +581 -0
- data/third_party/closure-library/closure/goog/structs/simplepool.js +205 -0
- data/third_party/closure-library/closure/goog/structs/stringset.js +403 -0
- data/third_party/closure-library/closure/goog/structs/stringset_test.html +265 -0
- data/third_party/closure-library/closure/goog/structs/structs.js +351 -0
- data/third_party/closure-library/closure/goog/structs/structs_test.html +1050 -0
- data/third_party/closure-library/closure/goog/structs/treenode.js +428 -0
- data/third_party/closure-library/closure/goog/structs/treenode_test.html +370 -0
- data/third_party/closure-library/closure/goog/structs/trie.js +368 -0
- data/third_party/closure-library/closure/goog/structs/trie_test.html +378 -0
- data/third_party/closure-library/closure/goog/style/bidi.js +182 -0
- data/third_party/closure-library/closure/goog/style/bidi_test.html +211 -0
- data/third_party/closure-library/closure/goog/style/cursor.js +115 -0
- data/third_party/closure-library/closure/goog/style/cursor_test.html +132 -0
- data/third_party/closure-library/closure/goog/style/style.js +2087 -0
- data/third_party/closure-library/closure/goog/style/style_quirks_test.html +530 -0
- data/third_party/closure-library/closure/goog/style/style_test.html +518 -0
- data/third_party/closure-library/closure/goog/style/style_test.js +2602 -0
- data/third_party/closure-library/closure/goog/style/style_test_iframe_quirk.html +27 -0
- data/third_party/closure-library/closure/goog/style/style_test_iframe_standard.html +30 -0
- data/third_party/closure-library/closure/goog/style/style_test_quirk.html +9 -0
- data/third_party/closure-library/closure/goog/style/style_test_standard.html +11 -0
- data/third_party/closure-library/closure/goog/style/style_webkit_scrollbars_test.html +79 -0
- data/third_party/closure-library/closure/goog/style/stylescrollbartester.js +78 -0
- data/third_party/closure-library/closure/goog/style/transition.js +138 -0
- data/third_party/closure-library/closure/goog/style/transition_test.html +124 -0
- data/third_party/closure-library/closure/goog/testing/asserts.js +1243 -0
- data/third_party/closure-library/closure/goog/testing/asserts_test.html +1150 -0
- data/third_party/closure-library/closure/goog/testing/async/mockcontrol.js +174 -0
- data/third_party/closure-library/closure/goog/testing/async/mockcontrol_test.html +223 -0
- data/third_party/closure-library/closure/goog/testing/asynctestcase.js +824 -0
- data/third_party/closure-library/closure/goog/testing/asynctestcase_async_test.html +102 -0
- data/third_party/closure-library/closure/goog/testing/asynctestcase_noasync_test.html +98 -0
- data/third_party/closure-library/closure/goog/testing/asynctestcase_test.html +58 -0
- data/third_party/closure-library/closure/goog/testing/benchmark.js +88 -0
- data/third_party/closure-library/closure/goog/testing/continuationtestcase.js +689 -0
- data/third_party/closure-library/closure/goog/testing/continuationtestcase_test.html +352 -0
- data/third_party/closure-library/closure/goog/testing/deferredtestcase.js +155 -0
- data/third_party/closure-library/closure/goog/testing/deferredtestcase_test.html +140 -0
- data/third_party/closure-library/closure/goog/testing/dom.js +608 -0
- data/third_party/closure-library/closure/goog/testing/dom_test.html +438 -0
- data/third_party/closure-library/closure/goog/testing/editor/dom.js +293 -0
- data/third_party/closure-library/closure/goog/testing/editor/dom_test.html +295 -0
- data/third_party/closure-library/closure/goog/testing/editor/fieldmock.js +99 -0
- data/third_party/closure-library/closure/goog/testing/editor/testhelper.js +176 -0
- data/third_party/closure-library/closure/goog/testing/editor/testhelper_test.html +177 -0
- data/third_party/closure-library/closure/goog/testing/events/eventobserver.js +86 -0
- data/third_party/closure-library/closure/goog/testing/events/eventobserver_test.html +70 -0
- data/third_party/closure-library/closure/goog/testing/events/events.js +713 -0
- data/third_party/closure-library/closure/goog/testing/events/events_test.html +614 -0
- data/third_party/closure-library/closure/goog/testing/events/matchers.js +41 -0
- data/third_party/closure-library/closure/goog/testing/events/matchers_test.html +40 -0
- data/third_party/closure-library/closure/goog/testing/events/onlinehandler.js +64 -0
- data/third_party/closure-library/closure/goog/testing/events/onlinehandler_test.html +89 -0
- data/third_party/closure-library/closure/goog/testing/expectedfailures.js +236 -0
- data/third_party/closure-library/closure/goog/testing/expectedfailures_test.html +122 -0
- data/third_party/closure-library/closure/goog/testing/fs/blob.js +116 -0
- data/third_party/closure-library/closure/goog/testing/fs/blob_test.html +65 -0
- data/third_party/closure-library/closure/goog/testing/fs/directoryentry_test.html +313 -0
- data/third_party/closure-library/closure/goog/testing/fs/entry.js +621 -0
- data/third_party/closure-library/closure/goog/testing/fs/entry_test.html +227 -0
- data/third_party/closure-library/closure/goog/testing/fs/file.js +52 -0
- data/third_party/closure-library/closure/goog/testing/fs/fileentry_test.html +93 -0
- data/third_party/closure-library/closure/goog/testing/fs/filereader.js +272 -0
- data/third_party/closure-library/closure/goog/testing/fs/filereader_test.html +236 -0
- data/third_party/closure-library/closure/goog/testing/fs/filesystem.js +63 -0
- data/third_party/closure-library/closure/goog/testing/fs/filewriter.js +261 -0
- data/third_party/closure-library/closure/goog/testing/fs/filewriter_test.html +325 -0
- data/third_party/closure-library/closure/goog/testing/fs/fs.js +147 -0
- data/third_party/closure-library/closure/goog/testing/fs/fs_test.html +53 -0
- data/third_party/closure-library/closure/goog/testing/fs/integration_test.html +223 -0
- data/third_party/closure-library/closure/goog/testing/fs/progressevent.js +81 -0
- data/third_party/closure-library/closure/goog/testing/functionmock.js +177 -0
- data/third_party/closure-library/closure/goog/testing/functionmock_test.html +511 -0
- data/third_party/closure-library/closure/goog/testing/graphics.js +64 -0
- data/third_party/closure-library/closure/goog/testing/i18n/asserts.js +77 -0
- data/third_party/closure-library/closure/goog/testing/i18n/asserts_test.html +19 -0
- data/third_party/closure-library/closure/goog/testing/i18n/asserts_test.js +67 -0
- data/third_party/closure-library/closure/goog/testing/jsunit.js +156 -0
- data/third_party/closure-library/closure/goog/testing/loosemock.js +240 -0
- data/third_party/closure-library/closure/goog/testing/loosemock_test.html +343 -0
- data/third_party/closure-library/closure/goog/testing/messaging/mockmessagechannel.js +79 -0
- data/third_party/closure-library/closure/goog/testing/messaging/mockmessageevent.js +100 -0
- data/third_party/closure-library/closure/goog/testing/messaging/mockmessageport.js +85 -0
- data/third_party/closure-library/closure/goog/testing/messaging/mockportnetwork.js +65 -0
- data/third_party/closure-library/closure/goog/testing/mock.js +619 -0
- data/third_party/closure-library/closure/goog/testing/mock_test.html +264 -0
- data/third_party/closure-library/closure/goog/testing/mockclassfactory.js +578 -0
- data/third_party/closure-library/closure/goog/testing/mockclassfactory_test.html +241 -0
- data/third_party/closure-library/closure/goog/testing/mockclock.js +520 -0
- data/third_party/closure-library/closure/goog/testing/mockclock_test.html +504 -0
- data/third_party/closure-library/closure/goog/testing/mockcontrol.js +219 -0
- data/third_party/closure-library/closure/goog/testing/mockcontrol_test.html +127 -0
- data/third_party/closure-library/closure/goog/testing/mockinterface.js +45 -0
- data/third_party/closure-library/closure/goog/testing/mockmatchers.js +395 -0
- data/third_party/closure-library/closure/goog/testing/mockmatchers_test.html +388 -0
- data/third_party/closure-library/closure/goog/testing/mockrandom.js +126 -0
- data/third_party/closure-library/closure/goog/testing/mockrandom_test.html +56 -0
- data/third_party/closure-library/closure/goog/testing/mockrange.js +66 -0
- data/third_party/closure-library/closure/goog/testing/mockrange_test.html +41 -0
- data/third_party/closure-library/closure/goog/testing/mockstorage.js +107 -0
- data/third_party/closure-library/closure/goog/testing/mockstorage_test.html +78 -0
- data/third_party/closure-library/closure/goog/testing/mockuseragent.js +141 -0
- data/third_party/closure-library/closure/goog/testing/mockuseragent_test.html +59 -0
- data/third_party/closure-library/closure/goog/testing/multitestrunner.js +1439 -0
- data/third_party/closure-library/closure/goog/testing/net/xhrio.js +709 -0
- data/third_party/closure-library/closure/goog/testing/net/xhrio_test.html +384 -0
- data/third_party/closure-library/closure/goog/testing/net/xhriopool.js +64 -0
- data/third_party/closure-library/closure/goog/testing/objectpropertystring.js +67 -0
- data/third_party/closure-library/closure/goog/testing/performancetable.css +46 -0
- data/third_party/closure-library/closure/goog/testing/performancetable.js +190 -0
- data/third_party/closure-library/closure/goog/testing/performancetimer.js +405 -0
- data/third_party/closure-library/closure/goog/testing/performancetimer_test.html +201 -0
- data/third_party/closure-library/closure/goog/testing/propertyreplacer.js +243 -0
- data/third_party/closure-library/closure/goog/testing/propertyreplacer_test.html +368 -0
- data/third_party/closure-library/closure/goog/testing/proto2/proto2.js +127 -0
- data/third_party/closure-library/closure/goog/testing/proto2/proto2_test.html +117 -0
- data/third_party/closure-library/closure/goog/testing/pseudorandom.js +179 -0
- data/third_party/closure-library/closure/goog/testing/pseudorandom_test.html +98 -0
- data/third_party/closure-library/closure/goog/testing/recordfunction.js +201 -0
- data/third_party/closure-library/closure/goog/testing/recordfunction_test.html +159 -0
- data/third_party/closure-library/closure/goog/testing/shardingtestcase.js +122 -0
- data/third_party/closure-library/closure/goog/testing/shardingtestcase_test.html +34 -0
- data/third_party/closure-library/closure/goog/testing/singleton.js +46 -0
- data/third_party/closure-library/closure/goog/testing/singleton_test.html +39 -0
- data/third_party/closure-library/closure/goog/testing/stacktrace.js +555 -0
- data/third_party/closure-library/closure/goog/testing/stacktrace_test.html +327 -0
- data/third_party/closure-library/closure/goog/testing/storage/fakemechanism.js +66 -0
- data/third_party/closure-library/closure/goog/testing/strictmock.js +128 -0
- data/third_party/closure-library/closure/goog/testing/strictmock_test.html +412 -0
- data/third_party/closure-library/closure/goog/testing/style/layoutasserts.js +310 -0
- data/third_party/closure-library/closure/goog/testing/style/layoutasserts_test.html +269 -0
- data/third_party/closure-library/closure/goog/testing/style/style.js +101 -0
- data/third_party/closure-library/closure/goog/testing/style/style_test.html +162 -0
- data/third_party/closure-library/closure/goog/testing/testcase.js +1233 -0
- data/third_party/closure-library/closure/goog/testing/testqueue.js +66 -0
- data/third_party/closure-library/closure/goog/testing/testrunner.js +399 -0
- data/third_party/closure-library/closure/goog/testing/ui/rendererasserts.js +56 -0
- data/third_party/closure-library/closure/goog/testing/ui/rendererasserts_test.html +52 -0
- data/third_party/closure-library/closure/goog/testing/ui/rendererharness.js +176 -0
- data/third_party/closure-library/closure/goog/testing/ui/style.js +137 -0
- data/third_party/closure-library/closure/goog/testing/ui/style_reference.html +27 -0
- data/third_party/closure-library/closure/goog/testing/ui/style_test.html +130 -0
- data/third_party/closure-library/closure/goog/timer/timer.js +291 -0
- data/third_party/closure-library/closure/goog/timer/timer_test.html +118 -0
- data/third_party/closure-library/closure/goog/tweak/entries.js +997 -0
- data/third_party/closure-library/closure/goog/tweak/entries_test.html +94 -0
- data/third_party/closure-library/closure/goog/tweak/registry.js +310 -0
- data/third_party/closure-library/closure/goog/tweak/registry_test.html +145 -0
- data/third_party/closure-library/closure/goog/tweak/testhelpers.js +119 -0
- data/third_party/closure-library/closure/goog/tweak/tweak.js +301 -0
- data/third_party/closure-library/closure/goog/tweak/tweakui.js +817 -0
- data/third_party/closure-library/closure/goog/tweak/tweakui_test.html +280 -0
- data/third_party/closure-library/closure/goog/ui/abstractspellchecker.js +1138 -0
- data/third_party/closure-library/closure/goog/ui/ac/ac.js +50 -0
- data/third_party/closure-library/closure/goog/ui/ac/ac_test.html +204 -0
- data/third_party/closure-library/closure/goog/ui/ac/arraymatcher.js +162 -0
- data/third_party/closure-library/closure/goog/ui/ac/arraymatcher_test.html +130 -0
- data/third_party/closure-library/closure/goog/ui/ac/autocomplete.js +919 -0
- data/third_party/closure-library/closure/goog/ui/ac/autocomplete_test.html +1613 -0
- data/third_party/closure-library/closure/goog/ui/ac/inputhandler.js +1308 -0
- data/third_party/closure-library/closure/goog/ui/ac/inputhandler_test.html +685 -0
- data/third_party/closure-library/closure/goog/ui/ac/remote.js +114 -0
- data/third_party/closure-library/closure/goog/ui/ac/remotearraymatcher.js +271 -0
- data/third_party/closure-library/closure/goog/ui/ac/remotearraymatcher_test.html +73 -0
- data/third_party/closure-library/closure/goog/ui/ac/renderer.js +1023 -0
- data/third_party/closure-library/closure/goog/ui/ac/renderer_test.html +606 -0
- data/third_party/closure-library/closure/goog/ui/ac/renderoptions.js +80 -0
- data/third_party/closure-library/closure/goog/ui/ac/richinputhandler.js +58 -0
- data/third_party/closure-library/closure/goog/ui/ac/richremote.js +107 -0
- data/third_party/closure-library/closure/goog/ui/ac/richremotearraymatcher.js +125 -0
- data/third_party/closure-library/closure/goog/ui/activitymonitor.js +347 -0
- data/third_party/closure-library/closure/goog/ui/activitymonitor_test.html +150 -0
- data/third_party/closure-library/closure/goog/ui/advancedtooltip.js +366 -0
- data/third_party/closure-library/closure/goog/ui/advancedtooltip_test.html +296 -0
- data/third_party/closure-library/closure/goog/ui/animatedzippy.js +199 -0
- data/third_party/closure-library/closure/goog/ui/animatedzippy_test.html +139 -0
- data/third_party/closure-library/closure/goog/ui/attachablemenu.js +473 -0
- data/third_party/closure-library/closure/goog/ui/bidiinput.js +178 -0
- data/third_party/closure-library/closure/goog/ui/bidiinput_test.html +131 -0
- data/third_party/closure-library/closure/goog/ui/bubble.js +472 -0
- data/third_party/closure-library/closure/goog/ui/button.js +213 -0
- data/third_party/closure-library/closure/goog/ui/button_perf.html +176 -0
- data/third_party/closure-library/closure/goog/ui/button_test.html +257 -0
- data/third_party/closure-library/closure/goog/ui/buttonrenderer.js +214 -0
- data/third_party/closure-library/closure/goog/ui/buttonrenderer_test.html +223 -0
- data/third_party/closure-library/closure/goog/ui/buttonside.js +41 -0
- data/third_party/closure-library/closure/goog/ui/charcounter.js +199 -0
- data/third_party/closure-library/closure/goog/ui/charpicker.js +880 -0
- data/third_party/closure-library/closure/goog/ui/charpicker_test.html +88 -0
- data/third_party/closure-library/closure/goog/ui/checkbox.js +269 -0
- data/third_party/closure-library/closure/goog/ui/checkbox_test.html +370 -0
- data/third_party/closure-library/closure/goog/ui/checkboxmenuitem.js +53 -0
- data/third_party/closure-library/closure/goog/ui/checkboxrenderer.js +171 -0
- data/third_party/closure-library/closure/goog/ui/colorbutton.js +58 -0
- data/third_party/closure-library/closure/goog/ui/colorbutton_test.html +70 -0
- data/third_party/closure-library/closure/goog/ui/colorbuttonrenderer.js +72 -0
- data/third_party/closure-library/closure/goog/ui/colormenubutton.js +215 -0
- data/third_party/closure-library/closure/goog/ui/colormenubuttonrenderer.js +144 -0
- data/third_party/closure-library/closure/goog/ui/colormenubuttonrenderer_test.html +88 -0
- data/third_party/closure-library/closure/goog/ui/colorpalette.js +177 -0
- data/third_party/closure-library/closure/goog/ui/colorpalette_test.html +174 -0
- data/third_party/closure-library/closure/goog/ui/colorpicker.js +344 -0
- data/third_party/closure-library/closure/goog/ui/colorsplitbehavior.js +60 -0
- data/third_party/closure-library/closure/goog/ui/combobox.js +961 -0
- data/third_party/closure-library/closure/goog/ui/combobox_test.html +292 -0
- data/third_party/closure-library/closure/goog/ui/component.js +1300 -0
- data/third_party/closure-library/closure/goog/ui/component_test.html +889 -0
- data/third_party/closure-library/closure/goog/ui/container.js +1322 -0
- data/third_party/closure-library/closure/goog/ui/container_perf.html +55 -0
- data/third_party/closure-library/closure/goog/ui/container_test.html +458 -0
- data/third_party/closure-library/closure/goog/ui/containerrenderer.js +371 -0
- data/third_party/closure-library/closure/goog/ui/containerrenderer_test.html +228 -0
- data/third_party/closure-library/closure/goog/ui/containerscroller.js +222 -0
- data/third_party/closure-library/closure/goog/ui/containerscroller_test.html +214 -0
- data/third_party/closure-library/closure/goog/ui/control.js +1387 -0
- data/third_party/closure-library/closure/goog/ui/control_perf.html +166 -0
- data/third_party/closure-library/closure/goog/ui/control_test.html +2142 -0
- data/third_party/closure-library/closure/goog/ui/controlcontent.js +28 -0
- data/third_party/closure-library/closure/goog/ui/controlrenderer.js +855 -0
- data/third_party/closure-library/closure/goog/ui/controlrenderer_test.html +1100 -0
- data/third_party/closure-library/closure/goog/ui/cookieeditor.js +183 -0
- data/third_party/closure-library/closure/goog/ui/cookieeditor_test.html +107 -0
- data/third_party/closure-library/closure/goog/ui/css3buttonrenderer.js +152 -0
- data/third_party/closure-library/closure/goog/ui/css3menubuttonrenderer.js +147 -0
- data/third_party/closure-library/closure/goog/ui/cssnames.js +29 -0
- data/third_party/closure-library/closure/goog/ui/custombutton.js +58 -0
- data/third_party/closure-library/closure/goog/ui/custombuttonrenderer.js +267 -0
- data/third_party/closure-library/closure/goog/ui/customcolorpalette.js +139 -0
- data/third_party/closure-library/closure/goog/ui/customcolorpalette_test.html +60 -0
- data/third_party/closure-library/closure/goog/ui/datepicker.js +1369 -0
- data/third_party/closure-library/closure/goog/ui/datepicker_test.html +252 -0
- data/third_party/closure-library/closure/goog/ui/datepickerrenderer.js +55 -0
- data/third_party/closure-library/closure/goog/ui/decorate.js +38 -0
- data/third_party/closure-library/closure/goog/ui/decorate_test.html +114 -0
- data/third_party/closure-library/closure/goog/ui/defaultdatepickerrenderer.js +202 -0
- data/third_party/closure-library/closure/goog/ui/dialog.js +1556 -0
- data/third_party/closure-library/closure/goog/ui/dialog_test.html +776 -0
- data/third_party/closure-library/closure/goog/ui/dimensionpicker.js +305 -0
- data/third_party/closure-library/closure/goog/ui/dimensionpicker_test.html +171 -0
- data/third_party/closure-library/closure/goog/ui/dimensionpickerrenderer.js +416 -0
- data/third_party/closure-library/closure/goog/ui/dimensionpickerrenderer_test.html +49 -0
- data/third_party/closure-library/closure/goog/ui/dragdropdetector.js +642 -0
- data/third_party/closure-library/closure/goog/ui/drilldownrow.js +486 -0
- data/third_party/closure-library/closure/goog/ui/drilldownrow_test.html +92 -0
- data/third_party/closure-library/closure/goog/ui/editor/abstractdialog.js +440 -0
- data/third_party/closure-library/closure/goog/ui/editor/abstractdialog_test.html +473 -0
- data/third_party/closure-library/closure/goog/ui/editor/bubble.js +525 -0
- data/third_party/closure-library/closure/goog/ui/editor/bubble_test.html +264 -0
- data/third_party/closure-library/closure/goog/ui/editor/defaulttoolbar.js +1065 -0
- data/third_party/closure-library/closure/goog/ui/editor/equationeditordialog.js +123 -0
- data/third_party/closure-library/closure/goog/ui/editor/equationeditorokevent.js +49 -0
- data/third_party/closure-library/closure/goog/ui/editor/linkdialog.js +1064 -0
- data/third_party/closure-library/closure/goog/ui/editor/linkdialog_test.html +653 -0
- data/third_party/closure-library/closure/goog/ui/editor/messages.js +123 -0
- data/third_party/closure-library/closure/goog/ui/editor/tabpane.js +198 -0
- data/third_party/closure-library/closure/goog/ui/editor/toolbarcontroller.js +295 -0
- data/third_party/closure-library/closure/goog/ui/editor/toolbarfactory.js +440 -0
- data/third_party/closure-library/closure/goog/ui/editor/toolbarfactory_test.html +73 -0
- data/third_party/closure-library/closure/goog/ui/emoji/emoji.js +72 -0
- data/third_party/closure-library/closure/goog/ui/emoji/emojipalette.js +288 -0
- data/third_party/closure-library/closure/goog/ui/emoji/emojipaletterenderer.js +208 -0
- data/third_party/closure-library/closure/goog/ui/emoji/emojipicker.js +804 -0
- data/third_party/closure-library/closure/goog/ui/emoji/emojipicker_test.html +913 -0
- data/third_party/closure-library/closure/goog/ui/emoji/fast_nonprogressive_emojipicker_test.html +256 -0
- data/third_party/closure-library/closure/goog/ui/emoji/fast_progressive_emojipicker_test.html +256 -0
- data/third_party/closure-library/closure/goog/ui/emoji/popupemojipicker.js +410 -0
- data/third_party/closure-library/closure/goog/ui/emoji/popupemojipicker_test.html +80 -0
- data/third_party/closure-library/closure/goog/ui/emoji/progressiveemojipaletterenderer.js +98 -0
- data/third_party/closure-library/closure/goog/ui/emoji/spriteinfo.js +212 -0
- data/third_party/closure-library/closure/goog/ui/emoji/spriteinfo_test.html +51 -0
- data/third_party/closure-library/closure/goog/ui/equation/arrowpalette.js +47 -0
- data/third_party/closure-library/closure/goog/ui/equation/changeevent.js +37 -0
- data/third_party/closure-library/closure/goog/ui/equation/comparisonpalette.js +56 -0
- data/third_party/closure-library/closure/goog/ui/equation/editorpane.js +93 -0
- data/third_party/closure-library/closure/goog/ui/equation/equationeditor.js +220 -0
- data/third_party/closure-library/closure/goog/ui/equation/equationeditordialog.js +137 -0
- data/third_party/closure-library/closure/goog/ui/equation/greekpalette.js +75 -0
- data/third_party/closure-library/closure/goog/ui/equation/imagerenderer.js +190 -0
- data/third_party/closure-library/closure/goog/ui/equation/mathpalette.js +55 -0
- data/third_party/closure-library/closure/goog/ui/equation/menupalette.js +86 -0
- data/third_party/closure-library/closure/goog/ui/equation/palette.js +288 -0
- data/third_party/closure-library/closure/goog/ui/equation/palettemanager.js +203 -0
- data/third_party/closure-library/closure/goog/ui/equation/symbolpalette.js +74 -0
- data/third_party/closure-library/closure/goog/ui/equation/texeditor.js +141 -0
- data/third_party/closure-library/closure/goog/ui/equation/texpane.js +444 -0
- data/third_party/closure-library/closure/goog/ui/filteredmenu.js +575 -0
- data/third_party/closure-library/closure/goog/ui/filteredmenu_test.html +321 -0
- data/third_party/closure-library/closure/goog/ui/filterobservingmenuitem.js +97 -0
- data/third_party/closure-library/closure/goog/ui/filterobservingmenuitemrenderer.js +62 -0
- data/third_party/closure-library/closure/goog/ui/flatbuttonrenderer.js +146 -0
- data/third_party/closure-library/closure/goog/ui/flatmenubuttonrenderer.js +238 -0
- data/third_party/closure-library/closure/goog/ui/formpost.js +109 -0
- data/third_party/closure-library/closure/goog/ui/formpost_test.html +105 -0
- data/third_party/closure-library/closure/goog/ui/gauge.js +1011 -0
- data/third_party/closure-library/closure/goog/ui/gaugetheme.js +169 -0
- data/third_party/closure-library/closure/goog/ui/hovercard.js +456 -0
- data/third_party/closure-library/closure/goog/ui/hovercard_test.html +360 -0
- data/third_party/closure-library/closure/goog/ui/hsvapalette.js +298 -0
- data/third_party/closure-library/closure/goog/ui/hsvapalette_test.html +152 -0
- data/third_party/closure-library/closure/goog/ui/hsvpalette.js +505 -0
- data/third_party/closure-library/closure/goog/ui/hsvpalette_test.html +219 -0
- data/third_party/closure-library/closure/goog/ui/idgenerator.js +57 -0
- data/third_party/closure-library/closure/goog/ui/idletimer.js +299 -0
- data/third_party/closure-library/closure/goog/ui/idletimer_test.html +100 -0
- data/third_party/closure-library/closure/goog/ui/iframemask.js +257 -0
- data/third_party/closure-library/closure/goog/ui/iframemask_test.html +230 -0
- data/third_party/closure-library/closure/goog/ui/imagelessbuttonrenderer.js +204 -0
- data/third_party/closure-library/closure/goog/ui/imagelessmenubuttonrenderer.js +207 -0
- data/third_party/closure-library/closure/goog/ui/inputdatepicker.js +305 -0
- data/third_party/closure-library/closure/goog/ui/inputdatepicker_test.html +111 -0
- data/third_party/closure-library/closure/goog/ui/itemevent.js +50 -0
- data/third_party/closure-library/closure/goog/ui/keyboardshortcuthandler.js +1017 -0
- data/third_party/closure-library/closure/goog/ui/keyboardshortcuthandler_test.html +702 -0
- data/third_party/closure-library/closure/goog/ui/labelinput.js +592 -0
- data/third_party/closure-library/closure/goog/ui/labelinput_test.html +252 -0
- data/third_party/closure-library/closure/goog/ui/linkbuttonrenderer.js +67 -0
- data/third_party/closure-library/closure/goog/ui/media/flashobject.js +631 -0
- data/third_party/closure-library/closure/goog/ui/media/flashobject_test.html +236 -0
- data/third_party/closure-library/closure/goog/ui/media/flickr.js +308 -0
- data/third_party/closure-library/closure/goog/ui/media/flickr_test.html +114 -0
- data/third_party/closure-library/closure/goog/ui/media/googlevideo.js +281 -0
- data/third_party/closure-library/closure/goog/ui/media/googlevideo_test.html +105 -0
- data/third_party/closure-library/closure/goog/ui/media/media.js +285 -0
- data/third_party/closure-library/closure/goog/ui/media/media_test.html +118 -0
- data/third_party/closure-library/closure/goog/ui/media/mediamodel.js +960 -0
- data/third_party/closure-library/closure/goog/ui/media/mediamodel_test.html +108 -0
- data/third_party/closure-library/closure/goog/ui/media/mp3.js +228 -0
- data/third_party/closure-library/closure/goog/ui/media/mp3_test.html +78 -0
- data/third_party/closure-library/closure/goog/ui/media/photo.js +142 -0
- data/third_party/closure-library/closure/goog/ui/media/photo_test.html +62 -0
- data/third_party/closure-library/closure/goog/ui/media/picasa.js +321 -0
- data/third_party/closure-library/closure/goog/ui/media/picasa_test.html +121 -0
- data/third_party/closure-library/closure/goog/ui/media/vimeo.js +276 -0
- data/third_party/closure-library/closure/goog/ui/media/vimeo_test.html +102 -0
- data/third_party/closure-library/closure/goog/ui/media/youtube.js +357 -0
- data/third_party/closure-library/closure/goog/ui/media/youtube_test.html +243 -0
- data/third_party/closure-library/closure/goog/ui/menu.js +476 -0
- data/third_party/closure-library/closure/goog/ui/menu_test.html +167 -0
- data/third_party/closure-library/closure/goog/ui/menubar.js +44 -0
- data/third_party/closure-library/closure/goog/ui/menubardecorator.js +35 -0
- data/third_party/closure-library/closure/goog/ui/menubarrenderer.js +74 -0
- data/third_party/closure-library/closure/goog/ui/menubase.js +190 -0
- data/third_party/closure-library/closure/goog/ui/menubutton.js +903 -0
- data/third_party/closure-library/closure/goog/ui/menubutton_test.html +637 -0
- data/third_party/closure-library/closure/goog/ui/menubutton_test_frame.html +41 -0
- data/third_party/closure-library/closure/goog/ui/menubuttonrenderer.js +266 -0
- data/third_party/closure-library/closure/goog/ui/menubuttonrenderer_test.html +179 -0
- data/third_party/closure-library/closure/goog/ui/menuheader.js +62 -0
- data/third_party/closure-library/closure/goog/ui/menuheaderrenderer.js +54 -0
- data/third_party/closure-library/closure/goog/ui/menuitem.js +233 -0
- data/third_party/closure-library/closure/goog/ui/menuitem_test.html +559 -0
- data/third_party/closure-library/closure/goog/ui/menuitemrenderer.js +358 -0
- data/third_party/closure-library/closure/goog/ui/menuitemrenderer_test.html +201 -0
- data/third_party/closure-library/closure/goog/ui/menurenderer.js +123 -0
- data/third_party/closure-library/closure/goog/ui/menuseparator.js +51 -0
- data/third_party/closure-library/closure/goog/ui/menuseparatorrenderer.js +113 -0
- data/third_party/closure-library/closure/goog/ui/menuseparatorrenderer_test.html +61 -0
- data/third_party/closure-library/closure/goog/ui/mockactivitymonitor.js +71 -0
- data/third_party/closure-library/closure/goog/ui/mockactivitymonitor_test.html +19 -0
- data/third_party/closure-library/closure/goog/ui/mockactivitymonitor_test.js +94 -0
- data/third_party/closure-library/closure/goog/ui/modalpopup.js +698 -0
- data/third_party/closure-library/closure/goog/ui/modalpopup_test.html +419 -0
- data/third_party/closure-library/closure/goog/ui/nativebuttonrenderer.js +207 -0
- data/third_party/closure-library/closure/goog/ui/nativebuttonrenderer_test.html +214 -0
- data/third_party/closure-library/closure/goog/ui/offlineinstalldialog.js +1089 -0
- data/third_party/closure-library/closure/goog/ui/offlinestatuscard.js +580 -0
- data/third_party/closure-library/closure/goog/ui/offlinestatuscomponent.js +540 -0
- data/third_party/closure-library/closure/goog/ui/option.js +68 -0
- data/third_party/closure-library/closure/goog/ui/palette.js +598 -0
- data/third_party/closure-library/closure/goog/ui/palette_test.html +135 -0
- data/third_party/closure-library/closure/goog/ui/paletterenderer.js +372 -0
- data/third_party/closure-library/closure/goog/ui/paletterenderer_test.html +83 -0
- data/third_party/closure-library/closure/goog/ui/plaintextspellchecker.js +672 -0
- data/third_party/closure-library/closure/goog/ui/plaintextspellchecker_test.html +239 -0
- data/third_party/closure-library/closure/goog/ui/popup.js +344 -0
- data/third_party/closure-library/closure/goog/ui/popup_test.html +137 -0
- data/third_party/closure-library/closure/goog/ui/popupbase.js +822 -0
- data/third_party/closure-library/closure/goog/ui/popupbase_test.html +484 -0
- data/third_party/closure-library/closure/goog/ui/popupcolorpicker.js +441 -0
- data/third_party/closure-library/closure/goog/ui/popupcolorpicker_test.html +71 -0
- data/third_party/closure-library/closure/goog/ui/popupdatepicker.js +273 -0
- data/third_party/closure-library/closure/goog/ui/popupmenu.js +557 -0
- data/third_party/closure-library/closure/goog/ui/popupmenu_test.html +308 -0
- data/third_party/closure-library/closure/goog/ui/progressbar.js +401 -0
- data/third_party/closure-library/closure/goog/ui/prompt.js +405 -0
- data/third_party/closure-library/closure/goog/ui/prompt_test.html +144 -0
- data/third_party/closure-library/closure/goog/ui/rangemodel.js +302 -0
- data/third_party/closure-library/closure/goog/ui/rangemodel_test.html +270 -0
- data/third_party/closure-library/closure/goog/ui/ratings.js +451 -0
- data/third_party/closure-library/closure/goog/ui/registry.js +167 -0
- data/third_party/closure-library/closure/goog/ui/registry_test.html +237 -0
- data/third_party/closure-library/closure/goog/ui/richtextspellchecker.js +626 -0
- data/third_party/closure-library/closure/goog/ui/richtextspellchecker_test.html +247 -0
- data/third_party/closure-library/closure/goog/ui/roundedpanel.js +625 -0
- data/third_party/closure-library/closure/goog/ui/roundedpanel_test.html +57 -0
- data/third_party/closure-library/closure/goog/ui/roundedtabrenderer.js +197 -0
- data/third_party/closure-library/closure/goog/ui/scrollfloater.js +585 -0
- data/third_party/closure-library/closure/goog/ui/scrollfloater_test.html +144 -0
- data/third_party/closure-library/closure/goog/ui/select.js +434 -0
- data/third_party/closure-library/closure/goog/ui/select_test.html +235 -0
- data/third_party/closure-library/closure/goog/ui/selectionmenubutton.js +299 -0
- data/third_party/closure-library/closure/goog/ui/selectionmenubutton_test.html +237 -0
- data/third_party/closure-library/closure/goog/ui/selectionmodel.js +300 -0
- data/third_party/closure-library/closure/goog/ui/selectionmodel_test.html +225 -0
- data/third_party/closure-library/closure/goog/ui/separator.js +80 -0
- data/third_party/closure-library/closure/goog/ui/serverchart.js +1837 -0
- data/third_party/closure-library/closure/goog/ui/serverchart_test.html +638 -0
- data/third_party/closure-library/closure/goog/ui/slider.js +126 -0
- data/third_party/closure-library/closure/goog/ui/sliderbase.js +1592 -0
- data/third_party/closure-library/closure/goog/ui/sliderbase_test.html +897 -0
- data/third_party/closure-library/closure/goog/ui/splitbehavior.js +340 -0
- data/third_party/closure-library/closure/goog/ui/splitbehavior_test.html +161 -0
- data/third_party/closure-library/closure/goog/ui/splitpane.js +898 -0
- data/third_party/closure-library/closure/goog/ui/splitpane_test.html +229 -0
- data/third_party/closure-library/closure/goog/ui/style/app/buttonrenderer.js +201 -0
- data/third_party/closure-library/closure/goog/ui/style/app/buttonrenderer_test.html +155 -0
- data/third_party/closure-library/closure/goog/ui/style/app/menubuttonrenderer.js +233 -0
- data/third_party/closure-library/closure/goog/ui/style/app/menubuttonrenderer_test.html +167 -0
- data/third_party/closure-library/closure/goog/ui/style/app/primaryactionbuttonrenderer.js +88 -0
- data/third_party/closure-library/closure/goog/ui/style/app/primaryactionbuttonrenderer_test.html +76 -0
- data/third_party/closure-library/closure/goog/ui/submenu.js +667 -0
- data/third_party/closure-library/closure/goog/ui/submenu_test.html +563 -0
- data/third_party/closure-library/closure/goog/ui/submenurenderer.js +233 -0
- data/third_party/closure-library/closure/goog/ui/tab.js +102 -0
- data/third_party/closure-library/closure/goog/ui/tab_test.html +62 -0
- data/third_party/closure-library/closure/goog/ui/tabbar.js +394 -0
- data/third_party/closure-library/closure/goog/ui/tabbar_test.html +612 -0
- data/third_party/closure-library/closure/goog/ui/tabbarrenderer.js +175 -0
- data/third_party/closure-library/closure/goog/ui/tabbarrenderer_test.html +138 -0
- data/third_party/closure-library/closure/goog/ui/tablesorter.js +325 -0
- data/third_party/closure-library/closure/goog/ui/tablesorter_test.html +197 -0
- data/third_party/closure-library/closure/goog/ui/tabpane.js +675 -0
- data/third_party/closure-library/closure/goog/ui/tabpane_test.html +107 -0
- data/third_party/closure-library/closure/goog/ui/tabrenderer.js +153 -0
- data/third_party/closure-library/closure/goog/ui/tabrenderer_test.html +135 -0
- data/third_party/closure-library/closure/goog/ui/textarea.js +577 -0
- data/third_party/closure-library/closure/goog/ui/textarea_test.html +314 -0
- data/third_party/closure-library/closure/goog/ui/textarearenderer.js +169 -0
- data/third_party/closure-library/closure/goog/ui/togglebutton.js +58 -0
- data/third_party/closure-library/closure/goog/ui/toolbar.js +46 -0
- data/third_party/closure-library/closure/goog/ui/toolbarbutton.js +55 -0
- data/third_party/closure-library/closure/goog/ui/toolbarbuttonrenderer.js +57 -0
- data/third_party/closure-library/closure/goog/ui/toolbarcolormenubutton.js +58 -0
- data/third_party/closure-library/closure/goog/ui/toolbarcolormenubuttonrenderer.js +98 -0
- data/third_party/closure-library/closure/goog/ui/toolbarcolormenubuttonrenderer_test.html +66 -0
- data/third_party/closure-library/closure/goog/ui/toolbarmenubutton.js +57 -0
- data/third_party/closure-library/closure/goog/ui/toolbarmenubuttonrenderer.js +57 -0
- data/third_party/closure-library/closure/goog/ui/toolbarrenderer.js +99 -0
- data/third_party/closure-library/closure/goog/ui/toolbarselect.js +56 -0
- data/third_party/closure-library/closure/goog/ui/toolbarseparator.js +53 -0
- data/third_party/closure-library/closure/goog/ui/toolbarseparatorrenderer.js +91 -0
- data/third_party/closure-library/closure/goog/ui/toolbartogglebutton.js +54 -0
- data/third_party/closure-library/closure/goog/ui/tooltip.js +999 -0
- data/third_party/closure-library/closure/goog/ui/tooltip_test.html +380 -0
- data/third_party/closure-library/closure/goog/ui/tree/basenode.js +1458 -0
- data/third_party/closure-library/closure/goog/ui/tree/basenode_test.html +232 -0
- data/third_party/closure-library/closure/goog/ui/tree/treecontrol.js +663 -0
- data/third_party/closure-library/closure/goog/ui/tree/treecontrol_test.html +113 -0
- data/third_party/closure-library/closure/goog/ui/tree/treenode.js +107 -0
- data/third_party/closure-library/closure/goog/ui/tree/typeahead.js +332 -0
- data/third_party/closure-library/closure/goog/ui/tree/typeahead_test.html +133 -0
- data/third_party/closure-library/closure/goog/ui/tristatemenuitem.js +184 -0
- data/third_party/closure-library/closure/goog/ui/tristatemenuitemrenderer.js +84 -0
- data/third_party/closure-library/closure/goog/ui/twothumbslider.js +157 -0
- data/third_party/closure-library/closure/goog/ui/twothumbslider_test.html +39 -0
- data/third_party/closure-library/closure/goog/ui/zippy.js +445 -0
- data/third_party/closure-library/closure/goog/ui/zippy_test.html +315 -0
- data/third_party/closure-library/closure/goog/uri/uri.js +1502 -0
- data/third_party/closure-library/closure/goog/uri/uri_test.html +21 -0
- data/third_party/closure-library/closure/goog/uri/uri_test.js +1048 -0
- data/third_party/closure-library/closure/goog/uri/utils.js +1053 -0
- data/third_party/closure-library/closure/goog/uri/utils_test.html +562 -0
- data/third_party/closure-library/closure/goog/useragent/adobereader.js +90 -0
- data/third_party/closure-library/closure/goog/useragent/adobereader_test.html +34 -0
- data/third_party/closure-library/closure/goog/useragent/flash.js +153 -0
- data/third_party/closure-library/closure/goog/useragent/flash_test.html +34 -0
- data/third_party/closure-library/closure/goog/useragent/iphoto.js +87 -0
- data/third_party/closure-library/closure/goog/useragent/jscript.js +95 -0
- data/third_party/closure-library/closure/goog/useragent/jscript_test.html +65 -0
- data/third_party/closure-library/closure/goog/useragent/picasa.js +112 -0
- data/third_party/closure-library/closure/goog/useragent/platform.js +82 -0
- data/third_party/closure-library/closure/goog/useragent/platform_test.html +182 -0
- data/third_party/closure-library/closure/goog/useragent/product.js +253 -0
- data/third_party/closure-library/closure/goog/useragent/product_isversion.js +140 -0
- data/third_party/closure-library/closure/goog/useragent/product_test.html +380 -0
- data/third_party/closure-library/closure/goog/useragent/useragent.js +599 -0
- data/third_party/closure-library/closure/goog/useragent/useragent_quirks_test.html +27 -0
- data/third_party/closure-library/closure/goog/useragent/useragent_test.html +300 -0
- data/third_party/closure-library/closure/goog/vec/float32array.js +110 -0
- data/third_party/closure-library/closure/goog/vec/float32array_test.html +69 -0
- data/third_party/closure-library/closure/goog/vec/float64array.js +117 -0
- data/third_party/closure-library/closure/goog/vec/float64array_test.html +69 -0
- data/third_party/closure-library/closure/goog/vec/mat3.js +1211 -0
- data/third_party/closure-library/closure/goog/vec/mat3_test.html +465 -0
- data/third_party/closure-library/closure/goog/vec/mat3d.js +1039 -0
- data/third_party/closure-library/closure/goog/vec/mat3d_test.html +432 -0
- data/third_party/closure-library/closure/goog/vec/mat3f.js +1039 -0
- data/third_party/closure-library/closure/goog/vec/mat3f_test.html +432 -0
- data/third_party/closure-library/closure/goog/vec/mat4.js +1822 -0
- data/third_party/closure-library/closure/goog/vec/mat4_test.html +781 -0
- data/third_party/closure-library/closure/goog/vec/mat4d.js +1769 -0
- data/third_party/closure-library/closure/goog/vec/mat4d_test.html +738 -0
- data/third_party/closure-library/closure/goog/vec/mat4f.js +1769 -0
- data/third_party/closure-library/closure/goog/vec/mat4f_test.html +738 -0
- data/third_party/closure-library/closure/goog/vec/matrix3.js +720 -0
- data/third_party/closure-library/closure/goog/vec/matrix3_test.html +301 -0
- data/third_party/closure-library/closure/goog/vec/matrix4.js +1405 -0
- data/third_party/closure-library/closure/goog/vec/matrix4_test.html +626 -0
- data/third_party/closure-library/closure/goog/vec/quaternion.js +458 -0
- data/third_party/closure-library/closure/goog/vec/quaternion_test.html +195 -0
- data/third_party/closure-library/closure/goog/vec/ray.js +94 -0
- data/third_party/closure-library/closure/goog/vec/ray_test.html +66 -0
- data/third_party/closure-library/closure/goog/vec/vec.js +73 -0
- data/third_party/closure-library/closure/goog/vec/vec2.js +376 -0
- data/third_party/closure-library/closure/goog/vec/vec2_test.html +216 -0
- data/third_party/closure-library/closure/goog/vec/vec2d.js +325 -0
- data/third_party/closure-library/closure/goog/vec/vec2d_test.html +208 -0
- data/third_party/closure-library/closure/goog/vec/vec2f.js +325 -0
- data/third_party/closure-library/closure/goog/vec/vec2f_test.html +208 -0
- data/third_party/closure-library/closure/goog/vec/vec3.js +474 -0
- data/third_party/closure-library/closure/goog/vec/vec3_test.html +258 -0
- data/third_party/closure-library/closure/goog/vec/vec3d.js +358 -0
- data/third_party/closure-library/closure/goog/vec/vec3d_test.html +232 -0
- data/third_party/closure-library/closure/goog/vec/vec3f.js +358 -0
- data/third_party/closure-library/closure/goog/vec/vec3f_test.html +232 -0
- data/third_party/closure-library/closure/goog/vec/vec4.js +406 -0
- data/third_party/closure-library/closure/goog/vec/vec4_test.html +192 -0
- data/third_party/closure-library/closure/goog/vec/vec4d.js +293 -0
- data/third_party/closure-library/closure/goog/vec/vec4d_test.html +168 -0
- data/third_party/closure-library/closure/goog/vec/vec4f.js +293 -0
- data/third_party/closure-library/closure/goog/vec/vec4f_test.html +168 -0
- data/third_party/closure-library/closure/goog/vec/vec_array_perf.html +443 -0
- data/third_party/closure-library/closure/goog/vec/vec_perf.html +101 -0
- data/third_party/closure-library/closure/goog/webgl/webgl.js +2194 -0
- data/third_party/closure-library/closure/goog/window/window.js +225 -0
- data/third_party/closure-library/closure/goog/window/window_test.html +239 -0
- data/third_party/closure-library/closure/known_issues/testdata/closure_library_warnings.txt +47 -0
- data/third_party/closure-library/third_party/closure/goog/base.js +2 -0
- data/third_party/closure-library/third_party/closure/goog/caja/string/html/htmlparser.js +611 -0
- data/third_party/closure-library/third_party/closure/goog/caja/string/html/htmlsanitizer.js +605 -0
- data/third_party/closure-library/third_party/closure/goog/deps.js +20 -0
- data/third_party/closure-library/third_party/closure/goog/dojo/dom/query.js +1543 -0
- data/third_party/closure-library/third_party/closure/goog/dojo/dom/query_compiled_test.html +65 -0
- data/third_party/closure-library/third_party/closure/goog/dojo/dom/query_test.html +64 -0
- data/third_party/closure-library/third_party/closure/goog/dojo/dom/query_test.js +158 -0
- data/third_party/closure-library/third_party/closure/goog/jpeg_encoder/jpeg_encoder_basic.js +751 -0
- data/third_party/closure-library/third_party/closure/goog/loremipsum/text/loremipsum.js +712 -0
- data/third_party/closure-library/third_party/closure/goog/loremipsum/text/loremipsum_test.html +60 -0
- data/third_party/closure-library/third_party/closure/goog/mochikit/async/deferred.js +764 -0
- data/third_party/closure-library/third_party/closure/goog/mochikit/async/deferred_async_test.html +144 -0
- data/third_party/closure-library/third_party/closure/goog/mochikit/async/deferred_test.html +877 -0
- data/third_party/closure-library/third_party/closure/goog/mochikit/async/deferredlist.js +205 -0
- data/third_party/closure-library/third_party/closure/goog/mochikit/async/deferredlist_test.html +504 -0
- data/third_party/closure-library/third_party/closure/goog/osapi/osapi.js +95 -0
- metadata +2054 -0
@@ -0,0 +1,68 @@
|
|
1
|
+
// Copyright 2013 The Closure Library Authors. All Rights Reserved.
|
2
|
+
//
|
3
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
// you may not use this file except in compliance with the License.
|
5
|
+
// You may obtain a copy of the License at
|
6
|
+
//
|
7
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
//
|
9
|
+
// Unless required by applicable law or agreed to in writing, software
|
10
|
+
// distributed under the License is distributed on an "AS-IS" BASIS,
|
11
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
// See the License for the specific language governing permissions and
|
13
|
+
// limitations under the License.
|
14
|
+
|
15
|
+
|
16
|
+
|
17
|
+
/**
|
18
|
+
* @fileoverview The file contains data tables generated from the ARIA
|
19
|
+
* standard schema http://www.w3.org/TR/wai-aria/.
|
20
|
+
*
|
21
|
+
* This is auto-generated code. Do not manually edit!
|
22
|
+
*/
|
23
|
+
|
24
|
+
goog.provide('goog.a11y.aria.datatables');
|
25
|
+
|
26
|
+
goog.require('goog.a11y.aria.State');
|
27
|
+
goog.require('goog.object');
|
28
|
+
|
29
|
+
|
30
|
+
/**
|
31
|
+
* A map that contains mapping between an ARIA state and the default value
|
32
|
+
* for it. Note that not all ARIA states have default values.
|
33
|
+
*
|
34
|
+
* @type {Object.<!(goog.a11y.aria.State|string), (string|boolean|number)>}
|
35
|
+
*/
|
36
|
+
goog.a11y.aria.DefaultStateValueMap_;
|
37
|
+
|
38
|
+
|
39
|
+
/**
|
40
|
+
* A method that creates a map that contains mapping between an ARIA state and
|
41
|
+
* the default value for it. Note that not all ARIA states have default values.
|
42
|
+
*
|
43
|
+
* @return {Object.<!(goog.a11y.aria.State|string), (string|boolean|number)>}
|
44
|
+
* The names for each of the notification methods.
|
45
|
+
*/
|
46
|
+
goog.a11y.aria.datatables.getDefaultValuesMap = function() {
|
47
|
+
if (!goog.a11y.aria.DefaultStateValueMap_) {
|
48
|
+
goog.a11y.aria.DefaultStateValueMap_ = goog.object.create(
|
49
|
+
goog.a11y.aria.State.ATOMIC, false,
|
50
|
+
goog.a11y.aria.State.AUTOCOMPLETE, 'none',
|
51
|
+
goog.a11y.aria.State.DROPEFFECT, 'none',
|
52
|
+
goog.a11y.aria.State.HASPOPUP, false,
|
53
|
+
goog.a11y.aria.State.LIVE, 'off',
|
54
|
+
goog.a11y.aria.State.MULTILINE, false,
|
55
|
+
goog.a11y.aria.State.MULTISELECTABLE, false,
|
56
|
+
goog.a11y.aria.State.ORIENTATION, 'vertical',
|
57
|
+
goog.a11y.aria.State.READONLY, false,
|
58
|
+
goog.a11y.aria.State.RELEVANT, 'additions text',
|
59
|
+
goog.a11y.aria.State.REQUIRED, false,
|
60
|
+
goog.a11y.aria.State.SORT, 'none',
|
61
|
+
goog.a11y.aria.State.BUSY, false,
|
62
|
+
goog.a11y.aria.State.DISABLED, false,
|
63
|
+
goog.a11y.aria.State.HIDDEN, false,
|
64
|
+
goog.a11y.aria.State.INVALID, 'false');
|
65
|
+
}
|
66
|
+
|
67
|
+
return goog.a11y.aria.DefaultStateValueMap_;
|
68
|
+
};
|
@@ -0,0 +1,216 @@
|
|
1
|
+
// Copyright 2013 The Closure Library Authors. All Rights Reserved.
|
2
|
+
//
|
3
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
// you may not use this file except in compliance with the License.
|
5
|
+
// You may obtain a copy of the License at
|
6
|
+
//
|
7
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
//
|
9
|
+
// Unless required by applicable law or agreed to in writing, software
|
10
|
+
// distributed under the License is distributed on an "AS-IS" BASIS,
|
11
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
// See the License for the specific language governing permissions and
|
13
|
+
// limitations under the License.
|
14
|
+
|
15
|
+
|
16
|
+
/**
|
17
|
+
* @fileoverview The file contains generated enumerations for ARIA roles
|
18
|
+
* as defined by W3C ARIA standard: http://www.w3.org/TR/wai-aria/.
|
19
|
+
*
|
20
|
+
* This is auto-generated code. Do not manually edit! For more details
|
21
|
+
* about how to edit it via the generator check go/closure-ariagen.
|
22
|
+
*/
|
23
|
+
|
24
|
+
goog.provide('goog.a11y.aria.Role');
|
25
|
+
|
26
|
+
|
27
|
+
/**
|
28
|
+
* ARIA role values.
|
29
|
+
* @enum {string}
|
30
|
+
*/
|
31
|
+
goog.a11y.aria.Role = {
|
32
|
+
// ARIA role for an alert element that doesn't need to be explicitly closed.
|
33
|
+
ALERT: 'alert',
|
34
|
+
|
35
|
+
// ARIA role for an alert dialog element that takes focus and must be closed.
|
36
|
+
ALERTDIALOG: 'alertdialog',
|
37
|
+
|
38
|
+
// ARIA role for an application that implements its own keyboard navigation.
|
39
|
+
APPLICATION: 'application',
|
40
|
+
|
41
|
+
// ARIA role for an article.
|
42
|
+
ARTICLE: 'article',
|
43
|
+
|
44
|
+
// ARIA role for a banner containing mostly site content, not page content.
|
45
|
+
BANNER: 'banner',
|
46
|
+
|
47
|
+
// ARIA role for a button element.
|
48
|
+
BUTTON: 'button',
|
49
|
+
|
50
|
+
// ARIA role for a checkbox button element; use with the CHECKED state.
|
51
|
+
CHECKBOX: 'checkbox',
|
52
|
+
|
53
|
+
// ARIA role for a column header of a table or grid.
|
54
|
+
COLUMNHEADER: 'columnheader',
|
55
|
+
|
56
|
+
// ARIA role for a combo box element.
|
57
|
+
COMBOBOX: 'combobox',
|
58
|
+
|
59
|
+
// ARIA role for a supporting section of the document.
|
60
|
+
COMPLEMENTARY: 'complementary',
|
61
|
+
|
62
|
+
// ARIA role for a large perceivable region that contains information
|
63
|
+
// about the parent document.
|
64
|
+
CONTENTINFO: 'contentinfo',
|
65
|
+
|
66
|
+
// ARIA role for a definition of a term or concept.
|
67
|
+
DEFINITION: 'definition',
|
68
|
+
|
69
|
+
// ARIA role for a dialog, some descendant must take initial focus.
|
70
|
+
DIALOG: 'dialog',
|
71
|
+
|
72
|
+
// ARIA role for a directory, like a table of contents.
|
73
|
+
DIRECTORY: 'directory',
|
74
|
+
|
75
|
+
// ARIA role for a part of a page that's a document, not a web application.
|
76
|
+
DOCUMENT: 'document',
|
77
|
+
|
78
|
+
// ARIA role for a landmark region logically considered one form.
|
79
|
+
FORM: 'form',
|
80
|
+
|
81
|
+
// ARIA role for an interactive control of tabular data.
|
82
|
+
GRID: 'grid',
|
83
|
+
|
84
|
+
// ARIA role for a cell in a grid.
|
85
|
+
GRIDCELL: 'gridcell',
|
86
|
+
|
87
|
+
// ARIA role for a group of related elements like tree item siblings.
|
88
|
+
GROUP: 'group',
|
89
|
+
|
90
|
+
// ARIA role for a heading element.
|
91
|
+
HEADING: 'heading',
|
92
|
+
|
93
|
+
// ARIA role for a container of elements that together comprise one image.
|
94
|
+
IMG: 'img',
|
95
|
+
|
96
|
+
// ARIA role for a link.
|
97
|
+
LINK: 'link',
|
98
|
+
|
99
|
+
// ARIA role for a list of non-interactive list items.
|
100
|
+
LIST: 'list',
|
101
|
+
|
102
|
+
// ARIA role for a listbox.
|
103
|
+
LISTBOX: 'listbox',
|
104
|
+
|
105
|
+
// ARIA role for a list item.
|
106
|
+
LISTITEM: 'listitem',
|
107
|
+
|
108
|
+
// ARIA role for a live region where new information is added.
|
109
|
+
LOG: 'log',
|
110
|
+
|
111
|
+
// ARIA landmark role for the main content in a document. Use only once.
|
112
|
+
MAIN: 'main',
|
113
|
+
|
114
|
+
// ARIA role for a live region of non-essential information that changes.
|
115
|
+
MARQUEE: 'marquee',
|
116
|
+
|
117
|
+
// ARIA role for a mathematical expression.
|
118
|
+
MATH: 'math',
|
119
|
+
|
120
|
+
// ARIA role for a popup menu.
|
121
|
+
MENU: 'menu',
|
122
|
+
|
123
|
+
// ARIA role for a menubar element containing menu elements.
|
124
|
+
MENUBAR: 'menubar',
|
125
|
+
|
126
|
+
// ARIA role for menu item elements.
|
127
|
+
MENU_ITEM: 'menuitem',
|
128
|
+
|
129
|
+
// ARIA role for a checkbox box element inside a menu.
|
130
|
+
MENU_ITEM_CHECKBOX: 'menuitemcheckbox',
|
131
|
+
|
132
|
+
// ARIA role for a radio button element inside a menu.
|
133
|
+
MENU_ITEM_RADIO: 'menuitemradio',
|
134
|
+
|
135
|
+
// ARIA landmark role for a collection of navigation links.
|
136
|
+
NAVIGATION: 'navigation',
|
137
|
+
|
138
|
+
// ARIA role for a section ancillary to the main content.
|
139
|
+
NOTE: 'note',
|
140
|
+
|
141
|
+
// ARIA role for option items that are children of combobox, listbox, menu,
|
142
|
+
// radiogroup, or tree elements.
|
143
|
+
OPTION: 'option',
|
144
|
+
|
145
|
+
// ARIA role for ignorable cosmetic elements with no semantic significance.
|
146
|
+
PRESENTATION: 'presentation',
|
147
|
+
|
148
|
+
// ARIA role for a progress bar element.
|
149
|
+
PROGRESSBAR: 'progressbar',
|
150
|
+
|
151
|
+
// ARIA role for a radio button element.
|
152
|
+
RADIO: 'radio',
|
153
|
+
|
154
|
+
// ARIA role for a group of connected radio button elements.
|
155
|
+
RADIOGROUP: 'radiogroup',
|
156
|
+
|
157
|
+
// ARIA role for an important region of the page.
|
158
|
+
REGION: 'region',
|
159
|
+
|
160
|
+
// ARIA role for a row of cells in a grid.
|
161
|
+
ROW: 'row',
|
162
|
+
|
163
|
+
// ARIA role for a group of one or more rows in a grid.
|
164
|
+
ROWGROUP: 'rowgroup',
|
165
|
+
|
166
|
+
// ARIA role for a row header of a table or grid.
|
167
|
+
ROWHEADER: 'rowheader',
|
168
|
+
|
169
|
+
// ARIA role for a scrollbar element.
|
170
|
+
SCROLLBAR: 'scrollbar',
|
171
|
+
|
172
|
+
// ARIA landmark role for a part of the page providing search functionality.
|
173
|
+
SEARCH: 'search',
|
174
|
+
|
175
|
+
// ARIA role for a menu separator.
|
176
|
+
SEPARATOR: 'separator',
|
177
|
+
|
178
|
+
// ARIA role for a slider.
|
179
|
+
SLIDER: 'slider',
|
180
|
+
|
181
|
+
// ARIA role for a spin button.
|
182
|
+
SPINBUTTON: 'spinbutton',
|
183
|
+
|
184
|
+
// ARIA role for a live region with advisory info less severe than an alert.
|
185
|
+
STATUS: 'status',
|
186
|
+
|
187
|
+
// ARIA role for a tab button.
|
188
|
+
TAB: 'tab',
|
189
|
+
|
190
|
+
// ARIA role for a tab bar (i.e. a list of tab buttons).
|
191
|
+
TAB_LIST: 'tablist',
|
192
|
+
|
193
|
+
// ARIA role for a tab page (i.e. the element holding tab contents).
|
194
|
+
TAB_PANEL: 'tabpanel',
|
195
|
+
|
196
|
+
// ARIA role for a textbox element.
|
197
|
+
TEXTBOX: 'textbox',
|
198
|
+
|
199
|
+
// ARIA role for an element displaying elapsed time or time remaining.
|
200
|
+
TIMER: 'timer',
|
201
|
+
|
202
|
+
// ARIA role for a toolbar element.
|
203
|
+
TOOLBAR: 'toolbar',
|
204
|
+
|
205
|
+
// ARIA role for a tooltip element.
|
206
|
+
TOOLTIP: 'tooltip',
|
207
|
+
|
208
|
+
// ARIA role for a tree.
|
209
|
+
TREE: 'tree',
|
210
|
+
|
211
|
+
// ARIA role for a grid whose rows can be expanded and collapsed like a tree.
|
212
|
+
TREEGRID: 'treegrid',
|
213
|
+
|
214
|
+
// ARIA role for a tree item that sometimes may be expanded or collapsed.
|
215
|
+
TREEITEM: 'treeitem'
|
216
|
+
};
|
@@ -0,0 +1,1507 @@
|
|
1
|
+
// Copyright 2006 The Closure Library Authors. All Rights Reserved.
|
2
|
+
//
|
3
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
// you may not use this file except in compliance with the License.
|
5
|
+
// You may obtain a copy of the License at
|
6
|
+
//
|
7
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
//
|
9
|
+
// Unless required by applicable law or agreed to in writing, software
|
10
|
+
// distributed under the License is distributed on an "AS-IS" BASIS,
|
11
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
// See the License for the specific language governing permissions and
|
13
|
+
// limitations under the License.
|
14
|
+
|
15
|
+
/**
|
16
|
+
* @fileoverview Utilities for manipulating arrays.
|
17
|
+
*
|
18
|
+
*/
|
19
|
+
|
20
|
+
|
21
|
+
goog.provide('goog.array');
|
22
|
+
goog.provide('goog.array.ArrayLike');
|
23
|
+
|
24
|
+
goog.require('goog.asserts');
|
25
|
+
|
26
|
+
|
27
|
+
/**
|
28
|
+
* @define {boolean} NATIVE_ARRAY_PROTOTYPES indicates whether the code should
|
29
|
+
* rely on Array.prototype functions, if available.
|
30
|
+
*
|
31
|
+
* The Array.prototype functions can be defined by external libraries like
|
32
|
+
* Prototype and setting this flag to false forces closure to use its own
|
33
|
+
* goog.array implementation.
|
34
|
+
*
|
35
|
+
* If your javascript can be loaded by a third party site and you are wary about
|
36
|
+
* relying on the prototype functions, specify
|
37
|
+
* "--define goog.NATIVE_ARRAY_PROTOTYPES=false" to the JSCompiler.
|
38
|
+
*
|
39
|
+
* Setting goog.TRUSTED_SITE to false will automatically set
|
40
|
+
* NATIVE_ARRAY_PROTOTYPES to false.
|
41
|
+
*/
|
42
|
+
goog.define('goog.NATIVE_ARRAY_PROTOTYPES', goog.TRUSTED_SITE);
|
43
|
+
|
44
|
+
|
45
|
+
/**
|
46
|
+
* @typedef {Array|NodeList|Arguments|{length: number}}
|
47
|
+
*/
|
48
|
+
goog.array.ArrayLike;
|
49
|
+
|
50
|
+
|
51
|
+
/**
|
52
|
+
* Returns the last element in an array without removing it.
|
53
|
+
* @param {goog.array.ArrayLike} array The array.
|
54
|
+
* @return {*} Last item in array.
|
55
|
+
*/
|
56
|
+
goog.array.peek = function(array) {
|
57
|
+
return array[array.length - 1];
|
58
|
+
};
|
59
|
+
|
60
|
+
|
61
|
+
/**
|
62
|
+
* Reference to the original {@code Array.prototype}.
|
63
|
+
* @private
|
64
|
+
*/
|
65
|
+
goog.array.ARRAY_PROTOTYPE_ = Array.prototype;
|
66
|
+
|
67
|
+
|
68
|
+
// NOTE(arv): Since most of the array functions are generic it allows you to
|
69
|
+
// pass an array-like object. Strings have a length and are considered array-
|
70
|
+
// like. However, the 'in' operator does not work on strings so we cannot just
|
71
|
+
// use the array path even if the browser supports indexing into strings. We
|
72
|
+
// therefore end up splitting the string.
|
73
|
+
|
74
|
+
|
75
|
+
/**
|
76
|
+
* Returns the index of the first element of an array with a specified
|
77
|
+
* value, or -1 if the element is not present in the array.
|
78
|
+
*
|
79
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-indexof}
|
80
|
+
*
|
81
|
+
* @param {goog.array.ArrayLike} arr The array to be searched.
|
82
|
+
* @param {*} obj The object for which we are searching.
|
83
|
+
* @param {number=} opt_fromIndex The index at which to start the search. If
|
84
|
+
* omitted the search starts at index 0.
|
85
|
+
* @return {number} The index of the first matching array element.
|
86
|
+
*/
|
87
|
+
goog.array.indexOf = goog.NATIVE_ARRAY_PROTOTYPES &&
|
88
|
+
goog.array.ARRAY_PROTOTYPE_.indexOf ?
|
89
|
+
function(arr, obj, opt_fromIndex) {
|
90
|
+
goog.asserts.assert(arr.length != null);
|
91
|
+
|
92
|
+
return goog.array.ARRAY_PROTOTYPE_.indexOf.call(arr, obj, opt_fromIndex);
|
93
|
+
} :
|
94
|
+
function(arr, obj, opt_fromIndex) {
|
95
|
+
var fromIndex = opt_fromIndex == null ?
|
96
|
+
0 : (opt_fromIndex < 0 ?
|
97
|
+
Math.max(0, arr.length + opt_fromIndex) : opt_fromIndex);
|
98
|
+
|
99
|
+
if (goog.isString(arr)) {
|
100
|
+
// Array.prototype.indexOf uses === so only strings should be found.
|
101
|
+
if (!goog.isString(obj) || obj.length != 1) {
|
102
|
+
return -1;
|
103
|
+
}
|
104
|
+
return arr.indexOf(obj, fromIndex);
|
105
|
+
}
|
106
|
+
|
107
|
+
for (var i = fromIndex; i < arr.length; i++) {
|
108
|
+
if (i in arr && arr[i] === obj)
|
109
|
+
return i;
|
110
|
+
}
|
111
|
+
return -1;
|
112
|
+
};
|
113
|
+
|
114
|
+
|
115
|
+
/**
|
116
|
+
* Returns the index of the last element of an array with a specified value, or
|
117
|
+
* -1 if the element is not present in the array.
|
118
|
+
*
|
119
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-lastindexof}
|
120
|
+
*
|
121
|
+
* @param {goog.array.ArrayLike} arr The array to be searched.
|
122
|
+
* @param {*} obj The object for which we are searching.
|
123
|
+
* @param {?number=} opt_fromIndex The index at which to start the search. If
|
124
|
+
* omitted the search starts at the end of the array.
|
125
|
+
* @return {number} The index of the last matching array element.
|
126
|
+
*/
|
127
|
+
goog.array.lastIndexOf = goog.NATIVE_ARRAY_PROTOTYPES &&
|
128
|
+
goog.array.ARRAY_PROTOTYPE_.lastIndexOf ?
|
129
|
+
function(arr, obj, opt_fromIndex) {
|
130
|
+
goog.asserts.assert(arr.length != null);
|
131
|
+
|
132
|
+
// Firefox treats undefined and null as 0 in the fromIndex argument which
|
133
|
+
// leads it to always return -1
|
134
|
+
var fromIndex = opt_fromIndex == null ? arr.length - 1 : opt_fromIndex;
|
135
|
+
return goog.array.ARRAY_PROTOTYPE_.lastIndexOf.call(arr, obj, fromIndex);
|
136
|
+
} :
|
137
|
+
function(arr, obj, opt_fromIndex) {
|
138
|
+
var fromIndex = opt_fromIndex == null ? arr.length - 1 : opt_fromIndex;
|
139
|
+
|
140
|
+
if (fromIndex < 0) {
|
141
|
+
fromIndex = Math.max(0, arr.length + fromIndex);
|
142
|
+
}
|
143
|
+
|
144
|
+
if (goog.isString(arr)) {
|
145
|
+
// Array.prototype.lastIndexOf uses === so only strings should be found.
|
146
|
+
if (!goog.isString(obj) || obj.length != 1) {
|
147
|
+
return -1;
|
148
|
+
}
|
149
|
+
return arr.lastIndexOf(obj, fromIndex);
|
150
|
+
}
|
151
|
+
|
152
|
+
for (var i = fromIndex; i >= 0; i--) {
|
153
|
+
if (i in arr && arr[i] === obj)
|
154
|
+
return i;
|
155
|
+
}
|
156
|
+
return -1;
|
157
|
+
};
|
158
|
+
|
159
|
+
|
160
|
+
/**
|
161
|
+
* Calls a function for each element in an array. Skips holes in the array.
|
162
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-foreach}
|
163
|
+
*
|
164
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array like object over
|
165
|
+
* which to iterate.
|
166
|
+
* @param {?function(this: S, T, number, ?): ?} f The function to call for every
|
167
|
+
* element. This function takes 3 arguments (the element, the index and the
|
168
|
+
* array). The return value is ignored.
|
169
|
+
* @param {S=} opt_obj The object to be used as the value of 'this' within f.
|
170
|
+
* @template T,S
|
171
|
+
*/
|
172
|
+
goog.array.forEach = goog.NATIVE_ARRAY_PROTOTYPES &&
|
173
|
+
goog.array.ARRAY_PROTOTYPE_.forEach ?
|
174
|
+
function(arr, f, opt_obj) {
|
175
|
+
goog.asserts.assert(arr.length != null);
|
176
|
+
|
177
|
+
goog.array.ARRAY_PROTOTYPE_.forEach.call(arr, f, opt_obj);
|
178
|
+
} :
|
179
|
+
function(arr, f, opt_obj) {
|
180
|
+
var l = arr.length; // must be fixed during loop... see docs
|
181
|
+
var arr2 = goog.isString(arr) ? arr.split('') : arr;
|
182
|
+
for (var i = 0; i < l; i++) {
|
183
|
+
if (i in arr2) {
|
184
|
+
f.call(opt_obj, arr2[i], i, arr);
|
185
|
+
}
|
186
|
+
}
|
187
|
+
};
|
188
|
+
|
189
|
+
|
190
|
+
/**
|
191
|
+
* Calls a function for each element in an array, starting from the last
|
192
|
+
* element rather than the first.
|
193
|
+
*
|
194
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
195
|
+
* like object over which to iterate.
|
196
|
+
* @param {?function(this: S, T, number, ?): ?} f The function to call for every
|
197
|
+
* element. This function
|
198
|
+
* takes 3 arguments (the element, the index and the array). The return
|
199
|
+
* value is ignored.
|
200
|
+
* @param {S=} opt_obj The object to be used as the value of 'this'
|
201
|
+
* within f.
|
202
|
+
* @template T,S
|
203
|
+
*/
|
204
|
+
goog.array.forEachRight = function(arr, f, opt_obj) {
|
205
|
+
var l = arr.length; // must be fixed during loop... see docs
|
206
|
+
var arr2 = goog.isString(arr) ? arr.split('') : arr;
|
207
|
+
for (var i = l - 1; i >= 0; --i) {
|
208
|
+
if (i in arr2) {
|
209
|
+
f.call(opt_obj, arr2[i], i, arr);
|
210
|
+
}
|
211
|
+
}
|
212
|
+
};
|
213
|
+
|
214
|
+
|
215
|
+
/**
|
216
|
+
* Calls a function for each element in an array, and if the function returns
|
217
|
+
* true adds the element to a new array.
|
218
|
+
*
|
219
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-filter}
|
220
|
+
*
|
221
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
222
|
+
* like object over which to iterate.
|
223
|
+
* @param {?function(this:S, T, number, ?):boolean} f The function to call for
|
224
|
+
* every element. This function
|
225
|
+
* takes 3 arguments (the element, the index and the array) and must
|
226
|
+
* return a Boolean. If the return value is true the element is added to the
|
227
|
+
* result array. If it is false the element is not included.
|
228
|
+
* @param {S=} opt_obj The object to be used as the value of 'this'
|
229
|
+
* within f.
|
230
|
+
* @return {!Array} a new array in which only elements that passed the test are
|
231
|
+
* present.
|
232
|
+
* @template T,S
|
233
|
+
*/
|
234
|
+
goog.array.filter = goog.NATIVE_ARRAY_PROTOTYPES &&
|
235
|
+
goog.array.ARRAY_PROTOTYPE_.filter ?
|
236
|
+
function(arr, f, opt_obj) {
|
237
|
+
goog.asserts.assert(arr.length != null);
|
238
|
+
|
239
|
+
return goog.array.ARRAY_PROTOTYPE_.filter.call(arr, f, opt_obj);
|
240
|
+
} :
|
241
|
+
function(arr, f, opt_obj) {
|
242
|
+
var l = arr.length; // must be fixed during loop... see docs
|
243
|
+
var res = [];
|
244
|
+
var resLength = 0;
|
245
|
+
var arr2 = goog.isString(arr) ? arr.split('') : arr;
|
246
|
+
for (var i = 0; i < l; i++) {
|
247
|
+
if (i in arr2) {
|
248
|
+
var val = arr2[i]; // in case f mutates arr2
|
249
|
+
if (f.call(opt_obj, val, i, arr)) {
|
250
|
+
res[resLength++] = val;
|
251
|
+
}
|
252
|
+
}
|
253
|
+
}
|
254
|
+
return res;
|
255
|
+
};
|
256
|
+
|
257
|
+
|
258
|
+
/**
|
259
|
+
* Calls a function for each element in an array and inserts the result into a
|
260
|
+
* new array.
|
261
|
+
*
|
262
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-map}
|
263
|
+
*
|
264
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
265
|
+
* like object over which to iterate.
|
266
|
+
* @param {?function(this:S, T, number, ?):?} f The function to call for every
|
267
|
+
* element. This function
|
268
|
+
* takes 3 arguments (the element, the index and the array) and should
|
269
|
+
* return something. The result will be inserted into a new array.
|
270
|
+
* @param {S=} opt_obj The object to be used as the value of 'this'
|
271
|
+
* within f.
|
272
|
+
* @return {!Array} a new array with the results from f.
|
273
|
+
* @template T,S
|
274
|
+
*/
|
275
|
+
goog.array.map = goog.NATIVE_ARRAY_PROTOTYPES &&
|
276
|
+
goog.array.ARRAY_PROTOTYPE_.map ?
|
277
|
+
function(arr, f, opt_obj) {
|
278
|
+
goog.asserts.assert(arr.length != null);
|
279
|
+
|
280
|
+
return goog.array.ARRAY_PROTOTYPE_.map.call(arr, f, opt_obj);
|
281
|
+
} :
|
282
|
+
function(arr, f, opt_obj) {
|
283
|
+
var l = arr.length; // must be fixed during loop... see docs
|
284
|
+
var res = new Array(l);
|
285
|
+
var arr2 = goog.isString(arr) ? arr.split('') : arr;
|
286
|
+
for (var i = 0; i < l; i++) {
|
287
|
+
if (i in arr2) {
|
288
|
+
res[i] = f.call(opt_obj, arr2[i], i, arr);
|
289
|
+
}
|
290
|
+
}
|
291
|
+
return res;
|
292
|
+
};
|
293
|
+
|
294
|
+
|
295
|
+
/**
|
296
|
+
* Passes every element of an array into a function and accumulates the result.
|
297
|
+
*
|
298
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-reduce}
|
299
|
+
*
|
300
|
+
* For example:
|
301
|
+
* var a = [1, 2, 3, 4];
|
302
|
+
* goog.array.reduce(a, function(r, v, i, arr) {return r + v;}, 0);
|
303
|
+
* returns 10
|
304
|
+
*
|
305
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
306
|
+
* like object over which to iterate.
|
307
|
+
* @param {?function(this:S, R, T, number, ?) : R} f The function to call for
|
308
|
+
* every element. This function
|
309
|
+
* takes 4 arguments (the function's previous result or the initial value,
|
310
|
+
* the value of the current array element, the current array index, and the
|
311
|
+
* array itself)
|
312
|
+
* function(previousValue, currentValue, index, array).
|
313
|
+
* @param {?} val The initial value to pass into the function on the first call.
|
314
|
+
* @param {S=} opt_obj The object to be used as the value of 'this'
|
315
|
+
* within f.
|
316
|
+
* @return {R} Result of evaluating f repeatedly across the values of the array.
|
317
|
+
* @template T,S,R
|
318
|
+
*/
|
319
|
+
goog.array.reduce = function(arr, f, val, opt_obj) {
|
320
|
+
if (arr.reduce) {
|
321
|
+
if (opt_obj) {
|
322
|
+
return arr.reduce(goog.bind(f, opt_obj), val);
|
323
|
+
} else {
|
324
|
+
return arr.reduce(f, val);
|
325
|
+
}
|
326
|
+
}
|
327
|
+
var rval = val;
|
328
|
+
goog.array.forEach(arr, function(val, index) {
|
329
|
+
rval = f.call(opt_obj, rval, val, index, arr);
|
330
|
+
});
|
331
|
+
return rval;
|
332
|
+
};
|
333
|
+
|
334
|
+
|
335
|
+
/**
|
336
|
+
* Passes every element of an array into a function and accumulates the result,
|
337
|
+
* starting from the last element and working towards the first.
|
338
|
+
*
|
339
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-reduceright}
|
340
|
+
*
|
341
|
+
* For example:
|
342
|
+
* var a = ['a', 'b', 'c'];
|
343
|
+
* goog.array.reduceRight(a, function(r, v, i, arr) {return r + v;}, '');
|
344
|
+
* returns 'cba'
|
345
|
+
*
|
346
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
347
|
+
* like object over which to iterate.
|
348
|
+
* @param {?function(this:S, R, T, number, ?) : R} f The function to call for
|
349
|
+
* every element. This function
|
350
|
+
* takes 4 arguments (the function's previous result or the initial value,
|
351
|
+
* the value of the current array element, the current array index, and the
|
352
|
+
* array itself)
|
353
|
+
* function(previousValue, currentValue, index, array).
|
354
|
+
* @param {?} val The initial value to pass into the function on the first call.
|
355
|
+
* @param {S=} opt_obj The object to be used as the value of 'this'
|
356
|
+
* within f.
|
357
|
+
* @return {R} Object returned as a result of evaluating f repeatedly across the
|
358
|
+
* values of the array.
|
359
|
+
* @template T,S,R
|
360
|
+
*/
|
361
|
+
goog.array.reduceRight = function(arr, f, val, opt_obj) {
|
362
|
+
if (arr.reduceRight) {
|
363
|
+
if (opt_obj) {
|
364
|
+
return arr.reduceRight(goog.bind(f, opt_obj), val);
|
365
|
+
} else {
|
366
|
+
return arr.reduceRight(f, val);
|
367
|
+
}
|
368
|
+
}
|
369
|
+
var rval = val;
|
370
|
+
goog.array.forEachRight(arr, function(val, index) {
|
371
|
+
rval = f.call(opt_obj, rval, val, index, arr);
|
372
|
+
});
|
373
|
+
return rval;
|
374
|
+
};
|
375
|
+
|
376
|
+
|
377
|
+
/**
|
378
|
+
* Calls f for each element of an array. If any call returns true, some()
|
379
|
+
* returns true (without checking the remaining elements). If all calls
|
380
|
+
* return false, some() returns false.
|
381
|
+
*
|
382
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-some}
|
383
|
+
*
|
384
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
385
|
+
* like object over which to iterate.
|
386
|
+
* @param {?function(this:S, T, number, ?) : boolean} f The function to call for
|
387
|
+
* for every element. This function takes 3 arguments (the element, the
|
388
|
+
* index and the array) and should return a boolean.
|
389
|
+
* @param {S=} opt_obj The object to be used as the value of 'this'
|
390
|
+
* within f.
|
391
|
+
* @return {boolean} true if any element passes the test.
|
392
|
+
* @template T,S
|
393
|
+
*/
|
394
|
+
goog.array.some = goog.NATIVE_ARRAY_PROTOTYPES &&
|
395
|
+
goog.array.ARRAY_PROTOTYPE_.some ?
|
396
|
+
function(arr, f, opt_obj) {
|
397
|
+
goog.asserts.assert(arr.length != null);
|
398
|
+
|
399
|
+
return goog.array.ARRAY_PROTOTYPE_.some.call(arr, f, opt_obj);
|
400
|
+
} :
|
401
|
+
function(arr, f, opt_obj) {
|
402
|
+
var l = arr.length; // must be fixed during loop... see docs
|
403
|
+
var arr2 = goog.isString(arr) ? arr.split('') : arr;
|
404
|
+
for (var i = 0; i < l; i++) {
|
405
|
+
if (i in arr2 && f.call(opt_obj, arr2[i], i, arr)) {
|
406
|
+
return true;
|
407
|
+
}
|
408
|
+
}
|
409
|
+
return false;
|
410
|
+
};
|
411
|
+
|
412
|
+
|
413
|
+
/**
|
414
|
+
* Call f for each element of an array. If all calls return true, every()
|
415
|
+
* returns true. If any call returns false, every() returns false and
|
416
|
+
* does not continue to check the remaining elements.
|
417
|
+
*
|
418
|
+
* See {@link http://tinyurl.com/developer-mozilla-org-array-every}
|
419
|
+
*
|
420
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
421
|
+
* like object over which to iterate.
|
422
|
+
* @param {?function(this:S, T, number, ?) : boolean} f The function to call for
|
423
|
+
* for every element. This function takes 3 arguments (the element, the
|
424
|
+
* index and the array) and should return a boolean.
|
425
|
+
* @param {S=} opt_obj The object to be used as the value of 'this'
|
426
|
+
* within f.
|
427
|
+
* @return {boolean} false if any element fails the test.
|
428
|
+
* @template T,S
|
429
|
+
*/
|
430
|
+
goog.array.every = goog.NATIVE_ARRAY_PROTOTYPES &&
|
431
|
+
goog.array.ARRAY_PROTOTYPE_.every ?
|
432
|
+
function(arr, f, opt_obj) {
|
433
|
+
goog.asserts.assert(arr.length != null);
|
434
|
+
|
435
|
+
return goog.array.ARRAY_PROTOTYPE_.every.call(arr, f, opt_obj);
|
436
|
+
} :
|
437
|
+
function(arr, f, opt_obj) {
|
438
|
+
var l = arr.length; // must be fixed during loop... see docs
|
439
|
+
var arr2 = goog.isString(arr) ? arr.split('') : arr;
|
440
|
+
for (var i = 0; i < l; i++) {
|
441
|
+
if (i in arr2 && !f.call(opt_obj, arr2[i], i, arr)) {
|
442
|
+
return false;
|
443
|
+
}
|
444
|
+
}
|
445
|
+
return true;
|
446
|
+
};
|
447
|
+
|
448
|
+
|
449
|
+
/**
|
450
|
+
* Counts the array elements that fulfill the predicate, i.e. for which the
|
451
|
+
* callback function returns true. Skips holes in the array.
|
452
|
+
*
|
453
|
+
* @param {!(Array.<T>|goog.array.ArrayLike)} arr Array or array like object
|
454
|
+
* over which to iterate.
|
455
|
+
* @param {function(this: S, T, number, ?): boolean} f The function to call for
|
456
|
+
* every element. Takes 3 arguments (the element, the index and the array).
|
457
|
+
* @param {S=} opt_obj The object to be used as the value of 'this' within f.
|
458
|
+
* @return {number} The number of the matching elements.
|
459
|
+
* @template T,S
|
460
|
+
*/
|
461
|
+
goog.array.count = function(arr, f, opt_obj) {
|
462
|
+
var count = 0;
|
463
|
+
goog.array.forEach(arr, function(element, index, arr) {
|
464
|
+
if (f.call(opt_obj, element, index, arr)) {
|
465
|
+
++count;
|
466
|
+
}
|
467
|
+
}, opt_obj);
|
468
|
+
return count;
|
469
|
+
};
|
470
|
+
|
471
|
+
|
472
|
+
/**
|
473
|
+
* Search an array for the first element that satisfies a given condition and
|
474
|
+
* return that element.
|
475
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
476
|
+
* like object over which to iterate.
|
477
|
+
* @param {?function(this:S, T, number, ?) : boolean} f The function to call
|
478
|
+
* for every element. This function takes 3 arguments (the element, the
|
479
|
+
* index and the array) and should return a boolean.
|
480
|
+
* @param {S=} opt_obj An optional "this" context for the function.
|
481
|
+
* @return {T} The first array element that passes the test, or null if no
|
482
|
+
* element is found.
|
483
|
+
* @template T,S
|
484
|
+
*/
|
485
|
+
goog.array.find = function(arr, f, opt_obj) {
|
486
|
+
var i = goog.array.findIndex(arr, f, opt_obj);
|
487
|
+
return i < 0 ? null : goog.isString(arr) ? arr.charAt(i) : arr[i];
|
488
|
+
};
|
489
|
+
|
490
|
+
|
491
|
+
/**
|
492
|
+
* Search an array for the first element that satisfies a given condition and
|
493
|
+
* return its index.
|
494
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
495
|
+
* like object over which to iterate.
|
496
|
+
* @param {?function(this:S, T, number, ?) : boolean} f The function to call for
|
497
|
+
* every element. This function
|
498
|
+
* takes 3 arguments (the element, the index and the array) and should
|
499
|
+
* return a boolean.
|
500
|
+
* @param {S=} opt_obj An optional "this" context for the function.
|
501
|
+
* @return {number} The index of the first array element that passes the test,
|
502
|
+
* or -1 if no element is found.
|
503
|
+
* @template T,S
|
504
|
+
*/
|
505
|
+
goog.array.findIndex = function(arr, f, opt_obj) {
|
506
|
+
var l = arr.length; // must be fixed during loop... see docs
|
507
|
+
var arr2 = goog.isString(arr) ? arr.split('') : arr;
|
508
|
+
for (var i = 0; i < l; i++) {
|
509
|
+
if (i in arr2 && f.call(opt_obj, arr2[i], i, arr)) {
|
510
|
+
return i;
|
511
|
+
}
|
512
|
+
}
|
513
|
+
return -1;
|
514
|
+
};
|
515
|
+
|
516
|
+
|
517
|
+
/**
|
518
|
+
* Search an array (in reverse order) for the last element that satisfies a
|
519
|
+
* given condition and return that element.
|
520
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
521
|
+
* like object over which to iterate.
|
522
|
+
* @param {?function(this:S, T, number, ?) : boolean} f The function to call
|
523
|
+
* for every element. This function
|
524
|
+
* takes 3 arguments (the element, the index and the array) and should
|
525
|
+
* return a boolean.
|
526
|
+
* @param {S=} opt_obj An optional "this" context for the function.
|
527
|
+
* @return {T} The last array element that passes the test, or null if no
|
528
|
+
* element is found.
|
529
|
+
* @template T,S
|
530
|
+
*/
|
531
|
+
goog.array.findRight = function(arr, f, opt_obj) {
|
532
|
+
var i = goog.array.findIndexRight(arr, f, opt_obj);
|
533
|
+
return i < 0 ? null : goog.isString(arr) ? arr.charAt(i) : arr[i];
|
534
|
+
};
|
535
|
+
|
536
|
+
|
537
|
+
/**
|
538
|
+
* Search an array (in reverse order) for the last element that satisfies a
|
539
|
+
* given condition and return its index.
|
540
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
541
|
+
* like object over which to iterate.
|
542
|
+
* @param {?function(this:S, T, number, ?) : boolean} f The function to call
|
543
|
+
* for every element. This function
|
544
|
+
* takes 3 arguments (the element, the index and the array) and should
|
545
|
+
* return a boolean.
|
546
|
+
* @param {Object=} opt_obj An optional "this" context for the function.
|
547
|
+
* @return {number} The index of the last array element that passes the test,
|
548
|
+
* or -1 if no element is found.
|
549
|
+
* @template T,S
|
550
|
+
*/
|
551
|
+
goog.array.findIndexRight = function(arr, f, opt_obj) {
|
552
|
+
var l = arr.length; // must be fixed during loop... see docs
|
553
|
+
var arr2 = goog.isString(arr) ? arr.split('') : arr;
|
554
|
+
for (var i = l - 1; i >= 0; i--) {
|
555
|
+
if (i in arr2 && f.call(opt_obj, arr2[i], i, arr)) {
|
556
|
+
return i;
|
557
|
+
}
|
558
|
+
}
|
559
|
+
return -1;
|
560
|
+
};
|
561
|
+
|
562
|
+
|
563
|
+
/**
|
564
|
+
* Whether the array contains the given object.
|
565
|
+
* @param {goog.array.ArrayLike} arr The array to test for the presence of the
|
566
|
+
* element.
|
567
|
+
* @param {*} obj The object for which to test.
|
568
|
+
* @return {boolean} true if obj is present.
|
569
|
+
*/
|
570
|
+
goog.array.contains = function(arr, obj) {
|
571
|
+
return goog.array.indexOf(arr, obj) >= 0;
|
572
|
+
};
|
573
|
+
|
574
|
+
|
575
|
+
/**
|
576
|
+
* Whether the array is empty.
|
577
|
+
* @param {goog.array.ArrayLike} arr The array to test.
|
578
|
+
* @return {boolean} true if empty.
|
579
|
+
*/
|
580
|
+
goog.array.isEmpty = function(arr) {
|
581
|
+
return arr.length == 0;
|
582
|
+
};
|
583
|
+
|
584
|
+
|
585
|
+
/**
|
586
|
+
* Clears the array.
|
587
|
+
* @param {goog.array.ArrayLike} arr Array or array like object to clear.
|
588
|
+
*/
|
589
|
+
goog.array.clear = function(arr) {
|
590
|
+
// For non real arrays we don't have the magic length so we delete the
|
591
|
+
// indices.
|
592
|
+
if (!goog.isArray(arr)) {
|
593
|
+
for (var i = arr.length - 1; i >= 0; i--) {
|
594
|
+
delete arr[i];
|
595
|
+
}
|
596
|
+
}
|
597
|
+
arr.length = 0;
|
598
|
+
};
|
599
|
+
|
600
|
+
|
601
|
+
/**
|
602
|
+
* Pushes an item into an array, if it's not already in the array.
|
603
|
+
* @param {Array.<T>} arr Array into which to insert the item.
|
604
|
+
* @param {T} obj Value to add.
|
605
|
+
* @template T
|
606
|
+
*/
|
607
|
+
goog.array.insert = function(arr, obj) {
|
608
|
+
if (!goog.array.contains(arr, obj)) {
|
609
|
+
arr.push(obj);
|
610
|
+
}
|
611
|
+
};
|
612
|
+
|
613
|
+
|
614
|
+
/**
|
615
|
+
* Inserts an object at the given index of the array.
|
616
|
+
* @param {goog.array.ArrayLike} arr The array to modify.
|
617
|
+
* @param {*} obj The object to insert.
|
618
|
+
* @param {number=} opt_i The index at which to insert the object. If omitted,
|
619
|
+
* treated as 0. A negative index is counted from the end of the array.
|
620
|
+
*/
|
621
|
+
goog.array.insertAt = function(arr, obj, opt_i) {
|
622
|
+
goog.array.splice(arr, opt_i, 0, obj);
|
623
|
+
};
|
624
|
+
|
625
|
+
|
626
|
+
/**
|
627
|
+
* Inserts at the given index of the array, all elements of another array.
|
628
|
+
* @param {goog.array.ArrayLike} arr The array to modify.
|
629
|
+
* @param {goog.array.ArrayLike} elementsToAdd The array of elements to add.
|
630
|
+
* @param {number=} opt_i The index at which to insert the object. If omitted,
|
631
|
+
* treated as 0. A negative index is counted from the end of the array.
|
632
|
+
*/
|
633
|
+
goog.array.insertArrayAt = function(arr, elementsToAdd, opt_i) {
|
634
|
+
goog.partial(goog.array.splice, arr, opt_i, 0).apply(null, elementsToAdd);
|
635
|
+
};
|
636
|
+
|
637
|
+
|
638
|
+
/**
|
639
|
+
* Inserts an object into an array before a specified object.
|
640
|
+
* @param {Array.<T>} arr The array to modify.
|
641
|
+
* @param {T} obj The object to insert.
|
642
|
+
* @param {T=} opt_obj2 The object before which obj should be inserted. If obj2
|
643
|
+
* is omitted or not found, obj is inserted at the end of the array.
|
644
|
+
* @template T
|
645
|
+
*/
|
646
|
+
goog.array.insertBefore = function(arr, obj, opt_obj2) {
|
647
|
+
var i;
|
648
|
+
if (arguments.length == 2 || (i = goog.array.indexOf(arr, opt_obj2)) < 0) {
|
649
|
+
arr.push(obj);
|
650
|
+
} else {
|
651
|
+
goog.array.insertAt(arr, obj, i);
|
652
|
+
}
|
653
|
+
};
|
654
|
+
|
655
|
+
|
656
|
+
/**
|
657
|
+
* Removes the first occurrence of a particular value from an array.
|
658
|
+
* @param {goog.array.ArrayLike} arr Array from which to remove value.
|
659
|
+
* @param {*} obj Object to remove.
|
660
|
+
* @return {boolean} True if an element was removed.
|
661
|
+
*/
|
662
|
+
goog.array.remove = function(arr, obj) {
|
663
|
+
var i = goog.array.indexOf(arr, obj);
|
664
|
+
var rv;
|
665
|
+
if ((rv = i >= 0)) {
|
666
|
+
goog.array.removeAt(arr, i);
|
667
|
+
}
|
668
|
+
return rv;
|
669
|
+
};
|
670
|
+
|
671
|
+
|
672
|
+
/**
|
673
|
+
* Removes from an array the element at index i
|
674
|
+
* @param {goog.array.ArrayLike} arr Array or array like object from which to
|
675
|
+
* remove value.
|
676
|
+
* @param {number} i The index to remove.
|
677
|
+
* @return {boolean} True if an element was removed.
|
678
|
+
*/
|
679
|
+
goog.array.removeAt = function(arr, i) {
|
680
|
+
goog.asserts.assert(arr.length != null);
|
681
|
+
|
682
|
+
// use generic form of splice
|
683
|
+
// splice returns the removed items and if successful the length of that
|
684
|
+
// will be 1
|
685
|
+
return goog.array.ARRAY_PROTOTYPE_.splice.call(arr, i, 1).length == 1;
|
686
|
+
};
|
687
|
+
|
688
|
+
|
689
|
+
/**
|
690
|
+
* Removes the first value that satisfies the given condition.
|
691
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array
|
692
|
+
* like object over which to iterate.
|
693
|
+
* @param {?function(this:S, T, number, ?) : boolean} f The function to call
|
694
|
+
* for every element. This function
|
695
|
+
* takes 3 arguments (the element, the index and the array) and should
|
696
|
+
* return a boolean.
|
697
|
+
* @param {S=} opt_obj An optional "this" context for the function.
|
698
|
+
* @return {boolean} True if an element was removed.
|
699
|
+
* @template T,S
|
700
|
+
*/
|
701
|
+
goog.array.removeIf = function(arr, f, opt_obj) {
|
702
|
+
var i = goog.array.findIndex(arr, f, opt_obj);
|
703
|
+
if (i >= 0) {
|
704
|
+
goog.array.removeAt(arr, i);
|
705
|
+
return true;
|
706
|
+
}
|
707
|
+
return false;
|
708
|
+
};
|
709
|
+
|
710
|
+
|
711
|
+
/**
|
712
|
+
* Returns a new array that is the result of joining the arguments. If arrays
|
713
|
+
* are passed then their items are added, however, if non-arrays are passed they
|
714
|
+
* will be added to the return array as is.
|
715
|
+
*
|
716
|
+
* Note that ArrayLike objects will be added as is, rather than having their
|
717
|
+
* items added.
|
718
|
+
*
|
719
|
+
* goog.array.concat([1, 2], [3, 4]) -> [1, 2, 3, 4]
|
720
|
+
* goog.array.concat(0, [1, 2]) -> [0, 1, 2]
|
721
|
+
* goog.array.concat([1, 2], null) -> [1, 2, null]
|
722
|
+
*
|
723
|
+
* There is bug in all current versions of IE (6, 7 and 8) where arrays created
|
724
|
+
* in an iframe become corrupted soon (not immediately) after the iframe is
|
725
|
+
* destroyed. This is common if loading data via goog.net.IframeIo, for example.
|
726
|
+
* This corruption only affects the concat method which will start throwing
|
727
|
+
* Catastrophic Errors (#-2147418113).
|
728
|
+
*
|
729
|
+
* See http://endoflow.com/scratch/corrupted-arrays.html for a test case.
|
730
|
+
*
|
731
|
+
* Internally goog.array should use this, so that all methods will continue to
|
732
|
+
* work on these broken array objects.
|
733
|
+
*
|
734
|
+
* @param {...*} var_args Items to concatenate. Arrays will have each item
|
735
|
+
* added, while primitives and objects will be added as is.
|
736
|
+
* @return {!Array} The new resultant array.
|
737
|
+
*/
|
738
|
+
goog.array.concat = function(var_args) {
|
739
|
+
return goog.array.ARRAY_PROTOTYPE_.concat.apply(
|
740
|
+
goog.array.ARRAY_PROTOTYPE_, arguments);
|
741
|
+
};
|
742
|
+
|
743
|
+
|
744
|
+
/**
|
745
|
+
* Converts an object to an array.
|
746
|
+
* @param {goog.array.ArrayLike} object The object to convert to an array.
|
747
|
+
* @return {!Array} The object converted into an array. If object has a
|
748
|
+
* length property, every property indexed with a non-negative number
|
749
|
+
* less than length will be included in the result. If object does not
|
750
|
+
* have a length property, an empty array will be returned.
|
751
|
+
*/
|
752
|
+
goog.array.toArray = function(object) {
|
753
|
+
var length = object.length;
|
754
|
+
|
755
|
+
// If length is not a number the following it false. This case is kept for
|
756
|
+
// backwards compatibility since there are callers that pass objects that are
|
757
|
+
// not array like.
|
758
|
+
if (length > 0) {
|
759
|
+
var rv = new Array(length);
|
760
|
+
for (var i = 0; i < length; i++) {
|
761
|
+
rv[i] = object[i];
|
762
|
+
}
|
763
|
+
return rv;
|
764
|
+
}
|
765
|
+
return [];
|
766
|
+
};
|
767
|
+
|
768
|
+
|
769
|
+
/**
|
770
|
+
* Does a shallow copy of an array.
|
771
|
+
* @param {goog.array.ArrayLike} arr Array or array-like object to clone.
|
772
|
+
* @return {!Array} Clone of the input array.
|
773
|
+
*/
|
774
|
+
goog.array.clone = goog.array.toArray;
|
775
|
+
|
776
|
+
|
777
|
+
/**
|
778
|
+
* Extends an array with another array, element, or "array like" object.
|
779
|
+
* This function operates 'in-place', it does not create a new Array.
|
780
|
+
*
|
781
|
+
* Example:
|
782
|
+
* var a = [];
|
783
|
+
* goog.array.extend(a, [0, 1]);
|
784
|
+
* a; // [0, 1]
|
785
|
+
* goog.array.extend(a, 2);
|
786
|
+
* a; // [0, 1, 2]
|
787
|
+
*
|
788
|
+
* @param {Array} arr1 The array to modify.
|
789
|
+
* @param {...*} var_args The elements or arrays of elements to add to arr1.
|
790
|
+
*/
|
791
|
+
goog.array.extend = function(arr1, var_args) {
|
792
|
+
for (var i = 1; i < arguments.length; i++) {
|
793
|
+
var arr2 = arguments[i];
|
794
|
+
// If we have an Array or an Arguments object we can just call push
|
795
|
+
// directly.
|
796
|
+
var isArrayLike;
|
797
|
+
if (goog.isArray(arr2) ||
|
798
|
+
// Detect Arguments. ES5 says that the [[Class]] of an Arguments object
|
799
|
+
// is "Arguments" but only V8 and JSC/Safari gets this right. We instead
|
800
|
+
// detect Arguments by checking for array like and presence of "callee".
|
801
|
+
(isArrayLike = goog.isArrayLike(arr2)) &&
|
802
|
+
// The getter for callee throws an exception in strict mode
|
803
|
+
// according to section 10.6 in ES5 so check for presence instead.
|
804
|
+
Object.prototype.hasOwnProperty.call(arr2, 'callee')) {
|
805
|
+
arr1.push.apply(arr1, arr2);
|
806
|
+
} else if (isArrayLike) {
|
807
|
+
// Otherwise loop over arr2 to prevent copying the object.
|
808
|
+
var len1 = arr1.length;
|
809
|
+
var len2 = arr2.length;
|
810
|
+
for (var j = 0; j < len2; j++) {
|
811
|
+
arr1[len1 + j] = arr2[j];
|
812
|
+
}
|
813
|
+
} else {
|
814
|
+
arr1.push(arr2);
|
815
|
+
}
|
816
|
+
}
|
817
|
+
};
|
818
|
+
|
819
|
+
|
820
|
+
/**
|
821
|
+
* Adds or removes elements from an array. This is a generic version of Array
|
822
|
+
* splice. This means that it might work on other objects similar to arrays,
|
823
|
+
* such as the arguments object.
|
824
|
+
*
|
825
|
+
* @param {goog.array.ArrayLike} arr The array to modify.
|
826
|
+
* @param {number|undefined} index The index at which to start changing the
|
827
|
+
* array. If not defined, treated as 0.
|
828
|
+
* @param {number} howMany How many elements to remove (0 means no removal. A
|
829
|
+
* value below 0 is treated as zero and so is any other non number. Numbers
|
830
|
+
* are floored).
|
831
|
+
* @param {...*} var_args Optional, additional elements to insert into the
|
832
|
+
* array.
|
833
|
+
* @return {!Array} the removed elements.
|
834
|
+
*/
|
835
|
+
goog.array.splice = function(arr, index, howMany, var_args) {
|
836
|
+
goog.asserts.assert(arr.length != null);
|
837
|
+
|
838
|
+
return goog.array.ARRAY_PROTOTYPE_.splice.apply(
|
839
|
+
arr, goog.array.slice(arguments, 1));
|
840
|
+
};
|
841
|
+
|
842
|
+
|
843
|
+
/**
|
844
|
+
* Returns a new array from a segment of an array. This is a generic version of
|
845
|
+
* Array slice. This means that it might work on other objects similar to
|
846
|
+
* arrays, such as the arguments object.
|
847
|
+
*
|
848
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr The array from
|
849
|
+
* which to copy a segment.
|
850
|
+
* @param {number} start The index of the first element to copy.
|
851
|
+
* @param {number=} opt_end The index after the last element to copy.
|
852
|
+
* @return {!Array.<T>} A new array containing the specified segment of the
|
853
|
+
* original array.
|
854
|
+
* @template T
|
855
|
+
*/
|
856
|
+
goog.array.slice = function(arr, start, opt_end) {
|
857
|
+
goog.asserts.assert(arr.length != null);
|
858
|
+
|
859
|
+
// passing 1 arg to slice is not the same as passing 2 where the second is
|
860
|
+
// null or undefined (in that case the second argument is treated as 0).
|
861
|
+
// we could use slice on the arguments object and then use apply instead of
|
862
|
+
// testing the length
|
863
|
+
if (arguments.length <= 2) {
|
864
|
+
return goog.array.ARRAY_PROTOTYPE_.slice.call(arr, start);
|
865
|
+
} else {
|
866
|
+
return goog.array.ARRAY_PROTOTYPE_.slice.call(arr, start, opt_end);
|
867
|
+
}
|
868
|
+
};
|
869
|
+
|
870
|
+
|
871
|
+
/**
|
872
|
+
* Removes all duplicates from an array (retaining only the first
|
873
|
+
* occurrence of each array element). This function modifies the
|
874
|
+
* array in place and doesn't change the order of the non-duplicate items.
|
875
|
+
*
|
876
|
+
* For objects, duplicates are identified as having the same unique ID as
|
877
|
+
* defined by {@link goog.getUid}.
|
878
|
+
*
|
879
|
+
* Runtime: N,
|
880
|
+
* Worstcase space: 2N (no dupes)
|
881
|
+
*
|
882
|
+
* @param {goog.array.ArrayLike} arr The array from which to remove duplicates.
|
883
|
+
* @param {Array=} opt_rv An optional array in which to return the results,
|
884
|
+
* instead of performing the removal inplace. If specified, the original
|
885
|
+
* array will remain unchanged.
|
886
|
+
*/
|
887
|
+
goog.array.removeDuplicates = function(arr, opt_rv) {
|
888
|
+
var returnArray = opt_rv || arr;
|
889
|
+
|
890
|
+
var seen = {}, cursorInsert = 0, cursorRead = 0;
|
891
|
+
while (cursorRead < arr.length) {
|
892
|
+
var current = arr[cursorRead++];
|
893
|
+
|
894
|
+
// Prefix each type with a single character representing the type to
|
895
|
+
// prevent conflicting keys (e.g. true and 'true').
|
896
|
+
var key = goog.isObject(current) ?
|
897
|
+
'o' + goog.getUid(current) :
|
898
|
+
(typeof current).charAt(0) + current;
|
899
|
+
|
900
|
+
if (!Object.prototype.hasOwnProperty.call(seen, key)) {
|
901
|
+
seen[key] = true;
|
902
|
+
returnArray[cursorInsert++] = current;
|
903
|
+
}
|
904
|
+
}
|
905
|
+
returnArray.length = cursorInsert;
|
906
|
+
};
|
907
|
+
|
908
|
+
|
909
|
+
/**
|
910
|
+
* Searches the specified array for the specified target using the binary
|
911
|
+
* search algorithm. If no opt_compareFn is specified, elements are compared
|
912
|
+
* using <code>goog.array.defaultCompare</code>, which compares the elements
|
913
|
+
* using the built in < and > operators. This will produce the expected
|
914
|
+
* behavior for homogeneous arrays of String(s) and Number(s). The array
|
915
|
+
* specified <b>must</b> be sorted in ascending order (as defined by the
|
916
|
+
* comparison function). If the array is not sorted, results are undefined.
|
917
|
+
* If the array contains multiple instances of the specified target value, any
|
918
|
+
* of these instances may be found.
|
919
|
+
*
|
920
|
+
* Runtime: O(log n)
|
921
|
+
*
|
922
|
+
* @param {goog.array.ArrayLike} arr The array to be searched.
|
923
|
+
* @param {*} target The sought value.
|
924
|
+
* @param {Function=} opt_compareFn Optional comparison function by which the
|
925
|
+
* array is ordered. Should take 2 arguments to compare, and return a
|
926
|
+
* negative number, zero, or a positive number depending on whether the
|
927
|
+
* first argument is less than, equal to, or greater than the second.
|
928
|
+
* @return {number} Lowest index of the target value if found, otherwise
|
929
|
+
* (-(insertion point) - 1). The insertion point is where the value should
|
930
|
+
* be inserted into arr to preserve the sorted property. Return value >= 0
|
931
|
+
* iff target is found.
|
932
|
+
*/
|
933
|
+
goog.array.binarySearch = function(arr, target, opt_compareFn) {
|
934
|
+
return goog.array.binarySearch_(arr,
|
935
|
+
opt_compareFn || goog.array.defaultCompare, false /* isEvaluator */,
|
936
|
+
target);
|
937
|
+
};
|
938
|
+
|
939
|
+
|
940
|
+
/**
|
941
|
+
* Selects an index in the specified array using the binary search algorithm.
|
942
|
+
* The evaluator receives an element and determines whether the desired index
|
943
|
+
* is before, at, or after it. The evaluator must be consistent (formally,
|
944
|
+
* goog.array.map(goog.array.map(arr, evaluator, opt_obj), goog.math.sign)
|
945
|
+
* must be monotonically non-increasing).
|
946
|
+
*
|
947
|
+
* Runtime: O(log n)
|
948
|
+
*
|
949
|
+
* @param {goog.array.ArrayLike} arr The array to be searched.
|
950
|
+
* @param {Function} evaluator Evaluator function that receives 3 arguments
|
951
|
+
* (the element, the index and the array). Should return a negative number,
|
952
|
+
* zero, or a positive number depending on whether the desired index is
|
953
|
+
* before, at, or after the element passed to it.
|
954
|
+
* @param {Object=} opt_obj The object to be used as the value of 'this'
|
955
|
+
* within evaluator.
|
956
|
+
* @return {number} Index of the leftmost element matched by the evaluator, if
|
957
|
+
* such exists; otherwise (-(insertion point) - 1). The insertion point is
|
958
|
+
* the index of the first element for which the evaluator returns negative,
|
959
|
+
* or arr.length if no such element exists. The return value is non-negative
|
960
|
+
* iff a match is found.
|
961
|
+
*/
|
962
|
+
goog.array.binarySelect = function(arr, evaluator, opt_obj) {
|
963
|
+
return goog.array.binarySearch_(arr, evaluator, true /* isEvaluator */,
|
964
|
+
undefined /* opt_target */, opt_obj);
|
965
|
+
};
|
966
|
+
|
967
|
+
|
968
|
+
/**
|
969
|
+
* Implementation of a binary search algorithm which knows how to use both
|
970
|
+
* comparison functions and evaluators. If an evaluator is provided, will call
|
971
|
+
* the evaluator with the given optional data object, conforming to the
|
972
|
+
* interface defined in binarySelect. Otherwise, if a comparison function is
|
973
|
+
* provided, will call the comparison function against the given data object.
|
974
|
+
*
|
975
|
+
* This implementation purposefully does not use goog.bind or goog.partial for
|
976
|
+
* performance reasons.
|
977
|
+
*
|
978
|
+
* Runtime: O(log n)
|
979
|
+
*
|
980
|
+
* @param {goog.array.ArrayLike} arr The array to be searched.
|
981
|
+
* @param {Function} compareFn Either an evaluator or a comparison function,
|
982
|
+
* as defined by binarySearch and binarySelect above.
|
983
|
+
* @param {boolean} isEvaluator Whether the function is an evaluator or a
|
984
|
+
* comparison function.
|
985
|
+
* @param {*=} opt_target If the function is a comparison function, then this is
|
986
|
+
* the target to binary search for.
|
987
|
+
* @param {Object=} opt_selfObj If the function is an evaluator, this is an
|
988
|
+
* optional this object for the evaluator.
|
989
|
+
* @return {number} Lowest index of the target value if found, otherwise
|
990
|
+
* (-(insertion point) - 1). The insertion point is where the value should
|
991
|
+
* be inserted into arr to preserve the sorted property. Return value >= 0
|
992
|
+
* iff target is found.
|
993
|
+
* @private
|
994
|
+
*/
|
995
|
+
goog.array.binarySearch_ = function(arr, compareFn, isEvaluator, opt_target,
|
996
|
+
opt_selfObj) {
|
997
|
+
var left = 0; // inclusive
|
998
|
+
var right = arr.length; // exclusive
|
999
|
+
var found;
|
1000
|
+
while (left < right) {
|
1001
|
+
var middle = (left + right) >> 1;
|
1002
|
+
var compareResult;
|
1003
|
+
if (isEvaluator) {
|
1004
|
+
compareResult = compareFn.call(opt_selfObj, arr[middle], middle, arr);
|
1005
|
+
} else {
|
1006
|
+
compareResult = compareFn(opt_target, arr[middle]);
|
1007
|
+
}
|
1008
|
+
if (compareResult > 0) {
|
1009
|
+
left = middle + 1;
|
1010
|
+
} else {
|
1011
|
+
right = middle;
|
1012
|
+
// We are looking for the lowest index so we can't return immediately.
|
1013
|
+
found = !compareResult;
|
1014
|
+
}
|
1015
|
+
}
|
1016
|
+
// left is the index if found, or the insertion point otherwise.
|
1017
|
+
// ~left is a shorthand for -left - 1.
|
1018
|
+
return found ? left : ~left;
|
1019
|
+
};
|
1020
|
+
|
1021
|
+
|
1022
|
+
/**
|
1023
|
+
* Sorts the specified array into ascending order. If no opt_compareFn is
|
1024
|
+
* specified, elements are compared using
|
1025
|
+
* <code>goog.array.defaultCompare</code>, which compares the elements using
|
1026
|
+
* the built in < and > operators. This will produce the expected behavior
|
1027
|
+
* for homogeneous arrays of String(s) and Number(s), unlike the native sort,
|
1028
|
+
* but will give unpredictable results for heterogenous lists of strings and
|
1029
|
+
* numbers with different numbers of digits.
|
1030
|
+
*
|
1031
|
+
* This sort is not guaranteed to be stable.
|
1032
|
+
*
|
1033
|
+
* Runtime: Same as <code>Array.prototype.sort</code>
|
1034
|
+
*
|
1035
|
+
* @param {Array.<T>} arr The array to be sorted.
|
1036
|
+
* @param {?function(T,T):number=} opt_compareFn Optional comparison
|
1037
|
+
* function by which the
|
1038
|
+
* array is to be ordered. Should take 2 arguments to compare, and return a
|
1039
|
+
* negative number, zero, or a positive number depending on whether the
|
1040
|
+
* first argument is less than, equal to, or greater than the second.
|
1041
|
+
* @template T
|
1042
|
+
*/
|
1043
|
+
goog.array.sort = function(arr, opt_compareFn) {
|
1044
|
+
// TODO(arv): Update type annotation since null is not accepted.
|
1045
|
+
goog.asserts.assert(arr.length != null);
|
1046
|
+
|
1047
|
+
goog.array.ARRAY_PROTOTYPE_.sort.call(
|
1048
|
+
arr, opt_compareFn || goog.array.defaultCompare);
|
1049
|
+
};
|
1050
|
+
|
1051
|
+
|
1052
|
+
/**
|
1053
|
+
* Sorts the specified array into ascending order in a stable way. If no
|
1054
|
+
* opt_compareFn is specified, elements are compared using
|
1055
|
+
* <code>goog.array.defaultCompare</code>, which compares the elements using
|
1056
|
+
* the built in < and > operators. This will produce the expected behavior
|
1057
|
+
* for homogeneous arrays of String(s) and Number(s).
|
1058
|
+
*
|
1059
|
+
* Runtime: Same as <code>Array.prototype.sort</code>, plus an additional
|
1060
|
+
* O(n) overhead of copying the array twice.
|
1061
|
+
*
|
1062
|
+
* @param {Array.<T>} arr The array to be sorted.
|
1063
|
+
* @param {?function(T, T): number=} opt_compareFn Optional comparison function
|
1064
|
+
* by which the array is to be ordered. Should take 2 arguments to compare,
|
1065
|
+
* and return a negative number, zero, or a positive number depending on
|
1066
|
+
* whether the first argument is less than, equal to, or greater than the
|
1067
|
+
* second.
|
1068
|
+
* @template T
|
1069
|
+
*/
|
1070
|
+
goog.array.stableSort = function(arr, opt_compareFn) {
|
1071
|
+
for (var i = 0; i < arr.length; i++) {
|
1072
|
+
arr[i] = {index: i, value: arr[i]};
|
1073
|
+
}
|
1074
|
+
var valueCompareFn = opt_compareFn || goog.array.defaultCompare;
|
1075
|
+
function stableCompareFn(obj1, obj2) {
|
1076
|
+
return valueCompareFn(obj1.value, obj2.value) || obj1.index - obj2.index;
|
1077
|
+
};
|
1078
|
+
goog.array.sort(arr, stableCompareFn);
|
1079
|
+
for (var i = 0; i < arr.length; i++) {
|
1080
|
+
arr[i] = arr[i].value;
|
1081
|
+
}
|
1082
|
+
};
|
1083
|
+
|
1084
|
+
|
1085
|
+
/**
|
1086
|
+
* Sorts an array of objects by the specified object key and compare
|
1087
|
+
* function. If no compare function is provided, the key values are
|
1088
|
+
* compared in ascending order using <code>goog.array.defaultCompare</code>.
|
1089
|
+
* This won't work for keys that get renamed by the compiler. So use
|
1090
|
+
* {'foo': 1, 'bar': 2} rather than {foo: 1, bar: 2}.
|
1091
|
+
* @param {Array.<Object>} arr An array of objects to sort.
|
1092
|
+
* @param {string} key The object key to sort by.
|
1093
|
+
* @param {Function=} opt_compareFn The function to use to compare key
|
1094
|
+
* values.
|
1095
|
+
*/
|
1096
|
+
goog.array.sortObjectsByKey = function(arr, key, opt_compareFn) {
|
1097
|
+
var compare = opt_compareFn || goog.array.defaultCompare;
|
1098
|
+
goog.array.sort(arr, function(a, b) {
|
1099
|
+
return compare(a[key], b[key]);
|
1100
|
+
});
|
1101
|
+
};
|
1102
|
+
|
1103
|
+
|
1104
|
+
/**
|
1105
|
+
* Tells if the array is sorted.
|
1106
|
+
* @param {!Array.<T>} arr The array.
|
1107
|
+
* @param {?function(T,T):number=} opt_compareFn Function to compare the
|
1108
|
+
* array elements.
|
1109
|
+
* Should take 2 arguments to compare, and return a negative number, zero,
|
1110
|
+
* or a positive number depending on whether the first argument is less
|
1111
|
+
* than, equal to, or greater than the second.
|
1112
|
+
* @param {boolean=} opt_strict If true no equal elements are allowed.
|
1113
|
+
* @return {boolean} Whether the array is sorted.
|
1114
|
+
* @template T
|
1115
|
+
*/
|
1116
|
+
goog.array.isSorted = function(arr, opt_compareFn, opt_strict) {
|
1117
|
+
var compare = opt_compareFn || goog.array.defaultCompare;
|
1118
|
+
for (var i = 1; i < arr.length; i++) {
|
1119
|
+
var compareResult = compare(arr[i - 1], arr[i]);
|
1120
|
+
if (compareResult > 0 || compareResult == 0 && opt_strict) {
|
1121
|
+
return false;
|
1122
|
+
}
|
1123
|
+
}
|
1124
|
+
return true;
|
1125
|
+
};
|
1126
|
+
|
1127
|
+
|
1128
|
+
/**
|
1129
|
+
* Compares two arrays for equality. Two arrays are considered equal if they
|
1130
|
+
* have the same length and their corresponding elements are equal according to
|
1131
|
+
* the comparison function.
|
1132
|
+
*
|
1133
|
+
* @param {goog.array.ArrayLike} arr1 The first array to compare.
|
1134
|
+
* @param {goog.array.ArrayLike} arr2 The second array to compare.
|
1135
|
+
* @param {Function=} opt_equalsFn Optional comparison function.
|
1136
|
+
* Should take 2 arguments to compare, and return true if the arguments
|
1137
|
+
* are equal. Defaults to {@link goog.array.defaultCompareEquality} which
|
1138
|
+
* compares the elements using the built-in '===' operator.
|
1139
|
+
* @return {boolean} Whether the two arrays are equal.
|
1140
|
+
*/
|
1141
|
+
goog.array.equals = function(arr1, arr2, opt_equalsFn) {
|
1142
|
+
if (!goog.isArrayLike(arr1) || !goog.isArrayLike(arr2) ||
|
1143
|
+
arr1.length != arr2.length) {
|
1144
|
+
return false;
|
1145
|
+
}
|
1146
|
+
var l = arr1.length;
|
1147
|
+
var equalsFn = opt_equalsFn || goog.array.defaultCompareEquality;
|
1148
|
+
for (var i = 0; i < l; i++) {
|
1149
|
+
if (!equalsFn(arr1[i], arr2[i])) {
|
1150
|
+
return false;
|
1151
|
+
}
|
1152
|
+
}
|
1153
|
+
return true;
|
1154
|
+
};
|
1155
|
+
|
1156
|
+
|
1157
|
+
/**
|
1158
|
+
* @deprecated Use {@link goog.array.equals}.
|
1159
|
+
* @param {goog.array.ArrayLike} arr1 See {@link goog.array.equals}.
|
1160
|
+
* @param {goog.array.ArrayLike} arr2 See {@link goog.array.equals}.
|
1161
|
+
* @param {Function=} opt_equalsFn See {@link goog.array.equals}.
|
1162
|
+
* @return {boolean} See {@link goog.array.equals}.
|
1163
|
+
*/
|
1164
|
+
goog.array.compare = function(arr1, arr2, opt_equalsFn) {
|
1165
|
+
return goog.array.equals(arr1, arr2, opt_equalsFn);
|
1166
|
+
};
|
1167
|
+
|
1168
|
+
|
1169
|
+
/**
|
1170
|
+
* 3-way array compare function.
|
1171
|
+
* @param {!goog.array.ArrayLike} arr1 The first array to compare.
|
1172
|
+
* @param {!goog.array.ArrayLike} arr2 The second array to compare.
|
1173
|
+
* @param {?function(?, ?): number=} opt_compareFn Optional comparison function
|
1174
|
+
* by which the array is to be ordered. Should take 2 arguments to compare,
|
1175
|
+
* and return a negative number, zero, or a positive number depending on
|
1176
|
+
* whether the first argument is less than, equal to, or greater than the
|
1177
|
+
* second.
|
1178
|
+
* @return {number} Negative number, zero, or a positive number depending on
|
1179
|
+
* whether the first argument is less than, equal to, or greater than the
|
1180
|
+
* second.
|
1181
|
+
*/
|
1182
|
+
goog.array.compare3 = function(arr1, arr2, opt_compareFn) {
|
1183
|
+
var compare = opt_compareFn || goog.array.defaultCompare;
|
1184
|
+
var l = Math.min(arr1.length, arr2.length);
|
1185
|
+
for (var i = 0; i < l; i++) {
|
1186
|
+
var result = compare(arr1[i], arr2[i]);
|
1187
|
+
if (result != 0) {
|
1188
|
+
return result;
|
1189
|
+
}
|
1190
|
+
}
|
1191
|
+
return goog.array.defaultCompare(arr1.length, arr2.length);
|
1192
|
+
};
|
1193
|
+
|
1194
|
+
|
1195
|
+
/**
|
1196
|
+
* Compares its two arguments for order, using the built in < and >
|
1197
|
+
* operators.
|
1198
|
+
* @param {*} a The first object to be compared.
|
1199
|
+
* @param {*} b The second object to be compared.
|
1200
|
+
* @return {number} A negative number, zero, or a positive number as the first
|
1201
|
+
* argument is less than, equal to, or greater than the second.
|
1202
|
+
*/
|
1203
|
+
goog.array.defaultCompare = function(a, b) {
|
1204
|
+
return a > b ? 1 : a < b ? -1 : 0;
|
1205
|
+
};
|
1206
|
+
|
1207
|
+
|
1208
|
+
/**
|
1209
|
+
* Compares its two arguments for equality, using the built in === operator.
|
1210
|
+
* @param {*} a The first object to compare.
|
1211
|
+
* @param {*} b The second object to compare.
|
1212
|
+
* @return {boolean} True if the two arguments are equal, false otherwise.
|
1213
|
+
*/
|
1214
|
+
goog.array.defaultCompareEquality = function(a, b) {
|
1215
|
+
return a === b;
|
1216
|
+
};
|
1217
|
+
|
1218
|
+
|
1219
|
+
/**
|
1220
|
+
* Inserts a value into a sorted array. The array is not modified if the
|
1221
|
+
* value is already present.
|
1222
|
+
* @param {Array.<T>} array The array to modify.
|
1223
|
+
* @param {T} value The object to insert.
|
1224
|
+
* @param {?function(T,T):number=} opt_compareFn Optional comparison function by
|
1225
|
+
* which the
|
1226
|
+
* array is ordered. Should take 2 arguments to compare, and return a
|
1227
|
+
* negative number, zero, or a positive number depending on whether the
|
1228
|
+
* first argument is less than, equal to, or greater than the second.
|
1229
|
+
* @return {boolean} True if an element was inserted.
|
1230
|
+
* @template T
|
1231
|
+
*/
|
1232
|
+
goog.array.binaryInsert = function(array, value, opt_compareFn) {
|
1233
|
+
var index = goog.array.binarySearch(array, value, opt_compareFn);
|
1234
|
+
if (index < 0) {
|
1235
|
+
goog.array.insertAt(array, value, -(index + 1));
|
1236
|
+
return true;
|
1237
|
+
}
|
1238
|
+
return false;
|
1239
|
+
};
|
1240
|
+
|
1241
|
+
|
1242
|
+
/**
|
1243
|
+
* Removes a value from a sorted array.
|
1244
|
+
* @param {Array} array The array to modify.
|
1245
|
+
* @param {*} value The object to remove.
|
1246
|
+
* @param {Function=} opt_compareFn Optional comparison function by which the
|
1247
|
+
* array is ordered. Should take 2 arguments to compare, and return a
|
1248
|
+
* negative number, zero, or a positive number depending on whether the
|
1249
|
+
* first argument is less than, equal to, or greater than the second.
|
1250
|
+
* @return {boolean} True if an element was removed.
|
1251
|
+
*/
|
1252
|
+
goog.array.binaryRemove = function(array, value, opt_compareFn) {
|
1253
|
+
var index = goog.array.binarySearch(array, value, opt_compareFn);
|
1254
|
+
return (index >= 0) ? goog.array.removeAt(array, index) : false;
|
1255
|
+
};
|
1256
|
+
|
1257
|
+
|
1258
|
+
/**
|
1259
|
+
* Splits an array into disjoint buckets according to a splitting function.
|
1260
|
+
* @param {Array.<T>} array The array.
|
1261
|
+
* @param {function(this:S, T,number,Array.<T>):?} sorter Function to call for
|
1262
|
+
* every element. This takes 3 arguments (the element, the index and the
|
1263
|
+
* array) and must return a valid object key (a string, number, etc), or
|
1264
|
+
* undefined, if that object should not be placed in a bucket.
|
1265
|
+
* @param {S=} opt_obj The object to be used as the value of 'this' within
|
1266
|
+
* sorter.
|
1267
|
+
* @return {!Object} An object, with keys being all of the unique return values
|
1268
|
+
* of sorter, and values being arrays containing the items for
|
1269
|
+
* which the splitter returned that key.
|
1270
|
+
* @template T,S
|
1271
|
+
*/
|
1272
|
+
goog.array.bucket = function(array, sorter, opt_obj) {
|
1273
|
+
var buckets = {};
|
1274
|
+
|
1275
|
+
for (var i = 0; i < array.length; i++) {
|
1276
|
+
var value = array[i];
|
1277
|
+
var key = sorter.call(opt_obj, value, i, array);
|
1278
|
+
if (goog.isDef(key)) {
|
1279
|
+
// Push the value to the right bucket, creating it if necessary.
|
1280
|
+
var bucket = buckets[key] || (buckets[key] = []);
|
1281
|
+
bucket.push(value);
|
1282
|
+
}
|
1283
|
+
}
|
1284
|
+
|
1285
|
+
return buckets;
|
1286
|
+
};
|
1287
|
+
|
1288
|
+
|
1289
|
+
/**
|
1290
|
+
* Creates a new object built from the provided array and the key-generation
|
1291
|
+
* function.
|
1292
|
+
* @param {Array.<T>|goog.array.ArrayLike} arr Array or array like object over
|
1293
|
+
* which to iterate whose elements will be the values in the new object.
|
1294
|
+
* @param {?function(this:S, T, number, ?) : string} keyFunc The function to
|
1295
|
+
* call for every element. This function takes 3 arguments (the element, the
|
1296
|
+
* index and the array) and should return a string that will be used as the
|
1297
|
+
* key for the element in the new object. If the function returns the same
|
1298
|
+
* key for more than one element, the value for that key is
|
1299
|
+
* implementation-defined.
|
1300
|
+
* @param {S=} opt_obj The object to be used as the value of 'this'
|
1301
|
+
* within keyFunc.
|
1302
|
+
* @return {!Object.<T>} The new object.
|
1303
|
+
* @template T,S
|
1304
|
+
*/
|
1305
|
+
goog.array.toObject = function(arr, keyFunc, opt_obj) {
|
1306
|
+
var ret = {};
|
1307
|
+
goog.array.forEach(arr, function(element, index) {
|
1308
|
+
ret[keyFunc.call(opt_obj, element, index, arr)] = element;
|
1309
|
+
});
|
1310
|
+
return ret;
|
1311
|
+
};
|
1312
|
+
|
1313
|
+
|
1314
|
+
/**
|
1315
|
+
* Creates a range of numbers in an arithmetic progression.
|
1316
|
+
*
|
1317
|
+
* Range takes 1, 2, or 3 arguments:
|
1318
|
+
* <pre>
|
1319
|
+
* range(5) is the same as range(0, 5, 1) and produces [0, 1, 2, 3, 4]
|
1320
|
+
* range(2, 5) is the same as range(2, 5, 1) and produces [2, 3, 4]
|
1321
|
+
* range(-2, -5, -1) produces [-2, -3, -4]
|
1322
|
+
* range(-2, -5, 1) produces [], since stepping by 1 wouldn't ever reach -5.
|
1323
|
+
* </pre>
|
1324
|
+
*
|
1325
|
+
* @param {number} startOrEnd The starting value of the range if an end argument
|
1326
|
+
* is provided. Otherwise, the start value is 0, and this is the end value.
|
1327
|
+
* @param {number=} opt_end The optional end value of the range.
|
1328
|
+
* @param {number=} opt_step The step size between range values. Defaults to 1
|
1329
|
+
* if opt_step is undefined or 0.
|
1330
|
+
* @return {!Array.<number>} An array of numbers for the requested range. May be
|
1331
|
+
* an empty array if adding the step would not converge toward the end
|
1332
|
+
* value.
|
1333
|
+
*/
|
1334
|
+
goog.array.range = function(startOrEnd, opt_end, opt_step) {
|
1335
|
+
var array = [];
|
1336
|
+
var start = 0;
|
1337
|
+
var end = startOrEnd;
|
1338
|
+
var step = opt_step || 1;
|
1339
|
+
if (opt_end !== undefined) {
|
1340
|
+
start = startOrEnd;
|
1341
|
+
end = opt_end;
|
1342
|
+
}
|
1343
|
+
|
1344
|
+
if (step * (end - start) < 0) {
|
1345
|
+
// Sign mismatch: start + step will never reach the end value.
|
1346
|
+
return [];
|
1347
|
+
}
|
1348
|
+
|
1349
|
+
if (step > 0) {
|
1350
|
+
for (var i = start; i < end; i += step) {
|
1351
|
+
array.push(i);
|
1352
|
+
}
|
1353
|
+
} else {
|
1354
|
+
for (var i = start; i > end; i += step) {
|
1355
|
+
array.push(i);
|
1356
|
+
}
|
1357
|
+
}
|
1358
|
+
return array;
|
1359
|
+
};
|
1360
|
+
|
1361
|
+
|
1362
|
+
/**
|
1363
|
+
* Returns an array consisting of the given value repeated N times.
|
1364
|
+
*
|
1365
|
+
* @param {*} value The value to repeat.
|
1366
|
+
* @param {number} n The repeat count.
|
1367
|
+
* @return {!Array} An array with the repeated value.
|
1368
|
+
*/
|
1369
|
+
goog.array.repeat = function(value, n) {
|
1370
|
+
var array = [];
|
1371
|
+
for (var i = 0; i < n; i++) {
|
1372
|
+
array[i] = value;
|
1373
|
+
}
|
1374
|
+
return array;
|
1375
|
+
};
|
1376
|
+
|
1377
|
+
|
1378
|
+
/**
|
1379
|
+
* Returns an array consisting of every argument with all arrays
|
1380
|
+
* expanded in-place recursively.
|
1381
|
+
*
|
1382
|
+
* @param {...*} var_args The values to flatten.
|
1383
|
+
* @return {!Array} An array containing the flattened values.
|
1384
|
+
*/
|
1385
|
+
goog.array.flatten = function(var_args) {
|
1386
|
+
var result = [];
|
1387
|
+
for (var i = 0; i < arguments.length; i++) {
|
1388
|
+
var element = arguments[i];
|
1389
|
+
if (goog.isArray(element)) {
|
1390
|
+
result.push.apply(result, goog.array.flatten.apply(null, element));
|
1391
|
+
} else {
|
1392
|
+
result.push(element);
|
1393
|
+
}
|
1394
|
+
}
|
1395
|
+
return result;
|
1396
|
+
};
|
1397
|
+
|
1398
|
+
|
1399
|
+
/**
|
1400
|
+
* Rotates an array in-place. After calling this method, the element at
|
1401
|
+
* index i will be the element previously at index (i - n) %
|
1402
|
+
* array.length, for all values of i between 0 and array.length - 1,
|
1403
|
+
* inclusive.
|
1404
|
+
*
|
1405
|
+
* For example, suppose list comprises [t, a, n, k, s]. After invoking
|
1406
|
+
* rotate(array, 1) (or rotate(array, -4)), array will comprise [s, t, a, n, k].
|
1407
|
+
*
|
1408
|
+
* @param {!Array.<T>} array The array to rotate.
|
1409
|
+
* @param {number} n The amount to rotate.
|
1410
|
+
* @return {!Array.<T>} The array.
|
1411
|
+
* @template T
|
1412
|
+
*/
|
1413
|
+
goog.array.rotate = function(array, n) {
|
1414
|
+
goog.asserts.assert(array.length != null);
|
1415
|
+
|
1416
|
+
if (array.length) {
|
1417
|
+
n %= array.length;
|
1418
|
+
if (n > 0) {
|
1419
|
+
goog.array.ARRAY_PROTOTYPE_.unshift.apply(array, array.splice(-n, n));
|
1420
|
+
} else if (n < 0) {
|
1421
|
+
goog.array.ARRAY_PROTOTYPE_.push.apply(array, array.splice(0, -n));
|
1422
|
+
}
|
1423
|
+
}
|
1424
|
+
return array;
|
1425
|
+
};
|
1426
|
+
|
1427
|
+
|
1428
|
+
/**
|
1429
|
+
* Moves one item of an array to a new position keeping the order of the rest
|
1430
|
+
* of the items. Example use case: keeping a list of JavaScript objects
|
1431
|
+
* synchronized with the corresponding list of DOM elements after one of the
|
1432
|
+
* elements has been dragged to a new position.
|
1433
|
+
* @param {!(Array|Arguments|{length:number})} arr The array to modify.
|
1434
|
+
* @param {number} fromIndex Index of the item to move between 0 and
|
1435
|
+
* {@code arr.length - 1}.
|
1436
|
+
* @param {number} toIndex Target index between 0 and {@code arr.length - 1}.
|
1437
|
+
*/
|
1438
|
+
goog.array.moveItem = function(arr, fromIndex, toIndex) {
|
1439
|
+
goog.asserts.assert(fromIndex >= 0 && fromIndex < arr.length);
|
1440
|
+
goog.asserts.assert(toIndex >= 0 && toIndex < arr.length);
|
1441
|
+
// Remove 1 item at fromIndex.
|
1442
|
+
var removedItems = goog.array.ARRAY_PROTOTYPE_.splice.call(arr, fromIndex, 1);
|
1443
|
+
// Insert the removed item at toIndex.
|
1444
|
+
goog.array.ARRAY_PROTOTYPE_.splice.call(arr, toIndex, 0, removedItems[0]);
|
1445
|
+
// We don't use goog.array.insertAt and goog.array.removeAt, because they're
|
1446
|
+
// significantly slower than splice.
|
1447
|
+
};
|
1448
|
+
|
1449
|
+
|
1450
|
+
/**
|
1451
|
+
* Creates a new array for which the element at position i is an array of the
|
1452
|
+
* ith element of the provided arrays. The returned array will only be as long
|
1453
|
+
* as the shortest array provided; additional values are ignored. For example,
|
1454
|
+
* the result of zipping [1, 2] and [3, 4, 5] is [[1,3], [2, 4]].
|
1455
|
+
*
|
1456
|
+
* This is similar to the zip() function in Python. See {@link
|
1457
|
+
* http://docs.python.org/library/functions.html#zip}
|
1458
|
+
*
|
1459
|
+
* @param {...!goog.array.ArrayLike} var_args Arrays to be combined.
|
1460
|
+
* @return {!Array.<!Array>} A new array of arrays created from provided arrays.
|
1461
|
+
*/
|
1462
|
+
goog.array.zip = function(var_args) {
|
1463
|
+
if (!arguments.length) {
|
1464
|
+
return [];
|
1465
|
+
}
|
1466
|
+
var result = [];
|
1467
|
+
for (var i = 0; true; i++) {
|
1468
|
+
var value = [];
|
1469
|
+
for (var j = 0; j < arguments.length; j++) {
|
1470
|
+
var arr = arguments[j];
|
1471
|
+
// If i is larger than the array length, this is the shortest array.
|
1472
|
+
if (i >= arr.length) {
|
1473
|
+
return result;
|
1474
|
+
}
|
1475
|
+
value.push(arr[i]);
|
1476
|
+
}
|
1477
|
+
result.push(value);
|
1478
|
+
}
|
1479
|
+
};
|
1480
|
+
|
1481
|
+
|
1482
|
+
/**
|
1483
|
+
* Shuffles the values in the specified array using the Fisher-Yates in-place
|
1484
|
+
* shuffle (also known as the Knuth Shuffle). By default, calls Math.random()
|
1485
|
+
* and so resets the state of that random number generator. Similarly, may reset
|
1486
|
+
* the state of the any other specified random number generator.
|
1487
|
+
*
|
1488
|
+
* Runtime: O(n)
|
1489
|
+
*
|
1490
|
+
* @param {!Array} arr The array to be shuffled.
|
1491
|
+
* @param {function():number=} opt_randFn Optional random function to use for
|
1492
|
+
* shuffling.
|
1493
|
+
* Takes no arguments, and returns a random number on the interval [0, 1).
|
1494
|
+
* Defaults to Math.random() using JavaScript's built-in Math library.
|
1495
|
+
*/
|
1496
|
+
goog.array.shuffle = function(arr, opt_randFn) {
|
1497
|
+
var randFn = opt_randFn || Math.random;
|
1498
|
+
|
1499
|
+
for (var i = arr.length - 1; i > 0; i--) {
|
1500
|
+
// Choose a random array index in [0, i] (inclusive with i).
|
1501
|
+
var j = Math.floor(randFn() * (i + 1));
|
1502
|
+
|
1503
|
+
var tmp = arr[i];
|
1504
|
+
arr[i] = arr[j];
|
1505
|
+
arr[j] = tmp;
|
1506
|
+
}
|
1507
|
+
};
|