closure 1.1.692
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +6 -0
- data/.yardopts +3 -0
- data/LICENSE +202 -0
- data/README.md +26 -0
- data/beanshell/LICENSE +12 -0
- data/beanshell/bsh-core-2.0b4.jar +0 -0
- data/closure-compiler/COPYING +202 -0
- data/closure-compiler/README +278 -0
- data/closure-compiler/compiler.jar +0 -0
- data/closure-library/AUTHORS +12 -0
- data/closure-library/LICENSE +176 -0
- data/closure-library/README +6 -0
- data/closure-library/all_tests.html +113 -0
- data/closure-library/alltests.js +16 -0
- data/closure-library/closure/bin/build/closurebuilder.py +257 -0
- data/closure-library/closure/bin/build/depstree.py +186 -0
- data/closure-library/closure/bin/build/depstree_test.py +127 -0
- data/closure-library/closure/bin/build/depswriter.py +197 -0
- data/closure-library/closure/bin/build/jscompiler.py +69 -0
- data/closure-library/closure/bin/build/source.py +86 -0
- data/closure-library/closure/bin/build/source_test.py +57 -0
- data/closure-library/closure/bin/build/treescan.py +78 -0
- data/closure-library/closure/bin/calcdeps.py +570 -0
- data/closure-library/closure/bin/scopify.py +211 -0
- data/closure-library/closure/css/inlay/g-base.css +82 -0
- data/closure-library/closure/css/inlay/g-fixed.css +158 -0
- data/closure-library/closure/css/inlay/g-ratio.css +253 -0
- data/closure-library/closure/goog/array/array.js +1300 -0
- data/closure-library/closure/goog/array/array_test.html +1524 -0
- data/closure-library/closure/goog/asserts/asserts.js +277 -0
- data/closure-library/closure/goog/asserts/asserts_test.html +163 -0
- data/closure-library/closure/goog/async/conditionaldelay.js +238 -0
- data/closure-library/closure/goog/async/conditionaldelay_test.html +227 -0
- data/closure-library/closure/goog/async/delay.js +174 -0
- data/closure-library/closure/goog/async/delay_test.html +148 -0
- data/closure-library/closure/goog/async/throttle.js +189 -0
- data/closure-library/closure/goog/async/throttle_test.html +102 -0
- data/closure-library/closure/goog/base.js +1471 -0
- data/closure-library/closure/goog/base_test.html +1166 -0
- data/closure-library/closure/goog/bootstrap/webworkers.js +37 -0
- data/closure-library/closure/goog/color/alpha.js +436 -0
- data/closure-library/closure/goog/color/alpha_test.html +234 -0
- data/closure-library/closure/goog/color/color.js +757 -0
- data/closure-library/closure/goog/color/color_test.html +645 -0
- data/closure-library/closure/goog/color/names.js +176 -0
- data/closure-library/closure/goog/crypt/arc4.js +141 -0
- data/closure-library/closure/goog/crypt/arc4_test.html +42 -0
- data/closure-library/closure/goog/crypt/base64.js +267 -0
- data/closure-library/closure/goog/crypt/base64_test.html +106 -0
- data/closure-library/closure/goog/crypt/basen.js +242 -0
- data/closure-library/closure/goog/crypt/basen_test.html +167 -0
- data/closure-library/closure/goog/crypt/crypt.js +103 -0
- data/closure-library/closure/goog/crypt/crypt_test.html +68 -0
- data/closure-library/closure/goog/crypt/hash32.js +184 -0
- data/closure-library/closure/goog/crypt/hash32_test.html +287 -0
- data/closure-library/closure/goog/crypt/sha1.js +238 -0
- data/closure-library/closure/goog/crypt/sha1_test.html +47 -0
- data/closure-library/closure/goog/css/autocomplete.css +43 -0
- data/closure-library/closure/goog/css/bubble.css +84 -0
- data/closure-library/closure/goog/css/button.css +38 -0
- data/closure-library/closure/goog/css/charpicker.css +201 -0
- data/closure-library/closure/goog/css/checkbox.css +38 -0
- data/closure-library/closure/goog/css/colormenubutton.css +25 -0
- data/closure-library/closure/goog/css/colorpalette.css +54 -0
- data/closure-library/closure/goog/css/colorpicker-simplegrid.css +50 -0
- data/closure-library/closure/goog/css/combobox.css +57 -0
- data/closure-library/closure/goog/css/common.css +41 -0
- data/closure-library/closure/goog/css/css3button.css +77 -0
- data/closure-library/closure/goog/css/css3menubutton.css +23 -0
- data/closure-library/closure/goog/css/custombutton.css +164 -0
- data/closure-library/closure/goog/css/datepicker.css +148 -0
- data/closure-library/closure/goog/css/dialog.css +72 -0
- data/closure-library/closure/goog/css/dimensionpicker.css +47 -0
- data/closure-library/closure/goog/css/dragdropdetector.css +48 -0
- data/closure-library/closure/goog/css/editor/bubble.css +73 -0
- data/closure-library/closure/goog/css/editor/dialog.css +66 -0
- data/closure-library/closure/goog/css/editor/linkdialog.css +36 -0
- data/closure-library/closure/goog/css/editortoolbar.css +225 -0
- data/closure-library/closure/goog/css/filteredmenu.css +30 -0
- data/closure-library/closure/goog/css/filterobservingmenuitem.css +25 -0
- data/closure-library/closure/goog/css/flatbutton.css +65 -0
- data/closure-library/closure/goog/css/flatmenubutton.css +63 -0
- data/closure-library/closure/goog/css/hovercard.css +51 -0
- data/closure-library/closure/goog/css/hsvapalette.css +231 -0
- data/closure-library/closure/goog/css/hsvpalette.css +179 -0
- data/closure-library/closure/goog/css/imagelessbutton.css +160 -0
- data/closure-library/closure/goog/css/imagelessmenubutton.css +23 -0
- data/closure-library/closure/goog/css/inputdatepicker.css +12 -0
- data/closure-library/closure/goog/css/linkbutton.css +26 -0
- data/closure-library/closure/goog/css/menu.css +27 -0
- data/closure-library/closure/goog/css/menubutton.css +169 -0
- data/closure-library/closure/goog/css/menuitem.css +96 -0
- data/closure-library/closure/goog/css/menuseparator.css +19 -0
- data/closure-library/closure/goog/css/multitestrunner.css +121 -0
- data/closure-library/closure/goog/css/offline.css +147 -0
- data/closure-library/closure/goog/css/palette.css +36 -0
- data/closure-library/closure/goog/css/popupdatepicker.css +17 -0
- data/closure-library/closure/goog/css/roundedpanel.css +29 -0
- data/closure-library/closure/goog/css/roundedtab.css +158 -0
- data/closure-library/closure/goog/css/submenu.css +28 -0
- data/closure-library/closure/goog/css/tab.css +91 -0
- data/closure-library/closure/goog/css/tabbar.css +52 -0
- data/closure-library/closure/goog/css/tablesorter.css +14 -0
- data/closure-library/closure/goog/css/toolbar.css +400 -0
- data/closure-library/closure/goog/css/tooltip.css +14 -0
- data/closure-library/closure/goog/css/tree.css +147 -0
- data/closure-library/closure/goog/css/tristatemenuitem.css +43 -0
- data/closure-library/closure/goog/cssom/cssom.js +447 -0
- data/closure-library/closure/goog/cssom/cssom_test.html +343 -0
- data/closure-library/closure/goog/cssom/cssom_test_import_1.css +11 -0
- data/closure-library/closure/goog/cssom/cssom_test_import_2.css +10 -0
- data/closure-library/closure/goog/cssom/cssom_test_link_1.css +10 -0
- data/closure-library/closure/goog/cssom/iframe/style.js +1020 -0
- data/closure-library/closure/goog/cssom/iframe/style_test.html +391 -0
- data/closure-library/closure/goog/cssom/iframe/style_test_import.css +10 -0
- data/closure-library/closure/goog/datasource/datamanager.js +566 -0
- data/closure-library/closure/goog/datasource/datasource.js +646 -0
- data/closure-library/closure/goog/datasource/datasource_test.html +265 -0
- data/closure-library/closure/goog/datasource/expr.js +544 -0
- data/closure-library/closure/goog/datasource/expr_test.html +97 -0
- data/closure-library/closure/goog/datasource/fastdatanode.js +792 -0
- data/closure-library/closure/goog/datasource/fastdatanode_test.html +254 -0
- data/closure-library/closure/goog/datasource/jsdatasource.js +460 -0
- data/closure-library/closure/goog/datasource/jsondatasource.js +146 -0
- data/closure-library/closure/goog/datasource/jsxmlhttpdatasource.js +191 -0
- data/closure-library/closure/goog/datasource/jsxmlhttpdatasource_test.html +94 -0
- data/closure-library/closure/goog/datasource/xmldatasource.js +407 -0
- data/closure-library/closure/goog/date/date.js +1642 -0
- data/closure-library/closure/goog/date/date_test.html +1293 -0
- data/closure-library/closure/goog/date/datelike.js +27 -0
- data/closure-library/closure/goog/date/daterange.js +398 -0
- data/closure-library/closure/goog/date/daterange_test.html +213 -0
- data/closure-library/closure/goog/date/relative.js +425 -0
- data/closure-library/closure/goog/date/relative_test.html +124 -0
- data/closure-library/closure/goog/date/utcdatetime.js +178 -0
- data/closure-library/closure/goog/date/utcdatetime_test.html +119 -0
- data/closure-library/closure/goog/debug/console.js +138 -0
- data/closure-library/closure/goog/debug/debug.js +452 -0
- data/closure-library/closure/goog/debug/debug_test.html +32 -0
- data/closure-library/closure/goog/debug/debugwindow.js +582 -0
- data/closure-library/closure/goog/debug/devcss/devcss.js +435 -0
- data/closure-library/closure/goog/debug/devcss/devcss_test.html +365 -0
- data/closure-library/closure/goog/debug/devcss/devcssrunner.js +26 -0
- data/closure-library/closure/goog/debug/divconsole.js +141 -0
- data/closure-library/closure/goog/debug/enhanceerror_test.html +138 -0
- data/closure-library/closure/goog/debug/entrypointregistry.js +111 -0
- data/closure-library/closure/goog/debug/entrypointregistry_test.html +63 -0
- data/closure-library/closure/goog/debug/error.js +47 -0
- data/closure-library/closure/goog/debug/error_test.html +85 -0
- data/closure-library/closure/goog/debug/errorhandler.js +234 -0
- data/closure-library/closure/goog/debug/errorhandler_async_test.html +112 -0
- data/closure-library/closure/goog/debug/errorhandler_test.html +186 -0
- data/closure-library/closure/goog/debug/errorhandlerweakdep.js +38 -0
- data/closure-library/closure/goog/debug/errorreporter.js +324 -0
- data/closure-library/closure/goog/debug/errorreporter_test.html +289 -0
- data/closure-library/closure/goog/debug/fancywindow.js +265 -0
- data/closure-library/closure/goog/debug/formatter.js +314 -0
- data/closure-library/closure/goog/debug/gcdiagnostics.js +143 -0
- data/closure-library/closure/goog/debug/logbuffer.js +147 -0
- data/closure-library/closure/goog/debug/logbuffer_test.html +105 -0
- data/closure-library/closure/goog/debug/logger.js +809 -0
- data/closure-library/closure/goog/debug/logger_test.html +208 -0
- data/closure-library/closure/goog/debug/logrecord.js +271 -0
- data/closure-library/closure/goog/debug/reflect.js +159 -0
- data/closure-library/closure/goog/debug/reflect_test.html +81 -0
- data/closure-library/closure/goog/debug/relativetimeprovider.js +83 -0
- data/closure-library/closure/goog/debug/tracer.js +750 -0
- data/closure-library/closure/goog/debug/tracer_test.html +57 -0
- data/closure-library/closure/goog/demos/advancedtooltip.html +78 -0
- data/closure-library/closure/goog/demos/animationqueue.html +149 -0
- data/closure-library/closure/goog/demos/autocomplete-basic.html +56 -0
- data/closure-library/closure/goog/demos/autocompleteremote.html +40 -0
- data/closure-library/closure/goog/demos/autocompleteremotedata.js +18 -0
- data/closure-library/closure/goog/demos/autocompleterichremote.html +137 -0
- data/closure-library/closure/goog/demos/autocompleterichremotedata.js +33 -0
- data/closure-library/closure/goog/demos/bidiinput.html +72 -0
- data/closure-library/closure/goog/demos/bubble.html +250 -0
- data/closure-library/closure/goog/demos/button.html +395 -0
- data/closure-library/closure/goog/demos/charcounter.html +57 -0
- data/closure-library/closure/goog/demos/charpicker.html +64 -0
- data/closure-library/closure/goog/demos/checkbox.html +122 -0
- data/closure-library/closure/goog/demos/color-contrast.html +60 -0
- data/closure-library/closure/goog/demos/colormenubutton.html +213 -0
- data/closure-library/closure/goog/demos/colorpicker.html +43 -0
- data/closure-library/closure/goog/demos/combobox.html +125 -0
- data/closure-library/closure/goog/demos/container.html +670 -0
- data/closure-library/closure/goog/demos/control.html +477 -0
- data/closure-library/closure/goog/demos/css/demo.css +75 -0
- data/closure-library/closure/goog/demos/css/emojipicker.css +36 -0
- data/closure-library/closure/goog/demos/css/emojisprite.css +92 -0
- data/closure-library/closure/goog/demos/css3button.html +166 -0
- data/closure-library/closure/goog/demos/css3menubutton.html +285 -0
- data/closure-library/closure/goog/demos/cssspriteanimation.html +80 -0
- data/closure-library/closure/goog/demos/datepicker.html +183 -0
- data/closure-library/closure/goog/demos/debug.html +119 -0
- data/closure-library/closure/goog/demos/depsgraph.html +221 -0
- data/closure-library/closure/goog/demos/dialog.html +156 -0
- data/closure-library/closure/goog/demos/dimensionpicker.html +108 -0
- data/closure-library/closure/goog/demos/dimensionpicker_rtl.html +123 -0
- data/closure-library/closure/goog/demos/dom_selection.html +88 -0
- data/closure-library/closure/goog/demos/drag.html +191 -0
- data/closure-library/closure/goog/demos/dragdrop.html +263 -0
- data/closure-library/closure/goog/demos/dragdropdetector.html +46 -0
- data/closure-library/closure/goog/demos/dragdropdetector_target.html +17 -0
- data/closure-library/closure/goog/demos/dragger.html +83 -0
- data/closure-library/closure/goog/demos/draglistgroup.html +261 -0
- data/closure-library/closure/goog/demos/drilldownrow.html +78 -0
- data/closure-library/closure/goog/demos/editor/deps.js +20 -0
- data/closure-library/closure/goog/demos/editor/editor.html +139 -0
- data/closure-library/closure/goog/demos/editor/field_basic.html +74 -0
- data/closure-library/closure/goog/demos/editor/helloworld.html +91 -0
- data/closure-library/closure/goog/demos/editor/helloworld.js +81 -0
- data/closure-library/closure/goog/demos/editor/helloworld_test.html +75 -0
- data/closure-library/closure/goog/demos/editor/helloworlddialog.js +163 -0
- data/closure-library/closure/goog/demos/editor/helloworlddialog_test.html +100 -0
- data/closure-library/closure/goog/demos/editor/helloworlddialogplugin.js +110 -0
- data/closure-library/closure/goog/demos/editor/helloworlddialogplugin_test.html +198 -0
- data/closure-library/closure/goog/demos/editor/seamlessfield.html +106 -0
- data/closure-library/closure/goog/demos/effects.html +142 -0
- data/closure-library/closure/goog/demos/emoji/200.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/201.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/202.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/203.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/204.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/205.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/206.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2BC.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2BD.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2BE.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2BF.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C0.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C1.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C2.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C3.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C4.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C5.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C6.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C7.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C8.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2C9.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2CA.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2CB.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2CC.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2CD.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2CE.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2CF.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D0.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D1.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D2.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D3.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D4.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D5.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D6.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D7.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D8.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2D9.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2DA.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2DB.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2DC.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2DD.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2DE.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2DF.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E0.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E1.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E2.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E3.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E4.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E5.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E6.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E7.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E8.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2E9.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2EA.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2EB.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2EC.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2ED.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2EE.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2EF.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F0.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F1.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F2.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F3.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F4.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F5.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F6.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F7.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F8.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2F9.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2FA.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2FB.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2FC.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2FD.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2FE.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/2FF.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/none.gif +0 -0
- data/closure-library/closure/goog/demos/emoji/sprite.png +0 -0
- data/closure-library/closure/goog/demos/emoji/sprite2.png +0 -0
- data/closure-library/closure/goog/demos/emoji/unknown.gif +0 -0
- data/closure-library/closure/goog/demos/event-propagation.html +192 -0
- data/closure-library/closure/goog/demos/events.html +99 -0
- data/closure-library/closure/goog/demos/eventtarget.html +70 -0
- data/closure-library/closure/goog/demos/filedrophandler.html +63 -0
- data/closure-library/closure/goog/demos/filteredmenu.html +118 -0
- data/closure-library/closure/goog/demos/focushandler.html +58 -0
- data/closure-library/closure/goog/demos/gauge.html +158 -0
- data/closure-library/closure/goog/demos/graphics/advancedcoordinates.html +141 -0
- data/closure-library/closure/goog/demos/graphics/advancedcoordinates2.html +130 -0
- data/closure-library/closure/goog/demos/graphics/basicelements.html +264 -0
- data/closure-library/closure/goog/demos/graphics/events.html +113 -0
- data/closure-library/closure/goog/demos/graphics/modifyelements.html +195 -0
- data/closure-library/closure/goog/demos/graphics/subpixel.html +80 -0
- data/closure-library/closure/goog/demos/graphics/tiger.html +105 -0
- data/closure-library/closure/goog/demos/graphics/tigerdata.js +2840 -0
- data/closure-library/closure/goog/demos/history1.html +132 -0
- data/closure-library/closure/goog/demos/history2.html +100 -0
- data/closure-library/closure/goog/demos/history3.html +106 -0
- data/closure-library/closure/goog/demos/history3js.html +36 -0
- data/closure-library/closure/goog/demos/history_blank.html +25 -0
- data/closure-library/closure/goog/demos/hovercard.html +177 -0
- data/closure-library/closure/goog/demos/hsvapalette.html +55 -0
- data/closure-library/closure/goog/demos/hsvpalette.html +56 -0
- data/closure-library/closure/goog/demos/html5history.html +87 -0
- data/closure-library/closure/goog/demos/imagelessbutton.html +221 -0
- data/closure-library/closure/goog/demos/imagelessmenubutton.html +285 -0
- data/closure-library/closure/goog/demos/imagelessroundedcorner.html +231 -0
- data/closure-library/closure/goog/demos/index.html +19 -0
- data/closure-library/closure/goog/demos/index_nav.html +253 -0
- data/closure-library/closure/goog/demos/index_splash.html +22 -0
- data/closure-library/closure/goog/demos/inline_block_quirks.html +125 -0
- data/closure-library/closure/goog/demos/inline_block_standards.html +126 -0
- data/closure-library/closure/goog/demos/inputdatepicker.html +60 -0
- data/closure-library/closure/goog/demos/inputhandler.html +72 -0
- data/closure-library/closure/goog/demos/jsonprettyprinter.html +80 -0
- data/closure-library/closure/goog/demos/keyboardshortcuts.html +112 -0
- data/closure-library/closure/goog/demos/keyhandler.html +127 -0
- data/closure-library/closure/goog/demos/labelinput.html +42 -0
- data/closure-library/closure/goog/demos/menu.html +220 -0
- data/closure-library/closure/goog/demos/menubutton.html +318 -0
- data/closure-library/closure/goog/demos/mousewheelhandler.html +109 -0
- data/closure-library/closure/goog/demos/offline.html +268 -0
- data/closure-library/closure/goog/demos/onlinehandler.html +77 -0
- data/closure-library/closure/goog/demos/palette.html +302 -0
- data/closure-library/closure/goog/demos/pastehandler.html +54 -0
- data/closure-library/closure/goog/demos/plaintextspellchecker.html +106 -0
- data/closure-library/closure/goog/demos/popup.html +200 -0
- data/closure-library/closure/goog/demos/popupcolorpicker.html +49 -0
- data/closure-library/closure/goog/demos/popupdatepicker.html +53 -0
- data/closure-library/closure/goog/demos/popupemojipicker.html +407 -0
- data/closure-library/closure/goog/demos/popupmenu.html +89 -0
- data/closure-library/closure/goog/demos/progressbar.html +97 -0
- data/closure-library/closure/goog/demos/prompt.html +92 -0
- data/closure-library/closure/goog/demos/quadtree.html +107 -0
- data/closure-library/closure/goog/demos/ratings.html +120 -0
- data/closure-library/closure/goog/demos/richtextspellchecker.html +92 -0
- data/closure-library/closure/goog/demos/roundedpanel.html +139 -0
- data/closure-library/closure/goog/demos/samplecomponent.html +75 -0
- data/closure-library/closure/goog/demos/samplecomponent.js +206 -0
- data/closure-library/closure/goog/demos/scrollfloater.html +117 -0
- data/closure-library/closure/goog/demos/select.html +324 -0
- data/closure-library/closure/goog/demos/selectionmenubutton.html +186 -0
- data/closure-library/closure/goog/demos/serverchart.html +122 -0
- data/closure-library/closure/goog/demos/silverlightclipboardbutton.html +71 -0
- data/closure-library/closure/goog/demos/slider.html +110 -0
- data/closure-library/closure/goog/demos/splitbehavior.html +164 -0
- data/closure-library/closure/goog/demos/splitpane.html +243 -0
- data/closure-library/closure/goog/demos/stopevent.html +171 -0
- data/closure-library/closure/goog/demos/submenus.html +130 -0
- data/closure-library/closure/goog/demos/submenus2.html +150 -0
- data/closure-library/closure/goog/demos/tabbar.html +289 -0
- data/closure-library/closure/goog/demos/tablesorter.html +116 -0
- data/closure-library/closure/goog/demos/tabpane.html +302 -0
- data/closure-library/closure/goog/demos/textarea.html +128 -0
- data/closure-library/closure/goog/demos/timers.html +291 -0
- data/closure-library/closure/goog/demos/toolbar.html +703 -0
- data/closure-library/closure/goog/demos/tooltip.html +91 -0
- data/closure-library/closure/goog/demos/tracer.html +92 -0
- data/closure-library/closure/goog/demos/tree/demo.html +126 -0
- data/closure-library/closure/goog/demos/tree/testdata.js +260 -0
- data/closure-library/closure/goog/demos/tweakui.html +121 -0
- data/closure-library/closure/goog/demos/twothumbslider.html +121 -0
- data/closure-library/closure/goog/demos/useragent.html +173 -0
- data/closure-library/closure/goog/demos/viewportsizemonitor.html +71 -0
- data/closure-library/closure/goog/demos/xpc/blank.html +7 -0
- data/closure-library/closure/goog/demos/xpc/index.html +89 -0
- data/closure-library/closure/goog/demos/xpc/inner.html +58 -0
- data/closure-library/closure/goog/demos/xpc/minimal/blank.html +7 -0
- data/closure-library/closure/goog/demos/xpc/minimal/index.html +105 -0
- data/closure-library/closure/goog/demos/xpc/minimal/inner.html +75 -0
- data/closure-library/closure/goog/demos/xpc/minimal/relay.html +7 -0
- data/closure-library/closure/goog/demos/xpc/relay.html +7 -0
- data/closure-library/closure/goog/demos/xpc/xpcdemo.js +304 -0
- data/closure-library/closure/goog/demos/zippy.html +127 -0
- data/closure-library/closure/goog/deps.js +672 -0
- data/closure-library/closure/goog/disposable/disposable.js +167 -0
- data/closure-library/closure/goog/disposable/disposable_test.html +202 -0
- data/closure-library/closure/goog/dom/a11y.js +438 -0
- data/closure-library/closure/goog/dom/a11y_test.html +86 -0
- data/closure-library/closure/goog/dom/abstractmultirange.js +77 -0
- data/closure-library/closure/goog/dom/abstractrange.js +514 -0
- data/closure-library/closure/goog/dom/abstractrange_test.html +73 -0
- data/closure-library/closure/goog/dom/annotate.js +352 -0
- data/closure-library/closure/goog/dom/annotate_test.html +187 -0
- data/closure-library/closure/goog/dom/browserfeature.js +50 -0
- data/closure-library/closure/goog/dom/browserrange/abstractrange.js +316 -0
- data/closure-library/closure/goog/dom/browserrange/browserrange.js +149 -0
- data/closure-library/closure/goog/dom/browserrange/browserrange_test.html +562 -0
- data/closure-library/closure/goog/dom/browserrange/geckorange.js +82 -0
- data/closure-library/closure/goog/dom/browserrange/ierange.js +970 -0
- data/closure-library/closure/goog/dom/browserrange/operarange.js +83 -0
- data/closure-library/closure/goog/dom/browserrange/w3crange.js +364 -0
- data/closure-library/closure/goog/dom/browserrange/webkitrange.js +112 -0
- data/closure-library/closure/goog/dom/classes.js +233 -0
- data/closure-library/closure/goog/dom/classes_test.html +228 -0
- data/closure-library/closure/goog/dom/controlrange.js +511 -0
- data/closure-library/closure/goog/dom/controlrange_test.html +246 -0
- data/closure-library/closure/goog/dom/dataset.js +90 -0
- data/closure-library/closure/goog/dom/dataset_test.html +104 -0
- data/closure-library/closure/goog/dom/dom.js +2424 -0
- data/closure-library/closure/goog/dom/dom_quirks_test.html +104 -0
- data/closure-library/closure/goog/dom/dom_test.html +103 -0
- data/closure-library/closure/goog/dom/dom_test.js +1129 -0
- data/closure-library/closure/goog/dom/fontsizemonitor.js +159 -0
- data/closure-library/closure/goog/dom/fontsizemonitor_test.html +283 -0
- data/closure-library/closure/goog/dom/forms.js +403 -0
- data/closure-library/closure/goog/dom/forms_test.html +483 -0
- data/closure-library/closure/goog/dom/iframe.js +128 -0
- data/closure-library/closure/goog/dom/iframe_test.html +87 -0
- data/closure-library/closure/goog/dom/iter.js +127 -0
- data/closure-library/closure/goog/dom/iter_test.html +97 -0
- data/closure-library/closure/goog/dom/multirange.js +519 -0
- data/closure-library/closure/goog/dom/multirange_test.html +67 -0
- data/closure-library/closure/goog/dom/nodeiterator.js +85 -0
- data/closure-library/closure/goog/dom/nodeiterator_test.html +49 -0
- data/closure-library/closure/goog/dom/nodeoffset.js +111 -0
- data/closure-library/closure/goog/dom/nodeoffset_test.html +88 -0
- data/closure-library/closure/goog/dom/pattern/abstractpattern.js +60 -0
- data/closure-library/closure/goog/dom/pattern/allchildren.js +73 -0
- data/closure-library/closure/goog/dom/pattern/callback/callback.js +82 -0
- data/closure-library/closure/goog/dom/pattern/callback/counter.js +72 -0
- data/closure-library/closure/goog/dom/pattern/callback/test.js +77 -0
- data/closure-library/closure/goog/dom/pattern/childmatches.js +152 -0
- data/closure-library/closure/goog/dom/pattern/endtag.js +53 -0
- data/closure-library/closure/goog/dom/pattern/fulltag.js +92 -0
- data/closure-library/closure/goog/dom/pattern/matcher.js +150 -0
- data/closure-library/closure/goog/dom/pattern/matcher_test.html +204 -0
- data/closure-library/closure/goog/dom/pattern/nodetype.js +57 -0
- data/closure-library/closure/goog/dom/pattern/pattern.js +93 -0
- data/closure-library/closure/goog/dom/pattern/pattern_test.html +614 -0
- data/closure-library/closure/goog/dom/pattern/repeat.js +188 -0
- data/closure-library/closure/goog/dom/pattern/sequence.js +139 -0
- data/closure-library/closure/goog/dom/pattern/starttag.js +53 -0
- data/closure-library/closure/goog/dom/pattern/tag.js +149 -0
- data/closure-library/closure/goog/dom/pattern/text.js +69 -0
- data/closure-library/closure/goog/dom/range.js +220 -0
- data/closure-library/closure/goog/dom/range_test.html +702 -0
- data/closure-library/closure/goog/dom/rangeendpoint.js +32 -0
- data/closure-library/closure/goog/dom/savedcaretrange.js +203 -0
- data/closure-library/closure/goog/dom/savedcaretrange_test.html +235 -0
- data/closure-library/closure/goog/dom/savedrange.js +74 -0
- data/closure-library/closure/goog/dom/savedrange_test.html +61 -0
- data/closure-library/closure/goog/dom/selection.js +470 -0
- data/closure-library/closure/goog/dom/selection_test.html +329 -0
- data/closure-library/closure/goog/dom/tagiterator.js +365 -0
- data/closure-library/closure/goog/dom/tagiterator_test.html +589 -0
- data/closure-library/closure/goog/dom/tagname.js +121 -0
- data/closure-library/closure/goog/dom/tagname_test.html +37 -0
- data/closure-library/closure/goog/dom/textrange.js +611 -0
- data/closure-library/closure/goog/dom/textrange_test.html +127 -0
- data/closure-library/closure/goog/dom/textrangeiterator.js +246 -0
- data/closure-library/closure/goog/dom/textrangeiterator_test.html +142 -0
- data/closure-library/closure/goog/dom/viewportsizemonitor.js +220 -0
- data/closure-library/closure/goog/dom/viewportsizemonitor_test.html +166 -0
- data/closure-library/closure/goog/dom/xml.js +187 -0
- data/closure-library/closure/goog/dom/xml_test.html +77 -0
- data/closure-library/closure/goog/editor/browserfeature.js +251 -0
- data/closure-library/closure/goog/editor/browserfeature_test.html +124 -0
- data/closure-library/closure/goog/editor/clicktoeditwrapper.js +438 -0
- data/closure-library/closure/goog/editor/clicktoeditwrapper_test.html +137 -0
- data/closure-library/closure/goog/editor/command.js +74 -0
- data/closure-library/closure/goog/editor/defines.js +34 -0
- data/closure-library/closure/goog/editor/field.js +2594 -0
- data/closure-library/closure/goog/editor/field_test.html +1000 -0
- data/closure-library/closure/goog/editor/focus.js +32 -0
- data/closure-library/closure/goog/editor/focus_test.html +66 -0
- data/closure-library/closure/goog/editor/icontent.js +296 -0
- data/closure-library/closure/goog/editor/icontent_test.html +209 -0
- data/closure-library/closure/goog/editor/link.js +279 -0
- data/closure-library/closure/goog/editor/link_test.html +234 -0
- data/closure-library/closure/goog/editor/node.js +435 -0
- data/closure-library/closure/goog/editor/node_test.html +590 -0
- data/closure-library/closure/goog/editor/plugin.js +444 -0
- data/closure-library/closure/goog/editor/plugin_test.html +187 -0
- data/closure-library/closure/goog/editor/plugins/abstractbubbleplugin.js +535 -0
- data/closure-library/closure/goog/editor/plugins/abstractbubbleplugin_test.html +227 -0
- data/closure-library/closure/goog/editor/plugins/abstractdialogplugin.js +336 -0
- data/closure-library/closure/goog/editor/plugins/abstractdialogplugin_test.html +399 -0
- data/closure-library/closure/goog/editor/plugins/abstracttabhandler.js +78 -0
- data/closure-library/closure/goog/editor/plugins/abstracttabhandler_test.html +91 -0
- data/closure-library/closure/goog/editor/plugins/basictextformatter.js +1740 -0
- data/closure-library/closure/goog/editor/plugins/basictextformatter_test.html +1171 -0
- data/closure-library/closure/goog/editor/plugins/blockquote.js +422 -0
- data/closure-library/closure/goog/editor/plugins/blockquote_test.html +149 -0
- data/closure-library/closure/goog/editor/plugins/emoticons.js +83 -0
- data/closure-library/closure/goog/editor/plugins/emoticons_test.html +67 -0
- data/closure-library/closure/goog/editor/plugins/enterhandler.js +730 -0
- data/closure-library/closure/goog/editor/plugins/enterhandler_test.html +739 -0
- data/closure-library/closure/goog/editor/plugins/headerformatter.js +95 -0
- data/closure-library/closure/goog/editor/plugins/headerformatter_test.html +100 -0
- data/closure-library/closure/goog/editor/plugins/linkbubble.js +458 -0
- data/closure-library/closure/goog/editor/plugins/linkbubble_test.html +309 -0
- data/closure-library/closure/goog/editor/plugins/linkdialogplugin.js +222 -0
- data/closure-library/closure/goog/editor/plugins/linkdialogplugin_test.html +370 -0
- data/closure-library/closure/goog/editor/plugins/listtabhandler.js +66 -0
- data/closure-library/closure/goog/editor/plugins/listtabhandler_test.html +177 -0
- data/closure-library/closure/goog/editor/plugins/loremipsum.js +186 -0
- data/closure-library/closure/goog/editor/plugins/loremipsum_test.html +169 -0
- data/closure-library/closure/goog/editor/plugins/removeformatting.js +772 -0
- data/closure-library/closure/goog/editor/plugins/removeformatting_test.html +920 -0
- data/closure-library/closure/goog/editor/plugins/spacestabhandler.js +93 -0
- data/closure-library/closure/goog/editor/plugins/spacestabhandler_test.html +186 -0
- data/closure-library/closure/goog/editor/plugins/tableeditor.js +496 -0
- data/closure-library/closure/goog/editor/plugins/tableeditor_test.html +299 -0
- data/closure-library/closure/goog/editor/plugins/tagonenterhandler.js +741 -0
- data/closure-library/closure/goog/editor/plugins/tagonenterhandler_test.html +481 -0
- data/closure-library/closure/goog/editor/plugins/undoredo.js +1014 -0
- data/closure-library/closure/goog/editor/plugins/undoredo_test.html +525 -0
- data/closure-library/closure/goog/editor/plugins/undoredomanager.js +337 -0
- data/closure-library/closure/goog/editor/plugins/undoredomanager_test.html +394 -0
- data/closure-library/closure/goog/editor/plugins/undoredostate.js +84 -0
- data/closure-library/closure/goog/editor/plugins/undoredostate_test.html +44 -0
- data/closure-library/closure/goog/editor/range.js +602 -0
- data/closure-library/closure/goog/editor/range_test.html +880 -0
- data/closure-library/closure/goog/editor/seamlessfield.js +720 -0
- data/closure-library/closure/goog/editor/seamlessfield_quirks_test.html +30 -0
- data/closure-library/closure/goog/editor/seamlessfield_test.html +33 -0
- data/closure-library/closure/goog/editor/seamlessfield_test.js +392 -0
- data/closure-library/closure/goog/editor/style.js +222 -0
- data/closure-library/closure/goog/editor/style_test.html +177 -0
- data/closure-library/closure/goog/editor/table.js +566 -0
- data/closure-library/closure/goog/editor/table_test.html +522 -0
- data/closure-library/closure/goog/events/actioneventwrapper.js +131 -0
- data/closure-library/closure/goog/events/actioneventwrapper_test.html +176 -0
- data/closure-library/closure/goog/events/actionhandler.js +189 -0
- data/closure-library/closure/goog/events/actionhandler_test.html +82 -0
- data/closure-library/closure/goog/events/browserevent.js +412 -0
- data/closure-library/closure/goog/events/browserevent_test.html +145 -0
- data/closure-library/closure/goog/events/browserfeature.js +43 -0
- data/closure-library/closure/goog/events/event.js +123 -0
- data/closure-library/closure/goog/events/event_test.html +70 -0
- data/closure-library/closure/goog/events/eventhandler.js +348 -0
- data/closure-library/closure/goog/events/eventhandler_test.html +230 -0
- data/closure-library/closure/goog/events/events.js +1101 -0
- data/closure-library/closure/goog/events/events_test.html +362 -0
- data/closure-library/closure/goog/events/eventtarget.js +197 -0
- data/closure-library/closure/goog/events/eventtarget_test.html +423 -0
- data/closure-library/closure/goog/events/eventtype.js +107 -0
- data/closure-library/closure/goog/events/eventwrapper.js +67 -0
- data/closure-library/closure/goog/events/filedrophandler.js +224 -0
- data/closure-library/closure/goog/events/filedrophandler_test.html +258 -0
- data/closure-library/closure/goog/events/focushandler.js +111 -0
- data/closure-library/closure/goog/events/imehandler.js +365 -0
- data/closure-library/closure/goog/events/imehandler_test.html +271 -0
- data/closure-library/closure/goog/events/inputhandler.js +218 -0
- data/closure-library/closure/goog/events/keycodes.js +314 -0
- data/closure-library/closure/goog/events/keycodes_test.html +72 -0
- data/closure-library/closure/goog/events/keyhandler.js +522 -0
- data/closure-library/closure/goog/events/keyhandler_test.html +621 -0
- data/closure-library/closure/goog/events/keynames.js +124 -0
- data/closure-library/closure/goog/events/listener.js +160 -0
- data/closure-library/closure/goog/events/mousewheelhandler.js +280 -0
- data/closure-library/closure/goog/events/mousewheelhandler_test.html +331 -0
- data/closure-library/closure/goog/events/onlinehandler.js +176 -0
- data/closure-library/closure/goog/events/onlinelistener_test.html +214 -0
- data/closure-library/closure/goog/events/pastehandler.js +444 -0
- data/closure-library/closure/goog/events/pastehandler_test.html +354 -0
- data/closure-library/closure/goog/events/pools.js +342 -0
- data/closure-library/closure/goog/format/emailaddress.js +329 -0
- data/closure-library/closure/goog/format/emailaddress_test.html +179 -0
- data/closure-library/closure/goog/format/format.js +451 -0
- data/closure-library/closure/goog/format/format_test.html +257 -0
- data/closure-library/closure/goog/format/htmlprettyprinter.js +406 -0
- data/closure-library/closure/goog/format/htmlprettyprinter_test.html +205 -0
- data/closure-library/closure/goog/format/jsonprettyprinter.js +405 -0
- data/closure-library/closure/goog/format/jsonprettyprinter_test.html +111 -0
- data/closure-library/closure/goog/fs/entry.js +406 -0
- data/closure-library/closure/goog/fs/error.js +103 -0
- data/closure-library/closure/goog/fs/filesaver.js +214 -0
- data/closure-library/closure/goog/fs/filesystem.js +59 -0
- data/closure-library/closure/goog/fs/filewriter.js +106 -0
- data/closure-library/closure/goog/fs/fs.js +183 -0
- data/closure-library/closure/goog/fs/fs_test.html +270 -0
- data/closure-library/closure/goog/functions/functions.js +219 -0
- data/closure-library/closure/goog/functions/functions_test.html +198 -0
- data/closure-library/closure/goog/fx/abstractdragdrop.js +1451 -0
- data/closure-library/closure/goog/fx/abstractdragdrop_test.html +430 -0
- data/closure-library/closure/goog/fx/animation.js +621 -0
- data/closure-library/closure/goog/fx/animationqueue.js +348 -0
- data/closure-library/closure/goog/fx/cssspriteanimation.js +112 -0
- data/closure-library/closure/goog/fx/cssspriteanimation_test.html +125 -0
- data/closure-library/closure/goog/fx/dom.js +610 -0
- data/closure-library/closure/goog/fx/dragdrop.js +49 -0
- data/closure-library/closure/goog/fx/dragdropgroup.js +107 -0
- data/closure-library/closure/goog/fx/dragdropgroup_test.html +234 -0
- data/closure-library/closure/goog/fx/dragger.js +731 -0
- data/closure-library/closure/goog/fx/dragger_test.html +415 -0
- data/closure-library/closure/goog/fx/draglistgroup.js +1159 -0
- data/closure-library/closure/goog/fx/draglistgroup_test.html +231 -0
- data/closure-library/closure/goog/fx/dragscrollsupport.js +274 -0
- data/closure-library/closure/goog/fx/dragscrollsupport_test.html +253 -0
- data/closure-library/closure/goog/fx/easing.js +50 -0
- data/closure-library/closure/goog/fx/fx.js +30 -0
- data/closure-library/closure/goog/fx/fx_test.html +157 -0
- data/closure-library/closure/goog/gears/basestore.js +523 -0
- data/closure-library/closure/goog/gears/basestore_test.html +247 -0
- data/closure-library/closure/goog/gears/database.js +935 -0
- data/closure-library/closure/goog/gears/database_test.html +699 -0
- data/closure-library/closure/goog/gears/fakeworkerpool.js +252 -0
- data/closure-library/closure/goog/gears/fakeworkerpool_test.html +188 -0
- data/closure-library/closure/goog/gears/gears.js +228 -0
- data/closure-library/closure/goog/gears/gears_test.html +78 -0
- data/closure-library/closure/goog/gears/httprequest.js +77 -0
- data/closure-library/closure/goog/gears/loggerclient.js +131 -0
- data/closure-library/closure/goog/gears/loggerclient_test.html +171 -0
- data/closure-library/closure/goog/gears/loggerserver.js +158 -0
- data/closure-library/closure/goog/gears/loggerserver_test.html +118 -0
- data/closure-library/closure/goog/gears/logstore.js +479 -0
- data/closure-library/closure/goog/gears/logstore_test.html +600 -0
- data/closure-library/closure/goog/gears/managedresourcestore.js +553 -0
- data/closure-library/closure/goog/gears/managedresourcestore_test.html +453 -0
- data/closure-library/closure/goog/gears/multipartformdata.js +203 -0
- data/closure-library/closure/goog/gears/multipartformdata_test.html +220 -0
- data/closure-library/closure/goog/gears/statustype.js +37 -0
- data/closure-library/closure/goog/gears/urlcapture.js +370 -0
- data/closure-library/closure/goog/gears/urlcapture_test.html +392 -0
- data/closure-library/closure/goog/gears/worker.js +201 -0
- data/closure-library/closure/goog/gears/workerchannel.js +205 -0
- data/closure-library/closure/goog/gears/workerchannel_test.html +207 -0
- data/closure-library/closure/goog/gears/workerpool.js +241 -0
- data/closure-library/closure/goog/gears/workerpool_test.html +203 -0
- data/closure-library/closure/goog/graphics/abstractgraphics.js +439 -0
- data/closure-library/closure/goog/graphics/affinetransform.js +497 -0
- data/closure-library/closure/goog/graphics/affinetransform_test.html +316 -0
- data/closure-library/closure/goog/graphics/canvaselement.js +776 -0
- data/closure-library/closure/goog/graphics/canvasgraphics.js +632 -0
- data/closure-library/closure/goog/graphics/element.js +145 -0
- data/closure-library/closure/goog/graphics/ellipseelement.js +59 -0
- data/closure-library/closure/goog/graphics/ext/coordinates.js +158 -0
- data/closure-library/closure/goog/graphics/ext/coordinates_test.html +74 -0
- data/closure-library/closure/goog/graphics/ext/element.js +970 -0
- data/closure-library/closure/goog/graphics/ext/element_test.html +144 -0
- data/closure-library/closure/goog/graphics/ext/ellipse.js +58 -0
- data/closure-library/closure/goog/graphics/ext/ext.js +29 -0
- data/closure-library/closure/goog/graphics/ext/graphics.js +209 -0
- data/closure-library/closure/goog/graphics/ext/group.js +213 -0
- data/closure-library/closure/goog/graphics/ext/image.js +62 -0
- data/closure-library/closure/goog/graphics/ext/path.js +140 -0
- data/closure-library/closure/goog/graphics/ext/path_test.html +46 -0
- data/closure-library/closure/goog/graphics/ext/rectangle.js +53 -0
- data/closure-library/closure/goog/graphics/ext/shape.js +144 -0
- data/closure-library/closure/goog/graphics/ext/strokeandfillelement.js +69 -0
- data/closure-library/closure/goog/graphics/fill.js +29 -0
- data/closure-library/closure/goog/graphics/font.js +59 -0
- data/closure-library/closure/goog/graphics/graphics.js +124 -0
- data/closure-library/closure/goog/graphics/groupelement.js +54 -0
- data/closure-library/closure/goog/graphics/imageelement.js +67 -0
- data/closure-library/closure/goog/graphics/lineargradient.js +131 -0
- data/closure-library/closure/goog/graphics/path.js +508 -0
- data/closure-library/closure/goog/graphics/path_test.html +359 -0
- data/closure-library/closure/goog/graphics/pathelement.js +50 -0
- data/closure-library/closure/goog/graphics/paths.js +86 -0
- data/closure-library/closure/goog/graphics/paths_test.html +97 -0
- data/closure-library/closure/goog/graphics/rectelement.js +59 -0
- data/closure-library/closure/goog/graphics/solidfill.js +70 -0
- data/closure-library/closure/goog/graphics/stroke.js +63 -0
- data/closure-library/closure/goog/graphics/strokeandfillelement.js +110 -0
- data/closure-library/closure/goog/graphics/svgelement.js +262 -0
- data/closure-library/closure/goog/graphics/svggraphics.js +813 -0
- data/closure-library/closure/goog/graphics/textelement.js +51 -0
- data/closure-library/closure/goog/graphics/vmlelement.js +380 -0
- data/closure-library/closure/goog/graphics/vmlgraphics.js +863 -0
- data/closure-library/closure/goog/history/event.js +54 -0
- data/closure-library/closure/goog/history/eventtype.js +30 -0
- data/closure-library/closure/goog/history/history.js +979 -0
- data/closure-library/closure/goog/history/html5history.js +303 -0
- data/closure-library/closure/goog/history/html5history_test.html +163 -0
- data/closure-library/closure/goog/i18n/bidi.js +772 -0
- data/closure-library/closure/goog/i18n/bidi_test.html +414 -0
- data/closure-library/closure/goog/i18n/bidiformatter.js +488 -0
- data/closure-library/closure/goog/i18n/bidiformatter_test.html +343 -0
- data/closure-library/closure/goog/i18n/charlistdecompressor.js +157 -0
- data/closure-library/closure/goog/i18n/charlistdecompressor_test.html +65 -0
- data/closure-library/closure/goog/i18n/charpickerdata.js +3185 -0
- data/closure-library/closure/goog/i18n/currency.js +385 -0
- data/closure-library/closure/goog/i18n/currency_test.html +202 -0
- data/closure-library/closure/goog/i18n/currencycodemap.js +210 -0
- data/closure-library/closure/goog/i18n/datetimeformat.js +636 -0
- data/closure-library/closure/goog/i18n/datetimeformat_test.html +436 -0
- data/closure-library/closure/goog/i18n/datetimeparse.js +1111 -0
- data/closure-library/closure/goog/i18n/datetimeparse_test.html +796 -0
- data/closure-library/closure/goog/i18n/datetimepatterns.js +1586 -0
- data/closure-library/closure/goog/i18n/datetimepatternsext.js +7386 -0
- data/closure-library/closure/goog/i18n/datetimesymbols.js +3350 -0
- data/closure-library/closure/goog/i18n/datetimesymbolsext.js +12938 -0
- data/closure-library/closure/goog/i18n/graphemebreak.js +181 -0
- data/closure-library/closure/goog/i18n/graphemebreak_test.html +72 -0
- data/closure-library/closure/goog/i18n/messageformat.js +553 -0
- data/closure-library/closure/goog/i18n/messageformat_test.html +323 -0
- data/closure-library/closure/goog/i18n/mime.js +100 -0
- data/closure-library/closure/goog/i18n/mime_test.html +51 -0
- data/closure-library/closure/goog/i18n/numberformat.js +763 -0
- data/closure-library/closure/goog/i18n/numberformat_test.html +605 -0
- data/closure-library/closure/goog/i18n/numberformatsymbols.js +10358 -0
- data/closure-library/closure/goog/i18n/pluralrules.js +695 -0
- data/closure-library/closure/goog/i18n/timezone.js +341 -0
- data/closure-library/closure/goog/i18n/timezone_test.html +163 -0
- data/closure-library/closure/goog/i18n/uchar.js +1160 -0
- data/closure-library/closure/goog/i18n/uchar_test.html +72 -0
- data/closure-library/closure/goog/images/blank.gif +0 -0
- data/closure-library/closure/goog/images/bubble_close.jpg +0 -0
- data/closure-library/closure/goog/images/bubble_left.gif +0 -0
- data/closure-library/closure/goog/images/bubble_right.gif +0 -0
- data/closure-library/closure/goog/images/button-bg.gif +0 -0
- data/closure-library/closure/goog/images/check-outline.gif +0 -0
- data/closure-library/closure/goog/images/check-sprite.gif +0 -0
- data/closure-library/closure/goog/images/check.gif +0 -0
- data/closure-library/closure/goog/images/close_box.gif +0 -0
- data/closure-library/closure/goog/images/color-swatch-tick.gif +0 -0
- data/closure-library/closure/goog/images/dialog_close_box.gif +0 -0
- data/closure-library/closure/goog/images/dimension-highlighted.png +0 -0
- data/closure-library/closure/goog/images/dimension-unhighlighted.png +0 -0
- data/closure-library/closure/goog/images/dropdn.gif +0 -0
- data/closure-library/closure/goog/images/dropdn_disabled.gif +0 -0
- data/closure-library/closure/goog/images/dropdown.gif +0 -0
- data/closure-library/closure/goog/images/gears_bluedot.gif +0 -0
- data/closure-library/closure/goog/images/gears_offline.gif +0 -0
- data/closure-library/closure/goog/images/gears_online.gif +0 -0
- data/closure-library/closure/goog/images/gears_paused.gif +0 -0
- data/closure-library/closure/goog/images/gears_syncing.gif +0 -0
- data/closure-library/closure/goog/images/hsv-sprite-sm.gif +0 -0
- data/closure-library/closure/goog/images/hsv-sprite-sm.png +0 -0
- data/closure-library/closure/goog/images/hsv-sprite.gif +0 -0
- data/closure-library/closure/goog/images/hsv-sprite.png +0 -0
- data/closure-library/closure/goog/images/hsva-sprite-sm.gif +0 -0
- data/closure-library/closure/goog/images/hsva-sprite-sm.png +0 -0
- data/closure-library/closure/goog/images/hsva-sprite.gif +0 -0
- data/closure-library/closure/goog/images/hsva-sprite.png +0 -0
- data/closure-library/closure/goog/images/left_anchor_bubble_bot.gif +0 -0
- data/closure-library/closure/goog/images/left_anchor_bubble_top.gif +0 -0
- data/closure-library/closure/goog/images/menu-arrows.gif +0 -0
- data/closure-library/closure/goog/images/minus.png +0 -0
- data/closure-library/closure/goog/images/no_anchor_bubble_bot.gif +0 -0
- data/closure-library/closure/goog/images/no_anchor_bubble_top.gif +0 -0
- data/closure-library/closure/goog/images/offlineicons.png +0 -0
- data/closure-library/closure/goog/images/plus.png +0 -0
- data/closure-library/closure/goog/images/ratingstars.gif +0 -0
- data/closure-library/closure/goog/images/right_anchor_bubble_bot.gif +0 -0
- data/closure-library/closure/goog/images/right_anchor_bubble_top.gif +0 -0
- data/closure-library/closure/goog/images/toolbar-bg.png +0 -0
- data/closure-library/closure/goog/images/toolbar-separator.gif +0 -0
- data/closure-library/closure/goog/images/toolbar_icons.gif +0 -0
- data/closure-library/closure/goog/images/tree/I.png +0 -0
- data/closure-library/closure/goog/images/tree/cleardot.gif +0 -0
- data/closure-library/closure/goog/images/tree/tree.gif +0 -0
- data/closure-library/closure/goog/images/tree/tree.png +0 -0
- data/closure-library/closure/goog/images/ui_controls.jpg +0 -0
- data/closure-library/closure/goog/iter/iter.js +627 -0
- data/closure-library/closure/goog/iter/iter_test.html +443 -0
- data/closure-library/closure/goog/json/json.js +302 -0
- data/closure-library/closure/goog/json/json_test.html +501 -0
- data/closure-library/closure/goog/locale/countries.js +288 -0
- data/closure-library/closure/goog/locale/countrylanguagenames_test.html +233 -0
- data/closure-library/closure/goog/locale/defaultlocalenameconstants.js +847 -0
- data/closure-library/closure/goog/locale/genericfontnames.js +73 -0
- data/closure-library/closure/goog/locale/genericfontnames_test.html +97 -0
- data/closure-library/closure/goog/locale/genericfontnamesdata.js +328 -0
- data/closure-library/closure/goog/locale/locale.js +397 -0
- data/closure-library/closure/goog/locale/nativenameconstants.js +1354 -0
- data/closure-library/closure/goog/locale/scriptToLanguages.js +482 -0
- data/closure-library/closure/goog/locale/timezonedetection.js +117 -0
- data/closure-library/closure/goog/locale/timezonedetection_test.html +130 -0
- data/closure-library/closure/goog/locale/timezonefingerprint.js +250 -0
- data/closure-library/closure/goog/locale/timezonelist.js +129 -0
- data/closure-library/closure/goog/locale/timezonelist_test.html +165 -0
- data/closure-library/closure/goog/math/bezier.js +244 -0
- data/closure-library/closure/goog/math/bezier_test.html +70 -0
- data/closure-library/closure/goog/math/box.js +236 -0
- data/closure-library/closure/goog/math/box_test.html +139 -0
- data/closure-library/closure/goog/math/coordinate.js +136 -0
- data/closure-library/closure/goog/math/coordinate3.js +168 -0
- data/closure-library/closure/goog/math/coordinate3_test.html +208 -0
- data/closure-library/closure/goog/math/coordinate_test.html +92 -0
- data/closure-library/closure/goog/math/integer.js +736 -0
- data/closure-library/closure/goog/math/integer_test.html +1653 -0
- data/closure-library/closure/goog/math/line.js +177 -0
- data/closure-library/closure/goog/math/line_test.html +62 -0
- data/closure-library/closure/goog/math/long.js +801 -0
- data/closure-library/closure/goog/math/long_test.html +1571 -0
- data/closure-library/closure/goog/math/math.js +355 -0
- data/closure-library/closure/goog/math/math_test.html +254 -0
- data/closure-library/closure/goog/math/matrix.js +669 -0
- data/closure-library/closure/goog/math/matrix_test.html +427 -0
- data/closure-library/closure/goog/math/range.js +146 -0
- data/closure-library/closure/goog/math/range_test.html +103 -0
- data/closure-library/closure/goog/math/rangeset.js +368 -0
- data/closure-library/closure/goog/math/rangeset_test.html +619 -0
- data/closure-library/closure/goog/math/rect.js +340 -0
- data/closure-library/closure/goog/math/rect_test.html +315 -0
- data/closure-library/closure/goog/math/size.js +201 -0
- data/closure-library/closure/goog/math/size_test.html +174 -0
- data/closure-library/closure/goog/math/vec2.js +255 -0
- data/closure-library/closure/goog/math/vec2_test.html +203 -0
- data/closure-library/closure/goog/math/vec3.js +327 -0
- data/closure-library/closure/goog/math/vec3_test.html +231 -0
- data/closure-library/closure/goog/memoize/memoize.js +98 -0
- data/closure-library/closure/goog/memoize/memoize_test.html +157 -0
- data/closure-library/closure/goog/messaging/abstractchannel.js +209 -0
- data/closure-library/closure/goog/messaging/abstractchannel_test.html +90 -0
- data/closure-library/closure/goog/messaging/bufferedchannel.js +277 -0
- data/closure-library/closure/goog/messaging/bufferedchannel_test.html +205 -0
- data/closure-library/closure/goog/messaging/deferredchannel.js +79 -0
- data/closure-library/closure/goog/messaging/deferredchannel_test.html +107 -0
- data/closure-library/closure/goog/messaging/loggerclient.js +131 -0
- data/closure-library/closure/goog/messaging/loggerclient_test.html +102 -0
- data/closure-library/closure/goog/messaging/loggerserver.js +94 -0
- data/closure-library/closure/goog/messaging/loggerserver_test.html +101 -0
- data/closure-library/closure/goog/messaging/messagechannel.js +115 -0
- data/closure-library/closure/goog/messaging/messaging.js +34 -0
- data/closure-library/closure/goog/messaging/messaging_test.html +42 -0
- data/closure-library/closure/goog/messaging/multichannel.js +303 -0
- data/closure-library/closure/goog/messaging/multichannel_test.html +122 -0
- data/closure-library/closure/goog/messaging/portchannel.js +341 -0
- data/closure-library/closure/goog/messaging/portchannel_test.html +359 -0
- data/closure-library/closure/goog/messaging/testdata/portchannel_worker.js +37 -0
- data/closure-library/closure/goog/module/abstractmoduleloader.js +46 -0
- data/closure-library/closure/goog/module/basemodule.js +45 -0
- data/closure-library/closure/goog/module/basemoduleloader.js +210 -0
- data/closure-library/closure/goog/module/loader.js +269 -0
- data/closure-library/closure/goog/module/module.js +166 -0
- data/closure-library/closure/goog/module/moduleinfo.js +336 -0
- data/closure-library/closure/goog/module/moduleinfo_test.html +109 -0
- data/closure-library/closure/goog/module/moduleloadcallback.js +84 -0
- data/closure-library/closure/goog/module/moduleloadcallback_test.html +57 -0
- data/closure-library/closure/goog/module/moduleloader.js +250 -0
- data/closure-library/closure/goog/module/moduleloader_test.html +244 -0
- data/closure-library/closure/goog/module/modulemanager.js +1008 -0
- data/closure-library/closure/goog/module/modulemanager_test.html +1240 -0
- data/closure-library/closure/goog/module/testdata/modA_1.js +22 -0
- data/closure-library/closure/goog/module/testdata/modA_2.js +24 -0
- data/closure-library/closure/goog/module/testdata/modB_1.js +24 -0
- data/closure-library/closure/goog/net/browserchannel.js +2441 -0
- data/closure-library/closure/goog/net/browserchannel_test.html +1176 -0
- data/closure-library/closure/goog/net/browsertestchannel.js +552 -0
- data/closure-library/closure/goog/net/bulkloader.js +174 -0
- data/closure-library/closure/goog/net/bulkloader_test.html +232 -0
- data/closure-library/closure/goog/net/bulkloaderhelper.js +129 -0
- data/closure-library/closure/goog/net/channeldebug.js +288 -0
- data/closure-library/closure/goog/net/channelrequest.js +1125 -0
- data/closure-library/closure/goog/net/channelrequest_test.html +158 -0
- data/closure-library/closure/goog/net/cookies.js +401 -0
- data/closure-library/closure/goog/net/cookies_test.html +255 -0
- data/closure-library/closure/goog/net/crossdomainrpc.js +848 -0
- data/closure-library/closure/goog/net/crossdomainrpc_test.gif +0 -0
- data/closure-library/closure/goog/net/crossdomainrpc_test.html +120 -0
- data/closure-library/closure/goog/net/crossdomainrpc_test_response.html +59 -0
- data/closure-library/closure/goog/net/errorcode.js +130 -0
- data/closure-library/closure/goog/net/eventtype.js +37 -0
- data/closure-library/closure/goog/net/iframe_xhr_test.html +142 -0
- data/closure-library/closure/goog/net/iframe_xhr_test_response.html +17 -0
- data/closure-library/closure/goog/net/iframeio.js +1342 -0
- data/closure-library/closure/goog/net/iframeio_different_base_test.data +2 -0
- data/closure-library/closure/goog/net/iframeio_different_base_test.html +42 -0
- data/closure-library/closure/goog/net/iframeio_test.html +368 -0
- data/closure-library/closure/goog/net/iframeloadmonitor.js +199 -0
- data/closure-library/closure/goog/net/iframeloadmonitor_test.html +113 -0
- data/closure-library/closure/goog/net/iframeloadmonitor_test_frame.html +12 -0
- data/closure-library/closure/goog/net/iframeloadmonitor_test_frame2.html +12 -0
- data/closure-library/closure/goog/net/iframeloadmonitor_test_frame3.html +12 -0
- data/closure-library/closure/goog/net/imageloader.js +237 -0
- data/closure-library/closure/goog/net/imageloader_test.html +200 -0
- data/closure-library/closure/goog/net/imageloader_testimg1.gif +0 -0
- data/closure-library/closure/goog/net/imageloader_testimg2.gif +0 -0
- data/closure-library/closure/goog/net/imageloader_testimg3.gif +0 -0
- data/closure-library/closure/goog/net/jsonp.js +379 -0
- data/closure-library/closure/goog/net/jsonp_test.html +328 -0
- data/closure-library/closure/goog/net/mockiframeio.js +318 -0
- data/closure-library/closure/goog/net/mockxhrlite.js +34 -0
- data/closure-library/closure/goog/net/mockxhrlite_test.html +109 -0
- data/closure-library/closure/goog/net/multiiframeloadmonitor.js +116 -0
- data/closure-library/closure/goog/net/multiiframeloadmonitor_test.html +172 -0
- data/closure-library/closure/goog/net/networktester.js +383 -0
- data/closure-library/closure/goog/net/networktester_test.html +227 -0
- data/closure-library/closure/goog/net/tmpnetwork.js +168 -0
- data/closure-library/closure/goog/net/wrapperxmlhttpfactory.js +68 -0
- data/closure-library/closure/goog/net/xhrio.js +1093 -0
- data/closure-library/closure/goog/net/xhrio_test.html +603 -0
- data/closure-library/closure/goog/net/xhriopool.js +87 -0
- data/closure-library/closure/goog/net/xhrlite.js +119 -0
- data/closure-library/closure/goog/net/xhrlite_test.html +156 -0
- data/closure-library/closure/goog/net/xhrlitepool.js +37 -0
- data/closure-library/closure/goog/net/xhrmanager.js +763 -0
- data/closure-library/closure/goog/net/xhrmonitor.js +254 -0
- data/closure-library/closure/goog/net/xhrmonitor_test.html +199 -0
- data/closure-library/closure/goog/net/xmlhttp.js +215 -0
- data/closure-library/closure/goog/net/xmlhttpfactory.js +64 -0
- data/closure-library/closure/goog/net/xpc/crosspagechannel.js +624 -0
- data/closure-library/closure/goog/net/xpc/crosspagechannel_test.html +422 -0
- data/closure-library/closure/goog/net/xpc/frameelementmethodtransport.js +251 -0
- data/closure-library/closure/goog/net/xpc/iframepollingtransport.js +822 -0
- data/closure-library/closure/goog/net/xpc/iframerelaytransport.js +288 -0
- data/closure-library/closure/goog/net/xpc/nativemessagingtransport.js +280 -0
- data/closure-library/closure/goog/net/xpc/nativemessagingtransport_test.html +164 -0
- data/closure-library/closure/goog/net/xpc/nixtransport.js +454 -0
- data/closure-library/closure/goog/net/xpc/relay.js +72 -0
- data/closure-library/closure/goog/net/xpc/testdata/inner_peer.html +106 -0
- data/closure-library/closure/goog/net/xpc/transport.js +104 -0
- data/closure-library/closure/goog/net/xpc/xpc.js +238 -0
- data/closure-library/closure/goog/object/object.js +553 -0
- data/closure-library/closure/goog/object/object_test.html +376 -0
- data/closure-library/closure/goog/positioning/absoluteposition.js +73 -0
- data/closure-library/closure/goog/positioning/abstractposition.js +47 -0
- data/closure-library/closure/goog/positioning/anchoredposition.js +78 -0
- data/closure-library/closure/goog/positioning/anchoredviewportposition.js +126 -0
- data/closure-library/closure/goog/positioning/anchoredviewportposition_test.html +117 -0
- data/closure-library/closure/goog/positioning/anchoredviewportposition_test_iframe.html +35 -0
- data/closure-library/closure/goog/positioning/clientposition.js +75 -0
- data/closure-library/closure/goog/positioning/menuanchoredposition.js +97 -0
- data/closure-library/closure/goog/positioning/positioning.js +476 -0
- data/closure-library/closure/goog/positioning/positioning_test.html +877 -0
- data/closure-library/closure/goog/positioning/positioning_test_iframe1.html +16 -0
- data/closure-library/closure/goog/positioning/positioning_test_iframe2.html +13 -0
- data/closure-library/closure/goog/positioning/positioning_test_quirk.html +9 -0
- data/closure-library/closure/goog/positioning/positioning_test_standard.html +13 -0
- data/closure-library/closure/goog/positioning/viewportclientposition.js +102 -0
- data/closure-library/closure/goog/positioning/viewportclientposition_test.html +172 -0
- data/closure-library/closure/goog/positioning/viewportposition.js +63 -0
- data/closure-library/closure/goog/proto/proto.js +43 -0
- data/closure-library/closure/goog/proto/serializer.js +68 -0
- data/closure-library/closure/goog/proto/serializer_test.html +43 -0
- data/closure-library/closure/goog/proto2/descriptor.js +198 -0
- data/closure-library/closure/goog/proto2/descriptor_test.html +60 -0
- data/closure-library/closure/goog/proto2/fielddescriptor.js +288 -0
- data/closure-library/closure/goog/proto2/fielddescriptor_test.html +124 -0
- data/closure-library/closure/goog/proto2/lazydeserializer.js +69 -0
- data/closure-library/closure/goog/proto2/message.js +726 -0
- data/closure-library/closure/goog/proto2/message_test.html +356 -0
- data/closure-library/closure/goog/proto2/objectserializer.js +159 -0
- data/closure-library/closure/goog/proto2/objectserializer_test.html +423 -0
- data/closure-library/closure/goog/proto2/package_test.pb.js +164 -0
- data/closure-library/closure/goog/proto2/pbliteserializer.js +150 -0
- data/closure-library/closure/goog/proto2/pbliteserializer_test.html +267 -0
- data/closure-library/closure/goog/proto2/proto_test.html +693 -0
- data/closure-library/closure/goog/proto2/serializer.js +148 -0
- data/closure-library/closure/goog/proto2/test.pb.js +2820 -0
- data/closure-library/closure/goog/proto2/util.js +54 -0
- data/closure-library/closure/goog/pubsub/pubsub.js +326 -0
- data/closure-library/closure/goog/pubsub/pubsub_test.html +635 -0
- data/closure-library/closure/goog/reflect/reflect.js +50 -0
- data/closure-library/closure/goog/spell/spellcheck.js +474 -0
- data/closure-library/closure/goog/spell/spellcheck_test.html +112 -0
- data/closure-library/closure/goog/string/path.js +100 -0
- data/closure-library/closure/goog/string/path_test.html +59 -0
- data/closure-library/closure/goog/string/string.js +1207 -0
- data/closure-library/closure/goog/string/string_test.html +877 -0
- data/closure-library/closure/goog/string/stringbuffer.js +167 -0
- data/closure-library/closure/goog/string/stringbuffer_test.html +101 -0
- data/closure-library/closure/goog/string/stringformat.js +247 -0
- data/closure-library/closure/goog/string/stringformat_test.html +211 -0
- data/closure-library/closure/goog/structs/avltree.js +769 -0
- data/closure-library/closure/goog/structs/avltree_test.html +241 -0
- data/closure-library/closure/goog/structs/circularbuffer.js +219 -0
- data/closure-library/closure/goog/structs/circularbuffer_test.html +105 -0
- data/closure-library/closure/goog/structs/heap.js +332 -0
- data/closure-library/closure/goog/structs/heap_test.html +220 -0
- data/closure-library/closure/goog/structs/inversionmap.js +159 -0
- data/closure-library/closure/goog/structs/inversionmap_test.html +157 -0
- data/closure-library/closure/goog/structs/linkedmap.js +472 -0
- data/closure-library/closure/goog/structs/linkedmap_test.html +300 -0
- data/closure-library/closure/goog/structs/map.js +446 -0
- data/closure-library/closure/goog/structs/map_test.html +430 -0
- data/closure-library/closure/goog/structs/node.js +74 -0
- data/closure-library/closure/goog/structs/pool.js +344 -0
- data/closure-library/closure/goog/structs/pool_test.html +265 -0
- data/closure-library/closure/goog/structs/prioritypool.js +147 -0
- data/closure-library/closure/goog/structs/prioritypool_test.html +478 -0
- data/closure-library/closure/goog/structs/priorityqueue.js +64 -0
- data/closure-library/closure/goog/structs/priorityqueue_test.html +179 -0
- data/closure-library/closure/goog/structs/quadtree.js +571 -0
- data/closure-library/closure/goog/structs/quadtree_test.html +179 -0
- data/closure-library/closure/goog/structs/queue.js +157 -0
- data/closure-library/closure/goog/structs/queue_test.html +140 -0
- data/closure-library/closure/goog/structs/set.js +251 -0
- data/closure-library/closure/goog/structs/set_test.html +551 -0
- data/closure-library/closure/goog/structs/simplepool.js +203 -0
- data/closure-library/closure/goog/structs/stringset.js +404 -0
- data/closure-library/closure/goog/structs/stringset_test.html +251 -0
- data/closure-library/closure/goog/structs/structs.js +341 -0
- data/closure-library/closure/goog/structs/structs_test.html +1050 -0
- data/closure-library/closure/goog/structs/treenode.js +312 -0
- data/closure-library/closure/goog/structs/treenode_test.html +285 -0
- data/closure-library/closure/goog/structs/trie.js +368 -0
- data/closure-library/closure/goog/structs/trie_test.html +378 -0
- data/closure-library/closure/goog/style/cursor.js +125 -0
- data/closure-library/closure/goog/style/cursor_test.html +131 -0
- data/closure-library/closure/goog/style/style.js +1804 -0
- data/closure-library/closure/goog/style/style_quirks_test.html +1928 -0
- data/closure-library/closure/goog/style/style_test.html +2073 -0
- data/closure-library/closure/goog/style/style_test_iframe_quirk.html +29 -0
- data/closure-library/closure/goog/style/style_test_iframe_standard.html +30 -0
- data/closure-library/closure/goog/style/style_test_quirk.html +9 -0
- data/closure-library/closure/goog/style/style_test_standard.html +11 -0
- data/closure-library/closure/goog/testing/asserts.js +970 -0
- data/closure-library/closure/goog/testing/asserts_test.html +966 -0
- data/closure-library/closure/goog/testing/async/mockcontrol.js +174 -0
- data/closure-library/closure/goog/testing/async/mockcontrol_test.html +224 -0
- data/closure-library/closure/goog/testing/asynctestcase.js +812 -0
- data/closure-library/closure/goog/testing/asynctestcase_async_test.html +102 -0
- data/closure-library/closure/goog/testing/asynctestcase_noasync_test.html +98 -0
- data/closure-library/closure/goog/testing/benchmark.js +87 -0
- data/closure-library/closure/goog/testing/benchmarks/jsbinarysizebutton.js +64 -0
- data/closure-library/closure/goog/testing/benchmarks/jsbinarysizebutton_test.html +58 -0
- data/closure-library/closure/goog/testing/benchmarks/jsbinarysizetoolbar.js +66 -0
- data/closure-library/closure/goog/testing/benchmarks/jsbinarysizetoolbar_test.html +49 -0
- data/closure-library/closure/goog/testing/continuationtestcase.js +682 -0
- data/closure-library/closure/goog/testing/continuationtestcase_test.html +349 -0
- data/closure-library/closure/goog/testing/deferredtestcase.js +157 -0
- data/closure-library/closure/goog/testing/deferredtestcase_test.html +152 -0
- data/closure-library/closure/goog/testing/dom.js +596 -0
- data/closure-library/closure/goog/testing/dom_test.html +438 -0
- data/closure-library/closure/goog/testing/editor/dom.js +293 -0
- data/closure-library/closure/goog/testing/editor/dom_test.html +295 -0
- data/closure-library/closure/goog/testing/editor/fieldmock.js +90 -0
- data/closure-library/closure/goog/testing/editor/testhelper.js +168 -0
- data/closure-library/closure/goog/testing/editor/testhelper_test.html +176 -0
- data/closure-library/closure/goog/testing/events/eventobserver.js +85 -0
- data/closure-library/closure/goog/testing/events/eventobserver_test.html +70 -0
- data/closure-library/closure/goog/testing/events/events.js +540 -0
- data/closure-library/closure/goog/testing/events/events_test.html +434 -0
- data/closure-library/closure/goog/testing/events/matchers.js +41 -0
- data/closure-library/closure/goog/testing/events/matchers_test.html +40 -0
- data/closure-library/closure/goog/testing/expectedfailures.js +236 -0
- data/closure-library/closure/goog/testing/expectedfailures_test.html +122 -0
- data/closure-library/closure/goog/testing/fs/blob.js +74 -0
- data/closure-library/closure/goog/testing/fs/blob_test.html +53 -0
- data/closure-library/closure/goog/testing/fs/directoryentry_test.html +185 -0
- data/closure-library/closure/goog/testing/fs/entry.js +511 -0
- data/closure-library/closure/goog/testing/fs/entry_test.html +153 -0
- data/closure-library/closure/goog/testing/fs/file.js +51 -0
- data/closure-library/closure/goog/testing/fs/fileentry_test.html +54 -0
- data/closure-library/closure/goog/testing/fs/filesystem.js +64 -0
- data/closure-library/closure/goog/testing/fs/filewriter.js +314 -0
- data/closure-library/closure/goog/testing/fs/filewriter_test.html +248 -0
- data/closure-library/closure/goog/testing/fs/fs.js +146 -0
- data/closure-library/closure/goog/testing/fs/fs_test.html +54 -0
- data/closure-library/closure/goog/testing/fs/integration_test.html +219 -0
- data/closure-library/closure/goog/testing/functionmock.js +157 -0
- data/closure-library/closure/goog/testing/functionmock_test.html +357 -0
- data/closure-library/closure/goog/testing/graphics.js +64 -0
- data/closure-library/closure/goog/testing/jsunit.js +144 -0
- data/closure-library/closure/goog/testing/loosemock.js +240 -0
- data/closure-library/closure/goog/testing/loosemock_test.html +343 -0
- data/closure-library/closure/goog/testing/messaging/mockmessagechannel.js +77 -0
- data/closure-library/closure/goog/testing/messaging/mockmessageevent.js +100 -0
- data/closure-library/closure/goog/testing/mock.js +556 -0
- data/closure-library/closure/goog/testing/mock_test.html +208 -0
- data/closure-library/closure/goog/testing/mockclassfactory.js +580 -0
- data/closure-library/closure/goog/testing/mockclassfactory_test.html +241 -0
- data/closure-library/closure/goog/testing/mockclock.js +395 -0
- data/closure-library/closure/goog/testing/mockclock_test.html +413 -0
- data/closure-library/closure/goog/testing/mockcontrol.js +210 -0
- data/closure-library/closure/goog/testing/mockcontrol_test.html +127 -0
- data/closure-library/closure/goog/testing/mockinterface.js +45 -0
- data/closure-library/closure/goog/testing/mockmatchers.js +395 -0
- data/closure-library/closure/goog/testing/mockmatchers_test.html +388 -0
- data/closure-library/closure/goog/testing/mockrandom.js +128 -0
- data/closure-library/closure/goog/testing/mockrandom_test.html +56 -0
- data/closure-library/closure/goog/testing/mockrange.js +65 -0
- data/closure-library/closure/goog/testing/mockrange_test.html +41 -0
- data/closure-library/closure/goog/testing/mockuseragent.js +143 -0
- data/closure-library/closure/goog/testing/mockuseragent_test.html +59 -0
- data/closure-library/closure/goog/testing/multitestrunner.js +1442 -0
- data/closure-library/closure/goog/testing/net/xhrio.js +595 -0
- data/closure-library/closure/goog/testing/net/xhrio_test.html +321 -0
- data/closure-library/closure/goog/testing/objectpropertystring.js +67 -0
- data/closure-library/closure/goog/testing/performancetable.css +46 -0
- data/closure-library/closure/goog/testing/performancetable.js +162 -0
- data/closure-library/closure/goog/testing/performancetimer.js +166 -0
- data/closure-library/closure/goog/testing/performancetimer_test.html +107 -0
- data/closure-library/closure/goog/testing/propertyreplacer.js +243 -0
- data/closure-library/closure/goog/testing/propertyreplacer_test.html +368 -0
- data/closure-library/closure/goog/testing/pseudorandom.js +162 -0
- data/closure-library/closure/goog/testing/pseudorandom_test.html +98 -0
- data/closure-library/closure/goog/testing/recordfunction.js +194 -0
- data/closure-library/closure/goog/testing/recordfunction_test.html +147 -0
- data/closure-library/closure/goog/testing/singleton.js +82 -0
- data/closure-library/closure/goog/testing/singleton_test.html +39 -0
- data/closure-library/closure/goog/testing/stacktrace.js +470 -0
- data/closure-library/closure/goog/testing/stacktrace_test.html +229 -0
- data/closure-library/closure/goog/testing/strictmock.js +124 -0
- data/closure-library/closure/goog/testing/strictmock_test.html +368 -0
- data/closure-library/closure/goog/testing/style/layoutasserts.js +368 -0
- data/closure-library/closure/goog/testing/style/layoutasserts_test.html +269 -0
- data/closure-library/closure/goog/testing/testcase.js +1053 -0
- data/closure-library/closure/goog/testing/testqueue.js +66 -0
- data/closure-library/closure/goog/testing/testrunner.js +391 -0
- data/closure-library/closure/goog/testing/ui/rendererasserts.js +50 -0
- data/closure-library/closure/goog/testing/ui/rendererasserts_test.html +51 -0
- data/closure-library/closure/goog/testing/ui/rendererharness.js +175 -0
- data/closure-library/closure/goog/testing/ui/style.js +137 -0
- data/closure-library/closure/goog/testing/ui/style_reference.html +27 -0
- data/closure-library/closure/goog/testing/ui/style_test.html +130 -0
- data/closure-library/closure/goog/timer/timer.js +285 -0
- data/closure-library/closure/goog/timer/timer_test.html +118 -0
- data/closure-library/closure/goog/tweak/entries.js +990 -0
- data/closure-library/closure/goog/tweak/entries_test.html +94 -0
- data/closure-library/closure/goog/tweak/registry.js +310 -0
- data/closure-library/closure/goog/tweak/registry_test.html +144 -0
- data/closure-library/closure/goog/tweak/testhelpers.js +111 -0
- data/closure-library/closure/goog/tweak/tweak.js +318 -0
- data/closure-library/closure/goog/tweak/tweakui.js +817 -0
- data/closure-library/closure/goog/tweak/tweakui_test.html +280 -0
- data/closure-library/closure/goog/ui/abstractspellchecker.js +1069 -0
- data/closure-library/closure/goog/ui/activitymonitor.js +286 -0
- data/closure-library/closure/goog/ui/activitymonitor_test.html +44 -0
- data/closure-library/closure/goog/ui/advancedtooltip.js +369 -0
- data/closure-library/closure/goog/ui/advancedtooltip_test.html +274 -0
- data/closure-library/closure/goog/ui/animatedzippy.js +190 -0
- data/closure-library/closure/goog/ui/attachablemenu.js +464 -0
- data/closure-library/closure/goog/ui/autocomplete/arraymatcher.js +156 -0
- data/closure-library/closure/goog/ui/autocomplete/arraymatcher_test.html +130 -0
- data/closure-library/closure/goog/ui/autocomplete/autocomplete.js +627 -0
- data/closure-library/closure/goog/ui/autocomplete/autocomplete_test.html +537 -0
- data/closure-library/closure/goog/ui/autocomplete/basic.js +53 -0
- data/closure-library/closure/goog/ui/autocomplete/basic_test.html +204 -0
- data/closure-library/closure/goog/ui/autocomplete/inputhandler.js +1209 -0
- data/closure-library/closure/goog/ui/autocomplete/inputhandler_test.html +555 -0
- data/closure-library/closure/goog/ui/autocomplete/remote.js +117 -0
- data/closure-library/closure/goog/ui/autocomplete/remotearraymatcher.js +273 -0
- data/closure-library/closure/goog/ui/autocomplete/remotearraymatcher_test.html +73 -0
- data/closure-library/closure/goog/ui/autocomplete/renderer.js +852 -0
- data/closure-library/closure/goog/ui/autocomplete/renderer_test.html +386 -0
- data/closure-library/closure/goog/ui/autocomplete/richinputhandler.js +59 -0
- data/closure-library/closure/goog/ui/autocomplete/richremote.js +108 -0
- data/closure-library/closure/goog/ui/autocomplete/richremotearraymatcher.js +126 -0
- data/closure-library/closure/goog/ui/basicmenu.js +930 -0
- data/closure-library/closure/goog/ui/bidiinput.js +164 -0
- data/closure-library/closure/goog/ui/bubble.js +475 -0
- data/closure-library/closure/goog/ui/button.js +208 -0
- data/closure-library/closure/goog/ui/button_test.html +257 -0
- data/closure-library/closure/goog/ui/buttonrenderer.js +205 -0
- data/closure-library/closure/goog/ui/buttonrenderer_test.html +190 -0
- data/closure-library/closure/goog/ui/buttonside.js +40 -0
- data/closure-library/closure/goog/ui/cccbutton.js +281 -0
- data/closure-library/closure/goog/ui/charcounter.js +200 -0
- data/closure-library/closure/goog/ui/charpicker.js +807 -0
- data/closure-library/closure/goog/ui/checkbox.js +303 -0
- data/closure-library/closure/goog/ui/checkbox_test.html +224 -0
- data/closure-library/closure/goog/ui/checkboxmenuitem.js +53 -0
- data/closure-library/closure/goog/ui/colorbutton.js +58 -0
- data/closure-library/closure/goog/ui/colorbutton_test.html +70 -0
- data/closure-library/closure/goog/ui/colorbuttonrenderer.js +72 -0
- data/closure-library/closure/goog/ui/colormenubutton.js +213 -0
- data/closure-library/closure/goog/ui/colormenubuttonrenderer.js +144 -0
- data/closure-library/closure/goog/ui/colormenubuttonrenderer_test.html +88 -0
- data/closure-library/closure/goog/ui/colorpalette.js +162 -0
- data/closure-library/closure/goog/ui/colorpalette_test.html +169 -0
- data/closure-library/closure/goog/ui/colorpicker.js +344 -0
- data/closure-library/closure/goog/ui/colorsplitbehavior.js +61 -0
- data/closure-library/closure/goog/ui/combobox.js +894 -0
- data/closure-library/closure/goog/ui/combobox_test.html +208 -0
- data/closure-library/closure/goog/ui/component.js +1187 -0
- data/closure-library/closure/goog/ui/component_test.html +723 -0
- data/closure-library/closure/goog/ui/container.js +1296 -0
- data/closure-library/closure/goog/ui/container_test.html +450 -0
- data/closure-library/closure/goog/ui/containerrenderer.js +370 -0
- data/closure-library/closure/goog/ui/containerrenderer_test.html +227 -0
- data/closure-library/closure/goog/ui/containerscroller.js +221 -0
- data/closure-library/closure/goog/ui/containerscroller_test.html +213 -0
- data/closure-library/closure/goog/ui/control.js +1348 -0
- data/closure-library/closure/goog/ui/control_test.html +2128 -0
- data/closure-library/closure/goog/ui/controlcontent.js +28 -0
- data/closure-library/closure/goog/ui/controlrenderer.js +808 -0
- data/closure-library/closure/goog/ui/controlrenderer_test.html +840 -0
- data/closure-library/closure/goog/ui/cookieeditor.js +182 -0
- data/closure-library/closure/goog/ui/cookieeditor_test.html +102 -0
- data/closure-library/closure/goog/ui/css3buttonrenderer.js +147 -0
- data/closure-library/closure/goog/ui/css3menubuttonrenderer.js +144 -0
- data/closure-library/closure/goog/ui/cssnames.js +28 -0
- data/closure-library/closure/goog/ui/custombutton.js +58 -0
- data/closure-library/closure/goog/ui/custombuttonrenderer.js +254 -0
- data/closure-library/closure/goog/ui/customcolorpalette.js +137 -0
- data/closure-library/closure/goog/ui/customcolorpalette_test.html +60 -0
- data/closure-library/closure/goog/ui/datepicker.js +1339 -0
- data/closure-library/closure/goog/ui/datepicker_test.html +190 -0
- data/closure-library/closure/goog/ui/decorate.js +37 -0
- data/closure-library/closure/goog/ui/decorate_test.html +113 -0
- data/closure-library/closure/goog/ui/deprecatedbutton.js +381 -0
- data/closure-library/closure/goog/ui/dialog.js +1776 -0
- data/closure-library/closure/goog/ui/dialog_test.html +493 -0
- data/closure-library/closure/goog/ui/dimensionpicker.js +289 -0
- data/closure-library/closure/goog/ui/dimensionpicker_test.html +128 -0
- data/closure-library/closure/goog/ui/dimensionpickerrenderer.js +387 -0
- data/closure-library/closure/goog/ui/dragdropdetector.js +642 -0
- data/closure-library/closure/goog/ui/drilldownrow.js +494 -0
- data/closure-library/closure/goog/ui/editor/abstractdialog.js +443 -0
- data/closure-library/closure/goog/ui/editor/abstractdialog_test.html +467 -0
- data/closure-library/closure/goog/ui/editor/bubble.js +520 -0
- data/closure-library/closure/goog/ui/editor/bubble_test.html +264 -0
- data/closure-library/closure/goog/ui/editor/defaulttoolbar.js +1062 -0
- data/closure-library/closure/goog/ui/editor/linkdialog.js +833 -0
- data/closure-library/closure/goog/ui/editor/linkdialog_test.html +449 -0
- data/closure-library/closure/goog/ui/editor/messages.js +115 -0
- data/closure-library/closure/goog/ui/editor/tabpane.js +183 -0
- data/closure-library/closure/goog/ui/editor/toolbarcontroller.js +293 -0
- data/closure-library/closure/goog/ui/editor/toolbarfactory.js +437 -0
- data/closure-library/closure/goog/ui/editor/toolbarfactory_test.html +73 -0
- data/closure-library/closure/goog/ui/emoji/emoji.js +72 -0
- data/closure-library/closure/goog/ui/emoji/emojipalette.js +298 -0
- data/closure-library/closure/goog/ui/emoji/emojipaletterenderer.js +206 -0
- data/closure-library/closure/goog/ui/emoji/emojipicker.js +797 -0
- data/closure-library/closure/goog/ui/emoji/emojipicker_test.html +840 -0
- data/closure-library/closure/goog/ui/emoji/fast_nonprogressive_emojipicker_test.html +256 -0
- data/closure-library/closure/goog/ui/emoji/fast_progressive_emojipicker_test.html +256 -0
- data/closure-library/closure/goog/ui/emoji/popupemojipicker.js +410 -0
- data/closure-library/closure/goog/ui/emoji/popupemojipicker_test.html +80 -0
- data/closure-library/closure/goog/ui/emoji/progressiveemojipaletterenderer.js +97 -0
- data/closure-library/closure/goog/ui/emoji/spriteinfo.js +212 -0
- data/closure-library/closure/goog/ui/emoji/spriteinfo_test.html +51 -0
- data/closure-library/closure/goog/ui/filteredmenu.js +562 -0
- data/closure-library/closure/goog/ui/filteredmenu_test.html +299 -0
- data/closure-library/closure/goog/ui/filterobservingmenuitem.js +97 -0
- data/closure-library/closure/goog/ui/filterobservingmenuitemrenderer.js +60 -0
- data/closure-library/closure/goog/ui/flatbuttonrenderer.js +138 -0
- data/closure-library/closure/goog/ui/flatmenubuttonrenderer.js +199 -0
- data/closure-library/closure/goog/ui/formpost.js +109 -0
- data/closure-library/closure/goog/ui/formpost_test.html +109 -0
- data/closure-library/closure/goog/ui/gauge.js +999 -0
- data/closure-library/closure/goog/ui/gaugetheme.js +169 -0
- data/closure-library/closure/goog/ui/hovercard.js +447 -0
- data/closure-library/closure/goog/ui/hovercard_test.html +343 -0
- data/closure-library/closure/goog/ui/hsvapalette.js +311 -0
- data/closure-library/closure/goog/ui/hsvapalette_test.html +152 -0
- data/closure-library/closure/goog/ui/hsvpalette.js +470 -0
- data/closure-library/closure/goog/ui/hsvpalette_test.html +202 -0
- data/closure-library/closure/goog/ui/idgenerator.js +57 -0
- data/closure-library/closure/goog/ui/idletimer.js +299 -0
- data/closure-library/closure/goog/ui/idletimer_test.html +100 -0
- data/closure-library/closure/goog/ui/iframemask.js +256 -0
- data/closure-library/closure/goog/ui/iframemask_test.html +230 -0
- data/closure-library/closure/goog/ui/imagelessbuttonrenderer.js +204 -0
- data/closure-library/closure/goog/ui/imagelessmenubuttonrenderer.js +202 -0
- data/closure-library/closure/goog/ui/imagelessroundedcorner.js +971 -0
- data/closure-library/closure/goog/ui/inputdatepicker.js +306 -0
- data/closure-library/closure/goog/ui/inputdatepicker_test.html +109 -0
- data/closure-library/closure/goog/ui/itemevent.js +50 -0
- data/closure-library/closure/goog/ui/keyboardshortcuthandler.js +981 -0
- data/closure-library/closure/goog/ui/keyboardshortcuthandler_test.html +671 -0
- data/closure-library/closure/goog/ui/labelinput.js +439 -0
- data/closure-library/closure/goog/ui/linkbuttonrenderer.js +67 -0
- data/closure-library/closure/goog/ui/media/flashobject.js +629 -0
- data/closure-library/closure/goog/ui/media/flashobject_test.html +236 -0
- data/closure-library/closure/goog/ui/media/flickr.js +309 -0
- data/closure-library/closure/goog/ui/media/flickr_test.html +90 -0
- data/closure-library/closure/goog/ui/media/media.js +284 -0
- data/closure-library/closure/goog/ui/media/media_test.html +161 -0
- data/closure-library/closure/goog/ui/media/mediamodel.js +840 -0
- data/closure-library/closure/goog/ui/media/mp3.js +225 -0
- data/closure-library/closure/goog/ui/media/mp3_test.html +78 -0
- data/closure-library/closure/goog/ui/media/photo.js +139 -0
- data/closure-library/closure/goog/ui/media/photo_test.html +62 -0
- data/closure-library/closure/goog/ui/media/picasa.js +317 -0
- data/closure-library/closure/goog/ui/media/picasa_test.html +131 -0
- data/closure-library/closure/goog/ui/media/vimeo.js +264 -0
- data/closure-library/closure/goog/ui/media/vimeo_test.html +79 -0
- data/closure-library/closure/goog/ui/media/youtube.js +328 -0
- data/closure-library/closure/goog/ui/media/youtube_test.html +185 -0
- data/closure-library/closure/goog/ui/menu.js +435 -0
- data/closure-library/closure/goog/ui/menu_test.html +129 -0
- data/closure-library/closure/goog/ui/menubase.js +191 -0
- data/closure-library/closure/goog/ui/menubutton.js +809 -0
- data/closure-library/closure/goog/ui/menubutton_test.html +440 -0
- data/closure-library/closure/goog/ui/menubutton_test_frame.html +41 -0
- data/closure-library/closure/goog/ui/menubuttonrenderer.js +226 -0
- data/closure-library/closure/goog/ui/menubuttonrenderer_test.html +161 -0
- data/closure-library/closure/goog/ui/menuheader.js +62 -0
- data/closure-library/closure/goog/ui/menuheaderrenderer.js +55 -0
- data/closure-library/closure/goog/ui/menuitem.js +154 -0
- data/closure-library/closure/goog/ui/menuitem_test.html +506 -0
- data/closure-library/closure/goog/ui/menuitemrenderer.js +353 -0
- data/closure-library/closure/goog/ui/menuitemrenderer_test.html +190 -0
- data/closure-library/closure/goog/ui/menurenderer.js +118 -0
- data/closure-library/closure/goog/ui/menuseparator.js +51 -0
- data/closure-library/closure/goog/ui/menuseparatorrenderer.js +102 -0
- data/closure-library/closure/goog/ui/mockactivitymonitor.js +54 -0
- data/closure-library/closure/goog/ui/nativebuttonrenderer.js +205 -0
- data/closure-library/closure/goog/ui/nativebuttonrenderer_test.html +213 -0
- data/closure-library/closure/goog/ui/offlineinstalldialog.js +1086 -0
- data/closure-library/closure/goog/ui/offlinestatuscard.js +580 -0
- data/closure-library/closure/goog/ui/offlinestatuscomponent.js +545 -0
- data/closure-library/closure/goog/ui/option.js +67 -0
- data/closure-library/closure/goog/ui/palette.js +528 -0
- data/closure-library/closure/goog/ui/paletterenderer.js +318 -0
- data/closure-library/closure/goog/ui/plaintextspellchecker.js +668 -0
- data/closure-library/closure/goog/ui/plaintextspellchecker_test.html +240 -0
- data/closure-library/closure/goog/ui/popup.js +410 -0
- data/closure-library/closure/goog/ui/popup_test.html +137 -0
- data/closure-library/closure/goog/ui/popupbase.js +721 -0
- data/closure-library/closure/goog/ui/popupbase_test.html +186 -0
- data/closure-library/closure/goog/ui/popupcolorpicker.js +441 -0
- data/closure-library/closure/goog/ui/popupcolorpicker_test.html +71 -0
- data/closure-library/closure/goog/ui/popupdatepicker.js +273 -0
- data/closure-library/closure/goog/ui/popupmenu.js +539 -0
- data/closure-library/closure/goog/ui/popupmenu_test.html +197 -0
- data/closure-library/closure/goog/ui/progressbar.js +390 -0
- data/closure-library/closure/goog/ui/prompt.js +307 -0
- data/closure-library/closure/goog/ui/prompt_test.html +65 -0
- data/closure-library/closure/goog/ui/rangemodel.js +301 -0
- data/closure-library/closure/goog/ui/rangemodel_test.html +270 -0
- data/closure-library/closure/goog/ui/ratings.js +441 -0
- data/closure-library/closure/goog/ui/registry.js +166 -0
- data/closure-library/closure/goog/ui/registry_test.html +236 -0
- data/closure-library/closure/goog/ui/richtextspellchecker.js +600 -0
- data/closure-library/closure/goog/ui/richtextspellchecker_test.html +224 -0
- data/closure-library/closure/goog/ui/roundedcorners.js +694 -0
- data/closure-library/closure/goog/ui/roundedpanel.js +609 -0
- data/closure-library/closure/goog/ui/roundedpanel_test.html +57 -0
- data/closure-library/closure/goog/ui/roundedtabrenderer.js +196 -0
- data/closure-library/closure/goog/ui/scrollfloater.js +394 -0
- data/closure-library/closure/goog/ui/scrollfloater_test.html +46 -0
- data/closure-library/closure/goog/ui/select.js +397 -0
- data/closure-library/closure/goog/ui/select_test.html +152 -0
- data/closure-library/closure/goog/ui/selectionmenubutton.js +277 -0
- data/closure-library/closure/goog/ui/selectionmenubutton_test.html +237 -0
- data/closure-library/closure/goog/ui/selectionmodel.js +291 -0
- data/closure-library/closure/goog/ui/separator.js +74 -0
- data/closure-library/closure/goog/ui/serverchart.js +1791 -0
- data/closure-library/closure/goog/ui/serverchart_test.html +598 -0
- data/closure-library/closure/goog/ui/slider.js +125 -0
- data/closure-library/closure/goog/ui/sliderbase.js +1087 -0
- data/closure-library/closure/goog/ui/sliderbase_test.html +198 -0
- data/closure-library/closure/goog/ui/splitbehavior.js +348 -0
- data/closure-library/closure/goog/ui/splitbehavior_test.html +161 -0
- data/closure-library/closure/goog/ui/splitpane.js +844 -0
- data/closure-library/closure/goog/ui/splitpane_test.html +143 -0
- data/closure-library/closure/goog/ui/style/app/buttonrenderer.js +204 -0
- data/closure-library/closure/goog/ui/style/app/buttonrenderer_test.html +155 -0
- data/closure-library/closure/goog/ui/style/app/menubuttonrenderer.js +227 -0
- data/closure-library/closure/goog/ui/style/app/menubuttonrenderer_test.html +167 -0
- data/closure-library/closure/goog/ui/style/app/primaryactionbuttonrenderer.js +88 -0
- data/closure-library/closure/goog/ui/style/app/primaryactionbuttonrenderer_test.html +76 -0
- data/closure-library/closure/goog/ui/submenu.js +660 -0
- data/closure-library/closure/goog/ui/submenu_test.html +446 -0
- data/closure-library/closure/goog/ui/submenurenderer.js +188 -0
- data/closure-library/closure/goog/ui/tab.js +102 -0
- data/closure-library/closure/goog/ui/tab_test.html +61 -0
- data/closure-library/closure/goog/ui/tabbar.js +393 -0
- data/closure-library/closure/goog/ui/tabbar_test.html +611 -0
- data/closure-library/closure/goog/ui/tabbarrenderer.js +173 -0
- data/closure-library/closure/goog/ui/tabbarrenderer_test.html +137 -0
- data/closure-library/closure/goog/ui/tablesorter.js +304 -0
- data/closure-library/closure/goog/ui/tablesorter_test.html +127 -0
- data/closure-library/closure/goog/ui/tabpane.js +674 -0
- data/closure-library/closure/goog/ui/tabpane_test.html +107 -0
- data/closure-library/closure/goog/ui/tabrenderer.js +152 -0
- data/closure-library/closure/goog/ui/tabrenderer_test.html +132 -0
- data/closure-library/closure/goog/ui/textarea.js +573 -0
- data/closure-library/closure/goog/ui/textarea_test.html +305 -0
- data/closure-library/closure/goog/ui/textarearenderer.js +167 -0
- data/closure-library/closure/goog/ui/togglebutton.js +58 -0
- data/closure-library/closure/goog/ui/toolbar.js +45 -0
- data/closure-library/closure/goog/ui/toolbarbutton.js +54 -0
- data/closure-library/closure/goog/ui/toolbarbuttonrenderer.js +55 -0
- data/closure-library/closure/goog/ui/toolbarcolormenubutton.js +57 -0
- data/closure-library/closure/goog/ui/toolbarcolormenubuttonrenderer.js +95 -0
- data/closure-library/closure/goog/ui/toolbarcolormenubuttonrenderer_test.html +66 -0
- data/closure-library/closure/goog/ui/toolbarmenubutton.js +56 -0
- data/closure-library/closure/goog/ui/toolbarmenubuttonrenderer.js +55 -0
- data/closure-library/closure/goog/ui/toolbarrenderer.js +95 -0
- data/closure-library/closure/goog/ui/toolbarselect.js +55 -0
- data/closure-library/closure/goog/ui/toolbarseparator.js +51 -0
- data/closure-library/closure/goog/ui/toolbarseparatorrenderer.js +87 -0
- data/closure-library/closure/goog/ui/toolbartogglebutton.js +53 -0
- data/closure-library/closure/goog/ui/tooltip.js +975 -0
- data/closure-library/closure/goog/ui/tooltip_test.html +351 -0
- data/closure-library/closure/goog/ui/tree/basenode.js +1457 -0
- data/closure-library/closure/goog/ui/tree/basenode_test.html +218 -0
- data/closure-library/closure/goog/ui/tree/treecontrol.js +656 -0
- data/closure-library/closure/goog/ui/tree/treecontrol_test.html +113 -0
- data/closure-library/closure/goog/ui/tree/treenode.js +102 -0
- data/closure-library/closure/goog/ui/tree/typeahead.js +332 -0
- data/closure-library/closure/goog/ui/tree/typeahead_test.html +133 -0
- data/closure-library/closure/goog/ui/tristatemenuitem.js +185 -0
- data/closure-library/closure/goog/ui/tristatemenuitemrenderer.js +86 -0
- data/closure-library/closure/goog/ui/twothumbslider.js +134 -0
- data/closure-library/closure/goog/ui/zippy.js +277 -0
- data/closure-library/closure/goog/ui/zippy_test.html +223 -0
- data/closure-library/closure/goog/uri/uri.js +1595 -0
- data/closure-library/closure/goog/uri/uri_test.html +837 -0
- data/closure-library/closure/goog/uri/utils.js +972 -0
- data/closure-library/closure/goog/uri/utils_test.html +521 -0
- data/closure-library/closure/goog/useragent/adobereader.js +90 -0
- data/closure-library/closure/goog/useragent/adobereader_test.html +34 -0
- data/closure-library/closure/goog/useragent/flash.js +113 -0
- data/closure-library/closure/goog/useragent/flash_test.html +34 -0
- data/closure-library/closure/goog/useragent/iphoto.js +86 -0
- data/closure-library/closure/goog/useragent/jscript.js +94 -0
- data/closure-library/closure/goog/useragent/jscript_test.html +65 -0
- data/closure-library/closure/goog/useragent/picasa.js +111 -0
- data/closure-library/closure/goog/useragent/platform.js +70 -0
- data/closure-library/closure/goog/useragent/platform_test.html +108 -0
- data/closure-library/closure/goog/useragent/product.js +253 -0
- data/closure-library/closure/goog/useragent/product_isversion.js +99 -0
- data/closure-library/closure/goog/useragent/product_test.html +322 -0
- data/closure-library/closure/goog/useragent/useragent.js +464 -0
- data/closure-library/closure/goog/useragent/useragent_test.html +290 -0
- data/closure-library/closure/goog/window/window.js +206 -0
- data/closure-library/closure/goog/window/window_test.html +185 -0
- data/closure-library/third_party/closure/goog/base.js +2 -0
- data/closure-library/third_party/closure/goog/caja/string/html/htmlparser.js +611 -0
- data/closure-library/third_party/closure/goog/caja/string/html/htmlsanitizer.js +605 -0
- data/closure-library/third_party/closure/goog/deps.js +26 -0
- data/closure-library/third_party/closure/goog/dojo/dom/query.js +1532 -0
- data/closure-library/third_party/closure/goog/dojo/dom/query_test.html +63 -0
- data/closure-library/third_party/closure/goog/dojo/dom/query_test.js +160 -0
- data/closure-library/third_party/closure/goog/jpeg_encoder/jpeg_encoder_basic.js +751 -0
- data/closure-library/third_party/closure/goog/loremipsum/text/loremipsum.js +712 -0
- data/closure-library/third_party/closure/goog/loremipsum/text/loremipsum_test.html +61 -0
- data/closure-library/third_party/closure/goog/mochikit/async/deferred.js +530 -0
- data/closure-library/third_party/closure/goog/mochikit/async/deferred_test.html +627 -0
- data/closure-library/third_party/closure/goog/mochikit/async/deferredlist.js +199 -0
- data/closure-library/third_party/closure/goog/mochikit/async/deferredlist_test.html +426 -0
- data/closure-library/third_party/closure/goog/osapi/osapi.js +91 -0
- data/closure-library/third_party/closure/goog/silverlight/AppManifest.xml +6 -0
- data/closure-library/third_party/closure/goog/silverlight/AssemblyInfo.cs +35 -0
- data/closure-library/third_party/closure/goog/silverlight/ClipboardButton.xaml +9 -0
- data/closure-library/third_party/closure/goog/silverlight/ClipboardButton.xaml.cs +74 -0
- data/closure-library/third_party/closure/goog/silverlight/ClipboardButtonApp.xaml +8 -0
- data/closure-library/third_party/closure/goog/silverlight/ClipboardButtonApp.xaml.cs +75 -0
- data/closure-library/third_party/closure/goog/silverlight/ClosureClipboardButton.csproj +108 -0
- data/closure-library/third_party/closure/goog/silverlight/ClosureClipboardButton.csproj.user +29 -0
- data/closure-library/third_party/closure/goog/silverlight/clipboardbutton.js +279 -0
- data/closure-library/third_party/closure/goog/silverlight/silverlight.js +758 -0
- data/closure-library/third_party/closure/goog/silverlight/supporteduseragent.js +138 -0
- data/closure-library/third_party/closure/goog/silverlight/xap_files +0 -0
- data/closure-templates/COPYING +202 -0
- data/closure-templates/README +47 -0
- data/closure-templates/SoyToJsSrcCompiler.jar +0 -0
- data/closure-templates/soyutils.js +880 -0
- data/closure-templates/soyutils_usegoog.js +308 -0
- data/closure.gemspec +20 -0
- data/config.ru +40 -0
- data/java_src/ClosureScript.java +89 -0
- data/java_src/make.rb +19 -0
- data/lib/closure/beanshell.rb +80 -0
- data/lib/closure/compiler.rb +184 -0
- data/lib/closure/file_response.rb +90 -0
- data/lib/closure/goog.rb +143 -0
- data/lib/closure/middleware.rb +43 -0
- data/lib/closure/sass.rb +56 -0
- data/lib/closure/script.rb +139 -0
- data/lib/closure/server.rb +83 -0
- data/lib/closure/sources.rb +310 -0
- data/lib/closure/templates.rb +156 -0
- data/lib/closure/version.rb +20 -0
- data/lib/closure.jar +0 -0
- data/lib/closure.rb +134 -0
- data/scripts/demos/compile.js.erb +8 -0
- data/scripts/demos/compile.out +1 -0
- data/scripts/demos/compiler.haml +17 -0
- data/scripts/demos/compiler.js +12 -0
- data/scripts/demos/deps.js.erb +1 -0
- data/scripts/demos/externs.haml +16 -0
- data/scripts/demos/externs.js.erb +8 -0
- data/scripts/demos/externs.out +1 -0
- data/scripts/demos/externs_jquery.externs +849 -0
- data/scripts/demos/externs_jquery.js +167 -0
- data/scripts/demos/externs_jquerytest.js +11 -0
- data/scripts/demos/helloworld.haml +15 -0
- data/scripts/demos/helloworld.js +58 -0
- data/scripts/demos/helloworld.soy +45 -0
- data/scripts/demos/index.haml +21 -0
- data/scripts/demos/rails_ujs.haml +24 -0
- data/scripts/examples/rails/ujs.js +136 -0
- data/scripts/favicon.ico +0 -0
- data/scripts/fixtures/_partial.haml +2 -0
- data/scripts/fixtures/erb.html.erb +8 -0
- data/scripts/fixtures/haml.haml +6 -0
- data/scripts/fixtures/html.html +9 -0
- data/scripts/fixtures/route_js.js.erb +1 -0
- data/scripts/index.haml +14 -0
- data/test/beanshell_test.rb +22 -0
- data/test/server_test.rb +67 -0
- data/test/sources_test.rb +41 -0
- data/test/test_helper.rb +12 -0
- metadata +1577 -0
@@ -0,0 +1,1451 @@
|
|
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 Abstract Base Class for Drag and Drop.
|
17
|
+
*
|
18
|
+
* Provides functionality for implementing drag and drop classes. Also provides
|
19
|
+
* support classes and events.
|
20
|
+
*
|
21
|
+
*/
|
22
|
+
|
23
|
+
goog.provide('goog.fx.AbstractDragDrop');
|
24
|
+
goog.provide('goog.fx.AbstractDragDrop.EventType');
|
25
|
+
goog.provide('goog.fx.DragDropEvent');
|
26
|
+
goog.provide('goog.fx.DragDropItem');
|
27
|
+
|
28
|
+
goog.require('goog.dom');
|
29
|
+
goog.require('goog.dom.classes');
|
30
|
+
goog.require('goog.events');
|
31
|
+
goog.require('goog.events.Event');
|
32
|
+
goog.require('goog.events.EventTarget');
|
33
|
+
goog.require('goog.events.EventType');
|
34
|
+
goog.require('goog.fx.Dragger');
|
35
|
+
goog.require('goog.fx.Dragger.EventType');
|
36
|
+
goog.require('goog.math.Box');
|
37
|
+
goog.require('goog.math.Coordinate');
|
38
|
+
goog.require('goog.style');
|
39
|
+
|
40
|
+
|
41
|
+
|
42
|
+
/**
|
43
|
+
* Abstract class that provides reusable functionality for implementing drag
|
44
|
+
* and drop functionality.
|
45
|
+
*
|
46
|
+
* This class also allows clients to define their own subtargeting function
|
47
|
+
* so that drop areas can have finer granularity then a singe element. This is
|
48
|
+
* accomplished by using a client provided function to map from element and
|
49
|
+
* coordinates to a subregion id.
|
50
|
+
*
|
51
|
+
* This class can also be made aware of scrollable containers that contain
|
52
|
+
* drop targets by calling addScrollableContainer. This will cause dnd to
|
53
|
+
* take changing scroll positions into account while a drag is occuring.
|
54
|
+
*
|
55
|
+
* @extends {goog.events.EventTarget}
|
56
|
+
* @constructor
|
57
|
+
*/
|
58
|
+
goog.fx.AbstractDragDrop = function() {
|
59
|
+
/**
|
60
|
+
* List of items that makes up the drag source or drop target.
|
61
|
+
* @type {Array.<goog.fx.DragDropItem>}
|
62
|
+
* @protected
|
63
|
+
* @suppress {underscore}
|
64
|
+
*/
|
65
|
+
this.items_ = [];
|
66
|
+
|
67
|
+
/**
|
68
|
+
* List of associated drop targets.
|
69
|
+
* @type {Array.<goog.fx.AbstractDragDrop>}
|
70
|
+
* @private
|
71
|
+
*/
|
72
|
+
this.targets_ = [];
|
73
|
+
|
74
|
+
/**
|
75
|
+
* Scrollable containers to account for during drag
|
76
|
+
* @type {Array.<goog.fx.ScrollableContainer_>}
|
77
|
+
* @private
|
78
|
+
*/
|
79
|
+
this.scrollableContainers_ = [];
|
80
|
+
|
81
|
+
};
|
82
|
+
goog.inherits(goog.fx.AbstractDragDrop, goog.events.EventTarget);
|
83
|
+
|
84
|
+
|
85
|
+
/**
|
86
|
+
* Minimum size (in pixels) for a dummy target. If the box for the target is
|
87
|
+
* less than the specified size it's not created.
|
88
|
+
* @type {number}
|
89
|
+
* @private
|
90
|
+
*/
|
91
|
+
goog.fx.AbstractDragDrop.DUMMY_TARGET_MIN_SIZE_ = 10;
|
92
|
+
|
93
|
+
|
94
|
+
/**
|
95
|
+
* Flag indicating if it's a drag source, set by addTarget.
|
96
|
+
* @type {boolean}
|
97
|
+
* @private
|
98
|
+
*/
|
99
|
+
goog.fx.AbstractDragDrop.prototype.isSource_ = false;
|
100
|
+
|
101
|
+
|
102
|
+
/**
|
103
|
+
* Flag indicating if it's a drop target, set when added as target to another
|
104
|
+
* DragDrop object.
|
105
|
+
* @type {boolean}
|
106
|
+
* @private
|
107
|
+
*/
|
108
|
+
goog.fx.AbstractDragDrop.prototype.isTarget_ = false;
|
109
|
+
|
110
|
+
|
111
|
+
/**
|
112
|
+
* Subtargeting function accepting args:
|
113
|
+
* (Element, goog.math.Box, number, number)
|
114
|
+
* @type {Function}
|
115
|
+
* @private
|
116
|
+
*/
|
117
|
+
goog.fx.AbstractDragDrop.prototype.subtargetFunction_;
|
118
|
+
|
119
|
+
|
120
|
+
/**
|
121
|
+
* Last active subtarget.
|
122
|
+
* @type {Object}
|
123
|
+
* @private
|
124
|
+
*/
|
125
|
+
goog.fx.AbstractDragDrop.prototype.activeSubtarget_;
|
126
|
+
|
127
|
+
|
128
|
+
/**
|
129
|
+
* Class name to add to source elements being dragged. Set by setDragClass.
|
130
|
+
* @type {?string}
|
131
|
+
* @private
|
132
|
+
*/
|
133
|
+
goog.fx.AbstractDragDrop.prototype.dragClass_;
|
134
|
+
|
135
|
+
|
136
|
+
/**
|
137
|
+
* Class name to add to source elements. Set by setSourceClass.
|
138
|
+
* @type {?string}
|
139
|
+
* @private
|
140
|
+
*/
|
141
|
+
goog.fx.AbstractDragDrop.prototype.sourceClass_;
|
142
|
+
|
143
|
+
|
144
|
+
/**
|
145
|
+
* Class name to add to target elements. Set by setTargetClass.
|
146
|
+
* @type {?string}
|
147
|
+
* @private
|
148
|
+
*/
|
149
|
+
goog.fx.AbstractDragDrop.prototype.targetClass_;
|
150
|
+
|
151
|
+
|
152
|
+
/**
|
153
|
+
* The SCROLL event target used to make drag element follow scrolling.
|
154
|
+
* @type {EventTarget}
|
155
|
+
* @private
|
156
|
+
*/
|
157
|
+
goog.fx.AbstractDragDrop.prototype.scrollTarget_;
|
158
|
+
|
159
|
+
|
160
|
+
/**
|
161
|
+
* Dummy target, {@see maybeCreateDummyTargetForPosition_}.
|
162
|
+
* @type {goog.fx.ActiveDropTarget_}
|
163
|
+
* @private
|
164
|
+
*/
|
165
|
+
goog.fx.AbstractDragDrop.prototype.dummyTarget_;
|
166
|
+
|
167
|
+
|
168
|
+
/**
|
169
|
+
* Whether the object has been initialized.
|
170
|
+
* @type {boolean}
|
171
|
+
* @private
|
172
|
+
*/
|
173
|
+
goog.fx.AbstractDragDrop.prototype.initialized_ = false;
|
174
|
+
|
175
|
+
|
176
|
+
/**
|
177
|
+
* Constants for event names
|
178
|
+
* @type {Object}
|
179
|
+
*/
|
180
|
+
goog.fx.AbstractDragDrop.EventType = {
|
181
|
+
DRAGOVER: 'dragover',
|
182
|
+
DRAGOUT: 'dragout',
|
183
|
+
DRAG: 'drag',
|
184
|
+
DROP: 'drop',
|
185
|
+
DRAGSTART: 'dragstart',
|
186
|
+
DRAGEND: 'dragend'
|
187
|
+
};
|
188
|
+
|
189
|
+
|
190
|
+
/**
|
191
|
+
* Constant for distance threshold, in pixels, an element has to be moved to
|
192
|
+
* initiate a drag operation.
|
193
|
+
* @type {number}
|
194
|
+
*/
|
195
|
+
goog.fx.AbstractDragDrop.initDragDistanceThreshold = 5;
|
196
|
+
|
197
|
+
|
198
|
+
/**
|
199
|
+
* Set class to add to source elements being dragged.
|
200
|
+
*
|
201
|
+
* @param {string} className Class to be added.
|
202
|
+
*/
|
203
|
+
goog.fx.AbstractDragDrop.prototype.setDragClass = function(className) {
|
204
|
+
this.dragClass_ = className;
|
205
|
+
};
|
206
|
+
|
207
|
+
|
208
|
+
/**
|
209
|
+
* Set class to add to source elements.
|
210
|
+
*
|
211
|
+
* @param {string} className Class to be added.
|
212
|
+
*/
|
213
|
+
goog.fx.AbstractDragDrop.prototype.setSourceClass = function(className) {
|
214
|
+
this.sourceClass_ = className;
|
215
|
+
};
|
216
|
+
|
217
|
+
|
218
|
+
/**
|
219
|
+
* Set class to add to target elements.
|
220
|
+
*
|
221
|
+
* @param {string} className Class to be added.
|
222
|
+
*/
|
223
|
+
goog.fx.AbstractDragDrop.prototype.setTargetClass = function(className) {
|
224
|
+
this.targetClass_ = className;
|
225
|
+
};
|
226
|
+
|
227
|
+
|
228
|
+
/**
|
229
|
+
* Whether the control has been initialized.
|
230
|
+
*
|
231
|
+
* @return {boolean} True if it's been initialized.
|
232
|
+
*/
|
233
|
+
goog.fx.AbstractDragDrop.prototype.isInitialized = function() {
|
234
|
+
return this.initialized_;
|
235
|
+
};
|
236
|
+
|
237
|
+
|
238
|
+
/**
|
239
|
+
* Add item to drag object.
|
240
|
+
*
|
241
|
+
* @param {goog.fx.DragDropItem} item Item to be added.
|
242
|
+
* @throws Error Thrown if called on instance of abstract class
|
243
|
+
*/
|
244
|
+
goog.fx.AbstractDragDrop.prototype.addItem = function(item) {
|
245
|
+
throw Error('Call to pure virtual method');
|
246
|
+
};
|
247
|
+
|
248
|
+
|
249
|
+
/**
|
250
|
+
* Associate drop target with drag element.
|
251
|
+
*
|
252
|
+
* @param {goog.fx.AbstractDragDrop} target Target to add.
|
253
|
+
*/
|
254
|
+
goog.fx.AbstractDragDrop.prototype.addTarget = function(target) {
|
255
|
+
this.targets_.push(target);
|
256
|
+
target.isTarget_ = true;
|
257
|
+
this.isSource_ = true;
|
258
|
+
};
|
259
|
+
|
260
|
+
|
261
|
+
/**
|
262
|
+
* Sets the SCROLL event target to make drag element follow scrolling.
|
263
|
+
*
|
264
|
+
* @param {EventTarget} scrollTarget The element that dispatches SCROLL events.
|
265
|
+
*/
|
266
|
+
goog.fx.AbstractDragDrop.prototype.setScrollTarget = function(scrollTarget) {
|
267
|
+
this.scrollTarget_ = scrollTarget;
|
268
|
+
};
|
269
|
+
|
270
|
+
|
271
|
+
/**
|
272
|
+
* Initialize drag and drop functionality for sources/targets already added.
|
273
|
+
* Sources/targets added after init has been called will initialize themselves
|
274
|
+
* one by one.
|
275
|
+
*/
|
276
|
+
goog.fx.AbstractDragDrop.prototype.init = function() {
|
277
|
+
if (this.initialized_) {
|
278
|
+
return;
|
279
|
+
}
|
280
|
+
for (var item, i = 0; item = this.items_[i]; i++) {
|
281
|
+
this.initItem(item);
|
282
|
+
}
|
283
|
+
|
284
|
+
this.initialized_ = true;
|
285
|
+
};
|
286
|
+
|
287
|
+
|
288
|
+
/**
|
289
|
+
* Initializes a single item.
|
290
|
+
*
|
291
|
+
* @param {goog.fx.DragDropItem} item Item to initialize.
|
292
|
+
* @protected
|
293
|
+
*/
|
294
|
+
goog.fx.AbstractDragDrop.prototype.initItem = function(item) {
|
295
|
+
if (this.isSource_) {
|
296
|
+
goog.events.listen(item.element, goog.events.EventType.MOUSEDOWN,
|
297
|
+
item.mouseDown_, false, item);
|
298
|
+
if (this.sourceClass_) {
|
299
|
+
goog.dom.classes.add(item.element, this.sourceClass_);
|
300
|
+
}
|
301
|
+
}
|
302
|
+
|
303
|
+
if (this.isTarget_ && this.targetClass_) {
|
304
|
+
goog.dom.classes.add(item.element, this.targetClass_);
|
305
|
+
}
|
306
|
+
};
|
307
|
+
|
308
|
+
|
309
|
+
/**
|
310
|
+
* Called when removing an item. Removes event listeners and classes.
|
311
|
+
*
|
312
|
+
* @param {goog.fx.DragDropItem} item Item to dispose.
|
313
|
+
* @protected
|
314
|
+
*/
|
315
|
+
goog.fx.AbstractDragDrop.prototype.disposeItem = function(item) {
|
316
|
+
if (this.isSource_) {
|
317
|
+
goog.events.unlisten(item.element, goog.events.EventType.MOUSEDOWN,
|
318
|
+
item.mouseDown_, false, item);
|
319
|
+
if (this.sourceClass_) {
|
320
|
+
goog.dom.classes.remove(item.element, this.sourceClass_);
|
321
|
+
}
|
322
|
+
}
|
323
|
+
if (this.isTarget_ && this.targetClass_) {
|
324
|
+
goog.dom.classes.remove(item.element, this.targetClass_);
|
325
|
+
}
|
326
|
+
};
|
327
|
+
|
328
|
+
|
329
|
+
/**
|
330
|
+
* Removes all items.
|
331
|
+
*/
|
332
|
+
goog.fx.AbstractDragDrop.prototype.removeItems = function() {
|
333
|
+
for (var item, i = 0; item = this.items_[i]; i++) {
|
334
|
+
this.disposeItem(item);
|
335
|
+
}
|
336
|
+
this.items_.length = 0;
|
337
|
+
};
|
338
|
+
|
339
|
+
|
340
|
+
/**
|
341
|
+
* Starts a drag event for an item if the mouse button stays pressed and the
|
342
|
+
* cursor moves a few pixels. Allows dragging of items without first having to
|
343
|
+
* register them with addItem.
|
344
|
+
*
|
345
|
+
* @param {goog.events.BrowserEvent} event Mouse down event.
|
346
|
+
* @param {goog.fx.DragDropItem} item Item that's being dragged.
|
347
|
+
*/
|
348
|
+
goog.fx.AbstractDragDrop.prototype.maybeStartDrag = function(event, item) {
|
349
|
+
item.maybeStartDrag_(event, item.element);
|
350
|
+
};
|
351
|
+
|
352
|
+
|
353
|
+
/**
|
354
|
+
* Event handler that's used to start drag.
|
355
|
+
*
|
356
|
+
* @param {goog.events.BrowserEvent} event Mouse move event.
|
357
|
+
* @param {goog.fx.DragDropItem} item Item that's being dragged.
|
358
|
+
*/
|
359
|
+
goog.fx.AbstractDragDrop.prototype.startDrag = function(event, item) {
|
360
|
+
|
361
|
+
// Prevent a new drag operation from being started if another one is already
|
362
|
+
// in progress (could happen if the mouse was released outside of the
|
363
|
+
// document).
|
364
|
+
if (this.dragItem_) {
|
365
|
+
return;
|
366
|
+
}
|
367
|
+
|
368
|
+
this.dragItem_ = item;
|
369
|
+
|
370
|
+
// Dispatch DRAGSTART event
|
371
|
+
var dragStartEvent = new goog.fx.DragDropEvent(
|
372
|
+
goog.fx.AbstractDragDrop.EventType.DRAGSTART, this, this.dragItem_);
|
373
|
+
if (this.dispatchEvent(dragStartEvent) == false) {
|
374
|
+
dragStartEvent.dispose();
|
375
|
+
this.dragItem_ = null;
|
376
|
+
return;
|
377
|
+
}
|
378
|
+
dragStartEvent.dispose();
|
379
|
+
|
380
|
+
// Get the source element and create a drag element for it.
|
381
|
+
var el = item.getCurrentDragElement();
|
382
|
+
this.dragEl_ = this.createDragElement(el);
|
383
|
+
var doc = goog.dom.getOwnerDocument(el);
|
384
|
+
doc.body.appendChild(this.dragEl_);
|
385
|
+
|
386
|
+
this.dragger_ = this.createDraggerFor(el, this.dragEl_, event);
|
387
|
+
this.dragger_.setScrollTarget(this.scrollTarget_);
|
388
|
+
|
389
|
+
goog.events.listen(this.dragger_, goog.fx.Dragger.EventType.DRAG,
|
390
|
+
this.moveDrag_, false, this);
|
391
|
+
|
392
|
+
goog.events.listen(this.dragger_, goog.fx.Dragger.EventType.END,
|
393
|
+
this.endDrag, false, this);
|
394
|
+
|
395
|
+
// IE may issue a 'selectstart' event when dragging over an iframe even when
|
396
|
+
// default mousemove behavior is suppressed. If the default selectstart
|
397
|
+
// behavior is not suppressed, elements dragged over will show as selected.
|
398
|
+
goog.events.listen(doc.body, goog.events.EventType.SELECTSTART,
|
399
|
+
this.suppressSelect_);
|
400
|
+
|
401
|
+
this.recalculateDragTargets();
|
402
|
+
this.activeTarget_ = null;
|
403
|
+
this.initScrollableContainers_();
|
404
|
+
this.dragger_.startDrag(event);
|
405
|
+
|
406
|
+
event.preventDefault();
|
407
|
+
};
|
408
|
+
|
409
|
+
|
410
|
+
/**
|
411
|
+
* Recalculates the geometry of this source's drag targets. Call this
|
412
|
+
* if the position or visibility of a drag target has changed during
|
413
|
+
* a drag, or if targets are added or removed.
|
414
|
+
*
|
415
|
+
* TODO(user): this is an expensive operation; more efficient APIs
|
416
|
+
* may be necessary.
|
417
|
+
*/
|
418
|
+
goog.fx.AbstractDragDrop.prototype.recalculateDragTargets = function() {
|
419
|
+
this.targetList_ = [];
|
420
|
+
for (var target, i = 0; target = this.targets_[i]; i++) {
|
421
|
+
for (var itm, j = 0; itm = target.items_[j]; j++) {
|
422
|
+
this.addDragTarget_(target, itm);
|
423
|
+
}
|
424
|
+
}
|
425
|
+
if (!this.targetBox_) {
|
426
|
+
this.targetBox_ = new goog.math.Box(0, 0, 0, 0);
|
427
|
+
}
|
428
|
+
};
|
429
|
+
|
430
|
+
|
431
|
+
/**
|
432
|
+
* Creates the Dragger for the drag element.
|
433
|
+
* @param {Element} sourceEl Drag source element.
|
434
|
+
* @param {Element} el the element created by createDragElement().
|
435
|
+
* @param {goog.events.BrowserEvent} event Mouse down event for start of drag.
|
436
|
+
* @return {goog.fx.Dragger} The new Dragger.
|
437
|
+
* @protected
|
438
|
+
*/
|
439
|
+
goog.fx.AbstractDragDrop.prototype.createDraggerFor =
|
440
|
+
function(sourceEl, el, event) {
|
441
|
+
// Position the drag element.
|
442
|
+
var pos = this.getDragElementPosition(sourceEl, el, event);
|
443
|
+
el.style.position = 'absolute';
|
444
|
+
el.style.left = pos.x + 'px';
|
445
|
+
el.style.top = pos.y + 'px';
|
446
|
+
return new goog.fx.Dragger(el);
|
447
|
+
};
|
448
|
+
|
449
|
+
|
450
|
+
/**
|
451
|
+
* Event handler that's used to stop drag. Fires a drop event if over a valid
|
452
|
+
* target.
|
453
|
+
*
|
454
|
+
* @param {goog.fx.DragEvent} event Drag event.
|
455
|
+
*/
|
456
|
+
goog.fx.AbstractDragDrop.prototype.endDrag = function(event) {
|
457
|
+
var activeTarget = event.dragCanceled ? null : this.activeTarget_;
|
458
|
+
if (activeTarget && activeTarget.target_) {
|
459
|
+
var clientX = event.clientX;
|
460
|
+
var clientY = event.clientY;
|
461
|
+
var scroll = this.getPageScroll_();
|
462
|
+
var x = clientX + scroll.x;
|
463
|
+
var y = clientY + scroll.y;
|
464
|
+
|
465
|
+
var subtarget;
|
466
|
+
// If a subtargeting function is enabled get the current subtarget
|
467
|
+
if (this.subtargetFunction_) {
|
468
|
+
subtarget = this.subtargetFunction_(activeTarget.item_,
|
469
|
+
activeTarget.box_, x, y);
|
470
|
+
}
|
471
|
+
|
472
|
+
var dragEvent = new goog.fx.DragDropEvent(
|
473
|
+
goog.fx.AbstractDragDrop.EventType.DRAG, this, this.dragItem_,
|
474
|
+
activeTarget.target_, activeTarget.item_, activeTarget.element_,
|
475
|
+
clientX, clientY, x, y);
|
476
|
+
this.dispatchEvent(dragEvent);
|
477
|
+
dragEvent.dispose();
|
478
|
+
|
479
|
+
var dropEvent = new goog.fx.DragDropEvent(
|
480
|
+
goog.fx.AbstractDragDrop.EventType.DROP, this, this.dragItem_,
|
481
|
+
activeTarget.target_, activeTarget.item_, activeTarget.element_,
|
482
|
+
clientX, clientY, x, y, subtarget);
|
483
|
+
activeTarget.target_.dispatchEvent(dropEvent);
|
484
|
+
dropEvent.dispose();
|
485
|
+
}
|
486
|
+
|
487
|
+
var dragEndEvent = new goog.fx.DragDropEvent(
|
488
|
+
goog.fx.AbstractDragDrop.EventType.DRAGEND, this, this.dragItem_);
|
489
|
+
this.dispatchEvent(dragEndEvent);
|
490
|
+
dragEndEvent.dispose();
|
491
|
+
|
492
|
+
goog.events.unlisten(this.dragger_, goog.fx.Dragger.EventType.DRAG,
|
493
|
+
this.moveDrag_, false, this);
|
494
|
+
goog.events.unlisten(this.dragger_, goog.fx.Dragger.EventType.END,
|
495
|
+
this.endDrag, false, this);
|
496
|
+
var doc = goog.dom.getOwnerDocument(this.dragItem_.getCurrentDragElement());
|
497
|
+
goog.events.unlisten(doc.body, goog.events.EventType.SELECTSTART,
|
498
|
+
this.suppressSelect_);
|
499
|
+
|
500
|
+
|
501
|
+
this.afterEndDrag(this.activeTarget_ ? this.activeTarget_.item_ : null);
|
502
|
+
};
|
503
|
+
|
504
|
+
|
505
|
+
/**
|
506
|
+
* Called after a drag operation has finished.
|
507
|
+
*
|
508
|
+
* @param {goog.fx.DragDropItem=} opt_dropTarget Target for successful drop.
|
509
|
+
* @protected
|
510
|
+
*/
|
511
|
+
goog.fx.AbstractDragDrop.prototype.afterEndDrag = function(opt_dropTarget) {
|
512
|
+
this.disposeDrag();
|
513
|
+
};
|
514
|
+
|
515
|
+
|
516
|
+
/**
|
517
|
+
* Called once a drag operation has finished. Removes event listeners and
|
518
|
+
* elements.
|
519
|
+
*
|
520
|
+
* @protected
|
521
|
+
*/
|
522
|
+
goog.fx.AbstractDragDrop.prototype.disposeDrag = function() {
|
523
|
+
this.disposeScrollableContainerListeners_();
|
524
|
+
this.dragger_.dispose();
|
525
|
+
|
526
|
+
goog.dom.removeNode(this.dragEl_);
|
527
|
+
delete this.dragItem_;
|
528
|
+
delete this.dragEl_;
|
529
|
+
delete this.dragger_;
|
530
|
+
delete this.targetList_;
|
531
|
+
delete this.activeTarget_;
|
532
|
+
};
|
533
|
+
|
534
|
+
|
535
|
+
/**
|
536
|
+
* Event handler for drag events. Determines the active drop target, if any, and
|
537
|
+
* fires dragover and dragout events appropriately.
|
538
|
+
*
|
539
|
+
* @param {goog.fx.DragEvent} event Drag event.
|
540
|
+
* @private
|
541
|
+
*/
|
542
|
+
goog.fx.AbstractDragDrop.prototype.moveDrag_ = function(event) {
|
543
|
+
var x = event.clientX;
|
544
|
+
var y = event.clientY;
|
545
|
+
var scroll = this.getPageScroll_();
|
546
|
+
x += scroll.x;
|
547
|
+
y += scroll.y;
|
548
|
+
|
549
|
+
// Check if we're still inside the bounds of the active target, if not fire
|
550
|
+
// a dragout event and proceed to find a new target.
|
551
|
+
var activeTarget = this.activeTarget_;
|
552
|
+
|
553
|
+
var subtarget;
|
554
|
+
if (activeTarget) {
|
555
|
+
// If a subtargeting function is enabled get the current subtarget
|
556
|
+
if (this.subtargetFunction_ && activeTarget.target_) {
|
557
|
+
subtarget = this.subtargetFunction_(activeTarget.item_,
|
558
|
+
activeTarget.box_, x, y);
|
559
|
+
}
|
560
|
+
|
561
|
+
if (this.isInside_(x, y, activeTarget.box_) &&
|
562
|
+
subtarget == this.activeSubtarget_) {
|
563
|
+
return;
|
564
|
+
}
|
565
|
+
|
566
|
+
if (activeTarget.target_) {
|
567
|
+
var sourceDragOutEvent = new goog.fx.DragDropEvent(
|
568
|
+
goog.fx.AbstractDragDrop.EventType.DRAGOUT, this, this.dragItem_,
|
569
|
+
activeTarget.target_, activeTarget.item_, activeTarget.element_);
|
570
|
+
this.dispatchEvent(sourceDragOutEvent);
|
571
|
+
sourceDragOutEvent.dispose();
|
572
|
+
|
573
|
+
// The event should be dispatched the by target DragDrop so that the
|
574
|
+
// target DragDrop can manage these events without having to know what
|
575
|
+
// sources this is a target for.
|
576
|
+
var targetDragOutEvent = new goog.fx.DragDropEvent(
|
577
|
+
goog.fx.AbstractDragDrop.EventType.DRAGOUT,
|
578
|
+
this,
|
579
|
+
this.dragItem_,
|
580
|
+
activeTarget.target_,
|
581
|
+
activeTarget.item_,
|
582
|
+
activeTarget.element_,
|
583
|
+
undefined,
|
584
|
+
undefined,
|
585
|
+
undefined,
|
586
|
+
undefined,
|
587
|
+
this.activeSubtarget_);
|
588
|
+
activeTarget.target_.dispatchEvent(targetDragOutEvent);
|
589
|
+
targetDragOutEvent.dispose();
|
590
|
+
}
|
591
|
+
this.activeSubtarget_ = subtarget;
|
592
|
+
this.activeTarget_ = null;
|
593
|
+
}
|
594
|
+
|
595
|
+
// Check if inside target box
|
596
|
+
if (this.isInside_(x, y, this.targetBox_)) {
|
597
|
+
// Search for target and fire a dragover event if found
|
598
|
+
activeTarget = this.activeTarget_ = this.getTargetFromPosition_(x, y);
|
599
|
+
if (activeTarget && activeTarget.target_) {
|
600
|
+
// If a subtargeting function is enabled get the current subtarget
|
601
|
+
if (this.subtargetFunction_) {
|
602
|
+
subtarget = this.subtargetFunction_(activeTarget.item_,
|
603
|
+
activeTarget.box_, x, y);
|
604
|
+
}
|
605
|
+
var sourceDragOverEvent = new goog.fx.DragDropEvent(
|
606
|
+
goog.fx.AbstractDragDrop.EventType.DRAGOVER, this, this.dragItem_,
|
607
|
+
activeTarget.target_, activeTarget.item_, activeTarget.element_);
|
608
|
+
sourceDragOverEvent.subtarget = subtarget;
|
609
|
+
this.dispatchEvent(sourceDragOverEvent);
|
610
|
+
sourceDragOverEvent.dispose();
|
611
|
+
|
612
|
+
// The event should be dispatched by the target DragDrop so that the
|
613
|
+
// target DragDrop can manage these events without having to know what
|
614
|
+
// sources this is a target for.
|
615
|
+
var targetDragOverEvent = new goog.fx.DragDropEvent(
|
616
|
+
goog.fx.AbstractDragDrop.EventType.DRAGOVER, this, this.dragItem_,
|
617
|
+
activeTarget.target_, activeTarget.item_, activeTarget.element_,
|
618
|
+
event.clientX, event.clientY, undefined, undefined, subtarget);
|
619
|
+
activeTarget.target_.dispatchEvent(targetDragOverEvent);
|
620
|
+
targetDragOverEvent.dispose();
|
621
|
+
|
622
|
+
} else if (!activeTarget) {
|
623
|
+
// If no target was found create a dummy one so we won't have to iterate
|
624
|
+
// over all possible targets for every move event.
|
625
|
+
this.activeTarget_ = this.maybeCreateDummyTargetForPosition_(x, y);
|
626
|
+
}
|
627
|
+
}
|
628
|
+
};
|
629
|
+
|
630
|
+
|
631
|
+
/**
|
632
|
+
* Event handler for suppressing selectstart events. Selecting should be
|
633
|
+
* disabled while dragging.
|
634
|
+
*
|
635
|
+
* @param {goog.events.Event} event The selectstart event to suppress.
|
636
|
+
* @return {boolean} Whether to perform default behavior.
|
637
|
+
* @private
|
638
|
+
*/
|
639
|
+
goog.fx.AbstractDragDrop.prototype.suppressSelect_ = function(event) {
|
640
|
+
return false;
|
641
|
+
};
|
642
|
+
|
643
|
+
|
644
|
+
/**
|
645
|
+
* Stores current scroll positions of containers and allocates targets
|
646
|
+
* to the approptiate containers.
|
647
|
+
* @private
|
648
|
+
*/
|
649
|
+
goog.fx.AbstractDragDrop.prototype.initScrollableContainers_ = function() {
|
650
|
+
var container, i, j, target;
|
651
|
+
for (i = 0; container = this.scrollableContainers_[i]; i++) {
|
652
|
+
goog.events.listen(container.element_, goog.events.EventType.SCROLL,
|
653
|
+
this.containerScrollHandler_, false, this);
|
654
|
+
container.containedTargets_ = [];
|
655
|
+
container.savedScrollLeft_ = container.element_.scrollLeft;
|
656
|
+
container.savedScrollTop_ = container.element_.scrollTop;
|
657
|
+
var pos = goog.style.getPageOffset(container.element_);
|
658
|
+
var size = goog.style.getSize(container.element_);
|
659
|
+
container.box_ = new goog.math.Box(pos.y, pos.x + size.width,
|
660
|
+
pos.y + size.height, pos.x);
|
661
|
+
|
662
|
+
}
|
663
|
+
|
664
|
+
for (i = 0; target = this.targetList_[i]; i++) {
|
665
|
+
for (j = 0; container = this.scrollableContainers_[j]; j++) {
|
666
|
+
if (goog.dom.contains(container.element_, target.element_)) {
|
667
|
+
container.containedTargets_.push(target);
|
668
|
+
target.scrollableContainer_ = container;
|
669
|
+
}
|
670
|
+
}
|
671
|
+
}
|
672
|
+
};
|
673
|
+
|
674
|
+
|
675
|
+
/**
|
676
|
+
* Cleans up the scrollable container listeners.
|
677
|
+
* @private
|
678
|
+
*/
|
679
|
+
goog.fx.AbstractDragDrop.prototype.disposeScrollableContainerListeners_ =
|
680
|
+
function() {
|
681
|
+
for (var i = 0, container; container = this.scrollableContainers_[i]; i++) {
|
682
|
+
goog.events.unlisten(container.element_, 'scroll',
|
683
|
+
this.containerScrollHandler_, false, this);
|
684
|
+
container.containedTargets_ = [];
|
685
|
+
}
|
686
|
+
};
|
687
|
+
|
688
|
+
|
689
|
+
/**
|
690
|
+
* Makes drag and drop aware of a target container that could scroll mid drag.
|
691
|
+
* @param {Element} element The scroll container.
|
692
|
+
*/
|
693
|
+
goog.fx.AbstractDragDrop.prototype.addScrollableContainer = function(element) {
|
694
|
+
this.scrollableContainers_.push(new goog.fx.ScrollableContainer_(element));
|
695
|
+
};
|
696
|
+
|
697
|
+
|
698
|
+
/**
|
699
|
+
* Event handler for containers scrolling.
|
700
|
+
* @param {goog.events.Event} e The event.
|
701
|
+
* @private
|
702
|
+
*/
|
703
|
+
goog.fx.AbstractDragDrop.prototype.containerScrollHandler_ = function(e) {
|
704
|
+
for (var i = 0, container; container = this.scrollableContainers_[i]; i++) {
|
705
|
+
if (e.target == container.element_) {
|
706
|
+
var deltaTop = container.savedScrollTop_ - container.element_.scrollTop;
|
707
|
+
var deltaLeft =
|
708
|
+
container.savedScrollLeft_ - container.element_.scrollLeft;
|
709
|
+
container.savedScrollTop_ = container.element_.scrollTop;
|
710
|
+
container.savedScrollLeft_ = container.element_.scrollLeft;
|
711
|
+
|
712
|
+
for (var j = 0, target; target = container.containedTargets_[j]; j++) {
|
713
|
+
var box = target.box_;
|
714
|
+
box.top += deltaTop;
|
715
|
+
box.left += deltaLeft;
|
716
|
+
box.bottom += deltaTop;
|
717
|
+
box.right += deltaLeft;
|
718
|
+
|
719
|
+
this.calculateTargetBox_(box);
|
720
|
+
}
|
721
|
+
}
|
722
|
+
}
|
723
|
+
};
|
724
|
+
|
725
|
+
|
726
|
+
/**
|
727
|
+
* Set a function that provides subtargets. A subtargeting function
|
728
|
+
* returns an arbitrary identifier for each subtarget of an element.
|
729
|
+
* DnD code will generate additional drag over / out events when
|
730
|
+
* switching from subtarget to subtarget. This is useful for instance
|
731
|
+
* if you are interested if you are on the top half or the bottom half
|
732
|
+
* of the element.
|
733
|
+
* The provided function will be given the DragDropItem, box, x, y
|
734
|
+
* box is the current window coordinates occupied by element
|
735
|
+
* x, y is the mouse position in window coordinates
|
736
|
+
*
|
737
|
+
* @param {Function} f The new subtarget function.
|
738
|
+
*/
|
739
|
+
goog.fx.AbstractDragDrop.prototype.setSubtargetFunction = function(f) {
|
740
|
+
this.subtargetFunction_ = f;
|
741
|
+
};
|
742
|
+
|
743
|
+
|
744
|
+
/**
|
745
|
+
* Creates an element for the item being dragged.
|
746
|
+
*
|
747
|
+
* @param {Element} sourceEl Drag source element.
|
748
|
+
* @return {Element} The new drag element.
|
749
|
+
*/
|
750
|
+
goog.fx.AbstractDragDrop.prototype.createDragElement = function(sourceEl) {
|
751
|
+
var dragEl = this.cloneNode_(sourceEl);
|
752
|
+
if (this.dragClass_) {
|
753
|
+
goog.dom.classes.add(dragEl, this.dragClass_);
|
754
|
+
}
|
755
|
+
|
756
|
+
return dragEl;
|
757
|
+
};
|
758
|
+
|
759
|
+
|
760
|
+
/**
|
761
|
+
* Returns the position for the drag element.
|
762
|
+
*
|
763
|
+
* @param {Element} el Drag source element.
|
764
|
+
* @param {Element} dragEl The dragged element created by createDragElement().
|
765
|
+
* @param {goog.events.BrowserEvent} event Mouse down event for start of drag.
|
766
|
+
* @return {goog.math.Coordinate} The position for the drag element.
|
767
|
+
*/
|
768
|
+
goog.fx.AbstractDragDrop.prototype.getDragElementPosition =
|
769
|
+
function(el, dragEl, event) {
|
770
|
+
var pos = goog.style.getPageOffset(el);
|
771
|
+
|
772
|
+
// Subtract margin from drag element position twice, once to adjust the
|
773
|
+
// position given by the original node and once for the drag node.
|
774
|
+
pos.x += (parseInt(goog.style.getStyle_(el, 'marginLeft'), 10) || 0) * 2;
|
775
|
+
pos.y += (parseInt(goog.style.getStyle_(el, 'marginTop'), 10) || 0) * 2;
|
776
|
+
|
777
|
+
return pos;
|
778
|
+
};
|
779
|
+
|
780
|
+
|
781
|
+
/**
|
782
|
+
* Returns the dragger object.
|
783
|
+
*
|
784
|
+
* @return {goog.fx.Dragger} The dragger object used by this drag and drop
|
785
|
+
* instance.
|
786
|
+
*/
|
787
|
+
goog.fx.AbstractDragDrop.prototype.getDragger = function() {
|
788
|
+
return this.dragger_;
|
789
|
+
};
|
790
|
+
|
791
|
+
|
792
|
+
/**
|
793
|
+
* Creates copy of node being dragged.
|
794
|
+
*
|
795
|
+
* @param {Element} sourceEl Element to copy.
|
796
|
+
* @return {Element} The clone of {@code sourceEl}.
|
797
|
+
* @private
|
798
|
+
*/
|
799
|
+
goog.fx.AbstractDragDrop.prototype.cloneNode_ = function(sourceEl) {
|
800
|
+
var clonedEl = /** @type {Element} */ (sourceEl.cloneNode(true));
|
801
|
+
switch (sourceEl.tagName.toLowerCase()) {
|
802
|
+
case 'tr':
|
803
|
+
return goog.dom.createDom(
|
804
|
+
'table', null, goog.dom.createDom('tbody', null, clonedEl));
|
805
|
+
case 'td':
|
806
|
+
case 'th':
|
807
|
+
return goog.dom.createDom(
|
808
|
+
'table', null, goog.dom.createDom('tbody', null, goog.dom.createDom(
|
809
|
+
'tr', null, clonedEl)));
|
810
|
+
default:
|
811
|
+
return clonedEl;
|
812
|
+
}
|
813
|
+
};
|
814
|
+
|
815
|
+
|
816
|
+
/**
|
817
|
+
* Add possible drop target for current drag operation.
|
818
|
+
*
|
819
|
+
* @param {goog.fx.AbstractDragDrop} target Drag handler.
|
820
|
+
* @param {goog.fx.DragDropItem} item Item that's being dragged.
|
821
|
+
* @private
|
822
|
+
*/
|
823
|
+
goog.fx.AbstractDragDrop.prototype.addDragTarget_ = function(target, item) {
|
824
|
+
|
825
|
+
// Get all the draggable elements and add each one.
|
826
|
+
var draggableElements = item.getDraggableElements();
|
827
|
+
var targetList = this.targetList_;
|
828
|
+
for (var i = 0; i < draggableElements.length; i++) {
|
829
|
+
var draggableElement = draggableElements[i];
|
830
|
+
|
831
|
+
// Determine target position and dimension
|
832
|
+
var pos = goog.style.getPageOffset(draggableElement);
|
833
|
+
var size = goog.style.getSize(draggableElement);
|
834
|
+
|
835
|
+
var box = new goog.math.Box(pos.y, pos.x + size.width,
|
836
|
+
pos.y + size.height, pos.x);
|
837
|
+
|
838
|
+
targetList.push(
|
839
|
+
new goog.fx.ActiveDropTarget_(box, target, item, draggableElement));
|
840
|
+
|
841
|
+
this.calculateTargetBox_(box);
|
842
|
+
}
|
843
|
+
};
|
844
|
+
|
845
|
+
|
846
|
+
/**
|
847
|
+
* Calculate the outer bounds (the region all targets are inside).
|
848
|
+
*
|
849
|
+
* @param {goog.math.Box} box Box describing the position and dimension
|
850
|
+
* of a drag target.
|
851
|
+
* @private
|
852
|
+
*/
|
853
|
+
goog.fx.AbstractDragDrop.prototype.calculateTargetBox_ = function(box) {
|
854
|
+
if (this.targetList_.length == 1) {
|
855
|
+
this.targetBox_ = new goog.math.Box(box.top, box.right,
|
856
|
+
box.bottom, box.left);
|
857
|
+
} else {
|
858
|
+
var tb = this.targetBox_;
|
859
|
+
tb.left = Math.min(box.left, tb.left);
|
860
|
+
tb.right = Math.max(box.right, tb.right);
|
861
|
+
tb.top = Math.min(box.top, tb.top);
|
862
|
+
tb.bottom = Math.max(box.bottom, tb.bottom);
|
863
|
+
}
|
864
|
+
};
|
865
|
+
|
866
|
+
|
867
|
+
/**
|
868
|
+
* Creates a dummy target for the given cursor position. The assumption is to
|
869
|
+
* create as big dummy target box as possible, the only constraints are:
|
870
|
+
* - The dummy targert box cannot overlap any of real target boxes.
|
871
|
+
* - The dummy target has to contain a point with current mouse coordinates.
|
872
|
+
*
|
873
|
+
* NOTE: For performance reasons the box construction algorithm is kept simple
|
874
|
+
* and it is not optimal (see example below). Currently it is O(n) in regard to
|
875
|
+
* the number of real drop target boxes, but its result depends on the order
|
876
|
+
* of those boxes being processed (the order in which they're added to the
|
877
|
+
* targetList_ collection).
|
878
|
+
*
|
879
|
+
* The algorithm.
|
880
|
+
* a) Assumptions
|
881
|
+
* - Mouse pointer is in the bounding box of real target boxes.
|
882
|
+
* - None of the boxes have negative coordinate values.
|
883
|
+
* - Mouse pointer is not contained by any of "real target" boxes.
|
884
|
+
*
|
885
|
+
* b) Outline
|
886
|
+
* - Initialize the fake target to the bounding box of real targets.
|
887
|
+
* - For each real target box - clip the fake target box so it does not contain
|
888
|
+
* that target box, but does contain the mouse pointer.
|
889
|
+
* -- Project the real target box, mouse pointer and fake target box onto
|
890
|
+
* both axes and calculate the clipping coordinates.
|
891
|
+
* -- Only one coordinate is used to clip the fake target box to keep the
|
892
|
+
* fake target as big as possible.
|
893
|
+
* -- If the projection of the real target box contains the mouse pointer,
|
894
|
+
* clipping for a given axis is not possible.
|
895
|
+
* -- If both clippings are possible, the clipping more distant from the
|
896
|
+
* mouse pointer is selected to keep bigger fake target area.
|
897
|
+
* - Save the created fake target only if it has a big enough area.
|
898
|
+
*
|
899
|
+
*
|
900
|
+
* c) Example
|
901
|
+
* <pre>
|
902
|
+
* Input: Algorithm created box: Maximum box:
|
903
|
+
* +---------------------+ +---------------------+ +---------------------+
|
904
|
+
* | B1 | B2 | | B1 B2 | | B1 B2 |
|
905
|
+
* | | | | +-------------+ | |+-------------------+|
|
906
|
+
* |---------x-----------| | | | | || ||
|
907
|
+
* | | | | | | | || ||
|
908
|
+
* | | | | | | | || ||
|
909
|
+
* | | | | | | | || ||
|
910
|
+
* | | | | | | | || ||
|
911
|
+
* | | | | +-------------+ | |+-------------------+|
|
912
|
+
* | B4 | B3 | | B4 B3 | | B4 B3 |
|
913
|
+
* +---------------------+ +---------------------+ +---------------------+
|
914
|
+
* </pre>
|
915
|
+
*
|
916
|
+
* @param {number} x Cursor position on the x-axis.
|
917
|
+
* @param {number} y Cursor position on the y-axis.
|
918
|
+
* @return {goog.fx.ActiveDropTarget_} Dummy drop target.
|
919
|
+
* @private
|
920
|
+
*/
|
921
|
+
goog.fx.AbstractDragDrop.prototype.maybeCreateDummyTargetForPosition_ =
|
922
|
+
function(x, y) {
|
923
|
+
if (!this.dummyTarget_) {
|
924
|
+
this.dummyTarget_ = new goog.fx.ActiveDropTarget_(this.targetBox_.clone());
|
925
|
+
}
|
926
|
+
var fakeTargetBox = this.dummyTarget_.box_;
|
927
|
+
|
928
|
+
// Initialize the fake target box to the bounding box of DnD targets.
|
929
|
+
fakeTargetBox.top = this.targetBox_.top;
|
930
|
+
fakeTargetBox.right = this.targetBox_.right;
|
931
|
+
fakeTargetBox.bottom = this.targetBox_.bottom;
|
932
|
+
fakeTargetBox.left = this.targetBox_.left;
|
933
|
+
|
934
|
+
// Clip the fake target based on mouse position and DnD target boxes.
|
935
|
+
for (var i = 0, target; target = this.targetList_[i]; i++) {
|
936
|
+
var box = target.box_;
|
937
|
+
|
938
|
+
// Calculate clipping coordinates for horizontal and vertical axis.
|
939
|
+
// The clipping coordinate is calculated by projecting fake target box,
|
940
|
+
// the mouse pointer and DnD target box onto an axis and checking how
|
941
|
+
// box projections overlap and if the projected DnD target box contains
|
942
|
+
// mouse pointer. The clipping coordinate cannot be computed and is set to
|
943
|
+
// a negative value if the projected DnD target contains the mouse pointer.
|
944
|
+
|
945
|
+
var horizontalClip = -1; // Assume mouse is above or below the DnD box.
|
946
|
+
if (x >= box.right) { // Mouse is to the right of the DnD box.
|
947
|
+
// Clip the fake box only if the DnD box overlaps it.
|
948
|
+
horizontalClip = box.right > fakeTargetBox.left ?
|
949
|
+
box.right : fakeTargetBox.left;
|
950
|
+
} else if (x < box.left) { // Mouse is to the left of the DnD box.
|
951
|
+
// Clip the fake box only if the DnD box overlaps it.
|
952
|
+
horizontalClip = box.left < fakeTargetBox.right ?
|
953
|
+
box.left : fakeTargetBox.right;
|
954
|
+
}
|
955
|
+
var verticalClip = -1;
|
956
|
+
if (y >= box.bottom) {
|
957
|
+
verticalClip = box.bottom > fakeTargetBox.top ?
|
958
|
+
box.bottom : fakeTargetBox.top;
|
959
|
+
} else if (y < box.top) {
|
960
|
+
verticalClip = box.top < fakeTargetBox.bottom ?
|
961
|
+
box.top : fakeTargetBox.bottom;
|
962
|
+
}
|
963
|
+
|
964
|
+
// If both clippings are possible (positive values have been set), choose
|
965
|
+
// one that gives us larger distance to mouse pointer (mark the shorter
|
966
|
+
// clipping as impossible, by setting it to negative value).
|
967
|
+
if (horizontalClip >= 0 && verticalClip >= 0) {
|
968
|
+
if (Math.abs(horizontalClip - x) > Math.abs(verticalClip - y)) {
|
969
|
+
verticalClip = -1;
|
970
|
+
} else {
|
971
|
+
horizontalClip = -1;
|
972
|
+
}
|
973
|
+
}
|
974
|
+
|
975
|
+
// Clip none or one of fake target box sides (at most one clipping
|
976
|
+
// coordinate can be active).
|
977
|
+
if (horizontalClip >= 0) {
|
978
|
+
if (horizontalClip <= x) {
|
979
|
+
fakeTargetBox.left = horizontalClip;
|
980
|
+
} else {
|
981
|
+
fakeTargetBox.right = horizontalClip;
|
982
|
+
}
|
983
|
+
} else if (verticalClip >= 0) {
|
984
|
+
if (verticalClip <= y) {
|
985
|
+
fakeTargetBox.top = verticalClip;
|
986
|
+
} else {
|
987
|
+
fakeTargetBox.bottom = verticalClip;
|
988
|
+
}
|
989
|
+
}
|
990
|
+
}
|
991
|
+
|
992
|
+
// Only return the new fake target if it is big enough.
|
993
|
+
return (fakeTargetBox.right - fakeTargetBox.left) *
|
994
|
+
(fakeTargetBox.bottom - fakeTargetBox.top) >=
|
995
|
+
goog.fx.AbstractDragDrop.DUMMY_TARGET_MIN_SIZE_ ?
|
996
|
+
this.dummyTarget_ : null;
|
997
|
+
};
|
998
|
+
|
999
|
+
|
1000
|
+
/**
|
1001
|
+
* Returns the target for a given cursor position.
|
1002
|
+
*
|
1003
|
+
* @param {number} x Cursor position on the x-axis.
|
1004
|
+
* @param {number} y Cursor position on the y-axis.
|
1005
|
+
* @return {Object} Target for position or null if no target was defined
|
1006
|
+
* for the given position.
|
1007
|
+
* @private
|
1008
|
+
*/
|
1009
|
+
goog.fx.AbstractDragDrop.prototype.getTargetFromPosition_ = function(x, y) {
|
1010
|
+
for (var target, i = 0; target = this.targetList_[i]; i++) {
|
1011
|
+
if (this.isInside_(x, y, target.box_)) {
|
1012
|
+
if (target.scrollableContainer_) {
|
1013
|
+
// If we have a scrollable container we will need to make sure
|
1014
|
+
// we account for clipping of the scroll area
|
1015
|
+
var box = target.scrollableContainer_.box_;
|
1016
|
+
if (this.isInside_(x, y, box)) {
|
1017
|
+
return target;
|
1018
|
+
}
|
1019
|
+
} else {
|
1020
|
+
return target;
|
1021
|
+
}
|
1022
|
+
}
|
1023
|
+
}
|
1024
|
+
|
1025
|
+
return null;
|
1026
|
+
};
|
1027
|
+
|
1028
|
+
|
1029
|
+
/**
|
1030
|
+
* Checks whatever a given point is inside a given box.
|
1031
|
+
*
|
1032
|
+
* @param {number} x Cursor position on the x-axis.
|
1033
|
+
* @param {number} y Cursor position on the y-axis.
|
1034
|
+
* @param {goog.math.Box} box Box to check position against.
|
1035
|
+
* @return {boolean} Whether the given point is inside {@code box}.
|
1036
|
+
* @private
|
1037
|
+
*/
|
1038
|
+
goog.fx.AbstractDragDrop.prototype.isInside_ = function(x, y, box) {
|
1039
|
+
return x >= box.left &&
|
1040
|
+
x < box.right &&
|
1041
|
+
y >= box.top &&
|
1042
|
+
y < box.bottom;
|
1043
|
+
};
|
1044
|
+
|
1045
|
+
|
1046
|
+
/**
|
1047
|
+
* Gets the page scroll distance as a coordinate object, using
|
1048
|
+
* the window of the current drag element's dom.
|
1049
|
+
* @return {goog.math.Coordinate} Object with scroll offsets 'x' and 'y'.
|
1050
|
+
* @private
|
1051
|
+
*/
|
1052
|
+
goog.fx.AbstractDragDrop.prototype.getPageScroll_ = function() {
|
1053
|
+
return goog.dom.getDomHelper(this.dragEl_).getDocumentScroll();
|
1054
|
+
};
|
1055
|
+
|
1056
|
+
|
1057
|
+
/**
|
1058
|
+
* Disposes of the drag and drop object.
|
1059
|
+
*/
|
1060
|
+
goog.fx.AbstractDragDrop.prototype.disposeInternal = function() {
|
1061
|
+
goog.fx.AbstractDragDrop.superClass_.disposeInternal.call(this);
|
1062
|
+
this.removeItems();
|
1063
|
+
};
|
1064
|
+
|
1065
|
+
|
1066
|
+
|
1067
|
+
/**
|
1068
|
+
* Object representing a drag and drop event.
|
1069
|
+
*
|
1070
|
+
* @param {string} type Event type.
|
1071
|
+
* @param {goog.fx.AbstractDragDrop} source Source drag drop object.
|
1072
|
+
* @param {goog.fx.DragDropItem} sourceItem Source item.
|
1073
|
+
* @param {goog.fx.AbstractDragDrop=} opt_target Target drag drop object.
|
1074
|
+
* @param {goog.fx.DragDropItem=} opt_targetItem Target item.
|
1075
|
+
* @param {Element=} opt_targetElement Target element.
|
1076
|
+
* @param {number=} opt_clientX X-Position relative to the screen.
|
1077
|
+
* @param {number=} opt_clientY Y-Position relative to the screen.
|
1078
|
+
* @param {number=} opt_x X-Position relative to the viewport.
|
1079
|
+
* @param {number=} opt_y Y-Position relative to the viewport.
|
1080
|
+
* @param {Object=} opt_subtarget The currently active subtarget.
|
1081
|
+
* @extends {goog.events.Event}
|
1082
|
+
* @constructor
|
1083
|
+
*/
|
1084
|
+
goog.fx.DragDropEvent = function(type, source, sourceItem,
|
1085
|
+
opt_target, opt_targetItem, opt_targetElement,
|
1086
|
+
opt_clientX, opt_clientY, opt_x, opt_y,
|
1087
|
+
opt_subtarget) {
|
1088
|
+
// TODO(user): Get rid of all the optional parameters and have the caller set
|
1089
|
+
// the fields directly instead.
|
1090
|
+
goog.events.Event.call(this, type);
|
1091
|
+
|
1092
|
+
/**
|
1093
|
+
* Reference to the source goog.fx.AbstractDragDrop object.
|
1094
|
+
* @type {goog.fx.AbstractDragDrop}
|
1095
|
+
*/
|
1096
|
+
this.dragSource = source;
|
1097
|
+
|
1098
|
+
/**
|
1099
|
+
* Reference to the source goog.fx.DragDropItem object.
|
1100
|
+
* @type {goog.fx.DragDropItem}
|
1101
|
+
*/
|
1102
|
+
this.dragSourceItem = sourceItem;
|
1103
|
+
|
1104
|
+
/**
|
1105
|
+
* Reference to the target goog.fx.AbstractDragDrop object.
|
1106
|
+
* @type {goog.fx.AbstractDragDrop|undefined}
|
1107
|
+
*/
|
1108
|
+
this.dropTarget = opt_target;
|
1109
|
+
|
1110
|
+
/**
|
1111
|
+
* Reference to the target goog.fx.DragDropItem object.
|
1112
|
+
* @type {goog.fx.DragDropItem|undefined}
|
1113
|
+
*/
|
1114
|
+
this.dropTargetItem = opt_targetItem;
|
1115
|
+
|
1116
|
+
/**
|
1117
|
+
* The actual element of the drop target that is the target for this event.
|
1118
|
+
* @type {Element|undefined}
|
1119
|
+
*/
|
1120
|
+
this.dropTargetElement = opt_targetElement;
|
1121
|
+
|
1122
|
+
/**
|
1123
|
+
* X-Position relative to the screen.
|
1124
|
+
* @type {number|undefined}
|
1125
|
+
*/
|
1126
|
+
this.clientX = opt_clientX;
|
1127
|
+
|
1128
|
+
/**
|
1129
|
+
* Y-Position relative to the screen.
|
1130
|
+
* @type {number|undefined}
|
1131
|
+
*/
|
1132
|
+
this.clientY = opt_clientY;
|
1133
|
+
|
1134
|
+
/**
|
1135
|
+
* X-Position relative to the viewport.
|
1136
|
+
* @type {number|undefined}
|
1137
|
+
*/
|
1138
|
+
this.viewportX = opt_x;
|
1139
|
+
|
1140
|
+
/**
|
1141
|
+
* Y-Position relative to the viewport.
|
1142
|
+
* @type {number|undefined}
|
1143
|
+
*/
|
1144
|
+
this.viewportY = opt_y;
|
1145
|
+
|
1146
|
+
/**
|
1147
|
+
* The subtarget that is currently active if a subtargeting function
|
1148
|
+
* is supplied.
|
1149
|
+
* @type {Object|undefined}
|
1150
|
+
*/
|
1151
|
+
this.subtarget = opt_subtarget;
|
1152
|
+
};
|
1153
|
+
goog.inherits(goog.fx.DragDropEvent, goog.events.Event);
|
1154
|
+
|
1155
|
+
|
1156
|
+
/**
|
1157
|
+
* Disposes of the event.
|
1158
|
+
*/
|
1159
|
+
goog.fx.DragDropEvent.prototype.disposeInternal = function() {
|
1160
|
+
goog.fx.DragDropEvent.superClass_.disposeInternal.call(this);
|
1161
|
+
|
1162
|
+
delete this.dragSource;
|
1163
|
+
delete this.dragSourceItem;
|
1164
|
+
delete this.dropTarget;
|
1165
|
+
delete this.dropTargetItem;
|
1166
|
+
delete this.dropTargetElement;
|
1167
|
+
};
|
1168
|
+
|
1169
|
+
|
1170
|
+
|
1171
|
+
/**
|
1172
|
+
* Class representing a source or target element for drag and drop operations.
|
1173
|
+
*
|
1174
|
+
* @param {Element|string} element Dom Node, or string representation of node
|
1175
|
+
* id, to be used as drag source/drop target.
|
1176
|
+
* @param {Object=} opt_data Data associated with the source/target.
|
1177
|
+
* @throws Error If no element argument is provided or if the type is invalid
|
1178
|
+
* @extends {goog.events.EventTarget}
|
1179
|
+
* @constructor
|
1180
|
+
*/
|
1181
|
+
goog.fx.DragDropItem = function(element, opt_data) {
|
1182
|
+
|
1183
|
+
/**
|
1184
|
+
* Reference to drag source/target element
|
1185
|
+
* @type {Element}
|
1186
|
+
*/
|
1187
|
+
this.element = goog.dom.getElement(element);
|
1188
|
+
|
1189
|
+
/**
|
1190
|
+
* Data associated with element.
|
1191
|
+
* @type {Object|undefined}
|
1192
|
+
*/
|
1193
|
+
this.data = opt_data;
|
1194
|
+
|
1195
|
+
/**
|
1196
|
+
* Drag object the item belongs to.
|
1197
|
+
* @type {goog.fx.AbstractDragDrop?}
|
1198
|
+
* @private
|
1199
|
+
*/
|
1200
|
+
this.parent_ = null;
|
1201
|
+
|
1202
|
+
if (!this.element) {
|
1203
|
+
throw Error('Invalid argument');
|
1204
|
+
}
|
1205
|
+
};
|
1206
|
+
goog.inherits(goog.fx.DragDropItem, goog.events.EventTarget);
|
1207
|
+
|
1208
|
+
|
1209
|
+
/**
|
1210
|
+
* The current element being dragged. This is needed because a DragDropItem can
|
1211
|
+
* have multiple elements that can be dragged.
|
1212
|
+
* @type {Element}
|
1213
|
+
* @private
|
1214
|
+
*/
|
1215
|
+
goog.fx.DragDropItem.prototype.currentDragElement_ = null;
|
1216
|
+
|
1217
|
+
|
1218
|
+
/**
|
1219
|
+
* Get the data associated with the source/target.
|
1220
|
+
* @return {Object|null|undefined} Data associated with the source/target.
|
1221
|
+
*/
|
1222
|
+
goog.fx.DragDropItem.prototype.getData = function() {
|
1223
|
+
return this.data;
|
1224
|
+
};
|
1225
|
+
|
1226
|
+
|
1227
|
+
/**
|
1228
|
+
* Gets the element that is actually draggable given that the given target was
|
1229
|
+
* attempted to be dragged. This should be overriden when the element that was
|
1230
|
+
* given actually contains many items that can be dragged. From the target, you
|
1231
|
+
* can determine what element should actually be dragged.
|
1232
|
+
*
|
1233
|
+
* @param {Element} target The target that was attempted to be dragged.
|
1234
|
+
* @return {Element} The element that is draggable given the target. If
|
1235
|
+
* none are draggable, this will return null.
|
1236
|
+
*/
|
1237
|
+
goog.fx.DragDropItem.prototype.getDraggableElement = function(target) {
|
1238
|
+
return target;
|
1239
|
+
};
|
1240
|
+
|
1241
|
+
|
1242
|
+
/**
|
1243
|
+
* Gets the element that is currently being dragged.
|
1244
|
+
*
|
1245
|
+
* @return {Element} The element that is currently being dragged.
|
1246
|
+
*/
|
1247
|
+
goog.fx.DragDropItem.prototype.getCurrentDragElement = function() {
|
1248
|
+
return this.currentDragElement_;
|
1249
|
+
};
|
1250
|
+
|
1251
|
+
|
1252
|
+
/**
|
1253
|
+
* Gets all the elements of this item that are potentially draggable/
|
1254
|
+
*
|
1255
|
+
* @return {Array.<Element>} The draggable elements.
|
1256
|
+
*/
|
1257
|
+
goog.fx.DragDropItem.prototype.getDraggableElements = function() {
|
1258
|
+
return [this.element];
|
1259
|
+
};
|
1260
|
+
|
1261
|
+
|
1262
|
+
/**
|
1263
|
+
* Event handler for mouse down.
|
1264
|
+
*
|
1265
|
+
* @param {goog.events.BrowserEvent} event Mouse down event.
|
1266
|
+
* @private
|
1267
|
+
*/
|
1268
|
+
goog.fx.DragDropItem.prototype.mouseDown_ = function(event) {
|
1269
|
+
// Get the draggable element for the target.
|
1270
|
+
var element = this.getDraggableElement(/** @type {Element} */ (event.target));
|
1271
|
+
if (element) {
|
1272
|
+
this.maybeStartDrag_(event, element);
|
1273
|
+
}
|
1274
|
+
};
|
1275
|
+
|
1276
|
+
|
1277
|
+
/**
|
1278
|
+
* Sets the dragdrop to which this item belongs.
|
1279
|
+
* @param {goog.fx.AbstractDragDrop} parent The parent dragdrop.
|
1280
|
+
*/
|
1281
|
+
goog.fx.DragDropItem.prototype.setParent = function(parent) {
|
1282
|
+
this.parent_ = parent;
|
1283
|
+
};
|
1284
|
+
|
1285
|
+
|
1286
|
+
/**
|
1287
|
+
* Adds mouse move, mouse out and mouse up handlers.
|
1288
|
+
*
|
1289
|
+
* @param {goog.events.BrowserEvent} event Mouse down event.
|
1290
|
+
* @param {Element} element Element.
|
1291
|
+
* @private
|
1292
|
+
*/
|
1293
|
+
goog.fx.DragDropItem.prototype.maybeStartDrag_ = function(event, element) {
|
1294
|
+
goog.events.listen(element, goog.events.EventType.MOUSEMOVE,
|
1295
|
+
this.mouseMove_, false, this);
|
1296
|
+
goog.events.listen(element, goog.events.EventType.MOUSEOUT,
|
1297
|
+
this.mouseMove_, false, this);
|
1298
|
+
goog.events.listen(element, goog.events.EventType.MOUSEUP,
|
1299
|
+
this.mouseUp_, false, this);
|
1300
|
+
|
1301
|
+
this.currentDragElement_ = element;
|
1302
|
+
|
1303
|
+
this.startPosition_ = new goog.math.Coordinate(
|
1304
|
+
event.clientX, event.clientY);
|
1305
|
+
|
1306
|
+
event.preventDefault();
|
1307
|
+
};
|
1308
|
+
|
1309
|
+
|
1310
|
+
/**
|
1311
|
+
* Event handler for mouse move. Starts drag operation if moved more than the
|
1312
|
+
* threshold value.
|
1313
|
+
*
|
1314
|
+
* @param {goog.events.BrowserEvent} event Mouse move or mouse out event.
|
1315
|
+
* @private
|
1316
|
+
*/
|
1317
|
+
goog.fx.DragDropItem.prototype.mouseMove_ = function(event) {
|
1318
|
+
var distance = Math.abs(event.clientX - this.startPosition_.x) +
|
1319
|
+
Math.abs(event.clientY - this.startPosition_.y);
|
1320
|
+
|
1321
|
+
if (distance > goog.fx.AbstractDragDrop.initDragDistanceThreshold) {
|
1322
|
+
var currentDragElement = this.currentDragElement_;
|
1323
|
+
goog.events.unlisten(currentDragElement, goog.events.EventType.MOUSEMOVE,
|
1324
|
+
this.mouseMove_, false, this);
|
1325
|
+
goog.events.unlisten(currentDragElement, goog.events.EventType.MOUSEOUT,
|
1326
|
+
this.mouseMove_, false, this);
|
1327
|
+
goog.events.unlisten(currentDragElement, goog.events.EventType.MOUSEUP,
|
1328
|
+
this.mouseUp_, false, this);
|
1329
|
+
|
1330
|
+
this.parent_.startDrag(event, this);
|
1331
|
+
}
|
1332
|
+
};
|
1333
|
+
|
1334
|
+
|
1335
|
+
/**
|
1336
|
+
* Event handler for mouse up. Removes mouse move, mouse out and mouse up event
|
1337
|
+
* handlers.
|
1338
|
+
*
|
1339
|
+
* @param {goog.events.BrowserEvent} event Mouse up event.
|
1340
|
+
* @private
|
1341
|
+
*/
|
1342
|
+
goog.fx.DragDropItem.prototype.mouseUp_ = function(event) {
|
1343
|
+
var currentDragElement = this.currentDragElement_;
|
1344
|
+
goog.events.unlisten(currentDragElement, goog.events.EventType.MOUSEMOVE,
|
1345
|
+
this.mouseMove_, false, this);
|
1346
|
+
goog.events.unlisten(currentDragElement, goog.events.EventType.MOUSEOUT,
|
1347
|
+
this.mouseMove_, false, this);
|
1348
|
+
goog.events.unlisten(currentDragElement, goog.events.EventType.MOUSEUP,
|
1349
|
+
this.mouseUp_, false, this);
|
1350
|
+
delete this.startPosition_;
|
1351
|
+
this.currentDragElement_ = null;
|
1352
|
+
};
|
1353
|
+
|
1354
|
+
|
1355
|
+
|
1356
|
+
/**
|
1357
|
+
* Class representing an active drop target
|
1358
|
+
*
|
1359
|
+
* @param {goog.math.Box} box Box describing the position and dimension of the
|
1360
|
+
* target item.
|
1361
|
+
* @param {goog.fx.AbstractDragDrop=} opt_target Target that contains the item
|
1362
|
+
associated with position.
|
1363
|
+
* @param {goog.fx.DragDropItem=} opt_item Item associated with position.
|
1364
|
+
* @param {Element=} opt_element Element of item associated with position.
|
1365
|
+
* @constructor
|
1366
|
+
* @private
|
1367
|
+
*/
|
1368
|
+
goog.fx.ActiveDropTarget_ = function(box, opt_target, opt_item, opt_element) {
|
1369
|
+
|
1370
|
+
/**
|
1371
|
+
* Box describing the position and dimension of the target item
|
1372
|
+
* @type {goog.math.Box}
|
1373
|
+
* @private
|
1374
|
+
*/
|
1375
|
+
this.box_ = box;
|
1376
|
+
|
1377
|
+
/**
|
1378
|
+
* Target that contains the item associated with position
|
1379
|
+
* @type {goog.fx.AbstractDragDrop|undefined}
|
1380
|
+
* @private
|
1381
|
+
*/
|
1382
|
+
this.target_ = opt_target;
|
1383
|
+
|
1384
|
+
/**
|
1385
|
+
* Item associated with position
|
1386
|
+
* @type {goog.fx.DragDropItem|undefined}
|
1387
|
+
* @private
|
1388
|
+
*/
|
1389
|
+
this.item_ = opt_item;
|
1390
|
+
|
1391
|
+
/**
|
1392
|
+
* The draggable element of the item associated with position.
|
1393
|
+
* @type {Element|undefined}
|
1394
|
+
* @private
|
1395
|
+
*/
|
1396
|
+
this.element_ = opt_element;
|
1397
|
+
};
|
1398
|
+
|
1399
|
+
|
1400
|
+
/**
|
1401
|
+
* If this target is in a scrollable container this is it.
|
1402
|
+
* @type {goog.fx.ScrollableContainer_}
|
1403
|
+
* @private
|
1404
|
+
*/
|
1405
|
+
goog.fx.ActiveDropTarget_.prototype.scrollableContainer_ = null;
|
1406
|
+
|
1407
|
+
|
1408
|
+
|
1409
|
+
/**
|
1410
|
+
* Class for representing a scrollable container
|
1411
|
+
* @param {Element} element the scrollable element.
|
1412
|
+
* @constructor
|
1413
|
+
* @private
|
1414
|
+
*/
|
1415
|
+
goog.fx.ScrollableContainer_ = function(element) {
|
1416
|
+
|
1417
|
+
/**
|
1418
|
+
* The targets that lie within this container.
|
1419
|
+
* @type {Array.<goog.fx.ActiveDropTarget_>}
|
1420
|
+
* @private
|
1421
|
+
*/
|
1422
|
+
this.containedTargets_ = [];
|
1423
|
+
|
1424
|
+
/**
|
1425
|
+
* The element that is this container
|
1426
|
+
* @type {Element}
|
1427
|
+
* @private
|
1428
|
+
*/
|
1429
|
+
this.element_ = element;
|
1430
|
+
|
1431
|
+
/**
|
1432
|
+
* The saved scroll left location for calculating deltas.
|
1433
|
+
* @type {number}
|
1434
|
+
* @private
|
1435
|
+
*/
|
1436
|
+
this.savedScrollLeft_ = 0;
|
1437
|
+
|
1438
|
+
/**
|
1439
|
+
* The saved scroll top location for calculating deltas.
|
1440
|
+
* @type {number}
|
1441
|
+
* @private
|
1442
|
+
*/
|
1443
|
+
this.savedScrollTop_ = 0;
|
1444
|
+
|
1445
|
+
/**
|
1446
|
+
* The space occupied by the container.
|
1447
|
+
* @type {goog.math.Box}
|
1448
|
+
* @private
|
1449
|
+
*/
|
1450
|
+
this.box_ = null;
|
1451
|
+
};
|