closure 1.2.701 → 1.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +9 -8
- data/closure-compiler/README +1 -1
- data/closure-compiler/compiler.jar +0 -0
- data/docs/SCRIPT.md +142 -0
- data/docs/closure/Closure/BeanShell.html +335 -0
- data/docs/closure/Closure/Compiler/Compilation.html +636 -0
- data/docs/closure/Closure/Compiler/Error.html +116 -0
- data/docs/closure/Closure/Compiler.html +387 -0
- data/docs/closure/Closure/FileResponse.html +622 -0
- data/docs/closure/Closure/Goog.html +1251 -0
- data/docs/closure/Closure/Middleware.html +304 -0
- data/docs/closure/Closure/Script/NotFound.html +116 -0
- data/docs/closure/Closure/Script/RenderStackOverflow.html +116 -0
- data/docs/closure/Closure/Script.html +1083 -0
- data/docs/closure/Closure/Server.html +439 -0
- data/docs/closure/Closure/ShowExceptions.html +266 -0
- data/docs/closure/Closure/Sources.html +1272 -0
- data/docs/closure/Closure/Templates/Error.html +116 -0
- data/docs/closure/Closure/Templates.html +361 -0
- data/docs/closure/Closure.html +715 -0
- data/docs/closure/_index.html +289 -0
- data/docs/closure/class_list.html +47 -0
- data/docs/closure/css/common.css +1 -0
- data/docs/closure/css/full_list.css +53 -0
- data/docs/closure/css/style.css +320 -0
- data/{closure-library/LICENSE → docs/closure/file.LICENSE.html} +106 -16
- data/docs/closure/file.README.html +79 -0
- data/docs/closure/file_list.html +52 -0
- data/docs/closure/frames.html +13 -0
- data/docs/closure/index.html +79 -0
- data/docs/closure/js/app.js +205 -0
- data/docs/closure/js/full_list.js +150 -0
- data/docs/closure/js/jquery.js +16 -0
- data/docs/closure/method_list.html +486 -0
- data/docs/closure/top-level-namespace.html +103 -0
- data/docs/index.erb +26 -0
- data/externs/chrome_extensions.externs +968 -0
- data/{scripts/externs/jquery_1_4_2.externs → externs/jquery-1.3.2.externs} +39 -170
- data/externs/jquery-1.4.3.externs +1289 -0
- data/externs/jquery-1.4.4.externs +1302 -0
- data/externs/jquery-1.5.externs +1697 -0
- data/externs/jquery.externs +4 -0
- data/lib/closure/beanshell.rb +9 -21
- data/lib/closure/compiler.rb +247 -102
- data/lib/closure/engines.rb +50 -0
- data/lib/closure/goog.rb +122 -68
- data/lib/closure/script.rb +68 -54
- data/lib/closure/server.rb +10 -1
- data/lib/closure/show_exceptions.rb +30 -3
- data/lib/closure/sources.rb +26 -25
- data/lib/closure/templates.rb +79 -124
- data/lib/closure/version.rb +1 -1
- data/lib/closure.rb +64 -43
- data/lib/shim.jar +0 -0
- data/scripts/config.ru +25 -0
- data/scripts/hello/compiler.js.erb +48 -0
- data/scripts/hello/compiler_build.js +5 -0
- data/scripts/hello/compiler_build.map +752 -0
- data/scripts/hello/compiler_debug.js +125 -0
- data/scripts/hello/hello.js +11 -0
- data/scripts/hello/index.erb +11 -0
- data/scripts/hello/legume.js +20 -0
- data/scripts/hello/legume.soy +9 -0
- data/scripts/index.erb +45 -5
- data/scripts/jquery/compiler.js.erb +7 -0
- data/scripts/jquery/compiler_out.js +1 -0
- data/scripts/jquery/index.erb +25 -0
- data/scripts/jquery/jquery_test.js +8 -0
- data/scripts/modules/api.js +11 -0
- data/scripts/modules/api_init.js +8 -0
- data/scripts/modules/app.js +102 -0
- data/scripts/modules/app_init.js +33 -0
- data/scripts/modules/compiler.js.erb +34 -0
- data/scripts/modules/compiler_build.js +6 -0
- data/scripts/modules/compiler_build.map +12077 -0
- data/scripts/modules/compiler_build_api.js +1 -0
- data/scripts/modules/compiler_build_app.js +74 -0
- data/scripts/modules/compiler_build_settings.js +2 -0
- data/scripts/modules/compiler_debug.js +6 -0
- data/scripts/modules/compiler_debug_api.js +11 -0
- data/scripts/modules/compiler_debug_app.js +2870 -0
- data/scripts/modules/compiler_debug_settings.js +42 -0
- data/scripts/modules/index.erb +18 -0
- data/scripts/modules/settings.js +19 -0
- data/scripts/modules/settings_init.js +14 -0
- data/scripts/{demos/rails_ujs.erb → rails/index.erb} +14 -6
- data/scripts/{demos → rails}/rails_ujs.js +0 -40
- data/scripts/svn.erb +228 -0
- data/scripts/welcome.erb +78 -0
- metadata +101 -1507
- data/.gitignore +0 -6
- data/.yardopts +0 -3
- data/closure-library/AUTHORS +0 -12
- data/closure-library/README +0 -6
- data/closure-library/all_tests.html +0 -113
- data/closure-library/alltests.js +0 -16
- data/closure-library/closure/bin/build/closurebuilder.py +0 -257
- data/closure-library/closure/bin/build/depstree.py +0 -186
- data/closure-library/closure/bin/build/depstree_test.py +0 -127
- data/closure-library/closure/bin/build/depswriter.py +0 -197
- data/closure-library/closure/bin/build/jscompiler.py +0 -69
- data/closure-library/closure/bin/build/source.py +0 -86
- data/closure-library/closure/bin/build/source_test.py +0 -57
- data/closure-library/closure/bin/build/treescan.py +0 -78
- data/closure-library/closure/bin/calcdeps.py +0 -570
- data/closure-library/closure/bin/scopify.py +0 -211
- data/closure-library/closure/css/inlay/g-base.css +0 -82
- data/closure-library/closure/css/inlay/g-fixed.css +0 -158
- data/closure-library/closure/css/inlay/g-ratio.css +0 -253
- data/closure-library/closure/goog/array/array.js +0 -1300
- data/closure-library/closure/goog/array/array_test.html +0 -1524
- data/closure-library/closure/goog/asserts/asserts.js +0 -277
- data/closure-library/closure/goog/asserts/asserts_test.html +0 -163
- data/closure-library/closure/goog/async/conditionaldelay.js +0 -238
- data/closure-library/closure/goog/async/conditionaldelay_test.html +0 -227
- data/closure-library/closure/goog/async/delay.js +0 -174
- data/closure-library/closure/goog/async/delay_test.html +0 -148
- data/closure-library/closure/goog/async/throttle.js +0 -189
- data/closure-library/closure/goog/async/throttle_test.html +0 -102
- data/closure-library/closure/goog/base.js +0 -1471
- data/closure-library/closure/goog/base_test.html +0 -1166
- data/closure-library/closure/goog/bootstrap/webworkers.js +0 -37
- data/closure-library/closure/goog/color/alpha.js +0 -436
- data/closure-library/closure/goog/color/alpha_test.html +0 -234
- data/closure-library/closure/goog/color/color.js +0 -757
- data/closure-library/closure/goog/color/color_test.html +0 -645
- data/closure-library/closure/goog/color/names.js +0 -176
- data/closure-library/closure/goog/crypt/arc4.js +0 -141
- data/closure-library/closure/goog/crypt/arc4_test.html +0 -42
- data/closure-library/closure/goog/crypt/base64.js +0 -267
- data/closure-library/closure/goog/crypt/base64_test.html +0 -106
- data/closure-library/closure/goog/crypt/basen.js +0 -242
- data/closure-library/closure/goog/crypt/basen_test.html +0 -167
- data/closure-library/closure/goog/crypt/crypt.js +0 -103
- data/closure-library/closure/goog/crypt/crypt_test.html +0 -68
- data/closure-library/closure/goog/crypt/hash32.js +0 -184
- data/closure-library/closure/goog/crypt/hash32_test.html +0 -287
- data/closure-library/closure/goog/crypt/sha1.js +0 -238
- data/closure-library/closure/goog/crypt/sha1_test.html +0 -47
- data/closure-library/closure/goog/css/autocomplete.css +0 -43
- data/closure-library/closure/goog/css/bubble.css +0 -84
- data/closure-library/closure/goog/css/button.css +0 -38
- data/closure-library/closure/goog/css/charpicker.css +0 -201
- data/closure-library/closure/goog/css/checkbox.css +0 -38
- data/closure-library/closure/goog/css/colormenubutton.css +0 -25
- data/closure-library/closure/goog/css/colorpalette.css +0 -54
- data/closure-library/closure/goog/css/colorpicker-simplegrid.css +0 -50
- data/closure-library/closure/goog/css/combobox.css +0 -57
- data/closure-library/closure/goog/css/common.css +0 -41
- data/closure-library/closure/goog/css/css3button.css +0 -77
- data/closure-library/closure/goog/css/css3menubutton.css +0 -23
- data/closure-library/closure/goog/css/custombutton.css +0 -164
- data/closure-library/closure/goog/css/datepicker.css +0 -148
- data/closure-library/closure/goog/css/dialog.css +0 -72
- data/closure-library/closure/goog/css/dimensionpicker.css +0 -47
- data/closure-library/closure/goog/css/dragdropdetector.css +0 -48
- data/closure-library/closure/goog/css/editor/bubble.css +0 -73
- data/closure-library/closure/goog/css/editor/dialog.css +0 -66
- data/closure-library/closure/goog/css/editor/linkdialog.css +0 -36
- data/closure-library/closure/goog/css/editortoolbar.css +0 -225
- data/closure-library/closure/goog/css/filteredmenu.css +0 -30
- data/closure-library/closure/goog/css/filterobservingmenuitem.css +0 -25
- data/closure-library/closure/goog/css/flatbutton.css +0 -65
- data/closure-library/closure/goog/css/flatmenubutton.css +0 -63
- data/closure-library/closure/goog/css/hovercard.css +0 -51
- data/closure-library/closure/goog/css/hsvapalette.css +0 -231
- data/closure-library/closure/goog/css/hsvpalette.css +0 -179
- data/closure-library/closure/goog/css/imagelessbutton.css +0 -160
- data/closure-library/closure/goog/css/imagelessmenubutton.css +0 -23
- data/closure-library/closure/goog/css/inputdatepicker.css +0 -12
- data/closure-library/closure/goog/css/linkbutton.css +0 -26
- data/closure-library/closure/goog/css/menu.css +0 -27
- data/closure-library/closure/goog/css/menubutton.css +0 -169
- data/closure-library/closure/goog/css/menuitem.css +0 -96
- data/closure-library/closure/goog/css/menuseparator.css +0 -19
- data/closure-library/closure/goog/css/multitestrunner.css +0 -121
- data/closure-library/closure/goog/css/offline.css +0 -147
- data/closure-library/closure/goog/css/palette.css +0 -36
- data/closure-library/closure/goog/css/popupdatepicker.css +0 -17
- data/closure-library/closure/goog/css/roundedpanel.css +0 -29
- data/closure-library/closure/goog/css/roundedtab.css +0 -158
- data/closure-library/closure/goog/css/submenu.css +0 -28
- data/closure-library/closure/goog/css/tab.css +0 -91
- data/closure-library/closure/goog/css/tabbar.css +0 -52
- data/closure-library/closure/goog/css/tablesorter.css +0 -14
- data/closure-library/closure/goog/css/toolbar.css +0 -400
- data/closure-library/closure/goog/css/tooltip.css +0 -14
- data/closure-library/closure/goog/css/tree.css +0 -147
- data/closure-library/closure/goog/css/tristatemenuitem.css +0 -43
- data/closure-library/closure/goog/cssom/cssom.js +0 -447
- data/closure-library/closure/goog/cssom/cssom_test.html +0 -343
- data/closure-library/closure/goog/cssom/cssom_test_import_1.css +0 -11
- data/closure-library/closure/goog/cssom/cssom_test_import_2.css +0 -10
- data/closure-library/closure/goog/cssom/cssom_test_link_1.css +0 -10
- data/closure-library/closure/goog/cssom/iframe/style.js +0 -1020
- data/closure-library/closure/goog/cssom/iframe/style_test.html +0 -391
- data/closure-library/closure/goog/cssom/iframe/style_test_import.css +0 -10
- data/closure-library/closure/goog/datasource/datamanager.js +0 -566
- data/closure-library/closure/goog/datasource/datasource.js +0 -646
- data/closure-library/closure/goog/datasource/datasource_test.html +0 -265
- data/closure-library/closure/goog/datasource/expr.js +0 -544
- data/closure-library/closure/goog/datasource/expr_test.html +0 -97
- data/closure-library/closure/goog/datasource/fastdatanode.js +0 -792
- data/closure-library/closure/goog/datasource/fastdatanode_test.html +0 -254
- data/closure-library/closure/goog/datasource/jsdatasource.js +0 -460
- data/closure-library/closure/goog/datasource/jsondatasource.js +0 -146
- data/closure-library/closure/goog/datasource/jsxmlhttpdatasource.js +0 -191
- data/closure-library/closure/goog/datasource/jsxmlhttpdatasource_test.html +0 -94
- data/closure-library/closure/goog/datasource/xmldatasource.js +0 -407
- data/closure-library/closure/goog/date/date.js +0 -1642
- data/closure-library/closure/goog/date/date_test.html +0 -1293
- data/closure-library/closure/goog/date/datelike.js +0 -27
- data/closure-library/closure/goog/date/daterange.js +0 -398
- data/closure-library/closure/goog/date/daterange_test.html +0 -213
- data/closure-library/closure/goog/date/relative.js +0 -425
- data/closure-library/closure/goog/date/relative_test.html +0 -124
- data/closure-library/closure/goog/date/utcdatetime.js +0 -178
- data/closure-library/closure/goog/date/utcdatetime_test.html +0 -119
- data/closure-library/closure/goog/debug/console.js +0 -138
- data/closure-library/closure/goog/debug/debug.js +0 -452
- data/closure-library/closure/goog/debug/debug_test.html +0 -32
- data/closure-library/closure/goog/debug/debugwindow.js +0 -582
- data/closure-library/closure/goog/debug/devcss/devcss.js +0 -435
- data/closure-library/closure/goog/debug/devcss/devcss_test.html +0 -365
- data/closure-library/closure/goog/debug/devcss/devcssrunner.js +0 -26
- data/closure-library/closure/goog/debug/divconsole.js +0 -141
- data/closure-library/closure/goog/debug/enhanceerror_test.html +0 -138
- data/closure-library/closure/goog/debug/entrypointregistry.js +0 -111
- data/closure-library/closure/goog/debug/entrypointregistry_test.html +0 -63
- data/closure-library/closure/goog/debug/error.js +0 -47
- data/closure-library/closure/goog/debug/error_test.html +0 -85
- data/closure-library/closure/goog/debug/errorhandler.js +0 -234
- data/closure-library/closure/goog/debug/errorhandler_async_test.html +0 -112
- data/closure-library/closure/goog/debug/errorhandler_test.html +0 -186
- data/closure-library/closure/goog/debug/errorhandlerweakdep.js +0 -38
- data/closure-library/closure/goog/debug/errorreporter.js +0 -324
- data/closure-library/closure/goog/debug/errorreporter_test.html +0 -289
- data/closure-library/closure/goog/debug/fancywindow.js +0 -265
- data/closure-library/closure/goog/debug/formatter.js +0 -314
- data/closure-library/closure/goog/debug/gcdiagnostics.js +0 -143
- data/closure-library/closure/goog/debug/logbuffer.js +0 -147
- data/closure-library/closure/goog/debug/logbuffer_test.html +0 -105
- data/closure-library/closure/goog/debug/logger.js +0 -809
- data/closure-library/closure/goog/debug/logger_test.html +0 -208
- data/closure-library/closure/goog/debug/logrecord.js +0 -271
- data/closure-library/closure/goog/debug/reflect.js +0 -163
- data/closure-library/closure/goog/debug/reflect_test.html +0 -81
- data/closure-library/closure/goog/debug/relativetimeprovider.js +0 -83
- data/closure-library/closure/goog/debug/tracer.js +0 -750
- data/closure-library/closure/goog/debug/tracer_test.html +0 -57
- data/closure-library/closure/goog/demos/advancedtooltip.html +0 -78
- data/closure-library/closure/goog/demos/animationqueue.html +0 -149
- data/closure-library/closure/goog/demos/autocomplete-basic.html +0 -56
- data/closure-library/closure/goog/demos/autocompleteremote.html +0 -40
- data/closure-library/closure/goog/demos/autocompleteremotedata.js +0 -18
- data/closure-library/closure/goog/demos/autocompleterichremote.html +0 -137
- data/closure-library/closure/goog/demos/autocompleterichremotedata.js +0 -33
- data/closure-library/closure/goog/demos/bidiinput.html +0 -72
- data/closure-library/closure/goog/demos/bubble.html +0 -250
- data/closure-library/closure/goog/demos/button.html +0 -395
- data/closure-library/closure/goog/demos/charcounter.html +0 -57
- data/closure-library/closure/goog/demos/charpicker.html +0 -64
- data/closure-library/closure/goog/demos/checkbox.html +0 -122
- data/closure-library/closure/goog/demos/color-contrast.html +0 -60
- data/closure-library/closure/goog/demos/colormenubutton.html +0 -213
- data/closure-library/closure/goog/demos/colorpicker.html +0 -43
- data/closure-library/closure/goog/demos/combobox.html +0 -125
- data/closure-library/closure/goog/demos/container.html +0 -670
- data/closure-library/closure/goog/demos/control.html +0 -477
- data/closure-library/closure/goog/demos/css/demo.css +0 -75
- data/closure-library/closure/goog/demos/css/emojipicker.css +0 -36
- data/closure-library/closure/goog/demos/css/emojisprite.css +0 -92
- data/closure-library/closure/goog/demos/css3button.html +0 -166
- data/closure-library/closure/goog/demos/css3menubutton.html +0 -285
- data/closure-library/closure/goog/demos/cssspriteanimation.html +0 -80
- data/closure-library/closure/goog/demos/datepicker.html +0 -183
- data/closure-library/closure/goog/demos/debug.html +0 -119
- data/closure-library/closure/goog/demos/depsgraph.html +0 -221
- data/closure-library/closure/goog/demos/dialog.html +0 -156
- data/closure-library/closure/goog/demos/dimensionpicker.html +0 -108
- data/closure-library/closure/goog/demos/dimensionpicker_rtl.html +0 -123
- data/closure-library/closure/goog/demos/dom_selection.html +0 -88
- data/closure-library/closure/goog/demos/drag.html +0 -191
- data/closure-library/closure/goog/demos/dragdrop.html +0 -263
- data/closure-library/closure/goog/demos/dragdropdetector.html +0 -46
- data/closure-library/closure/goog/demos/dragdropdetector_target.html +0 -17
- data/closure-library/closure/goog/demos/dragger.html +0 -83
- data/closure-library/closure/goog/demos/draglistgroup.html +0 -261
- data/closure-library/closure/goog/demos/drilldownrow.html +0 -78
- data/closure-library/closure/goog/demos/editor/deps.js +0 -20
- data/closure-library/closure/goog/demos/editor/editor.html +0 -139
- data/closure-library/closure/goog/demos/editor/field_basic.html +0 -74
- data/closure-library/closure/goog/demos/editor/helloworld.html +0 -91
- data/closure-library/closure/goog/demos/editor/helloworld.js +0 -81
- data/closure-library/closure/goog/demos/editor/helloworld_test.html +0 -75
- data/closure-library/closure/goog/demos/editor/helloworlddialog.js +0 -163
- data/closure-library/closure/goog/demos/editor/helloworlddialog_test.html +0 -100
- data/closure-library/closure/goog/demos/editor/helloworlddialogplugin.js +0 -110
- data/closure-library/closure/goog/demos/editor/helloworlddialogplugin_test.html +0 -198
- data/closure-library/closure/goog/demos/editor/seamlessfield.html +0 -106
- data/closure-library/closure/goog/demos/effects.html +0 -142
- 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 +0 -192
- data/closure-library/closure/goog/demos/events.html +0 -99
- data/closure-library/closure/goog/demos/eventtarget.html +0 -70
- data/closure-library/closure/goog/demos/filedrophandler.html +0 -63
- data/closure-library/closure/goog/demos/filteredmenu.html +0 -118
- data/closure-library/closure/goog/demos/focushandler.html +0 -58
- data/closure-library/closure/goog/demos/gauge.html +0 -158
- data/closure-library/closure/goog/demos/graphics/advancedcoordinates.html +0 -141
- data/closure-library/closure/goog/demos/graphics/advancedcoordinates2.html +0 -130
- data/closure-library/closure/goog/demos/graphics/basicelements.html +0 -264
- data/closure-library/closure/goog/demos/graphics/events.html +0 -113
- data/closure-library/closure/goog/demos/graphics/modifyelements.html +0 -195
- data/closure-library/closure/goog/demos/graphics/subpixel.html +0 -80
- data/closure-library/closure/goog/demos/graphics/tiger.html +0 -105
- data/closure-library/closure/goog/demos/graphics/tigerdata.js +0 -2840
- data/closure-library/closure/goog/demos/history1.html +0 -132
- data/closure-library/closure/goog/demos/history2.html +0 -100
- data/closure-library/closure/goog/demos/history3.html +0 -106
- data/closure-library/closure/goog/demos/history3js.html +0 -36
- data/closure-library/closure/goog/demos/history_blank.html +0 -25
- data/closure-library/closure/goog/demos/hovercard.html +0 -177
- data/closure-library/closure/goog/demos/hsvapalette.html +0 -55
- data/closure-library/closure/goog/demos/hsvpalette.html +0 -56
- data/closure-library/closure/goog/demos/html5history.html +0 -87
- data/closure-library/closure/goog/demos/imagelessbutton.html +0 -221
- data/closure-library/closure/goog/demos/imagelessmenubutton.html +0 -285
- data/closure-library/closure/goog/demos/imagelessroundedcorner.html +0 -231
- data/closure-library/closure/goog/demos/index.html +0 -19
- data/closure-library/closure/goog/demos/index_nav.html +0 -253
- data/closure-library/closure/goog/demos/index_splash.html +0 -22
- data/closure-library/closure/goog/demos/inline_block_quirks.html +0 -125
- data/closure-library/closure/goog/demos/inline_block_standards.html +0 -126
- data/closure-library/closure/goog/demos/inputdatepicker.html +0 -60
- data/closure-library/closure/goog/demos/inputhandler.html +0 -72
- data/closure-library/closure/goog/demos/jsonprettyprinter.html +0 -80
- data/closure-library/closure/goog/demos/keyboardshortcuts.html +0 -112
- data/closure-library/closure/goog/demos/keyhandler.html +0 -127
- data/closure-library/closure/goog/demos/labelinput.html +0 -42
- data/closure-library/closure/goog/demos/menu.html +0 -220
- data/closure-library/closure/goog/demos/menubutton.html +0 -318
- data/closure-library/closure/goog/demos/mousewheelhandler.html +0 -109
- data/closure-library/closure/goog/demos/offline.html +0 -268
- data/closure-library/closure/goog/demos/onlinehandler.html +0 -77
- data/closure-library/closure/goog/demos/palette.html +0 -302
- data/closure-library/closure/goog/demos/pastehandler.html +0 -54
- data/closure-library/closure/goog/demos/plaintextspellchecker.html +0 -106
- data/closure-library/closure/goog/demos/popup.html +0 -200
- data/closure-library/closure/goog/demos/popupcolorpicker.html +0 -49
- data/closure-library/closure/goog/demos/popupdatepicker.html +0 -53
- data/closure-library/closure/goog/demos/popupemojipicker.html +0 -407
- data/closure-library/closure/goog/demos/popupmenu.html +0 -89
- data/closure-library/closure/goog/demos/progressbar.html +0 -97
- data/closure-library/closure/goog/demos/prompt.html +0 -92
- data/closure-library/closure/goog/demos/quadtree.html +0 -107
- data/closure-library/closure/goog/demos/ratings.html +0 -120
- data/closure-library/closure/goog/demos/richtextspellchecker.html +0 -92
- data/closure-library/closure/goog/demos/roundedpanel.html +0 -139
- data/closure-library/closure/goog/demos/samplecomponent.html +0 -75
- data/closure-library/closure/goog/demos/samplecomponent.js +0 -206
- data/closure-library/closure/goog/demos/scrollfloater.html +0 -117
- data/closure-library/closure/goog/demos/select.html +0 -324
- data/closure-library/closure/goog/demos/selectionmenubutton.html +0 -186
- data/closure-library/closure/goog/demos/serverchart.html +0 -122
- data/closure-library/closure/goog/demos/silverlightclipboardbutton.html +0 -71
- data/closure-library/closure/goog/demos/slider.html +0 -110
- data/closure-library/closure/goog/demos/splitbehavior.html +0 -164
- data/closure-library/closure/goog/demos/splitpane.html +0 -243
- data/closure-library/closure/goog/demos/stopevent.html +0 -171
- data/closure-library/closure/goog/demos/submenus.html +0 -130
- data/closure-library/closure/goog/demos/submenus2.html +0 -150
- data/closure-library/closure/goog/demos/tabbar.html +0 -289
- data/closure-library/closure/goog/demos/tablesorter.html +0 -116
- data/closure-library/closure/goog/demos/tabpane.html +0 -302
- data/closure-library/closure/goog/demos/textarea.html +0 -128
- data/closure-library/closure/goog/demos/timers.html +0 -291
- data/closure-library/closure/goog/demos/toolbar.html +0 -703
- data/closure-library/closure/goog/demos/tooltip.html +0 -91
- data/closure-library/closure/goog/demos/tracer.html +0 -92
- data/closure-library/closure/goog/demos/tree/demo.html +0 -126
- data/closure-library/closure/goog/demos/tree/testdata.js +0 -260
- data/closure-library/closure/goog/demos/tweakui.html +0 -121
- data/closure-library/closure/goog/demos/twothumbslider.html +0 -121
- data/closure-library/closure/goog/demos/useragent.html +0 -173
- data/closure-library/closure/goog/demos/viewportsizemonitor.html +0 -71
- data/closure-library/closure/goog/demos/xpc/blank.html +0 -7
- data/closure-library/closure/goog/demos/xpc/index.html +0 -89
- data/closure-library/closure/goog/demos/xpc/inner.html +0 -58
- data/closure-library/closure/goog/demos/xpc/minimal/blank.html +0 -7
- data/closure-library/closure/goog/demos/xpc/minimal/index.html +0 -105
- data/closure-library/closure/goog/demos/xpc/minimal/inner.html +0 -75
- data/closure-library/closure/goog/demos/xpc/minimal/relay.html +0 -7
- data/closure-library/closure/goog/demos/xpc/relay.html +0 -7
- data/closure-library/closure/goog/demos/xpc/xpcdemo.js +0 -304
- data/closure-library/closure/goog/demos/zippy.html +0 -127
- data/closure-library/closure/goog/deps.js +0 -679
- data/closure-library/closure/goog/disposable/disposable.js +0 -167
- data/closure-library/closure/goog/disposable/disposable_test.html +0 -202
- data/closure-library/closure/goog/dom/a11y.js +0 -438
- data/closure-library/closure/goog/dom/a11y_test.html +0 -86
- data/closure-library/closure/goog/dom/abstractmultirange.js +0 -77
- data/closure-library/closure/goog/dom/abstractrange.js +0 -514
- data/closure-library/closure/goog/dom/abstractrange_test.html +0 -73
- data/closure-library/closure/goog/dom/annotate.js +0 -352
- data/closure-library/closure/goog/dom/annotate_test.html +0 -187
- data/closure-library/closure/goog/dom/browserfeature.js +0 -50
- data/closure-library/closure/goog/dom/browserrange/abstractrange.js +0 -316
- data/closure-library/closure/goog/dom/browserrange/browserrange.js +0 -149
- data/closure-library/closure/goog/dom/browserrange/browserrange_test.html +0 -562
- data/closure-library/closure/goog/dom/browserrange/geckorange.js +0 -82
- data/closure-library/closure/goog/dom/browserrange/ierange.js +0 -970
- data/closure-library/closure/goog/dom/browserrange/operarange.js +0 -83
- data/closure-library/closure/goog/dom/browserrange/w3crange.js +0 -364
- data/closure-library/closure/goog/dom/browserrange/webkitrange.js +0 -112
- data/closure-library/closure/goog/dom/classes.js +0 -233
- data/closure-library/closure/goog/dom/classes_test.html +0 -228
- data/closure-library/closure/goog/dom/controlrange.js +0 -511
- data/closure-library/closure/goog/dom/controlrange_test.html +0 -246
- data/closure-library/closure/goog/dom/dataset.js +0 -90
- data/closure-library/closure/goog/dom/dataset_test.html +0 -104
- data/closure-library/closure/goog/dom/dom.js +0 -2424
- data/closure-library/closure/goog/dom/dom_quirks_test.html +0 -104
- data/closure-library/closure/goog/dom/dom_test.html +0 -103
- data/closure-library/closure/goog/dom/dom_test.js +0 -1129
- data/closure-library/closure/goog/dom/fontsizemonitor.js +0 -159
- data/closure-library/closure/goog/dom/fontsizemonitor_test.html +0 -283
- data/closure-library/closure/goog/dom/forms.js +0 -403
- data/closure-library/closure/goog/dom/forms_test.html +0 -483
- data/closure-library/closure/goog/dom/iframe.js +0 -128
- data/closure-library/closure/goog/dom/iframe_test.html +0 -87
- data/closure-library/closure/goog/dom/iter.js +0 -127
- data/closure-library/closure/goog/dom/iter_test.html +0 -97
- data/closure-library/closure/goog/dom/multirange.js +0 -519
- data/closure-library/closure/goog/dom/multirange_test.html +0 -67
- data/closure-library/closure/goog/dom/nodeiterator.js +0 -85
- data/closure-library/closure/goog/dom/nodeiterator_test.html +0 -49
- data/closure-library/closure/goog/dom/nodeoffset.js +0 -111
- data/closure-library/closure/goog/dom/nodeoffset_test.html +0 -88
- data/closure-library/closure/goog/dom/pattern/abstractpattern.js +0 -60
- data/closure-library/closure/goog/dom/pattern/allchildren.js +0 -73
- data/closure-library/closure/goog/dom/pattern/callback/callback.js +0 -82
- data/closure-library/closure/goog/dom/pattern/callback/counter.js +0 -72
- data/closure-library/closure/goog/dom/pattern/callback/test.js +0 -77
- data/closure-library/closure/goog/dom/pattern/childmatches.js +0 -152
- data/closure-library/closure/goog/dom/pattern/endtag.js +0 -53
- data/closure-library/closure/goog/dom/pattern/fulltag.js +0 -92
- data/closure-library/closure/goog/dom/pattern/matcher.js +0 -150
- data/closure-library/closure/goog/dom/pattern/matcher_test.html +0 -204
- data/closure-library/closure/goog/dom/pattern/nodetype.js +0 -57
- data/closure-library/closure/goog/dom/pattern/pattern.js +0 -93
- data/closure-library/closure/goog/dom/pattern/pattern_test.html +0 -614
- data/closure-library/closure/goog/dom/pattern/repeat.js +0 -188
- data/closure-library/closure/goog/dom/pattern/sequence.js +0 -139
- data/closure-library/closure/goog/dom/pattern/starttag.js +0 -53
- data/closure-library/closure/goog/dom/pattern/tag.js +0 -149
- data/closure-library/closure/goog/dom/pattern/text.js +0 -69
- data/closure-library/closure/goog/dom/range.js +0 -220
- data/closure-library/closure/goog/dom/range_test.html +0 -702
- data/closure-library/closure/goog/dom/rangeendpoint.js +0 -32
- data/closure-library/closure/goog/dom/savedcaretrange.js +0 -203
- data/closure-library/closure/goog/dom/savedcaretrange_test.html +0 -235
- data/closure-library/closure/goog/dom/savedrange.js +0 -74
- data/closure-library/closure/goog/dom/savedrange_test.html +0 -61
- data/closure-library/closure/goog/dom/selection.js +0 -470
- data/closure-library/closure/goog/dom/selection_test.html +0 -329
- data/closure-library/closure/goog/dom/tagiterator.js +0 -365
- data/closure-library/closure/goog/dom/tagiterator_test.html +0 -589
- data/closure-library/closure/goog/dom/tagname.js +0 -121
- data/closure-library/closure/goog/dom/tagname_test.html +0 -37
- data/closure-library/closure/goog/dom/textrange.js +0 -611
- data/closure-library/closure/goog/dom/textrange_test.html +0 -127
- data/closure-library/closure/goog/dom/textrangeiterator.js +0 -246
- data/closure-library/closure/goog/dom/textrangeiterator_test.html +0 -142
- data/closure-library/closure/goog/dom/viewportsizemonitor.js +0 -220
- data/closure-library/closure/goog/dom/viewportsizemonitor_test.html +0 -166
- data/closure-library/closure/goog/dom/xml.js +0 -187
- data/closure-library/closure/goog/dom/xml_test.html +0 -77
- data/closure-library/closure/goog/editor/browserfeature.js +0 -251
- data/closure-library/closure/goog/editor/browserfeature_test.html +0 -124
- data/closure-library/closure/goog/editor/clicktoeditwrapper.js +0 -438
- data/closure-library/closure/goog/editor/clicktoeditwrapper_test.html +0 -137
- data/closure-library/closure/goog/editor/command.js +0 -74
- data/closure-library/closure/goog/editor/defines.js +0 -34
- data/closure-library/closure/goog/editor/field.js +0 -2594
- data/closure-library/closure/goog/editor/field_test.html +0 -1000
- data/closure-library/closure/goog/editor/focus.js +0 -32
- data/closure-library/closure/goog/editor/focus_test.html +0 -66
- data/closure-library/closure/goog/editor/icontent.js +0 -296
- data/closure-library/closure/goog/editor/icontent_test.html +0 -209
- data/closure-library/closure/goog/editor/link.js +0 -279
- data/closure-library/closure/goog/editor/link_test.html +0 -234
- data/closure-library/closure/goog/editor/node.js +0 -435
- data/closure-library/closure/goog/editor/node_test.html +0 -590
- data/closure-library/closure/goog/editor/plugin.js +0 -444
- data/closure-library/closure/goog/editor/plugin_test.html +0 -187
- data/closure-library/closure/goog/editor/plugins/abstractbubbleplugin.js +0 -535
- data/closure-library/closure/goog/editor/plugins/abstractbubbleplugin_test.html +0 -227
- data/closure-library/closure/goog/editor/plugins/abstractdialogplugin.js +0 -336
- data/closure-library/closure/goog/editor/plugins/abstractdialogplugin_test.html +0 -399
- data/closure-library/closure/goog/editor/plugins/abstracttabhandler.js +0 -78
- data/closure-library/closure/goog/editor/plugins/abstracttabhandler_test.html +0 -91
- data/closure-library/closure/goog/editor/plugins/basictextformatter.js +0 -1740
- data/closure-library/closure/goog/editor/plugins/basictextformatter_test.html +0 -1171
- data/closure-library/closure/goog/editor/plugins/blockquote.js +0 -422
- data/closure-library/closure/goog/editor/plugins/blockquote_test.html +0 -149
- data/closure-library/closure/goog/editor/plugins/emoticons.js +0 -83
- data/closure-library/closure/goog/editor/plugins/emoticons_test.html +0 -67
- data/closure-library/closure/goog/editor/plugins/enterhandler.js +0 -730
- data/closure-library/closure/goog/editor/plugins/enterhandler_test.html +0 -739
- data/closure-library/closure/goog/editor/plugins/headerformatter.js +0 -95
- data/closure-library/closure/goog/editor/plugins/headerformatter_test.html +0 -100
- data/closure-library/closure/goog/editor/plugins/linkbubble.js +0 -458
- data/closure-library/closure/goog/editor/plugins/linkbubble_test.html +0 -309
- data/closure-library/closure/goog/editor/plugins/linkdialogplugin.js +0 -222
- data/closure-library/closure/goog/editor/plugins/linkdialogplugin_test.html +0 -370
- data/closure-library/closure/goog/editor/plugins/listtabhandler.js +0 -66
- data/closure-library/closure/goog/editor/plugins/listtabhandler_test.html +0 -177
- data/closure-library/closure/goog/editor/plugins/loremipsum.js +0 -186
- data/closure-library/closure/goog/editor/plugins/loremipsum_test.html +0 -169
- data/closure-library/closure/goog/editor/plugins/removeformatting.js +0 -772
- data/closure-library/closure/goog/editor/plugins/removeformatting_test.html +0 -920
- data/closure-library/closure/goog/editor/plugins/spacestabhandler.js +0 -93
- data/closure-library/closure/goog/editor/plugins/spacestabhandler_test.html +0 -186
- data/closure-library/closure/goog/editor/plugins/tableeditor.js +0 -496
- data/closure-library/closure/goog/editor/plugins/tableeditor_test.html +0 -299
- data/closure-library/closure/goog/editor/plugins/tagonenterhandler.js +0 -741
- data/closure-library/closure/goog/editor/plugins/tagonenterhandler_test.html +0 -481
- data/closure-library/closure/goog/editor/plugins/undoredo.js +0 -1014
- data/closure-library/closure/goog/editor/plugins/undoredo_test.html +0 -525
- data/closure-library/closure/goog/editor/plugins/undoredomanager.js +0 -337
- data/closure-library/closure/goog/editor/plugins/undoredomanager_test.html +0 -394
- data/closure-library/closure/goog/editor/plugins/undoredostate.js +0 -84
- data/closure-library/closure/goog/editor/plugins/undoredostate_test.html +0 -44
- data/closure-library/closure/goog/editor/range.js +0 -602
- data/closure-library/closure/goog/editor/range_test.html +0 -880
- data/closure-library/closure/goog/editor/seamlessfield.js +0 -720
- data/closure-library/closure/goog/editor/seamlessfield_quirks_test.html +0 -30
- data/closure-library/closure/goog/editor/seamlessfield_test.html +0 -33
- data/closure-library/closure/goog/editor/seamlessfield_test.js +0 -392
- data/closure-library/closure/goog/editor/style.js +0 -222
- data/closure-library/closure/goog/editor/style_test.html +0 -177
- data/closure-library/closure/goog/editor/table.js +0 -566
- data/closure-library/closure/goog/editor/table_test.html +0 -522
- data/closure-library/closure/goog/events/actioneventwrapper.js +0 -131
- data/closure-library/closure/goog/events/actioneventwrapper_test.html +0 -176
- data/closure-library/closure/goog/events/actionhandler.js +0 -189
- data/closure-library/closure/goog/events/actionhandler_test.html +0 -82
- data/closure-library/closure/goog/events/browserevent.js +0 -412
- data/closure-library/closure/goog/events/browserevent_test.html +0 -145
- data/closure-library/closure/goog/events/browserfeature.js +0 -43
- data/closure-library/closure/goog/events/event.js +0 -123
- data/closure-library/closure/goog/events/event_test.html +0 -70
- data/closure-library/closure/goog/events/eventhandler.js +0 -348
- data/closure-library/closure/goog/events/eventhandler_test.html +0 -230
- data/closure-library/closure/goog/events/events.js +0 -1101
- data/closure-library/closure/goog/events/events_test.html +0 -362
- data/closure-library/closure/goog/events/eventtarget.js +0 -197
- data/closure-library/closure/goog/events/eventtarget_test.html +0 -423
- data/closure-library/closure/goog/events/eventtype.js +0 -107
- data/closure-library/closure/goog/events/eventwrapper.js +0 -67
- data/closure-library/closure/goog/events/filedrophandler.js +0 -224
- data/closure-library/closure/goog/events/filedrophandler_test.html +0 -258
- data/closure-library/closure/goog/events/focushandler.js +0 -111
- data/closure-library/closure/goog/events/imehandler.js +0 -365
- data/closure-library/closure/goog/events/imehandler_test.html +0 -271
- data/closure-library/closure/goog/events/inputhandler.js +0 -218
- data/closure-library/closure/goog/events/keycodes.js +0 -314
- data/closure-library/closure/goog/events/keycodes_test.html +0 -72
- data/closure-library/closure/goog/events/keyhandler.js +0 -522
- data/closure-library/closure/goog/events/keyhandler_test.html +0 -621
- data/closure-library/closure/goog/events/keynames.js +0 -124
- data/closure-library/closure/goog/events/listener.js +0 -160
- data/closure-library/closure/goog/events/mousewheelhandler.js +0 -280
- data/closure-library/closure/goog/events/mousewheelhandler_test.html +0 -331
- data/closure-library/closure/goog/events/onlinehandler.js +0 -176
- data/closure-library/closure/goog/events/onlinelistener_test.html +0 -214
- data/closure-library/closure/goog/events/pastehandler.js +0 -444
- data/closure-library/closure/goog/events/pastehandler_test.html +0 -354
- data/closure-library/closure/goog/events/pools.js +0 -342
- data/closure-library/closure/goog/format/emailaddress.js +0 -329
- data/closure-library/closure/goog/format/emailaddress_test.html +0 -179
- data/closure-library/closure/goog/format/format.js +0 -451
- data/closure-library/closure/goog/format/format_test.html +0 -257
- data/closure-library/closure/goog/format/htmlprettyprinter.js +0 -406
- data/closure-library/closure/goog/format/htmlprettyprinter_test.html +0 -205
- data/closure-library/closure/goog/format/jsonprettyprinter.js +0 -405
- data/closure-library/closure/goog/format/jsonprettyprinter_test.html +0 -111
- data/closure-library/closure/goog/fs/entry.js +0 -406
- data/closure-library/closure/goog/fs/error.js +0 -103
- data/closure-library/closure/goog/fs/filesaver.js +0 -214
- data/closure-library/closure/goog/fs/filesystem.js +0 -59
- data/closure-library/closure/goog/fs/filewriter.js +0 -106
- data/closure-library/closure/goog/fs/fs.js +0 -183
- data/closure-library/closure/goog/fs/fs_test.html +0 -270
- data/closure-library/closure/goog/functions/functions.js +0 -219
- data/closure-library/closure/goog/functions/functions_test.html +0 -198
- data/closure-library/closure/goog/fx/abstractdragdrop.js +0 -1451
- data/closure-library/closure/goog/fx/abstractdragdrop_test.html +0 -430
- data/closure-library/closure/goog/fx/animation.js +0 -621
- data/closure-library/closure/goog/fx/animationqueue.js +0 -348
- data/closure-library/closure/goog/fx/cssspriteanimation.js +0 -112
- data/closure-library/closure/goog/fx/cssspriteanimation_test.html +0 -125
- data/closure-library/closure/goog/fx/dom.js +0 -610
- data/closure-library/closure/goog/fx/dragdrop.js +0 -49
- data/closure-library/closure/goog/fx/dragdropgroup.js +0 -107
- data/closure-library/closure/goog/fx/dragdropgroup_test.html +0 -234
- data/closure-library/closure/goog/fx/dragger.js +0 -731
- data/closure-library/closure/goog/fx/dragger_test.html +0 -415
- data/closure-library/closure/goog/fx/draglistgroup.js +0 -1159
- data/closure-library/closure/goog/fx/draglistgroup_test.html +0 -231
- data/closure-library/closure/goog/fx/dragscrollsupport.js +0 -274
- data/closure-library/closure/goog/fx/dragscrollsupport_test.html +0 -253
- data/closure-library/closure/goog/fx/easing.js +0 -50
- data/closure-library/closure/goog/fx/fx.js +0 -30
- data/closure-library/closure/goog/fx/fx_test.html +0 -157
- data/closure-library/closure/goog/gears/basestore.js +0 -523
- data/closure-library/closure/goog/gears/basestore_test.html +0 -247
- data/closure-library/closure/goog/gears/database.js +0 -935
- data/closure-library/closure/goog/gears/database_test.html +0 -699
- data/closure-library/closure/goog/gears/fakeworkerpool.js +0 -252
- data/closure-library/closure/goog/gears/fakeworkerpool_test.html +0 -188
- data/closure-library/closure/goog/gears/gears.js +0 -228
- data/closure-library/closure/goog/gears/gears_test.html +0 -78
- data/closure-library/closure/goog/gears/httprequest.js +0 -77
- data/closure-library/closure/goog/gears/loggerclient.js +0 -131
- data/closure-library/closure/goog/gears/loggerclient_test.html +0 -171
- data/closure-library/closure/goog/gears/loggerserver.js +0 -158
- data/closure-library/closure/goog/gears/loggerserver_test.html +0 -118
- data/closure-library/closure/goog/gears/logstore.js +0 -479
- data/closure-library/closure/goog/gears/logstore_test.html +0 -600
- data/closure-library/closure/goog/gears/managedresourcestore.js +0 -553
- data/closure-library/closure/goog/gears/managedresourcestore_test.html +0 -453
- data/closure-library/closure/goog/gears/multipartformdata.js +0 -203
- data/closure-library/closure/goog/gears/multipartformdata_test.html +0 -220
- data/closure-library/closure/goog/gears/statustype.js +0 -37
- data/closure-library/closure/goog/gears/urlcapture.js +0 -370
- data/closure-library/closure/goog/gears/urlcapture_test.html +0 -392
- data/closure-library/closure/goog/gears/worker.js +0 -201
- data/closure-library/closure/goog/gears/workerchannel.js +0 -205
- data/closure-library/closure/goog/gears/workerchannel_test.html +0 -207
- data/closure-library/closure/goog/gears/workerpool.js +0 -241
- data/closure-library/closure/goog/gears/workerpool_test.html +0 -203
- data/closure-library/closure/goog/graphics/abstractgraphics.js +0 -439
- data/closure-library/closure/goog/graphics/affinetransform.js +0 -497
- data/closure-library/closure/goog/graphics/affinetransform_test.html +0 -316
- data/closure-library/closure/goog/graphics/canvaselement.js +0 -776
- data/closure-library/closure/goog/graphics/canvasgraphics.js +0 -632
- data/closure-library/closure/goog/graphics/element.js +0 -145
- data/closure-library/closure/goog/graphics/ellipseelement.js +0 -59
- data/closure-library/closure/goog/graphics/ext/coordinates.js +0 -158
- data/closure-library/closure/goog/graphics/ext/coordinates_test.html +0 -74
- data/closure-library/closure/goog/graphics/ext/element.js +0 -970
- data/closure-library/closure/goog/graphics/ext/element_test.html +0 -144
- data/closure-library/closure/goog/graphics/ext/ellipse.js +0 -58
- data/closure-library/closure/goog/graphics/ext/ext.js +0 -29
- data/closure-library/closure/goog/graphics/ext/graphics.js +0 -209
- data/closure-library/closure/goog/graphics/ext/group.js +0 -213
- data/closure-library/closure/goog/graphics/ext/image.js +0 -62
- data/closure-library/closure/goog/graphics/ext/path.js +0 -140
- data/closure-library/closure/goog/graphics/ext/path_test.html +0 -46
- data/closure-library/closure/goog/graphics/ext/rectangle.js +0 -53
- data/closure-library/closure/goog/graphics/ext/shape.js +0 -144
- data/closure-library/closure/goog/graphics/ext/strokeandfillelement.js +0 -69
- data/closure-library/closure/goog/graphics/fill.js +0 -29
- data/closure-library/closure/goog/graphics/font.js +0 -59
- data/closure-library/closure/goog/graphics/graphics.js +0 -124
- data/closure-library/closure/goog/graphics/groupelement.js +0 -54
- data/closure-library/closure/goog/graphics/imageelement.js +0 -67
- data/closure-library/closure/goog/graphics/lineargradient.js +0 -131
- data/closure-library/closure/goog/graphics/path.js +0 -508
- data/closure-library/closure/goog/graphics/path_test.html +0 -359
- data/closure-library/closure/goog/graphics/pathelement.js +0 -50
- data/closure-library/closure/goog/graphics/paths.js +0 -86
- data/closure-library/closure/goog/graphics/paths_test.html +0 -97
- data/closure-library/closure/goog/graphics/rectelement.js +0 -59
- data/closure-library/closure/goog/graphics/solidfill.js +0 -70
- data/closure-library/closure/goog/graphics/stroke.js +0 -63
- data/closure-library/closure/goog/graphics/strokeandfillelement.js +0 -110
- data/closure-library/closure/goog/graphics/svgelement.js +0 -262
- data/closure-library/closure/goog/graphics/svggraphics.js +0 -813
- data/closure-library/closure/goog/graphics/textelement.js +0 -51
- data/closure-library/closure/goog/graphics/vmlelement.js +0 -380
- data/closure-library/closure/goog/graphics/vmlgraphics.js +0 -863
- data/closure-library/closure/goog/history/event.js +0 -54
- data/closure-library/closure/goog/history/eventtype.js +0 -30
- data/closure-library/closure/goog/history/history.js +0 -979
- data/closure-library/closure/goog/history/html5history.js +0 -303
- data/closure-library/closure/goog/history/html5history_test.html +0 -163
- data/closure-library/closure/goog/i18n/bidi.js +0 -772
- data/closure-library/closure/goog/i18n/bidi_test.html +0 -414
- data/closure-library/closure/goog/i18n/bidiformatter.js +0 -488
- data/closure-library/closure/goog/i18n/bidiformatter_test.html +0 -343
- data/closure-library/closure/goog/i18n/charlistdecompressor.js +0 -157
- data/closure-library/closure/goog/i18n/charlistdecompressor_test.html +0 -65
- data/closure-library/closure/goog/i18n/charpickerdata.js +0 -3185
- data/closure-library/closure/goog/i18n/currency.js +0 -385
- data/closure-library/closure/goog/i18n/currency_test.html +0 -202
- data/closure-library/closure/goog/i18n/currencycodemap.js +0 -210
- data/closure-library/closure/goog/i18n/datetimeformat.js +0 -636
- data/closure-library/closure/goog/i18n/datetimeformat_test.html +0 -436
- data/closure-library/closure/goog/i18n/datetimeparse.js +0 -1111
- data/closure-library/closure/goog/i18n/datetimeparse_test.html +0 -796
- data/closure-library/closure/goog/i18n/datetimepatterns.js +0 -1586
- data/closure-library/closure/goog/i18n/datetimepatternsext.js +0 -7386
- data/closure-library/closure/goog/i18n/datetimesymbols.js +0 -3350
- data/closure-library/closure/goog/i18n/datetimesymbolsext.js +0 -12938
- data/closure-library/closure/goog/i18n/graphemebreak.js +0 -181
- data/closure-library/closure/goog/i18n/graphemebreak_test.html +0 -72
- data/closure-library/closure/goog/i18n/messageformat.js +0 -556
- data/closure-library/closure/goog/i18n/messageformat_test.html +0 -334
- data/closure-library/closure/goog/i18n/mime.js +0 -100
- data/closure-library/closure/goog/i18n/mime_test.html +0 -51
- data/closure-library/closure/goog/i18n/numberformat.js +0 -763
- data/closure-library/closure/goog/i18n/numberformat_test.html +0 -605
- data/closure-library/closure/goog/i18n/numberformatsymbols.js +0 -10358
- data/closure-library/closure/goog/i18n/pluralrules.js +0 -695
- data/closure-library/closure/goog/i18n/timezone.js +0 -341
- data/closure-library/closure/goog/i18n/timezone_test.html +0 -163
- data/closure-library/closure/goog/i18n/uchar.js +0 -1160
- data/closure-library/closure/goog/i18n/uchar_test.html +0 -72
- 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 +0 -627
- data/closure-library/closure/goog/iter/iter_test.html +0 -443
- data/closure-library/closure/goog/json/json.js +0 -302
- data/closure-library/closure/goog/json/json_test.html +0 -501
- data/closure-library/closure/goog/locale/countries.js +0 -288
- data/closure-library/closure/goog/locale/countrylanguagenames_test.html +0 -233
- data/closure-library/closure/goog/locale/defaultlocalenameconstants.js +0 -847
- data/closure-library/closure/goog/locale/genericfontnames.js +0 -73
- data/closure-library/closure/goog/locale/genericfontnames_test.html +0 -97
- data/closure-library/closure/goog/locale/genericfontnamesdata.js +0 -328
- data/closure-library/closure/goog/locale/locale.js +0 -397
- data/closure-library/closure/goog/locale/nativenameconstants.js +0 -1354
- data/closure-library/closure/goog/locale/scriptToLanguages.js +0 -482
- data/closure-library/closure/goog/locale/timezonedetection.js +0 -117
- data/closure-library/closure/goog/locale/timezonedetection_test.html +0 -130
- data/closure-library/closure/goog/locale/timezonefingerprint.js +0 -250
- data/closure-library/closure/goog/locale/timezonelist.js +0 -129
- data/closure-library/closure/goog/locale/timezonelist_test.html +0 -165
- data/closure-library/closure/goog/math/bezier.js +0 -244
- data/closure-library/closure/goog/math/bezier_test.html +0 -70
- data/closure-library/closure/goog/math/box.js +0 -236
- data/closure-library/closure/goog/math/box_test.html +0 -139
- data/closure-library/closure/goog/math/coordinate.js +0 -136
- data/closure-library/closure/goog/math/coordinate3.js +0 -168
- data/closure-library/closure/goog/math/coordinate3_test.html +0 -208
- data/closure-library/closure/goog/math/coordinate_test.html +0 -92
- data/closure-library/closure/goog/math/integer.js +0 -736
- data/closure-library/closure/goog/math/integer_test.html +0 -1653
- data/closure-library/closure/goog/math/line.js +0 -177
- data/closure-library/closure/goog/math/line_test.html +0 -62
- data/closure-library/closure/goog/math/long.js +0 -801
- data/closure-library/closure/goog/math/long_test.html +0 -1571
- data/closure-library/closure/goog/math/math.js +0 -355
- data/closure-library/closure/goog/math/math_test.html +0 -254
- data/closure-library/closure/goog/math/matrix.js +0 -669
- data/closure-library/closure/goog/math/matrix_test.html +0 -427
- data/closure-library/closure/goog/math/range.js +0 -146
- data/closure-library/closure/goog/math/range_test.html +0 -103
- data/closure-library/closure/goog/math/rangeset.js +0 -368
- data/closure-library/closure/goog/math/rangeset_test.html +0 -619
- data/closure-library/closure/goog/math/rect.js +0 -340
- data/closure-library/closure/goog/math/rect_test.html +0 -315
- data/closure-library/closure/goog/math/size.js +0 -201
- data/closure-library/closure/goog/math/size_test.html +0 -174
- data/closure-library/closure/goog/math/vec2.js +0 -255
- data/closure-library/closure/goog/math/vec2_test.html +0 -203
- data/closure-library/closure/goog/math/vec3.js +0 -308
- data/closure-library/closure/goog/math/vec3_test.html +0 -231
- data/closure-library/closure/goog/memoize/memoize.js +0 -98
- data/closure-library/closure/goog/memoize/memoize_test.html +0 -157
- data/closure-library/closure/goog/messaging/abstractchannel.js +0 -209
- data/closure-library/closure/goog/messaging/abstractchannel_test.html +0 -90
- data/closure-library/closure/goog/messaging/bufferedchannel.js +0 -277
- data/closure-library/closure/goog/messaging/bufferedchannel_test.html +0 -205
- data/closure-library/closure/goog/messaging/deferredchannel.js +0 -79
- data/closure-library/closure/goog/messaging/deferredchannel_test.html +0 -107
- data/closure-library/closure/goog/messaging/loggerclient.js +0 -131
- data/closure-library/closure/goog/messaging/loggerclient_test.html +0 -102
- data/closure-library/closure/goog/messaging/loggerserver.js +0 -94
- data/closure-library/closure/goog/messaging/loggerserver_test.html +0 -101
- data/closure-library/closure/goog/messaging/messagechannel.js +0 -115
- data/closure-library/closure/goog/messaging/messaging.js +0 -34
- data/closure-library/closure/goog/messaging/messaging_test.html +0 -42
- data/closure-library/closure/goog/messaging/multichannel.js +0 -303
- data/closure-library/closure/goog/messaging/multichannel_test.html +0 -122
- data/closure-library/closure/goog/messaging/portcaller.js +0 -150
- data/closure-library/closure/goog/messaging/portcaller_test.html +0 -66
- data/closure-library/closure/goog/messaging/portchannel.js +0 -341
- data/closure-library/closure/goog/messaging/portchannel_test.html +0 -359
- data/closure-library/closure/goog/messaging/portnetwork.js +0 -78
- data/closure-library/closure/goog/messaging/portnetwork_test.html +0 -64
- data/closure-library/closure/goog/messaging/portoperator.js +0 -196
- data/closure-library/closure/goog/messaging/portoperator_test.html +0 -112
- data/closure-library/closure/goog/messaging/testdata/portchannel_inner.html +0 -28
- data/closure-library/closure/goog/messaging/testdata/portchannel_worker.js +0 -37
- data/closure-library/closure/goog/messaging/testdata/portnetwork_inner.html +0 -35
- data/closure-library/closure/goog/messaging/testdata/portnetwork_worker1.js +0 -33
- data/closure-library/closure/goog/messaging/testdata/portnetwork_worker2.js +0 -33
- data/closure-library/closure/goog/module/abstractmoduleloader.js +0 -46
- data/closure-library/closure/goog/module/basemodule.js +0 -45
- data/closure-library/closure/goog/module/basemoduleloader.js +0 -210
- data/closure-library/closure/goog/module/loader.js +0 -269
- data/closure-library/closure/goog/module/module.js +0 -166
- data/closure-library/closure/goog/module/moduleinfo.js +0 -336
- data/closure-library/closure/goog/module/moduleinfo_test.html +0 -109
- data/closure-library/closure/goog/module/moduleloadcallback.js +0 -84
- data/closure-library/closure/goog/module/moduleloadcallback_test.html +0 -57
- data/closure-library/closure/goog/module/moduleloader.js +0 -250
- data/closure-library/closure/goog/module/moduleloader_test.html +0 -244
- data/closure-library/closure/goog/module/modulemanager.js +0 -1008
- data/closure-library/closure/goog/module/modulemanager_test.html +0 -1240
- data/closure-library/closure/goog/module/testdata/modA_1.js +0 -22
- data/closure-library/closure/goog/module/testdata/modA_2.js +0 -24
- data/closure-library/closure/goog/module/testdata/modB_1.js +0 -24
- data/closure-library/closure/goog/net/browserchannel.js +0 -2441
- data/closure-library/closure/goog/net/browserchannel_test.html +0 -1176
- data/closure-library/closure/goog/net/browsertestchannel.js +0 -552
- data/closure-library/closure/goog/net/bulkloader.js +0 -174
- data/closure-library/closure/goog/net/bulkloader_test.html +0 -232
- data/closure-library/closure/goog/net/bulkloaderhelper.js +0 -129
- data/closure-library/closure/goog/net/channeldebug.js +0 -288
- data/closure-library/closure/goog/net/channelrequest.js +0 -1125
- data/closure-library/closure/goog/net/channelrequest_test.html +0 -158
- data/closure-library/closure/goog/net/cookies.js +0 -401
- data/closure-library/closure/goog/net/cookies_test.html +0 -255
- data/closure-library/closure/goog/net/crossdomainrpc.js +0 -848
- data/closure-library/closure/goog/net/crossdomainrpc_test.gif +0 -0
- data/closure-library/closure/goog/net/crossdomainrpc_test.html +0 -120
- data/closure-library/closure/goog/net/crossdomainrpc_test_response.html +0 -59
- data/closure-library/closure/goog/net/errorcode.js +0 -130
- data/closure-library/closure/goog/net/eventtype.js +0 -37
- data/closure-library/closure/goog/net/iframe_xhr_test.html +0 -142
- data/closure-library/closure/goog/net/iframe_xhr_test_response.html +0 -17
- data/closure-library/closure/goog/net/iframeio.js +0 -1342
- data/closure-library/closure/goog/net/iframeio_different_base_test.data +0 -2
- data/closure-library/closure/goog/net/iframeio_different_base_test.html +0 -42
- data/closure-library/closure/goog/net/iframeio_test.html +0 -368
- data/closure-library/closure/goog/net/iframeloadmonitor.js +0 -199
- data/closure-library/closure/goog/net/iframeloadmonitor_test.html +0 -113
- data/closure-library/closure/goog/net/iframeloadmonitor_test_frame.html +0 -12
- data/closure-library/closure/goog/net/iframeloadmonitor_test_frame2.html +0 -12
- data/closure-library/closure/goog/net/iframeloadmonitor_test_frame3.html +0 -12
- data/closure-library/closure/goog/net/imageloader.js +0 -237
- data/closure-library/closure/goog/net/imageloader_test.html +0 -200
- 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 +0 -379
- data/closure-library/closure/goog/net/jsonp_test.html +0 -328
- data/closure-library/closure/goog/net/mockiframeio.js +0 -318
- data/closure-library/closure/goog/net/mockxhrlite.js +0 -34
- data/closure-library/closure/goog/net/mockxhrlite_test.html +0 -109
- data/closure-library/closure/goog/net/multiiframeloadmonitor.js +0 -116
- data/closure-library/closure/goog/net/multiiframeloadmonitor_test.html +0 -172
- data/closure-library/closure/goog/net/networktester.js +0 -383
- data/closure-library/closure/goog/net/networktester_test.html +0 -227
- data/closure-library/closure/goog/net/tmpnetwork.js +0 -168
- data/closure-library/closure/goog/net/wrapperxmlhttpfactory.js +0 -68
- data/closure-library/closure/goog/net/xhrio.js +0 -1093
- data/closure-library/closure/goog/net/xhrio_test.html +0 -603
- data/closure-library/closure/goog/net/xhriopool.js +0 -87
- data/closure-library/closure/goog/net/xhrlite.js +0 -119
- data/closure-library/closure/goog/net/xhrlite_test.html +0 -156
- data/closure-library/closure/goog/net/xhrlitepool.js +0 -37
- data/closure-library/closure/goog/net/xhrmanager.js +0 -763
- data/closure-library/closure/goog/net/xhrmonitor.js +0 -254
- data/closure-library/closure/goog/net/xhrmonitor_test.html +0 -199
- data/closure-library/closure/goog/net/xmlhttp.js +0 -215
- data/closure-library/closure/goog/net/xmlhttpfactory.js +0 -64
- data/closure-library/closure/goog/net/xpc/crosspagechannel.js +0 -624
- data/closure-library/closure/goog/net/xpc/crosspagechannel_test.html +0 -422
- data/closure-library/closure/goog/net/xpc/frameelementmethodtransport.js +0 -251
- data/closure-library/closure/goog/net/xpc/iframepollingtransport.js +0 -822
- data/closure-library/closure/goog/net/xpc/iframerelaytransport.js +0 -288
- data/closure-library/closure/goog/net/xpc/nativemessagingtransport.js +0 -280
- data/closure-library/closure/goog/net/xpc/nativemessagingtransport_test.html +0 -164
- data/closure-library/closure/goog/net/xpc/nixtransport.js +0 -454
- data/closure-library/closure/goog/net/xpc/relay.js +0 -72
- data/closure-library/closure/goog/net/xpc/testdata/inner_peer.html +0 -106
- data/closure-library/closure/goog/net/xpc/transport.js +0 -104
- data/closure-library/closure/goog/net/xpc/xpc.js +0 -238
- data/closure-library/closure/goog/object/object.js +0 -553
- data/closure-library/closure/goog/object/object_test.html +0 -376
- data/closure-library/closure/goog/positioning/absoluteposition.js +0 -73
- data/closure-library/closure/goog/positioning/abstractposition.js +0 -47
- data/closure-library/closure/goog/positioning/anchoredposition.js +0 -78
- data/closure-library/closure/goog/positioning/anchoredviewportposition.js +0 -126
- data/closure-library/closure/goog/positioning/anchoredviewportposition_test.html +0 -117
- data/closure-library/closure/goog/positioning/anchoredviewportposition_test_iframe.html +0 -35
- data/closure-library/closure/goog/positioning/clientposition.js +0 -75
- data/closure-library/closure/goog/positioning/menuanchoredposition.js +0 -97
- data/closure-library/closure/goog/positioning/positioning.js +0 -476
- data/closure-library/closure/goog/positioning/positioning_test.html +0 -877
- data/closure-library/closure/goog/positioning/positioning_test_iframe1.html +0 -16
- data/closure-library/closure/goog/positioning/positioning_test_iframe2.html +0 -13
- data/closure-library/closure/goog/positioning/positioning_test_quirk.html +0 -9
- data/closure-library/closure/goog/positioning/positioning_test_standard.html +0 -13
- data/closure-library/closure/goog/positioning/viewportclientposition.js +0 -102
- data/closure-library/closure/goog/positioning/viewportclientposition_test.html +0 -172
- data/closure-library/closure/goog/positioning/viewportposition.js +0 -63
- data/closure-library/closure/goog/proto/proto.js +0 -43
- data/closure-library/closure/goog/proto/serializer.js +0 -68
- data/closure-library/closure/goog/proto/serializer_test.html +0 -43
- data/closure-library/closure/goog/proto2/descriptor.js +0 -198
- data/closure-library/closure/goog/proto2/descriptor_test.html +0 -60
- data/closure-library/closure/goog/proto2/fielddescriptor.js +0 -288
- data/closure-library/closure/goog/proto2/fielddescriptor_test.html +0 -124
- data/closure-library/closure/goog/proto2/lazydeserializer.js +0 -69
- data/closure-library/closure/goog/proto2/message.js +0 -726
- data/closure-library/closure/goog/proto2/message_test.html +0 -356
- data/closure-library/closure/goog/proto2/objectserializer.js +0 -159
- data/closure-library/closure/goog/proto2/objectserializer_test.html +0 -423
- data/closure-library/closure/goog/proto2/package_test.pb.js +0 -164
- data/closure-library/closure/goog/proto2/pbliteserializer.js +0 -150
- data/closure-library/closure/goog/proto2/pbliteserializer_test.html +0 -267
- data/closure-library/closure/goog/proto2/proto_test.html +0 -693
- data/closure-library/closure/goog/proto2/serializer.js +0 -148
- data/closure-library/closure/goog/proto2/test.pb.js +0 -2820
- data/closure-library/closure/goog/proto2/util.js +0 -54
- data/closure-library/closure/goog/pubsub/pubsub.js +0 -326
- data/closure-library/closure/goog/pubsub/pubsub_test.html +0 -635
- data/closure-library/closure/goog/reflect/reflect.js +0 -50
- data/closure-library/closure/goog/spell/spellcheck.js +0 -474
- data/closure-library/closure/goog/spell/spellcheck_test.html +0 -112
- data/closure-library/closure/goog/string/path.js +0 -100
- data/closure-library/closure/goog/string/path_test.html +0 -59
- data/closure-library/closure/goog/string/string.js +0 -1207
- data/closure-library/closure/goog/string/string_test.html +0 -877
- data/closure-library/closure/goog/string/stringbuffer.js +0 -167
- data/closure-library/closure/goog/string/stringbuffer_test.html +0 -101
- data/closure-library/closure/goog/string/stringformat.js +0 -247
- data/closure-library/closure/goog/string/stringformat_test.html +0 -211
- data/closure-library/closure/goog/structs/avltree.js +0 -769
- data/closure-library/closure/goog/structs/avltree_test.html +0 -241
- data/closure-library/closure/goog/structs/circularbuffer.js +0 -219
- data/closure-library/closure/goog/structs/circularbuffer_test.html +0 -105
- data/closure-library/closure/goog/structs/heap.js +0 -332
- data/closure-library/closure/goog/structs/heap_test.html +0 -220
- data/closure-library/closure/goog/structs/inversionmap.js +0 -159
- data/closure-library/closure/goog/structs/inversionmap_test.html +0 -157
- data/closure-library/closure/goog/structs/linkedmap.js +0 -472
- data/closure-library/closure/goog/structs/linkedmap_test.html +0 -300
- data/closure-library/closure/goog/structs/map.js +0 -446
- data/closure-library/closure/goog/structs/map_test.html +0 -430
- data/closure-library/closure/goog/structs/node.js +0 -74
- data/closure-library/closure/goog/structs/pool.js +0 -344
- data/closure-library/closure/goog/structs/pool_test.html +0 -265
- data/closure-library/closure/goog/structs/prioritypool.js +0 -147
- data/closure-library/closure/goog/structs/prioritypool_test.html +0 -478
- data/closure-library/closure/goog/structs/priorityqueue.js +0 -64
- data/closure-library/closure/goog/structs/priorityqueue_test.html +0 -179
- data/closure-library/closure/goog/structs/quadtree.js +0 -571
- data/closure-library/closure/goog/structs/quadtree_test.html +0 -179
- data/closure-library/closure/goog/structs/queue.js +0 -157
- data/closure-library/closure/goog/structs/queue_test.html +0 -140
- data/closure-library/closure/goog/structs/set.js +0 -251
- data/closure-library/closure/goog/structs/set_test.html +0 -551
- data/closure-library/closure/goog/structs/simplepool.js +0 -203
- data/closure-library/closure/goog/structs/stringset.js +0 -404
- data/closure-library/closure/goog/structs/stringset_test.html +0 -251
- data/closure-library/closure/goog/structs/structs.js +0 -341
- data/closure-library/closure/goog/structs/structs_test.html +0 -1050
- data/closure-library/closure/goog/structs/treenode.js +0 -312
- data/closure-library/closure/goog/structs/treenode_test.html +0 -285
- data/closure-library/closure/goog/structs/trie.js +0 -368
- data/closure-library/closure/goog/structs/trie_test.html +0 -378
- data/closure-library/closure/goog/style/cursor.js +0 -125
- data/closure-library/closure/goog/style/cursor_test.html +0 -131
- data/closure-library/closure/goog/style/style.js +0 -1804
- data/closure-library/closure/goog/style/style_quirks_test.html +0 -1928
- data/closure-library/closure/goog/style/style_test.html +0 -2073
- data/closure-library/closure/goog/style/style_test_iframe_quirk.html +0 -29
- data/closure-library/closure/goog/style/style_test_iframe_standard.html +0 -30
- data/closure-library/closure/goog/style/style_test_quirk.html +0 -9
- data/closure-library/closure/goog/style/style_test_standard.html +0 -11
- data/closure-library/closure/goog/testing/asserts.js +0 -970
- data/closure-library/closure/goog/testing/asserts_test.html +0 -966
- data/closure-library/closure/goog/testing/async/mockcontrol.js +0 -174
- data/closure-library/closure/goog/testing/async/mockcontrol_test.html +0 -224
- data/closure-library/closure/goog/testing/asynctestcase.js +0 -812
- data/closure-library/closure/goog/testing/asynctestcase_async_test.html +0 -102
- data/closure-library/closure/goog/testing/asynctestcase_noasync_test.html +0 -98
- data/closure-library/closure/goog/testing/benchmark.js +0 -87
- data/closure-library/closure/goog/testing/benchmarks/jsbinarysizebutton.js +0 -64
- data/closure-library/closure/goog/testing/benchmarks/jsbinarysizebutton_test.html +0 -58
- data/closure-library/closure/goog/testing/benchmarks/jsbinarysizetoolbar.js +0 -66
- data/closure-library/closure/goog/testing/benchmarks/jsbinarysizetoolbar_test.html +0 -49
- data/closure-library/closure/goog/testing/continuationtestcase.js +0 -682
- data/closure-library/closure/goog/testing/continuationtestcase_test.html +0 -349
- data/closure-library/closure/goog/testing/deferredtestcase.js +0 -157
- data/closure-library/closure/goog/testing/deferredtestcase_test.html +0 -152
- data/closure-library/closure/goog/testing/dom.js +0 -596
- data/closure-library/closure/goog/testing/dom_test.html +0 -438
- data/closure-library/closure/goog/testing/editor/dom.js +0 -293
- data/closure-library/closure/goog/testing/editor/dom_test.html +0 -295
- data/closure-library/closure/goog/testing/editor/fieldmock.js +0 -90
- data/closure-library/closure/goog/testing/editor/testhelper.js +0 -168
- data/closure-library/closure/goog/testing/editor/testhelper_test.html +0 -176
- data/closure-library/closure/goog/testing/events/eventobserver.js +0 -85
- data/closure-library/closure/goog/testing/events/eventobserver_test.html +0 -70
- data/closure-library/closure/goog/testing/events/events.js +0 -540
- data/closure-library/closure/goog/testing/events/events_test.html +0 -434
- data/closure-library/closure/goog/testing/events/matchers.js +0 -41
- data/closure-library/closure/goog/testing/events/matchers_test.html +0 -40
- data/closure-library/closure/goog/testing/expectedfailures.js +0 -236
- data/closure-library/closure/goog/testing/expectedfailures_test.html +0 -122
- data/closure-library/closure/goog/testing/fs/blob.js +0 -74
- data/closure-library/closure/goog/testing/fs/blob_test.html +0 -53
- data/closure-library/closure/goog/testing/fs/directoryentry_test.html +0 -185
- data/closure-library/closure/goog/testing/fs/entry.js +0 -511
- data/closure-library/closure/goog/testing/fs/entry_test.html +0 -153
- data/closure-library/closure/goog/testing/fs/file.js +0 -51
- data/closure-library/closure/goog/testing/fs/fileentry_test.html +0 -54
- data/closure-library/closure/goog/testing/fs/filesystem.js +0 -64
- data/closure-library/closure/goog/testing/fs/filewriter.js +0 -314
- data/closure-library/closure/goog/testing/fs/filewriter_test.html +0 -248
- data/closure-library/closure/goog/testing/fs/fs.js +0 -146
- data/closure-library/closure/goog/testing/fs/fs_test.html +0 -54
- data/closure-library/closure/goog/testing/fs/integration_test.html +0 -219
- data/closure-library/closure/goog/testing/functionmock.js +0 -157
- data/closure-library/closure/goog/testing/functionmock_test.html +0 -357
- data/closure-library/closure/goog/testing/graphics.js +0 -64
- data/closure-library/closure/goog/testing/jsunit.js +0 -144
- data/closure-library/closure/goog/testing/loosemock.js +0 -240
- data/closure-library/closure/goog/testing/loosemock_test.html +0 -343
- data/closure-library/closure/goog/testing/messaging/mockmessagechannel.js +0 -77
- data/closure-library/closure/goog/testing/messaging/mockmessageevent.js +0 -100
- data/closure-library/closure/goog/testing/messaging/mockmessageport.js +0 -85
- data/closure-library/closure/goog/testing/messaging/mockportnetwork.js +0 -64
- data/closure-library/closure/goog/testing/mock.js +0 -556
- data/closure-library/closure/goog/testing/mock_test.html +0 -208
- data/closure-library/closure/goog/testing/mockclassfactory.js +0 -580
- data/closure-library/closure/goog/testing/mockclassfactory_test.html +0 -241
- data/closure-library/closure/goog/testing/mockclock.js +0 -395
- data/closure-library/closure/goog/testing/mockclock_test.html +0 -413
- data/closure-library/closure/goog/testing/mockcontrol.js +0 -210
- data/closure-library/closure/goog/testing/mockcontrol_test.html +0 -127
- data/closure-library/closure/goog/testing/mockinterface.js +0 -45
- data/closure-library/closure/goog/testing/mockmatchers.js +0 -395
- data/closure-library/closure/goog/testing/mockmatchers_test.html +0 -388
- data/closure-library/closure/goog/testing/mockrandom.js +0 -128
- data/closure-library/closure/goog/testing/mockrandom_test.html +0 -56
- data/closure-library/closure/goog/testing/mockrange.js +0 -65
- data/closure-library/closure/goog/testing/mockrange_test.html +0 -41
- data/closure-library/closure/goog/testing/mockuseragent.js +0 -143
- data/closure-library/closure/goog/testing/mockuseragent_test.html +0 -59
- data/closure-library/closure/goog/testing/multitestrunner.js +0 -1442
- data/closure-library/closure/goog/testing/net/xhrio.js +0 -595
- data/closure-library/closure/goog/testing/net/xhrio_test.html +0 -321
- data/closure-library/closure/goog/testing/objectpropertystring.js +0 -67
- data/closure-library/closure/goog/testing/performancetable.css +0 -46
- data/closure-library/closure/goog/testing/performancetable.js +0 -162
- data/closure-library/closure/goog/testing/performancetimer.js +0 -166
- data/closure-library/closure/goog/testing/performancetimer_test.html +0 -107
- data/closure-library/closure/goog/testing/propertyreplacer.js +0 -243
- data/closure-library/closure/goog/testing/propertyreplacer_test.html +0 -368
- data/closure-library/closure/goog/testing/pseudorandom.js +0 -162
- data/closure-library/closure/goog/testing/pseudorandom_test.html +0 -98
- data/closure-library/closure/goog/testing/recordfunction.js +0 -194
- data/closure-library/closure/goog/testing/recordfunction_test.html +0 -147
- data/closure-library/closure/goog/testing/singleton.js +0 -82
- data/closure-library/closure/goog/testing/singleton_test.html +0 -39
- data/closure-library/closure/goog/testing/stacktrace.js +0 -470
- data/closure-library/closure/goog/testing/stacktrace_test.html +0 -229
- data/closure-library/closure/goog/testing/strictmock.js +0 -124
- data/closure-library/closure/goog/testing/strictmock_test.html +0 -368
- data/closure-library/closure/goog/testing/style/layoutasserts.js +0 -368
- data/closure-library/closure/goog/testing/style/layoutasserts_test.html +0 -269
- data/closure-library/closure/goog/testing/testcase.js +0 -1053
- data/closure-library/closure/goog/testing/testqueue.js +0 -66
- data/closure-library/closure/goog/testing/testrunner.js +0 -391
- data/closure-library/closure/goog/testing/ui/rendererasserts.js +0 -50
- data/closure-library/closure/goog/testing/ui/rendererasserts_test.html +0 -51
- data/closure-library/closure/goog/testing/ui/rendererharness.js +0 -175
- data/closure-library/closure/goog/testing/ui/style.js +0 -137
- data/closure-library/closure/goog/testing/ui/style_reference.html +0 -27
- data/closure-library/closure/goog/testing/ui/style_test.html +0 -130
- data/closure-library/closure/goog/timer/timer.js +0 -285
- data/closure-library/closure/goog/timer/timer_test.html +0 -118
- data/closure-library/closure/goog/tweak/entries.js +0 -990
- data/closure-library/closure/goog/tweak/entries_test.html +0 -94
- data/closure-library/closure/goog/tweak/registry.js +0 -310
- data/closure-library/closure/goog/tweak/registry_test.html +0 -144
- data/closure-library/closure/goog/tweak/testhelpers.js +0 -111
- data/closure-library/closure/goog/tweak/tweak.js +0 -318
- data/closure-library/closure/goog/tweak/tweakui.js +0 -817
- data/closure-library/closure/goog/tweak/tweakui_test.html +0 -280
- data/closure-library/closure/goog/ui/abstractspellchecker.js +0 -1069
- data/closure-library/closure/goog/ui/activitymonitor.js +0 -286
- data/closure-library/closure/goog/ui/activitymonitor_test.html +0 -44
- data/closure-library/closure/goog/ui/advancedtooltip.js +0 -368
- data/closure-library/closure/goog/ui/advancedtooltip_test.html +0 -274
- data/closure-library/closure/goog/ui/animatedzippy.js +0 -190
- data/closure-library/closure/goog/ui/attachablemenu.js +0 -464
- data/closure-library/closure/goog/ui/autocomplete/arraymatcher.js +0 -156
- data/closure-library/closure/goog/ui/autocomplete/arraymatcher_test.html +0 -130
- data/closure-library/closure/goog/ui/autocomplete/autocomplete.js +0 -627
- data/closure-library/closure/goog/ui/autocomplete/autocomplete_test.html +0 -537
- data/closure-library/closure/goog/ui/autocomplete/basic.js +0 -53
- data/closure-library/closure/goog/ui/autocomplete/basic_test.html +0 -204
- data/closure-library/closure/goog/ui/autocomplete/inputhandler.js +0 -1209
- data/closure-library/closure/goog/ui/autocomplete/inputhandler_test.html +0 -555
- data/closure-library/closure/goog/ui/autocomplete/remote.js +0 -117
- data/closure-library/closure/goog/ui/autocomplete/remotearraymatcher.js +0 -273
- data/closure-library/closure/goog/ui/autocomplete/remotearraymatcher_test.html +0 -73
- data/closure-library/closure/goog/ui/autocomplete/renderer.js +0 -852
- data/closure-library/closure/goog/ui/autocomplete/renderer_test.html +0 -386
- data/closure-library/closure/goog/ui/autocomplete/richinputhandler.js +0 -59
- data/closure-library/closure/goog/ui/autocomplete/richremote.js +0 -108
- data/closure-library/closure/goog/ui/autocomplete/richremotearraymatcher.js +0 -126
- data/closure-library/closure/goog/ui/basicmenu.js +0 -930
- data/closure-library/closure/goog/ui/bidiinput.js +0 -164
- data/closure-library/closure/goog/ui/bubble.js +0 -475
- data/closure-library/closure/goog/ui/button.js +0 -208
- data/closure-library/closure/goog/ui/button_test.html +0 -257
- data/closure-library/closure/goog/ui/buttonrenderer.js +0 -205
- data/closure-library/closure/goog/ui/buttonrenderer_test.html +0 -190
- data/closure-library/closure/goog/ui/buttonside.js +0 -40
- data/closure-library/closure/goog/ui/cccbutton.js +0 -281
- data/closure-library/closure/goog/ui/charcounter.js +0 -200
- data/closure-library/closure/goog/ui/charpicker.js +0 -807
- data/closure-library/closure/goog/ui/checkbox.js +0 -303
- data/closure-library/closure/goog/ui/checkbox_test.html +0 -224
- data/closure-library/closure/goog/ui/checkboxmenuitem.js +0 -53
- data/closure-library/closure/goog/ui/colorbutton.js +0 -58
- data/closure-library/closure/goog/ui/colorbutton_test.html +0 -70
- data/closure-library/closure/goog/ui/colorbuttonrenderer.js +0 -72
- data/closure-library/closure/goog/ui/colormenubutton.js +0 -213
- data/closure-library/closure/goog/ui/colormenubuttonrenderer.js +0 -144
- data/closure-library/closure/goog/ui/colormenubuttonrenderer_test.html +0 -88
- data/closure-library/closure/goog/ui/colorpalette.js +0 -162
- data/closure-library/closure/goog/ui/colorpalette_test.html +0 -169
- data/closure-library/closure/goog/ui/colorpicker.js +0 -344
- data/closure-library/closure/goog/ui/colorsplitbehavior.js +0 -61
- data/closure-library/closure/goog/ui/combobox.js +0 -894
- data/closure-library/closure/goog/ui/combobox_test.html +0 -208
- data/closure-library/closure/goog/ui/component.js +0 -1187
- data/closure-library/closure/goog/ui/component_test.html +0 -723
- data/closure-library/closure/goog/ui/container.js +0 -1296
- data/closure-library/closure/goog/ui/container_test.html +0 -450
- data/closure-library/closure/goog/ui/containerrenderer.js +0 -370
- data/closure-library/closure/goog/ui/containerrenderer_test.html +0 -227
- data/closure-library/closure/goog/ui/containerscroller.js +0 -221
- data/closure-library/closure/goog/ui/containerscroller_test.html +0 -213
- data/closure-library/closure/goog/ui/control.js +0 -1348
- data/closure-library/closure/goog/ui/control_test.html +0 -2128
- data/closure-library/closure/goog/ui/controlcontent.js +0 -28
- data/closure-library/closure/goog/ui/controlrenderer.js +0 -808
- data/closure-library/closure/goog/ui/controlrenderer_test.html +0 -840
- data/closure-library/closure/goog/ui/cookieeditor.js +0 -182
- data/closure-library/closure/goog/ui/cookieeditor_test.html +0 -102
- data/closure-library/closure/goog/ui/css3buttonrenderer.js +0 -147
- data/closure-library/closure/goog/ui/css3menubuttonrenderer.js +0 -144
- data/closure-library/closure/goog/ui/cssnames.js +0 -28
- data/closure-library/closure/goog/ui/custombutton.js +0 -58
- data/closure-library/closure/goog/ui/custombuttonrenderer.js +0 -254
- data/closure-library/closure/goog/ui/customcolorpalette.js +0 -137
- data/closure-library/closure/goog/ui/customcolorpalette_test.html +0 -60
- data/closure-library/closure/goog/ui/datepicker.js +0 -1339
- data/closure-library/closure/goog/ui/datepicker_test.html +0 -190
- data/closure-library/closure/goog/ui/decorate.js +0 -37
- data/closure-library/closure/goog/ui/decorate_test.html +0 -113
- data/closure-library/closure/goog/ui/deprecatedbutton.js +0 -381
- data/closure-library/closure/goog/ui/dialog.js +0 -1776
- data/closure-library/closure/goog/ui/dialog_test.html +0 -493
- data/closure-library/closure/goog/ui/dimensionpicker.js +0 -289
- data/closure-library/closure/goog/ui/dimensionpicker_test.html +0 -128
- data/closure-library/closure/goog/ui/dimensionpickerrenderer.js +0 -387
- data/closure-library/closure/goog/ui/dragdropdetector.js +0 -642
- data/closure-library/closure/goog/ui/drilldownrow.js +0 -494
- data/closure-library/closure/goog/ui/editor/abstractdialog.js +0 -443
- data/closure-library/closure/goog/ui/editor/abstractdialog_test.html +0 -467
- data/closure-library/closure/goog/ui/editor/bubble.js +0 -520
- data/closure-library/closure/goog/ui/editor/bubble_test.html +0 -264
- data/closure-library/closure/goog/ui/editor/defaulttoolbar.js +0 -1062
- data/closure-library/closure/goog/ui/editor/linkdialog.js +0 -833
- data/closure-library/closure/goog/ui/editor/linkdialog_test.html +0 -449
- data/closure-library/closure/goog/ui/editor/messages.js +0 -115
- data/closure-library/closure/goog/ui/editor/tabpane.js +0 -183
- data/closure-library/closure/goog/ui/editor/toolbarcontroller.js +0 -293
- data/closure-library/closure/goog/ui/editor/toolbarfactory.js +0 -437
- data/closure-library/closure/goog/ui/editor/toolbarfactory_test.html +0 -73
- data/closure-library/closure/goog/ui/emoji/emoji.js +0 -72
- data/closure-library/closure/goog/ui/emoji/emojipalette.js +0 -298
- data/closure-library/closure/goog/ui/emoji/emojipaletterenderer.js +0 -206
- data/closure-library/closure/goog/ui/emoji/emojipicker.js +0 -797
- data/closure-library/closure/goog/ui/emoji/emojipicker_test.html +0 -840
- data/closure-library/closure/goog/ui/emoji/fast_nonprogressive_emojipicker_test.html +0 -256
- data/closure-library/closure/goog/ui/emoji/fast_progressive_emojipicker_test.html +0 -256
- data/closure-library/closure/goog/ui/emoji/popupemojipicker.js +0 -410
- data/closure-library/closure/goog/ui/emoji/popupemojipicker_test.html +0 -80
- data/closure-library/closure/goog/ui/emoji/progressiveemojipaletterenderer.js +0 -97
- data/closure-library/closure/goog/ui/emoji/spriteinfo.js +0 -212
- data/closure-library/closure/goog/ui/emoji/spriteinfo_test.html +0 -51
- data/closure-library/closure/goog/ui/filteredmenu.js +0 -562
- data/closure-library/closure/goog/ui/filteredmenu_test.html +0 -299
- data/closure-library/closure/goog/ui/filterobservingmenuitem.js +0 -97
- data/closure-library/closure/goog/ui/filterobservingmenuitemrenderer.js +0 -60
- data/closure-library/closure/goog/ui/flatbuttonrenderer.js +0 -138
- data/closure-library/closure/goog/ui/flatmenubuttonrenderer.js +0 -199
- data/closure-library/closure/goog/ui/formpost.js +0 -109
- data/closure-library/closure/goog/ui/formpost_test.html +0 -109
- data/closure-library/closure/goog/ui/gauge.js +0 -999
- data/closure-library/closure/goog/ui/gaugetheme.js +0 -169
- data/closure-library/closure/goog/ui/hovercard.js +0 -447
- data/closure-library/closure/goog/ui/hovercard_test.html +0 -343
- data/closure-library/closure/goog/ui/hsvapalette.js +0 -311
- data/closure-library/closure/goog/ui/hsvapalette_test.html +0 -152
- data/closure-library/closure/goog/ui/hsvpalette.js +0 -470
- data/closure-library/closure/goog/ui/hsvpalette_test.html +0 -202
- data/closure-library/closure/goog/ui/idgenerator.js +0 -57
- data/closure-library/closure/goog/ui/idletimer.js +0 -299
- data/closure-library/closure/goog/ui/idletimer_test.html +0 -100
- data/closure-library/closure/goog/ui/iframemask.js +0 -256
- data/closure-library/closure/goog/ui/iframemask_test.html +0 -230
- data/closure-library/closure/goog/ui/imagelessbuttonrenderer.js +0 -204
- data/closure-library/closure/goog/ui/imagelessmenubuttonrenderer.js +0 -202
- data/closure-library/closure/goog/ui/imagelessroundedcorner.js +0 -971
- data/closure-library/closure/goog/ui/inputdatepicker.js +0 -306
- data/closure-library/closure/goog/ui/inputdatepicker_test.html +0 -109
- data/closure-library/closure/goog/ui/itemevent.js +0 -50
- data/closure-library/closure/goog/ui/keyboardshortcuthandler.js +0 -981
- data/closure-library/closure/goog/ui/keyboardshortcuthandler_test.html +0 -671
- data/closure-library/closure/goog/ui/labelinput.js +0 -439
- data/closure-library/closure/goog/ui/linkbuttonrenderer.js +0 -67
- data/closure-library/closure/goog/ui/media/flashobject.js +0 -629
- data/closure-library/closure/goog/ui/media/flashobject_test.html +0 -236
- data/closure-library/closure/goog/ui/media/flickr.js +0 -309
- data/closure-library/closure/goog/ui/media/flickr_test.html +0 -90
- data/closure-library/closure/goog/ui/media/media.js +0 -284
- data/closure-library/closure/goog/ui/media/media_test.html +0 -161
- data/closure-library/closure/goog/ui/media/mediamodel.js +0 -840
- data/closure-library/closure/goog/ui/media/mp3.js +0 -225
- data/closure-library/closure/goog/ui/media/mp3_test.html +0 -78
- data/closure-library/closure/goog/ui/media/photo.js +0 -139
- data/closure-library/closure/goog/ui/media/photo_test.html +0 -62
- data/closure-library/closure/goog/ui/media/picasa.js +0 -317
- data/closure-library/closure/goog/ui/media/picasa_test.html +0 -131
- data/closure-library/closure/goog/ui/media/vimeo.js +0 -264
- data/closure-library/closure/goog/ui/media/vimeo_test.html +0 -79
- data/closure-library/closure/goog/ui/media/youtube.js +0 -328
- data/closure-library/closure/goog/ui/media/youtube_test.html +0 -185
- data/closure-library/closure/goog/ui/menu.js +0 -435
- data/closure-library/closure/goog/ui/menu_test.html +0 -129
- data/closure-library/closure/goog/ui/menubase.js +0 -191
- data/closure-library/closure/goog/ui/menubutton.js +0 -815
- data/closure-library/closure/goog/ui/menubutton_test.html +0 -440
- data/closure-library/closure/goog/ui/menubutton_test_frame.html +0 -41
- data/closure-library/closure/goog/ui/menubuttonrenderer.js +0 -226
- data/closure-library/closure/goog/ui/menubuttonrenderer_test.html +0 -161
- data/closure-library/closure/goog/ui/menuheader.js +0 -62
- data/closure-library/closure/goog/ui/menuheaderrenderer.js +0 -55
- data/closure-library/closure/goog/ui/menuitem.js +0 -154
- data/closure-library/closure/goog/ui/menuitem_test.html +0 -506
- data/closure-library/closure/goog/ui/menuitemrenderer.js +0 -353
- data/closure-library/closure/goog/ui/menuitemrenderer_test.html +0 -190
- data/closure-library/closure/goog/ui/menurenderer.js +0 -118
- data/closure-library/closure/goog/ui/menuseparator.js +0 -51
- data/closure-library/closure/goog/ui/menuseparatorrenderer.js +0 -102
- data/closure-library/closure/goog/ui/mockactivitymonitor.js +0 -54
- data/closure-library/closure/goog/ui/nativebuttonrenderer.js +0 -205
- data/closure-library/closure/goog/ui/nativebuttonrenderer_test.html +0 -213
- data/closure-library/closure/goog/ui/offlineinstalldialog.js +0 -1086
- data/closure-library/closure/goog/ui/offlinestatuscard.js +0 -580
- data/closure-library/closure/goog/ui/offlinestatuscomponent.js +0 -545
- data/closure-library/closure/goog/ui/option.js +0 -67
- data/closure-library/closure/goog/ui/palette.js +0 -528
- data/closure-library/closure/goog/ui/paletterenderer.js +0 -318
- data/closure-library/closure/goog/ui/plaintextspellchecker.js +0 -668
- data/closure-library/closure/goog/ui/plaintextspellchecker_test.html +0 -240
- data/closure-library/closure/goog/ui/popup.js +0 -410
- data/closure-library/closure/goog/ui/popup_test.html +0 -137
- data/closure-library/closure/goog/ui/popupbase.js +0 -721
- data/closure-library/closure/goog/ui/popupbase_test.html +0 -186
- data/closure-library/closure/goog/ui/popupcolorpicker.js +0 -441
- data/closure-library/closure/goog/ui/popupcolorpicker_test.html +0 -71
- data/closure-library/closure/goog/ui/popupdatepicker.js +0 -273
- data/closure-library/closure/goog/ui/popupmenu.js +0 -539
- data/closure-library/closure/goog/ui/popupmenu_test.html +0 -197
- data/closure-library/closure/goog/ui/progressbar.js +0 -390
- data/closure-library/closure/goog/ui/prompt.js +0 -307
- data/closure-library/closure/goog/ui/prompt_test.html +0 -65
- data/closure-library/closure/goog/ui/rangemodel.js +0 -301
- data/closure-library/closure/goog/ui/rangemodel_test.html +0 -270
- data/closure-library/closure/goog/ui/ratings.js +0 -441
- data/closure-library/closure/goog/ui/registry.js +0 -166
- data/closure-library/closure/goog/ui/registry_test.html +0 -236
- data/closure-library/closure/goog/ui/richtextspellchecker.js +0 -600
- data/closure-library/closure/goog/ui/richtextspellchecker_test.html +0 -224
- data/closure-library/closure/goog/ui/roundedcorners.js +0 -694
- data/closure-library/closure/goog/ui/roundedpanel.js +0 -609
- data/closure-library/closure/goog/ui/roundedpanel_test.html +0 -57
- data/closure-library/closure/goog/ui/roundedtabrenderer.js +0 -196
- data/closure-library/closure/goog/ui/scrollfloater.js +0 -394
- data/closure-library/closure/goog/ui/scrollfloater_test.html +0 -46
- data/closure-library/closure/goog/ui/select.js +0 -397
- data/closure-library/closure/goog/ui/select_test.html +0 -152
- data/closure-library/closure/goog/ui/selectionmenubutton.js +0 -277
- data/closure-library/closure/goog/ui/selectionmenubutton_test.html +0 -237
- data/closure-library/closure/goog/ui/selectionmodel.js +0 -291
- data/closure-library/closure/goog/ui/separator.js +0 -74
- data/closure-library/closure/goog/ui/serverchart.js +0 -1791
- data/closure-library/closure/goog/ui/serverchart_test.html +0 -598
- data/closure-library/closure/goog/ui/slider.js +0 -125
- data/closure-library/closure/goog/ui/sliderbase.js +0 -1087
- data/closure-library/closure/goog/ui/sliderbase_test.html +0 -198
- data/closure-library/closure/goog/ui/splitbehavior.js +0 -348
- data/closure-library/closure/goog/ui/splitbehavior_test.html +0 -161
- data/closure-library/closure/goog/ui/splitpane.js +0 -844
- data/closure-library/closure/goog/ui/splitpane_test.html +0 -143
- data/closure-library/closure/goog/ui/style/app/buttonrenderer.js +0 -204
- data/closure-library/closure/goog/ui/style/app/buttonrenderer_test.html +0 -155
- data/closure-library/closure/goog/ui/style/app/menubuttonrenderer.js +0 -227
- data/closure-library/closure/goog/ui/style/app/menubuttonrenderer_test.html +0 -167
- data/closure-library/closure/goog/ui/style/app/primaryactionbuttonrenderer.js +0 -88
- data/closure-library/closure/goog/ui/style/app/primaryactionbuttonrenderer_test.html +0 -76
- data/closure-library/closure/goog/ui/submenu.js +0 -660
- data/closure-library/closure/goog/ui/submenu_test.html +0 -446
- data/closure-library/closure/goog/ui/submenurenderer.js +0 -188
- data/closure-library/closure/goog/ui/tab.js +0 -102
- data/closure-library/closure/goog/ui/tab_test.html +0 -61
- data/closure-library/closure/goog/ui/tabbar.js +0 -393
- data/closure-library/closure/goog/ui/tabbar_test.html +0 -611
- data/closure-library/closure/goog/ui/tabbarrenderer.js +0 -173
- data/closure-library/closure/goog/ui/tabbarrenderer_test.html +0 -137
- data/closure-library/closure/goog/ui/tablesorter.js +0 -304
- data/closure-library/closure/goog/ui/tablesorter_test.html +0 -127
- data/closure-library/closure/goog/ui/tabpane.js +0 -674
- data/closure-library/closure/goog/ui/tabpane_test.html +0 -107
- data/closure-library/closure/goog/ui/tabrenderer.js +0 -152
- data/closure-library/closure/goog/ui/tabrenderer_test.html +0 -132
- data/closure-library/closure/goog/ui/textarea.js +0 -573
- data/closure-library/closure/goog/ui/textarea_test.html +0 -305
- data/closure-library/closure/goog/ui/textarearenderer.js +0 -167
- data/closure-library/closure/goog/ui/togglebutton.js +0 -58
- data/closure-library/closure/goog/ui/toolbar.js +0 -45
- data/closure-library/closure/goog/ui/toolbarbutton.js +0 -54
- data/closure-library/closure/goog/ui/toolbarbuttonrenderer.js +0 -55
- data/closure-library/closure/goog/ui/toolbarcolormenubutton.js +0 -57
- data/closure-library/closure/goog/ui/toolbarcolormenubuttonrenderer.js +0 -95
- data/closure-library/closure/goog/ui/toolbarcolormenubuttonrenderer_test.html +0 -66
- data/closure-library/closure/goog/ui/toolbarmenubutton.js +0 -56
- data/closure-library/closure/goog/ui/toolbarmenubuttonrenderer.js +0 -55
- data/closure-library/closure/goog/ui/toolbarrenderer.js +0 -95
- data/closure-library/closure/goog/ui/toolbarselect.js +0 -55
- data/closure-library/closure/goog/ui/toolbarseparator.js +0 -51
- data/closure-library/closure/goog/ui/toolbarseparatorrenderer.js +0 -87
- data/closure-library/closure/goog/ui/toolbartogglebutton.js +0 -53
- data/closure-library/closure/goog/ui/tooltip.js +0 -975
- data/closure-library/closure/goog/ui/tooltip_test.html +0 -351
- data/closure-library/closure/goog/ui/tree/basenode.js +0 -1457
- data/closure-library/closure/goog/ui/tree/basenode_test.html +0 -218
- data/closure-library/closure/goog/ui/tree/treecontrol.js +0 -656
- data/closure-library/closure/goog/ui/tree/treecontrol_test.html +0 -113
- data/closure-library/closure/goog/ui/tree/treenode.js +0 -102
- data/closure-library/closure/goog/ui/tree/typeahead.js +0 -332
- data/closure-library/closure/goog/ui/tree/typeahead_test.html +0 -133
- data/closure-library/closure/goog/ui/tristatemenuitem.js +0 -185
- data/closure-library/closure/goog/ui/tristatemenuitemrenderer.js +0 -86
- data/closure-library/closure/goog/ui/twothumbslider.js +0 -134
- data/closure-library/closure/goog/ui/zippy.js +0 -277
- data/closure-library/closure/goog/ui/zippy_test.html +0 -223
- data/closure-library/closure/goog/uri/uri.js +0 -1595
- data/closure-library/closure/goog/uri/uri_test.html +0 -837
- data/closure-library/closure/goog/uri/utils.js +0 -972
- data/closure-library/closure/goog/uri/utils_test.html +0 -521
- data/closure-library/closure/goog/useragent/adobereader.js +0 -90
- data/closure-library/closure/goog/useragent/adobereader_test.html +0 -34
- data/closure-library/closure/goog/useragent/flash.js +0 -113
- data/closure-library/closure/goog/useragent/flash_test.html +0 -34
- data/closure-library/closure/goog/useragent/iphoto.js +0 -86
- data/closure-library/closure/goog/useragent/jscript.js +0 -94
- data/closure-library/closure/goog/useragent/jscript_test.html +0 -65
- data/closure-library/closure/goog/useragent/picasa.js +0 -111
- data/closure-library/closure/goog/useragent/platform.js +0 -70
- data/closure-library/closure/goog/useragent/platform_test.html +0 -108
- data/closure-library/closure/goog/useragent/product.js +0 -253
- data/closure-library/closure/goog/useragent/product_isversion.js +0 -99
- data/closure-library/closure/goog/useragent/product_test.html +0 -322
- data/closure-library/closure/goog/useragent/useragent.js +0 -464
- data/closure-library/closure/goog/useragent/useragent_test.html +0 -290
- data/closure-library/closure/goog/window/window.js +0 -206
- data/closure-library/closure/goog/window/window_test.html +0 -185
- data/closure-library/third_party/closure/goog/base.js +0 -2
- data/closure-library/third_party/closure/goog/caja/string/html/htmlparser.js +0 -611
- data/closure-library/third_party/closure/goog/caja/string/html/htmlsanitizer.js +0 -605
- data/closure-library/third_party/closure/goog/deps.js +0 -26
- data/closure-library/third_party/closure/goog/dojo/dom/query.js +0 -1537
- data/closure-library/third_party/closure/goog/dojo/dom/query_test.html +0 -63
- data/closure-library/third_party/closure/goog/dojo/dom/query_test.js +0 -160
- data/closure-library/third_party/closure/goog/jpeg_encoder/jpeg_encoder_basic.js +0 -751
- data/closure-library/third_party/closure/goog/loremipsum/text/loremipsum.js +0 -712
- data/closure-library/third_party/closure/goog/loremipsum/text/loremipsum_test.html +0 -61
- data/closure-library/third_party/closure/goog/mochikit/async/deferred.js +0 -530
- data/closure-library/third_party/closure/goog/mochikit/async/deferred_test.html +0 -627
- data/closure-library/third_party/closure/goog/mochikit/async/deferredlist.js +0 -199
- data/closure-library/third_party/closure/goog/mochikit/async/deferredlist_test.html +0 -426
- data/closure-library/third_party/closure/goog/osapi/osapi.js +0 -91
- data/closure-library/third_party/closure/goog/silverlight/AppManifest.xml +0 -6
- data/closure-library/third_party/closure/goog/silverlight/AssemblyInfo.cs +0 -35
- data/closure-library/third_party/closure/goog/silverlight/ClipboardButton.xaml +0 -9
- data/closure-library/third_party/closure/goog/silverlight/ClipboardButton.xaml.cs +0 -74
- data/closure-library/third_party/closure/goog/silverlight/ClipboardButtonApp.xaml +0 -8
- data/closure-library/third_party/closure/goog/silverlight/ClipboardButtonApp.xaml.cs +0 -75
- data/closure-library/third_party/closure/goog/silverlight/ClosureClipboardButton.csproj +0 -108
- data/closure-library/third_party/closure/goog/silverlight/ClosureClipboardButton.csproj.user +0 -29
- data/closure-library/third_party/closure/goog/silverlight/clipboardbutton.js +0 -279
- data/closure-library/third_party/closure/goog/silverlight/silverlight.js +0 -758
- data/closure-library/third_party/closure/goog/silverlight/supporteduseragent.js +0 -138
- data/closure-library/third_party/closure/goog/silverlight/xap_files +0 -0
- data/closure.gemspec +0 -19
- data/config.ru +0 -40
- data/java_src/ClosureScript.java +0 -89
- data/java_src/make.rb +0 -19
- data/lib/closure/sass.rb +0 -56
- data/lib/closure.jar +0 -0
- data/scripts/demos/compiler.build +0 -1
- data/scripts/demos/compiler.debug +0 -24
- data/scripts/demos/compiler.js.erb +0 -22
- data/scripts/demos/compiler.map +0 -114
- data/scripts/demos/deps.js.erb +0 -1
- data/scripts/demos/googly.erb +0 -19
- data/scripts/demos/googly.js +0 -24
- data/scripts/demos/helloworld.erb +0 -24
- data/scripts/demos/helloworld.js +0 -58
- data/scripts/demos/helloworld.soy +0 -45
- data/scripts/demos/index.erb +0 -29
- data/scripts/externs/jquery.externs +0 -4
- data/scripts/fixtures/_partial.haml +0 -2
- data/scripts/fixtures/erb.html.erb +0 -8
- data/scripts/fixtures/haml.haml +0 -6
- data/scripts/fixtures/html.html +0 -9
- data/scripts/fixtures/route_js.js.erb +0 -1
- data/test/beanshell_test.rb +0 -22
- data/test/server_test.rb +0 -67
- data/test/sources_test.rb +0 -41
- data/test/test_helper.rb +0 -12
- /data/{scripts/externs → externs}/jquery-ui.externs +0 -0
- /data/scripts/{demos/jquery.js → jquery/jquery_1.4.4.js} +0 -0
@@ -1,1804 +0,0 @@
|
|
1
|
-
// Copyright 2006 The Closure Library Authors. All Rights Reserved.
|
2
|
-
//
|
3
|
-
// Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
// you may not use this file except in compliance with the License.
|
5
|
-
// You may obtain a copy of the License at
|
6
|
-
//
|
7
|
-
// http://www.apache.org/licenses/LICENSE-2.0
|
8
|
-
//
|
9
|
-
// Unless required by applicable law or agreed to in writing, software
|
10
|
-
// distributed under the License is distributed on an "AS-IS" BASIS,
|
11
|
-
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
// See the License for the specific language governing permissions and
|
13
|
-
// limitations under the License.
|
14
|
-
|
15
|
-
/**
|
16
|
-
* @fileoverview Utilities for element styles.
|
17
|
-
*
|
18
|
-
* @see ../demos/inline_block_quirks.html
|
19
|
-
* @see ../demos/inline_block_standards.html
|
20
|
-
* @see ../demos/style_viewport.html
|
21
|
-
*/
|
22
|
-
|
23
|
-
goog.provide('goog.style');
|
24
|
-
|
25
|
-
|
26
|
-
goog.require('goog.array');
|
27
|
-
goog.require('goog.dom');
|
28
|
-
goog.require('goog.math.Box');
|
29
|
-
goog.require('goog.math.Coordinate');
|
30
|
-
goog.require('goog.math.Rect');
|
31
|
-
goog.require('goog.math.Size');
|
32
|
-
goog.require('goog.object');
|
33
|
-
goog.require('goog.string');
|
34
|
-
goog.require('goog.userAgent');
|
35
|
-
|
36
|
-
|
37
|
-
/**
|
38
|
-
* Sets a style value on an element.
|
39
|
-
*
|
40
|
-
* This function is not indended to patch issues in the browser's style
|
41
|
-
* handling, but to allow easy programmatic access to setting dash-separated
|
42
|
-
* style properties. An example is setting a batch of properties from a data
|
43
|
-
* object without overwriting old styles. When possible, use native APIs:
|
44
|
-
* elem.style.propertyKey = 'value' or (if obliterating old styles is fine)
|
45
|
-
* elem.style.cssText = 'property1: value1; property2: value2'.
|
46
|
-
*
|
47
|
-
* @param {Element} element The element to change.
|
48
|
-
* @param {string|Object} style If a string, a style name. If an object, a hash
|
49
|
-
* of style names to style values.
|
50
|
-
* @param {string|number|boolean=} opt_value If style was a string, then this
|
51
|
-
* should be the value.
|
52
|
-
*/
|
53
|
-
goog.style.setStyle = function(element, style, opt_value) {
|
54
|
-
if (goog.isString(style)) {
|
55
|
-
goog.style.setStyle_(element, opt_value, style);
|
56
|
-
} else {
|
57
|
-
goog.object.forEach(style, goog.partial(goog.style.setStyle_, element));
|
58
|
-
}
|
59
|
-
};
|
60
|
-
|
61
|
-
|
62
|
-
/**
|
63
|
-
* Sets a style value on an element, with parameters swapped to work with
|
64
|
-
* {@code goog.object.forEach()}.
|
65
|
-
* @param {Element} element The element to change.
|
66
|
-
* @param {string|number|boolean|undefined} value Style value.
|
67
|
-
* @param {string} style Style name.
|
68
|
-
* @private
|
69
|
-
*/
|
70
|
-
goog.style.setStyle_ = function(element, value, style) {
|
71
|
-
element.style[goog.string.toCamelCase(style)] = value;
|
72
|
-
};
|
73
|
-
|
74
|
-
|
75
|
-
/**
|
76
|
-
* Retrieves an explicitly-set style value of a node. This returns '' if there
|
77
|
-
* isn't a style attribute on the element or if this style property has not been
|
78
|
-
* explicitly set in script.
|
79
|
-
*
|
80
|
-
* @param {Element} element Element to get style of.
|
81
|
-
* @param {string} property Property to get, css-style (if you have a camel-case
|
82
|
-
* property, use element.style[style]).
|
83
|
-
* @return {string} Style value.
|
84
|
-
*/
|
85
|
-
goog.style.getStyle = function(element, property) {
|
86
|
-
// element.style is '' for well-known properties which are unset.
|
87
|
-
// For for browser specific styles as 'filter' is undefined
|
88
|
-
// so we need to return '' explicitly to make it consistent across
|
89
|
-
// browsers.
|
90
|
-
return element.style[goog.string.toCamelCase(property)] || '';
|
91
|
-
};
|
92
|
-
|
93
|
-
|
94
|
-
/**
|
95
|
-
* Retrieves a computed style value of a node. It returns empty string if the
|
96
|
-
* value cannot be computed (which will be the case in Internet Explorer) or
|
97
|
-
* "none" if the property requested is a SVG one and it has not been
|
98
|
-
* explicitly set (firefox and webkit).
|
99
|
-
*
|
100
|
-
* @param {Element} element Element to get style of.
|
101
|
-
* @param {string} property Property to get (camel-case).
|
102
|
-
* @return {string} Style value.
|
103
|
-
*/
|
104
|
-
goog.style.getComputedStyle = function(element, property) {
|
105
|
-
var doc = goog.dom.getOwnerDocument(element);
|
106
|
-
if (doc.defaultView && doc.defaultView.getComputedStyle) {
|
107
|
-
var styles = doc.defaultView.getComputedStyle(element, null);
|
108
|
-
if (styles) {
|
109
|
-
// element.style[..] is undefined for browser specific styles
|
110
|
-
// as 'filter'.
|
111
|
-
return styles[property] || styles.getPropertyValue(property);
|
112
|
-
}
|
113
|
-
}
|
114
|
-
|
115
|
-
return '';
|
116
|
-
};
|
117
|
-
|
118
|
-
|
119
|
-
/**
|
120
|
-
* Gets the cascaded style value of a node, or null if the value cannot be
|
121
|
-
* computed (only Internet Explorer can do this).
|
122
|
-
*
|
123
|
-
* @param {Element} element Element to get style of.
|
124
|
-
* @param {string} style Property to get (camel-case).
|
125
|
-
* @return {string} Style value.
|
126
|
-
*/
|
127
|
-
goog.style.getCascadedStyle = function(element, style) {
|
128
|
-
return element.currentStyle ? element.currentStyle[style] : null;
|
129
|
-
};
|
130
|
-
|
131
|
-
|
132
|
-
/**
|
133
|
-
* Cross-browser pseudo get computed style. It returns the computed style where
|
134
|
-
* available. If not available it tries the cascaded style value (IE
|
135
|
-
* currentStyle) and in worst case the inline style value. It shouldn't be
|
136
|
-
* called directly, see http://wiki/Main/ComputedStyleVsCascadedStyle for
|
137
|
-
* discussion.
|
138
|
-
*
|
139
|
-
* @param {Element} element Element to get style of.
|
140
|
-
* @param {string} style Property to get (must be camelCase, not css-style.).
|
141
|
-
* @return {string} Style value.
|
142
|
-
* @private
|
143
|
-
*/
|
144
|
-
goog.style.getStyle_ = function(element, style) {
|
145
|
-
return goog.style.getComputedStyle(element, style) ||
|
146
|
-
goog.style.getCascadedStyle(element, style) ||
|
147
|
-
element.style[style];
|
148
|
-
};
|
149
|
-
|
150
|
-
|
151
|
-
/**
|
152
|
-
* Retrieves the computed value of the position CSS attribute.
|
153
|
-
* @param {Element} element The element to get the position of.
|
154
|
-
* @return {string} Position value.
|
155
|
-
*/
|
156
|
-
goog.style.getComputedPosition = function(element) {
|
157
|
-
return goog.style.getStyle_(element, 'position');
|
158
|
-
};
|
159
|
-
|
160
|
-
|
161
|
-
/**
|
162
|
-
* Retrieves the computed background color string for a given element. The
|
163
|
-
* string returned is suitable for assigning to another element's
|
164
|
-
* background-color, but is not guaranteed to be in any particular string
|
165
|
-
* format. Accessing the color in a numeric form may not be possible in all
|
166
|
-
* browsers or with all input.
|
167
|
-
*
|
168
|
-
* If the background color for the element is defined as a hexadecimal value,
|
169
|
-
* the resulting string can be parsed by goog.color.parse in all supported
|
170
|
-
* browsers.
|
171
|
-
*
|
172
|
-
* Whether named colors like "red" or "lightblue" get translated into a
|
173
|
-
* format which can be parsed is browser dependent. Calling this function on
|
174
|
-
* transparent elements will return "transparent" in most browsers or
|
175
|
-
* "rgba(0, 0, 0, 0)" in WebKit.
|
176
|
-
* @param {Element} element The element to get the background color of.
|
177
|
-
* @return {string} The computed string value of the background color.
|
178
|
-
*/
|
179
|
-
goog.style.getBackgroundColor = function(element) {
|
180
|
-
return goog.style.getStyle_(element, 'backgroundColor');
|
181
|
-
};
|
182
|
-
|
183
|
-
|
184
|
-
/**
|
185
|
-
* Retrieves the computed value of the overflow-x CSS attribute.
|
186
|
-
* @param {Element} element The element to get the overflow-x of.
|
187
|
-
* @return {string} The computed string value of the overflow-x attribute.
|
188
|
-
*/
|
189
|
-
goog.style.getComputedOverflowX = function(element) {
|
190
|
-
return goog.style.getStyle_(element, 'overflowX');
|
191
|
-
};
|
192
|
-
|
193
|
-
|
194
|
-
/**
|
195
|
-
* Retrieves the computed value of the overflow-y CSS attribute.
|
196
|
-
* @param {Element} element The element to get the overflow-y of.
|
197
|
-
* @return {string} The computed string value of the overflow-y attribute.
|
198
|
-
*/
|
199
|
-
goog.style.getComputedOverflowY = function(element) {
|
200
|
-
return goog.style.getStyle_(element, 'overflowY');
|
201
|
-
};
|
202
|
-
|
203
|
-
|
204
|
-
/**
|
205
|
-
* Retrieves the computed value of the z-index CSS attribute.
|
206
|
-
* @param {Element} element The element to get the z-index of.
|
207
|
-
* @return {string|number} The computed value of the z-index attribute.
|
208
|
-
*/
|
209
|
-
goog.style.getComputedZIndex = function(element) {
|
210
|
-
return goog.style.getStyle_(element, 'zIndex');
|
211
|
-
};
|
212
|
-
|
213
|
-
|
214
|
-
/**
|
215
|
-
* Retrieves the computed value of the text-align CSS attribute.
|
216
|
-
* @param {Element} element The element to get the text-align of.
|
217
|
-
* @return {string} The computed string value of the text-align attribute.
|
218
|
-
*/
|
219
|
-
goog.style.getComputedTextAlign = function(element) {
|
220
|
-
return goog.style.getStyle_(element, 'textAlign');
|
221
|
-
};
|
222
|
-
|
223
|
-
|
224
|
-
/**
|
225
|
-
* Retrieves the computed value of the cursor CSS attribute.
|
226
|
-
* @param {Element} element The element to get the cursor of.
|
227
|
-
* @return {string} The computed string value of the cursor attribute.
|
228
|
-
*/
|
229
|
-
goog.style.getComputedCursor = function(element) {
|
230
|
-
return goog.style.getStyle_(element, 'cursor');
|
231
|
-
};
|
232
|
-
|
233
|
-
|
234
|
-
/**
|
235
|
-
* Sets the top/left values of an element. If no unit is specified in the
|
236
|
-
* argument then it will add px.
|
237
|
-
* @param {Element} el Element to move.
|
238
|
-
* @param {string|number|goog.math.Coordinate} arg1 Left position or coordinate.
|
239
|
-
* @param {string|number=} opt_arg2 Top position.
|
240
|
-
*/
|
241
|
-
goog.style.setPosition = function(el, arg1, opt_arg2) {
|
242
|
-
var x, y;
|
243
|
-
var buggyGeckoSubPixelPos = goog.userAgent.GECKO &&
|
244
|
-
(goog.userAgent.MAC || goog.userAgent.X11) &&
|
245
|
-
goog.userAgent.isVersion('1.9');
|
246
|
-
|
247
|
-
if (arg1 instanceof goog.math.Coordinate) {
|
248
|
-
x = arg1.x;
|
249
|
-
y = arg1.y;
|
250
|
-
} else {
|
251
|
-
x = arg1;
|
252
|
-
y = opt_arg2;
|
253
|
-
}
|
254
|
-
|
255
|
-
// Round to the nearest pixel for buggy sub-pixel support.
|
256
|
-
el.style.left = goog.style.getPixelStyleValue_(
|
257
|
-
/** @type {number|string} */ (x), buggyGeckoSubPixelPos);
|
258
|
-
el.style.top = goog.style.getPixelStyleValue_(
|
259
|
-
/** @type {number|string} */ (y), buggyGeckoSubPixelPos);
|
260
|
-
};
|
261
|
-
|
262
|
-
|
263
|
-
/**
|
264
|
-
* Gets the offsetLeft and offsetTop properties of an element and returns them
|
265
|
-
* in a Coordinate object
|
266
|
-
* @param {Element} element Element.
|
267
|
-
* @return {!goog.math.Coordinate} The position.
|
268
|
-
*/
|
269
|
-
goog.style.getPosition = function(element) {
|
270
|
-
return new goog.math.Coordinate(element.offsetLeft, element.offsetTop);
|
271
|
-
};
|
272
|
-
|
273
|
-
|
274
|
-
/**
|
275
|
-
* Returns the viewport element for a particular document
|
276
|
-
* @param {Node=} opt_node DOM node (Document is OK) to get the viewport element
|
277
|
-
* of.
|
278
|
-
* @return {Element} document.documentElement or document.body.
|
279
|
-
*/
|
280
|
-
goog.style.getClientViewportElement = function(opt_node) {
|
281
|
-
var doc;
|
282
|
-
if (opt_node) {
|
283
|
-
if (opt_node.nodeType == goog.dom.NodeType.DOCUMENT) {
|
284
|
-
doc = opt_node;
|
285
|
-
} else {
|
286
|
-
doc = goog.dom.getOwnerDocument(opt_node);
|
287
|
-
}
|
288
|
-
} else {
|
289
|
-
doc = goog.dom.getDocument();
|
290
|
-
}
|
291
|
-
|
292
|
-
// In old IE versions the document.body represented the viewport
|
293
|
-
if (goog.userAgent.IE && !goog.dom.getDomHelper(doc).isCss1CompatMode()) {
|
294
|
-
return doc.body;
|
295
|
-
}
|
296
|
-
return doc.documentElement;
|
297
|
-
};
|
298
|
-
|
299
|
-
|
300
|
-
/**
|
301
|
-
* Gets the client rectangle of the DOM element.
|
302
|
-
*
|
303
|
-
* getBoundingClientRect is part of a new CSS object model draft (with a
|
304
|
-
* long-time presence in IE), replacing the error-prone parent offset
|
305
|
-
* computation and the now-deprecated Gecko getBoxObjectFor.
|
306
|
-
*
|
307
|
-
* This utility patches common browser bugs in getClientBoundingRect. It
|
308
|
-
* will fail if getClientBoundingRect is unsupported.
|
309
|
-
*
|
310
|
-
* If the element is not in the DOM, the result is undefined, and an error may
|
311
|
-
* be thrown depending on user agent.
|
312
|
-
*
|
313
|
-
* @param {Element} el The element whose bounding rectangle is being queried.
|
314
|
-
* @return {Object} A native bounding rectangle with numerical left, top,
|
315
|
-
* right, and bottom. Reported by Firefox to be of object type ClientRect.
|
316
|
-
* @private
|
317
|
-
*/
|
318
|
-
goog.style.getBoundingClientRect_ = function(el) {
|
319
|
-
var rect = el.getBoundingClientRect();
|
320
|
-
// Patch the result in IE only, so that this function can be inlined if
|
321
|
-
// compiled for non-IE.
|
322
|
-
if (goog.userAgent.IE) {
|
323
|
-
|
324
|
-
// In IE, most of the time, 2 extra pixels are added to the top and left
|
325
|
-
// due to the implicit 2-pixel inset border. In IE6/7 quirks mode and
|
326
|
-
// IE6 standards mode, this border can be overridden by setting the
|
327
|
-
// document element's border to zero -- thus, we cannot rely on the
|
328
|
-
// offset always being 2 pixels.
|
329
|
-
|
330
|
-
// In quirks mode, the offset can be determined by querying the body's
|
331
|
-
// clientLeft/clientTop, but in standards mode, it is found by querying
|
332
|
-
// the document element's clientLeft/clientTop. Since we already called
|
333
|
-
// getClientBoundingRect we have already forced a reflow, so it is not
|
334
|
-
// too expensive just to query them all.
|
335
|
-
|
336
|
-
// See: http://msdn.microsoft.com/en-us/library/ms536433(VS.85).aspx
|
337
|
-
var doc = el.ownerDocument;
|
338
|
-
rect.left -= doc.documentElement.clientLeft + doc.body.clientLeft;
|
339
|
-
rect.top -= doc.documentElement.clientTop + doc.body.clientTop;
|
340
|
-
}
|
341
|
-
return /** @type {Object} */ (rect);
|
342
|
-
};
|
343
|
-
|
344
|
-
|
345
|
-
/**
|
346
|
-
* Returns the first parent that could affect the position of a given element.
|
347
|
-
* @param {Element} element The element to get the offset parent for.
|
348
|
-
* @return {Element} The first offset parent or null if one cannot be found.
|
349
|
-
*/
|
350
|
-
goog.style.getOffsetParent = function(element) {
|
351
|
-
// element.offsetParent does the right thing in IE, in other browser it
|
352
|
-
// only includes elements with position absolute, relative or fixed, not
|
353
|
-
// elements with overflow set to auto or scroll.
|
354
|
-
if (goog.userAgent.IE) {
|
355
|
-
return element.offsetParent;
|
356
|
-
}
|
357
|
-
|
358
|
-
var doc = goog.dom.getOwnerDocument(element);
|
359
|
-
var positionStyle = goog.style.getStyle_(element, 'position');
|
360
|
-
var skipStatic = positionStyle == 'fixed' || positionStyle == 'absolute';
|
361
|
-
for (var parent = element.parentNode; parent && parent != doc;
|
362
|
-
parent = parent.parentNode) {
|
363
|
-
positionStyle =
|
364
|
-
goog.style.getStyle_(/** @type {!Element} */ (parent), 'position');
|
365
|
-
skipStatic = skipStatic && positionStyle == 'static' &&
|
366
|
-
parent != doc.documentElement && parent != doc.body;
|
367
|
-
if (!skipStatic && (parent.scrollWidth > parent.clientWidth ||
|
368
|
-
parent.scrollHeight > parent.clientHeight ||
|
369
|
-
positionStyle == 'fixed' ||
|
370
|
-
positionStyle == 'absolute')) {
|
371
|
-
return /** @type {!Element} */ (parent);
|
372
|
-
}
|
373
|
-
}
|
374
|
-
return null;
|
375
|
-
};
|
376
|
-
|
377
|
-
|
378
|
-
/**
|
379
|
-
* Calculates and returns the visible rectangle for a given element. Returns a
|
380
|
-
* box describing the visible portion of the nearest scrollable ancestor.
|
381
|
-
* Coordinates are given relative to the document.
|
382
|
-
*
|
383
|
-
* @param {Element} element Element to get the visible rect for.
|
384
|
-
* @return {goog.math.Box} Bounding elementBox describing the visible rect or
|
385
|
-
* null if scrollable ancestor isn't inside the visible viewport.
|
386
|
-
*/
|
387
|
-
goog.style.getVisibleRectForElement = function(element) {
|
388
|
-
var visibleRect = new goog.math.Box(0, Infinity, Infinity, 0);
|
389
|
-
var dom = goog.dom.getDomHelper(element);
|
390
|
-
var body = dom.getDocument().body;
|
391
|
-
var scrollEl = dom.getDocumentScrollElement();
|
392
|
-
var inContainer;
|
393
|
-
|
394
|
-
// Determine the size of the visible rect by climbing the dom accounting for
|
395
|
-
// all scrollable containers.
|
396
|
-
for (var el = element; el = goog.style.getOffsetParent(el); ) {
|
397
|
-
// clientWidth is zero for inline block elements in IE.
|
398
|
-
// on WEBKIT, body element can have clientHeight = 0 and scrollHeight > 0
|
399
|
-
if ((!goog.userAgent.IE || el.clientWidth != 0) &&
|
400
|
-
(!goog.userAgent.WEBKIT || el.clientHeight != 0 || el != body) &&
|
401
|
-
(el.scrollWidth != el.clientWidth ||
|
402
|
-
el.scrollHeight != el.clientHeight) &&
|
403
|
-
goog.style.getStyle_(el, 'overflow') != 'visible') {
|
404
|
-
var pos = goog.style.getPageOffset(el);
|
405
|
-
var client = goog.style.getClientLeftTop(el);
|
406
|
-
pos.x += client.x;
|
407
|
-
pos.y += client.y;
|
408
|
-
|
409
|
-
visibleRect.top = Math.max(visibleRect.top, pos.y);
|
410
|
-
visibleRect.right = Math.min(visibleRect.right,
|
411
|
-
pos.x + el.clientWidth);
|
412
|
-
visibleRect.bottom = Math.min(visibleRect.bottom,
|
413
|
-
pos.y + el.clientHeight);
|
414
|
-
visibleRect.left = Math.max(visibleRect.left, pos.x);
|
415
|
-
inContainer = inContainer || el != scrollEl;
|
416
|
-
}
|
417
|
-
}
|
418
|
-
|
419
|
-
// Compensate for document scroll in non webkit browsers.
|
420
|
-
var scrollX = scrollEl.scrollLeft, scrollY = scrollEl.scrollTop;
|
421
|
-
if (goog.userAgent.WEBKIT) {
|
422
|
-
visibleRect.left += scrollX;
|
423
|
-
visibleRect.top += scrollY;
|
424
|
-
} else {
|
425
|
-
visibleRect.left = Math.max(visibleRect.left, scrollX);
|
426
|
-
visibleRect.top = Math.max(visibleRect.top, scrollY);
|
427
|
-
}
|
428
|
-
if (!inContainer || goog.userAgent.WEBKIT) {
|
429
|
-
visibleRect.right += scrollX;
|
430
|
-
visibleRect.bottom += scrollY;
|
431
|
-
}
|
432
|
-
|
433
|
-
// Clip by the window's viewport.
|
434
|
-
var winSize = dom.getViewportSize();
|
435
|
-
visibleRect.right = Math.min(visibleRect.right, scrollX + winSize.width);
|
436
|
-
visibleRect.bottom = Math.min(visibleRect.bottom, scrollY + winSize.height);
|
437
|
-
|
438
|
-
return visibleRect.top >= 0 && visibleRect.left >= 0 &&
|
439
|
-
visibleRect.bottom > visibleRect.top &&
|
440
|
-
visibleRect.right > visibleRect.left ?
|
441
|
-
visibleRect : null;
|
442
|
-
};
|
443
|
-
|
444
|
-
|
445
|
-
/**
|
446
|
-
* Changes the scroll position of {@code container} with the minimum amount so
|
447
|
-
* that the content and the borders of the given {@code element} become visible.
|
448
|
-
* If the element is bigger than the container, its top left corner will be
|
449
|
-
* aligned to the container's top left corner.
|
450
|
-
*
|
451
|
-
* @param {Element} element The element to make visible.
|
452
|
-
* @param {Element} container The container to scroll.
|
453
|
-
* @param {boolean=} opt_center Whether to center the element in the container.
|
454
|
-
* Defaults to false.
|
455
|
-
*/
|
456
|
-
goog.style.scrollIntoContainerView = function(element, container, opt_center) {
|
457
|
-
// Absolute position of the element's border's top left corner.
|
458
|
-
var elementPos = goog.style.getPageOffset(element);
|
459
|
-
// Absolute position of the container's border's top left corner.
|
460
|
-
var containerPos = goog.style.getPageOffset(container);
|
461
|
-
var containerBorder = goog.style.getBorderBox(container);
|
462
|
-
// Relative pos. of the element's border box to the container's content box.
|
463
|
-
var relX = elementPos.x - containerPos.x - containerBorder.left;
|
464
|
-
var relY = elementPos.y - containerPos.y - containerBorder.top;
|
465
|
-
// How much the element can move in the container, i.e. the difference between
|
466
|
-
// the element's bottom-right-most and top-left-most position where it's
|
467
|
-
// fully visible.
|
468
|
-
var spaceX = container.clientWidth - element.offsetWidth;
|
469
|
-
var spaceY = container.clientHeight - element.offsetHeight;
|
470
|
-
|
471
|
-
if (opt_center) {
|
472
|
-
// All browsers round non-integer scroll positions down.
|
473
|
-
container.scrollLeft += relX - spaceX / 2;
|
474
|
-
container.scrollTop += relY - spaceY / 2;
|
475
|
-
} else {
|
476
|
-
// This formula was designed to give the correct scroll values in the
|
477
|
-
// following cases:
|
478
|
-
// - element is higher than container (spaceY < 0) => scroll down by relY
|
479
|
-
// - element is not higher that container (spaceY >= 0):
|
480
|
-
// - it is above container (relY < 0) => scroll up by abs(relY)
|
481
|
-
// - it is below container (relY > spaceY) => scroll down by relY - spaceY
|
482
|
-
// - it is in the container => don't scroll
|
483
|
-
container.scrollLeft += Math.min(relX, Math.max(relX - spaceX, 0));
|
484
|
-
container.scrollTop += Math.min(relY, Math.max(relY - spaceY, 0));
|
485
|
-
}
|
486
|
-
};
|
487
|
-
|
488
|
-
|
489
|
-
/**
|
490
|
-
* Returns clientLeft (width of the left border and, if the directionality is
|
491
|
-
* right to left, the vertical scrollbar) and clientTop as a coordinate object.
|
492
|
-
*
|
493
|
-
* @param {Element} el Element to get clientLeft for.
|
494
|
-
* @return {!goog.math.Coordinate} Client left and top.
|
495
|
-
*/
|
496
|
-
goog.style.getClientLeftTop = function(el) {
|
497
|
-
// NOTE(user): Gecko prior to 1.9 doesn't support clientTop/Left, see
|
498
|
-
// https://bugzilla.mozilla.org/show_bug.cgi?id=111207
|
499
|
-
if (goog.userAgent.GECKO && !goog.userAgent.isVersion('1.9')) {
|
500
|
-
var left = parseFloat(goog.style.getComputedStyle(el, 'borderLeftWidth'));
|
501
|
-
if (goog.style.isRightToLeft(el)) {
|
502
|
-
var scrollbarWidth = el.offsetWidth - el.clientWidth - left -
|
503
|
-
parseFloat(goog.style.getComputedStyle(el, 'borderRightWidth'));
|
504
|
-
left += scrollbarWidth;
|
505
|
-
}
|
506
|
-
return new goog.math.Coordinate(left,
|
507
|
-
parseFloat(goog.style.getComputedStyle(el, 'borderTopWidth')));
|
508
|
-
}
|
509
|
-
|
510
|
-
return new goog.math.Coordinate(el.clientLeft, el.clientTop);
|
511
|
-
};
|
512
|
-
|
513
|
-
|
514
|
-
/**
|
515
|
-
* Returns a Coordinate object relative to the top-left of the HTML document.
|
516
|
-
* Implemented as a single function to save having to do two recursive loops in
|
517
|
-
* opera and safari just to get both coordinates. If you just want one value do
|
518
|
-
* use goog.style.getPageOffsetLeft() and goog.style.getPageOffsetTop(), but
|
519
|
-
* note if you call both those methods the tree will be analysed twice.
|
520
|
-
*
|
521
|
-
* @param {Element} el Element to get the page offset for.
|
522
|
-
* @return {!goog.math.Coordinate} The page offset.
|
523
|
-
*/
|
524
|
-
goog.style.getPageOffset = function(el) {
|
525
|
-
var box, doc = goog.dom.getOwnerDocument(el);
|
526
|
-
var positionStyle = goog.style.getStyle_(el, 'position');
|
527
|
-
|
528
|
-
// NOTE(user): Gecko pre 1.9 normally use getBoxObjectFor to calculate the
|
529
|
-
// position. When invoked for an element with position absolute and a negative
|
530
|
-
// position though it can be off by one. Therefor the recursive implementation
|
531
|
-
// is used in those (relatively rare) cases.
|
532
|
-
var BUGGY_GECKO_BOX_OBJECT = goog.userAgent.GECKO && doc.getBoxObjectFor &&
|
533
|
-
!el.getBoundingClientRect && positionStyle == 'absolute' &&
|
534
|
-
(box = doc.getBoxObjectFor(el)) && (box.screenX < 0 || box.screenY < 0);
|
535
|
-
|
536
|
-
// NOTE(user): If element is hidden (display none or disconnected or any the
|
537
|
-
// ancestors are hidden) we get (0,0) by default but we still do the
|
538
|
-
// accumulation of scroll position.
|
539
|
-
|
540
|
-
// TODO(user): Should we check if the node is disconnected and in that case
|
541
|
-
// return (0,0)?
|
542
|
-
|
543
|
-
var pos = new goog.math.Coordinate(0, 0);
|
544
|
-
var viewportElement = goog.style.getClientViewportElement(doc);
|
545
|
-
if (el == viewportElement) {
|
546
|
-
// viewport is always at 0,0 as that defined the coordinate system for this
|
547
|
-
// function - this avoids special case checks in the code below
|
548
|
-
return pos;
|
549
|
-
}
|
550
|
-
|
551
|
-
// IE and Gecko 1.9+.
|
552
|
-
if (el.getBoundingClientRect) {
|
553
|
-
box = goog.style.getBoundingClientRect_(el);
|
554
|
-
// Must add the scroll coordinates in to get the absolute page offset
|
555
|
-
// of element since getBoundingClientRect returns relative coordinates to
|
556
|
-
// the viewport.
|
557
|
-
var scrollCoord = goog.dom.getDomHelper(doc).getDocumentScroll();
|
558
|
-
pos.x = box.left + scrollCoord.x;
|
559
|
-
pos.y = box.top + scrollCoord.y;
|
560
|
-
|
561
|
-
// Gecko prior to 1.9.
|
562
|
-
} else if (doc.getBoxObjectFor && !BUGGY_GECKO_BOX_OBJECT) {
|
563
|
-
// Gecko ignores the scroll values for ancestors, up to 1.9. See:
|
564
|
-
// https://bugzilla.mozilla.org/show_bug.cgi?id=328881 and
|
565
|
-
// https://bugzilla.mozilla.org/show_bug.cgi?id=330619
|
566
|
-
|
567
|
-
box = doc.getBoxObjectFor(el);
|
568
|
-
// TODO(user): Fix the off-by-one error when window is scrolled down
|
569
|
-
// or right more than 1 pixel. The viewport offset does not move in lock
|
570
|
-
// step with the window scroll; it moves in increments of 2px and at
|
571
|
-
// somewhat random intervals.
|
572
|
-
var vpBox = doc.getBoxObjectFor(viewportElement);
|
573
|
-
pos.x = box.screenX - vpBox.screenX;
|
574
|
-
pos.y = box.screenY - vpBox.screenY;
|
575
|
-
|
576
|
-
// Safari, Opera and Camino up to 1.0.4.
|
577
|
-
} else {
|
578
|
-
var parent = el;
|
579
|
-
do {
|
580
|
-
pos.x += parent.offsetLeft;
|
581
|
-
pos.y += parent.offsetTop;
|
582
|
-
// For safari/chrome, we need to add parent's clientLeft/Top as well.
|
583
|
-
if (parent != el) {
|
584
|
-
pos.x += parent.clientLeft || 0;
|
585
|
-
pos.y += parent.clientTop || 0;
|
586
|
-
}
|
587
|
-
// In Safari when hit a position fixed element the rest of the offsets
|
588
|
-
// are not correct.
|
589
|
-
if (goog.userAgent.WEBKIT &&
|
590
|
-
goog.style.getComputedPosition(parent) == 'fixed') {
|
591
|
-
pos.x += doc.body.scrollLeft;
|
592
|
-
pos.y += doc.body.scrollTop;
|
593
|
-
break;
|
594
|
-
}
|
595
|
-
parent = parent.offsetParent;
|
596
|
-
} while (parent && parent != el);
|
597
|
-
|
598
|
-
// Opera & (safari absolute) incorrectly account for body offsetTop.
|
599
|
-
if (goog.userAgent.OPERA || (goog.userAgent.WEBKIT &&
|
600
|
-
positionStyle == 'absolute')) {
|
601
|
-
pos.y -= doc.body.offsetTop;
|
602
|
-
}
|
603
|
-
|
604
|
-
for (parent = el; (parent = goog.style.getOffsetParent(parent)) &&
|
605
|
-
parent != doc.body && parent != viewportElement; ) {
|
606
|
-
pos.x -= parent.scrollLeft;
|
607
|
-
// Workaround for a bug in Opera 9.2 (and earlier) where table rows may
|
608
|
-
// report an invalid scroll top value. The bug was fixed in Opera 9.5
|
609
|
-
// however as that version supports getBoundingClientRect it won't
|
610
|
-
// trigger this code path. https://bugs.opera.com/show_bug.cgi?id=249965
|
611
|
-
if (!goog.userAgent.OPERA || parent.tagName != 'TR') {
|
612
|
-
pos.y -= parent.scrollTop;
|
613
|
-
}
|
614
|
-
}
|
615
|
-
}
|
616
|
-
|
617
|
-
return pos;
|
618
|
-
};
|
619
|
-
|
620
|
-
|
621
|
-
/**
|
622
|
-
* Returns the left coordinate of an element relative to the HTML document
|
623
|
-
* @param {Element} el Elements.
|
624
|
-
* @return {number} The left coordinate.
|
625
|
-
*/
|
626
|
-
goog.style.getPageOffsetLeft = function(el) {
|
627
|
-
return goog.style.getPageOffset(el).x;
|
628
|
-
};
|
629
|
-
|
630
|
-
|
631
|
-
/**
|
632
|
-
* Returns the top coordinate of an element relative to the HTML document
|
633
|
-
* @param {Element} el Elements.
|
634
|
-
* @return {number} The top coordinate.
|
635
|
-
*/
|
636
|
-
goog.style.getPageOffsetTop = function(el) {
|
637
|
-
return goog.style.getPageOffset(el).y;
|
638
|
-
};
|
639
|
-
|
640
|
-
|
641
|
-
/**
|
642
|
-
* Returns a Coordinate object relative to the top-left of an HTML document
|
643
|
-
* in an ancestor frame of this element. Used for measuring the position of
|
644
|
-
* an element inside a frame relative to a containing frame.
|
645
|
-
*
|
646
|
-
* @param {Element} el Element to get the page offset for.
|
647
|
-
* @param {Window} relativeWin The window to measure relative to. If relativeWin
|
648
|
-
* is not in the ancestor frame chain of the element, we measure relative to
|
649
|
-
* the top-most window.
|
650
|
-
* @return {!goog.math.Coordinate} The page offset.
|
651
|
-
*/
|
652
|
-
goog.style.getFramedPageOffset = function(el, relativeWin) {
|
653
|
-
var position = new goog.math.Coordinate(0, 0);
|
654
|
-
|
655
|
-
// Iterate up the ancestor frame chain, keeping track of the current window
|
656
|
-
// and the current element in that window.
|
657
|
-
var currentWin = goog.dom.getWindow(goog.dom.getOwnerDocument(el));
|
658
|
-
var currentEl = el;
|
659
|
-
do {
|
660
|
-
// if we're at the top window, we want to get the page offset.
|
661
|
-
// if we're at an inner frame, we only want to get the window position
|
662
|
-
// so that we can determine the actual page offset in the context of
|
663
|
-
// the outer window.
|
664
|
-
var offset = currentWin == relativeWin ?
|
665
|
-
goog.style.getPageOffset(currentEl) :
|
666
|
-
goog.style.getClientPosition(currentEl);
|
667
|
-
|
668
|
-
position.x += offset.x;
|
669
|
-
position.y += offset.y;
|
670
|
-
} while (currentWin && currentWin != relativeWin &&
|
671
|
-
(currentEl = currentWin.frameElement) &&
|
672
|
-
(currentWin = currentWin.parent));
|
673
|
-
|
674
|
-
return position;
|
675
|
-
};
|
676
|
-
|
677
|
-
|
678
|
-
/**
|
679
|
-
* Translates the specified rect relative to origBase page, for newBase page.
|
680
|
-
* If origBase and newBase are the same, this function does nothing.
|
681
|
-
*
|
682
|
-
* @param {goog.math.Rect} rect The source rectangle relative to origBase page,
|
683
|
-
* and it will have the translated result.
|
684
|
-
* @param {goog.dom.DomHelper} origBase The DomHelper for the input rectangle.
|
685
|
-
* @param {goog.dom.DomHelper} newBase The DomHelper for the resultant
|
686
|
-
* coordinate. This must be a DOM for an ancestor frame of origBase
|
687
|
-
* or the same as origBase.
|
688
|
-
*/
|
689
|
-
goog.style.translateRectForAnotherFrame = function(rect, origBase, newBase) {
|
690
|
-
if (origBase.getDocument() != newBase.getDocument()) {
|
691
|
-
var body = origBase.getDocument().body;
|
692
|
-
var pos = goog.style.getFramedPageOffset(body, newBase.getWindow());
|
693
|
-
|
694
|
-
// Adjust Body's margin.
|
695
|
-
pos = goog.math.Coordinate.difference(pos, goog.style.getPageOffset(body));
|
696
|
-
|
697
|
-
if (goog.userAgent.IE && !origBase.isCss1CompatMode()) {
|
698
|
-
pos = goog.math.Coordinate.difference(pos, origBase.getDocumentScroll());
|
699
|
-
}
|
700
|
-
|
701
|
-
rect.left += pos.x;
|
702
|
-
rect.top += pos.y;
|
703
|
-
}
|
704
|
-
};
|
705
|
-
|
706
|
-
|
707
|
-
/**
|
708
|
-
* Returns the position of an element relative to another element in the
|
709
|
-
* document. A relative to B
|
710
|
-
* @param {Element|Event|goog.events.Event} a Element or mouse event whose
|
711
|
-
* position we're calculating.
|
712
|
-
* @param {Element|Event|goog.events.Event} b Element or mouse event position
|
713
|
-
* is relative to.
|
714
|
-
* @return {!goog.math.Coordinate} The relative position.
|
715
|
-
*/
|
716
|
-
goog.style.getRelativePosition = function(a, b) {
|
717
|
-
var ap = goog.style.getClientPosition(a);
|
718
|
-
var bp = goog.style.getClientPosition(b);
|
719
|
-
return new goog.math.Coordinate(ap.x - bp.x, ap.y - bp.y);
|
720
|
-
};
|
721
|
-
|
722
|
-
|
723
|
-
/**
|
724
|
-
* Returns the position relative to the client viewport.
|
725
|
-
* @param {Element|Event|goog.events.Event} el Element or a mouse / touch event.
|
726
|
-
* @return {!goog.math.Coordinate} The position.
|
727
|
-
*/
|
728
|
-
goog.style.getClientPosition = function(el) {
|
729
|
-
var pos = new goog.math.Coordinate;
|
730
|
-
if (el.nodeType == goog.dom.NodeType.ELEMENT) {
|
731
|
-
if (el.getBoundingClientRect) { // IE and Gecko 1.9+
|
732
|
-
var box = goog.style.getBoundingClientRect_(/** @type {Element} */ (el));
|
733
|
-
pos.x = box.left;
|
734
|
-
pos.y = box.top;
|
735
|
-
} else {
|
736
|
-
var scrollCoord = goog.dom.getDomHelper(/** @type {Element} */ (el))
|
737
|
-
.getDocumentScroll();
|
738
|
-
var pageCoord = goog.style.getPageOffset(/** @type {Element} */ (el));
|
739
|
-
pos.x = pageCoord.x - scrollCoord.x;
|
740
|
-
pos.y = pageCoord.y - scrollCoord.y;
|
741
|
-
}
|
742
|
-
} else {
|
743
|
-
var isAbstractedEvent = goog.isFunction(el.getBrowserEvent);
|
744
|
-
var targetEvent = el;
|
745
|
-
|
746
|
-
if (el.targetTouches) {
|
747
|
-
targetEvent = el.targetTouches[0];
|
748
|
-
} else if (isAbstractedEvent && el.getBrowserEvent().targetTouches) {
|
749
|
-
targetEvent = el.getBrowserEvent().targetTouches[0];
|
750
|
-
}
|
751
|
-
|
752
|
-
pos.x = targetEvent.clientX;
|
753
|
-
pos.y = targetEvent.clientY;
|
754
|
-
}
|
755
|
-
|
756
|
-
return pos;
|
757
|
-
};
|
758
|
-
|
759
|
-
|
760
|
-
/**
|
761
|
-
* Sets the top and left of an element such that it will have a
|
762
|
-
*
|
763
|
-
* @param {Element} el The element to set page offset for.
|
764
|
-
* @param {number|goog.math.Coordinate} x Left position or coordinate obj.
|
765
|
-
* @param {number=} opt_y Top position.
|
766
|
-
*/
|
767
|
-
goog.style.setPageOffset = function(el, x, opt_y) {
|
768
|
-
// Get current pageoffset
|
769
|
-
var cur = goog.style.getPageOffset(el);
|
770
|
-
|
771
|
-
if (x instanceof goog.math.Coordinate) {
|
772
|
-
opt_y = x.y;
|
773
|
-
x = x.x;
|
774
|
-
}
|
775
|
-
|
776
|
-
// NOTE(user): We cannot allow strings for x and y. We could but that would
|
777
|
-
// require us to manually transform between different units
|
778
|
-
|
779
|
-
// Work out deltas
|
780
|
-
var dx = x - cur.x;
|
781
|
-
var dy = opt_y - cur.y;
|
782
|
-
|
783
|
-
// Set position to current left/top + delta
|
784
|
-
goog.style.setPosition(el, el.offsetLeft + dx, el.offsetTop + dy);
|
785
|
-
};
|
786
|
-
|
787
|
-
|
788
|
-
/**
|
789
|
-
* Sets the width/height values of an element. If an argument is numeric,
|
790
|
-
* or a goog.math.Size is passed, it is assumed to be pixels and will add
|
791
|
-
* 'px' after converting it to an integer in string form. (This just sets the
|
792
|
-
* CSS width and height properties so it might set content-box or border-box
|
793
|
-
* size depending on the box model the browser is using.)
|
794
|
-
*
|
795
|
-
* @param {Element} element Element to set the size of.
|
796
|
-
* @param {string|number|goog.math.Size} w Width of the element, or a
|
797
|
-
* size object.
|
798
|
-
* @param {string|number=} opt_h Height of the element. Required if w is not a
|
799
|
-
* size object.
|
800
|
-
*/
|
801
|
-
goog.style.setSize = function(element, w, opt_h) {
|
802
|
-
var h;
|
803
|
-
if (w instanceof goog.math.Size) {
|
804
|
-
h = w.height;
|
805
|
-
w = w.width;
|
806
|
-
} else {
|
807
|
-
if (opt_h == undefined) {
|
808
|
-
throw Error('missing height argument');
|
809
|
-
}
|
810
|
-
h = opt_h;
|
811
|
-
}
|
812
|
-
|
813
|
-
goog.style.setWidth(element, /** @type {string|number} */ (w));
|
814
|
-
goog.style.setHeight(element, /** @type {string|number} */ (h));
|
815
|
-
};
|
816
|
-
|
817
|
-
|
818
|
-
/**
|
819
|
-
* Helper function to create a string to be set into a pixel-value style
|
820
|
-
* property of an element. Can round to the nearest integer value.
|
821
|
-
*
|
822
|
-
* @param {string|number} value The style value to be used. If a number,
|
823
|
-
* 'px' will be appended, otherwise the value will be applied directly.
|
824
|
-
* @param {boolean} round Whether to round the nearest integer (if property
|
825
|
-
* is a number).
|
826
|
-
* @return {string} The string value for the property.
|
827
|
-
* @private
|
828
|
-
*/
|
829
|
-
goog.style.getPixelStyleValue_ = function(value, round) {
|
830
|
-
if (typeof value == 'number') {
|
831
|
-
value = (round ? Math.round(value) : value) + 'px';
|
832
|
-
}
|
833
|
-
|
834
|
-
return value;
|
835
|
-
};
|
836
|
-
|
837
|
-
|
838
|
-
/**
|
839
|
-
* Set the height of an element. Sets the element's style property.
|
840
|
-
* @param {Element} element Element to set the height of.
|
841
|
-
* @param {string|number} height The height value to set. If a number, 'px'
|
842
|
-
* will be appended, otherwise the value will be applied directly.
|
843
|
-
*/
|
844
|
-
goog.style.setHeight = function(element, height) {
|
845
|
-
element.style.height = goog.style.getPixelStyleValue_(height, true);
|
846
|
-
};
|
847
|
-
|
848
|
-
|
849
|
-
/**
|
850
|
-
* Set the width of an element. Sets the element's style property.
|
851
|
-
* @param {Element} element Element to set the height of.
|
852
|
-
* @param {string|number} width The width value to set. If a number, 'px'
|
853
|
-
* will be appended, otherwise the value will be applied directly.
|
854
|
-
*/
|
855
|
-
goog.style.setWidth = function(element, width) {
|
856
|
-
element.style.width = goog.style.getPixelStyleValue_(width, true);
|
857
|
-
};
|
858
|
-
|
859
|
-
|
860
|
-
/**
|
861
|
-
* Gets the height and width of an element, even if its display is none.
|
862
|
-
* Specifically, this returns the height and width of the border box,
|
863
|
-
* irrespective of the box model in effect.
|
864
|
-
* @param {Element} element Element to get width of.
|
865
|
-
* @return {!goog.math.Size} Object with width/height properties.
|
866
|
-
*/
|
867
|
-
goog.style.getSize = function(element) {
|
868
|
-
var hasOperaBug = goog.userAgent.OPERA && !goog.userAgent.isVersion('10');
|
869
|
-
if (goog.style.getStyle_(element, 'display') != 'none') {
|
870
|
-
if (hasOperaBug) {
|
871
|
-
return new goog.math.Size(element.offsetWidth || element.clientWidth,
|
872
|
-
element.offsetHeight || element.clientHeight);
|
873
|
-
} else {
|
874
|
-
return new goog.math.Size(element.offsetWidth, element.offsetHeight);
|
875
|
-
}
|
876
|
-
}
|
877
|
-
|
878
|
-
var style = element.style;
|
879
|
-
var originalDisplay = style.display;
|
880
|
-
var originalVisibility = style.visibility;
|
881
|
-
var originalPosition = style.position;
|
882
|
-
|
883
|
-
style.visibility = 'hidden';
|
884
|
-
style.position = 'absolute';
|
885
|
-
style.display = 'inline';
|
886
|
-
|
887
|
-
var originalWidth, originalHeight;
|
888
|
-
if (hasOperaBug) {
|
889
|
-
originalWidth = element.offsetWidth || element.clientWidth;
|
890
|
-
originalHeight = element.offsetHeight || element.clientHeight;
|
891
|
-
} else {
|
892
|
-
originalWidth = element.offsetWidth;
|
893
|
-
originalHeight = element.offsetHeight;
|
894
|
-
}
|
895
|
-
|
896
|
-
style.display = originalDisplay;
|
897
|
-
style.position = originalPosition;
|
898
|
-
style.visibility = originalVisibility;
|
899
|
-
|
900
|
-
return new goog.math.Size(originalWidth, originalHeight);
|
901
|
-
};
|
902
|
-
|
903
|
-
|
904
|
-
/**
|
905
|
-
* Returns a bounding rectangle for a given element in page space.
|
906
|
-
* @param {Element} element Element to get bounds of.
|
907
|
-
* @return {!goog.math.Rect} Bounding rectangle for the element.
|
908
|
-
*/
|
909
|
-
goog.style.getBounds = function(element) {
|
910
|
-
var o = goog.style.getPageOffset(element);
|
911
|
-
var s = goog.style.getSize(element);
|
912
|
-
return new goog.math.Rect(o.x, o.y, s.width, s.height);
|
913
|
-
};
|
914
|
-
|
915
|
-
|
916
|
-
/**
|
917
|
-
* Converts a CSS selector in the form style-property to styleProperty.
|
918
|
-
* @param {*} selector CSS Selector.
|
919
|
-
* @return {string} Camel case selector.
|
920
|
-
* @deprecated Use goog.string.toCamelCase instead.
|
921
|
-
*/
|
922
|
-
goog.style.toCamelCase = function(selector) {
|
923
|
-
return goog.string.toCamelCase(String(selector));
|
924
|
-
};
|
925
|
-
|
926
|
-
|
927
|
-
/**
|
928
|
-
* Converts a CSS selector in the form styleProperty to style-property.
|
929
|
-
* @param {string} selector Camel case selector.
|
930
|
-
* @return {string} Selector cased.
|
931
|
-
* @deprecated Use goog.string.toSelectorCase instead.
|
932
|
-
*/
|
933
|
-
goog.style.toSelectorCase = function(selector) {
|
934
|
-
return goog.string.toSelectorCase(selector);
|
935
|
-
};
|
936
|
-
|
937
|
-
|
938
|
-
/**
|
939
|
-
* Gets the opacity of a node (x-browser). This gets the inline style opacity
|
940
|
-
* of the node, and does not take into account the cascaded or the computed
|
941
|
-
* style for this node.
|
942
|
-
* @param {Element} el Element whose opacity has to be found.
|
943
|
-
* @return {number|string} Opacity between 0 and 1 or an empty string {@code ''}
|
944
|
-
* if the opacity is not set.
|
945
|
-
*/
|
946
|
-
goog.style.getOpacity = function(el) {
|
947
|
-
var style = el.style;
|
948
|
-
var result = '';
|
949
|
-
if ('opacity' in style) {
|
950
|
-
result = style.opacity;
|
951
|
-
} else if ('MozOpacity' in style) {
|
952
|
-
result = style.MozOpacity;
|
953
|
-
} else if ('filter' in style) {
|
954
|
-
var match = style.filter.match(/alpha\(opacity=([\d.]+)\)/);
|
955
|
-
if (match) {
|
956
|
-
result = String(match[1] / 100);
|
957
|
-
}
|
958
|
-
}
|
959
|
-
return result == '' ? result : Number(result);
|
960
|
-
};
|
961
|
-
|
962
|
-
|
963
|
-
/**
|
964
|
-
* Sets the opacity of a node (x-browser).
|
965
|
-
* @param {Element} el Elements whose opacity has to be set.
|
966
|
-
* @param {number|string} alpha Opacity between 0 and 1 or an empty string
|
967
|
-
* {@code ''} to clear the opacity.
|
968
|
-
*/
|
969
|
-
goog.style.setOpacity = function(el, alpha) {
|
970
|
-
var style = el.style;
|
971
|
-
if ('opacity' in style) {
|
972
|
-
style.opacity = alpha;
|
973
|
-
} else if ('MozOpacity' in style) {
|
974
|
-
style.MozOpacity = alpha;
|
975
|
-
} else if ('filter' in style) {
|
976
|
-
// TODO(user): Overwriting the filter might have undesired side effects.
|
977
|
-
if (alpha === '') {
|
978
|
-
style.filter = '';
|
979
|
-
} else {
|
980
|
-
style.filter = 'alpha(opacity=' + alpha * 100 + ')';
|
981
|
-
}
|
982
|
-
}
|
983
|
-
};
|
984
|
-
|
985
|
-
|
986
|
-
/**
|
987
|
-
* Sets the background of an element to a transparent image in a browser-
|
988
|
-
* independent manner.
|
989
|
-
*
|
990
|
-
* This function does not support repeating backgrounds or alternate background
|
991
|
-
* positions to match the behavior of Internet Explorer. It also does not
|
992
|
-
* support sizingMethods other than crop since they cannot be replicated in
|
993
|
-
* browsers other than Internet Explorer.
|
994
|
-
*
|
995
|
-
* @param {Element} el The element to set background on.
|
996
|
-
* @param {string} src The image source URL.
|
997
|
-
*/
|
998
|
-
goog.style.setTransparentBackgroundImage = function(el, src) {
|
999
|
-
var style = el.style;
|
1000
|
-
// It is safe to use the style.filter in IE only. In Safari 'filter' is in
|
1001
|
-
// style object but access to style.filter causes it to throw an exception.
|
1002
|
-
// Note: IE8 supports images with an alpha channel.
|
1003
|
-
if (goog.userAgent.IE && !goog.userAgent.isVersion('8')) {
|
1004
|
-
// See TODO in setOpacity.
|
1005
|
-
style.filter = 'progid:DXImageTransform.Microsoft.AlphaImageLoader(' +
|
1006
|
-
'src="' + src + '", sizingMethod="crop")';
|
1007
|
-
} else {
|
1008
|
-
// Set style properties individually instead of using background shorthand
|
1009
|
-
// to prevent overwriting a pre-existing background color.
|
1010
|
-
style.backgroundImage = 'url(' + src + ')';
|
1011
|
-
style.backgroundPosition = 'top left';
|
1012
|
-
style.backgroundRepeat = 'no-repeat';
|
1013
|
-
}
|
1014
|
-
};
|
1015
|
-
|
1016
|
-
|
1017
|
-
/**
|
1018
|
-
* Clears the background image of an element in a browser independent manner.
|
1019
|
-
* @param {Element} el The element to clear background image for.
|
1020
|
-
*/
|
1021
|
-
goog.style.clearTransparentBackgroundImage = function(el) {
|
1022
|
-
var style = el.style;
|
1023
|
-
if ('filter' in style) {
|
1024
|
-
// See TODO in setOpacity.
|
1025
|
-
style.filter = '';
|
1026
|
-
} else {
|
1027
|
-
// Set style properties individually instead of using background shorthand
|
1028
|
-
// to prevent overwriting a pre-existing background color.
|
1029
|
-
style.backgroundImage = 'none';
|
1030
|
-
}
|
1031
|
-
};
|
1032
|
-
|
1033
|
-
|
1034
|
-
/**
|
1035
|
-
* Shows or hides an element from the page. Hiding the element is done by
|
1036
|
-
* setting the display property to "none", removing the element from the
|
1037
|
-
* rendering hierarchy so it takes up no space. To show the element, the default
|
1038
|
-
* inherited display property is restored (defined either in stylesheets or by
|
1039
|
-
* the browser's default style rules.)
|
1040
|
-
*
|
1041
|
-
* Caveat 1: if the inherited display property for the element is set to "none"
|
1042
|
-
* by the stylesheets, that is the property that will be restored by a call to
|
1043
|
-
* showElement(), effectively toggling the display between "none" and "none".
|
1044
|
-
*
|
1045
|
-
* Caveat 2: if the element display style is set inline (by setting either
|
1046
|
-
* element.style.display or a style attribute in the HTML), a call to
|
1047
|
-
* showElement will clear that setting and defer to the inherited style in the
|
1048
|
-
* stylesheet.
|
1049
|
-
* @param {Element} el Element to show or hide.
|
1050
|
-
* @param {*} display True to render the element in its default style,
|
1051
|
-
* false to disable rendering the element.
|
1052
|
-
*/
|
1053
|
-
goog.style.showElement = function(el, display) {
|
1054
|
-
el.style.display = display ? '' : 'none';
|
1055
|
-
};
|
1056
|
-
|
1057
|
-
|
1058
|
-
/**
|
1059
|
-
* Test whether the given element has been shown or hidden via a call to
|
1060
|
-
* {@link #showElement}.
|
1061
|
-
*
|
1062
|
-
* Note this is strictly a companion method for a call
|
1063
|
-
* to {@link #showElement} and the same caveats apply; in particular, this
|
1064
|
-
* method does not guarantee that the return value will be consistent with
|
1065
|
-
* whether or not the element is actually visible.
|
1066
|
-
*
|
1067
|
-
* @param {Element} el The element to test.
|
1068
|
-
* @return {boolean} Whether the element has been shown.
|
1069
|
-
* @see #showElement
|
1070
|
-
*/
|
1071
|
-
goog.style.isElementShown = function(el) {
|
1072
|
-
return el.style.display != 'none';
|
1073
|
-
};
|
1074
|
-
|
1075
|
-
|
1076
|
-
/**
|
1077
|
-
* Installs the styles string into the window that contains opt_element. If
|
1078
|
-
* opt_element is null, the main window is used.
|
1079
|
-
* @param {string} stylesString The style string to install.
|
1080
|
-
* @param {Node=} opt_node Node whose parent document should have the
|
1081
|
-
* styles installed.
|
1082
|
-
* @return {Element|StyleSheet} The style element created.
|
1083
|
-
*/
|
1084
|
-
goog.style.installStyles = function(stylesString, opt_node) {
|
1085
|
-
var dh = goog.dom.getDomHelper(opt_node);
|
1086
|
-
var styleSheet = null;
|
1087
|
-
|
1088
|
-
if (goog.userAgent.IE) {
|
1089
|
-
styleSheet = dh.getDocument().createStyleSheet();
|
1090
|
-
goog.style.setStyles(styleSheet, stylesString);
|
1091
|
-
} else {
|
1092
|
-
var head = dh.getElementsByTagNameAndClass('head')[0];
|
1093
|
-
|
1094
|
-
// In opera documents are not guaranteed to have a head element, thus we
|
1095
|
-
// have to make sure one exists before using it.
|
1096
|
-
if (!head) {
|
1097
|
-
var body = dh.getElementsByTagNameAndClass('body')[0];
|
1098
|
-
head = dh.createDom('head');
|
1099
|
-
body.parentNode.insertBefore(head, body);
|
1100
|
-
}
|
1101
|
-
styleSheet = dh.createDom('style');
|
1102
|
-
// NOTE(user): Setting styles after the style element has been appended
|
1103
|
-
// to the head results in a nasty Webkit bug in certain scenarios. Please
|
1104
|
-
// refer to https://bugs.webkit.org/show_bug.cgi?id=26307 for additional
|
1105
|
-
// details.
|
1106
|
-
goog.style.setStyles(styleSheet, stylesString);
|
1107
|
-
dh.appendChild(head, styleSheet);
|
1108
|
-
}
|
1109
|
-
return styleSheet;
|
1110
|
-
};
|
1111
|
-
|
1112
|
-
|
1113
|
-
/**
|
1114
|
-
* Removes the styles added by {@link #installStyles}.
|
1115
|
-
* @param {Element|StyleSheet} styleSheet The value returned by
|
1116
|
-
* {@link #installStyles}.
|
1117
|
-
*/
|
1118
|
-
goog.style.uninstallStyles = function(styleSheet) {
|
1119
|
-
var node = styleSheet.ownerNode || styleSheet.owningElement ||
|
1120
|
-
/** @type {Element} */ (styleSheet);
|
1121
|
-
goog.dom.removeNode(node);
|
1122
|
-
};
|
1123
|
-
|
1124
|
-
|
1125
|
-
/**
|
1126
|
-
* Sets the content of a style element. The style element can be any valid
|
1127
|
-
* style element. This element will have its content completely replaced by
|
1128
|
-
* the new stylesString.
|
1129
|
-
* @param {Element|StyleSheet} element A stylesheet element as returned by
|
1130
|
-
* installStyles.
|
1131
|
-
* @param {string} stylesString The new content of the stylesheet.
|
1132
|
-
*/
|
1133
|
-
goog.style.setStyles = function(element, stylesString) {
|
1134
|
-
if (goog.userAgent.IE) {
|
1135
|
-
// Adding the selectors individually caused the browser to hang if the
|
1136
|
-
// selector was invalid or there were CSS comments. Setting the cssText of
|
1137
|
-
// the style node works fine and ignores CSS that IE doesn't understand
|
1138
|
-
element.cssText = stylesString;
|
1139
|
-
} else {
|
1140
|
-
var propToSet = goog.userAgent.WEBKIT ? 'innerText' : 'innerHTML';
|
1141
|
-
element[propToSet] = stylesString;
|
1142
|
-
}
|
1143
|
-
};
|
1144
|
-
|
1145
|
-
|
1146
|
-
/**
|
1147
|
-
* Sets 'white-space: pre-wrap' for a node (x-browser).
|
1148
|
-
*
|
1149
|
-
* There are as many ways of specifying pre-wrap as there are browsers.
|
1150
|
-
*
|
1151
|
-
* CSS3/IE8: white-space: pre-wrap;
|
1152
|
-
* Mozilla: white-space: -moz-pre-wrap;
|
1153
|
-
* Opera: white-space: -o-pre-wrap;
|
1154
|
-
* IE6/7: white-space: pre; word-wrap: break-word;
|
1155
|
-
*
|
1156
|
-
* @param {Element} el Element to enable pre-wrap for.
|
1157
|
-
*/
|
1158
|
-
goog.style.setPreWrap = function(el) {
|
1159
|
-
var style = el.style;
|
1160
|
-
if (goog.userAgent.IE && !goog.userAgent.isVersion('8')) {
|
1161
|
-
style.whiteSpace = 'pre';
|
1162
|
-
style.wordWrap = 'break-word';
|
1163
|
-
} else if (goog.userAgent.GECKO) {
|
1164
|
-
style.whiteSpace = '-moz-pre-wrap';
|
1165
|
-
} else if (goog.userAgent.OPERA) {
|
1166
|
-
style.whiteSpace = '-o-pre-wrap';
|
1167
|
-
} else {
|
1168
|
-
style.whiteSpace = 'pre-wrap';
|
1169
|
-
}
|
1170
|
-
};
|
1171
|
-
|
1172
|
-
|
1173
|
-
/**
|
1174
|
-
* Sets 'display: inline-block' for an element (cross-browser).
|
1175
|
-
* @param {Element} el Element to which the inline-block display style is to be
|
1176
|
-
* applied.
|
1177
|
-
* @see ../demos/inline_block_quirks.html
|
1178
|
-
* @see ../demos/inline_block_standards.html
|
1179
|
-
*/
|
1180
|
-
goog.style.setInlineBlock = function(el) {
|
1181
|
-
var style = el.style;
|
1182
|
-
// Without position:relative, weirdness ensues. Just accept it and move on.
|
1183
|
-
style.position = 'relative';
|
1184
|
-
|
1185
|
-
if (goog.userAgent.IE && !goog.userAgent.isVersion('8')) {
|
1186
|
-
// IE8 supports inline-block so fall through to the else
|
1187
|
-
// Zoom:1 forces hasLayout, display:inline gives inline behavior.
|
1188
|
-
style.zoom = '1';
|
1189
|
-
style.display = 'inline';
|
1190
|
-
} else if (goog.userAgent.GECKO) {
|
1191
|
-
// Pre-Firefox 3, Gecko doesn't support inline-block, but -moz-inline-box
|
1192
|
-
// is close enough.
|
1193
|
-
style.display = goog.userAgent.isVersion('1.9a') ? 'inline-block' :
|
1194
|
-
'-moz-inline-box';
|
1195
|
-
} else {
|
1196
|
-
// Opera, Webkit, and Safari seem to do OK with the standard inline-block
|
1197
|
-
// style.
|
1198
|
-
style.display = 'inline-block';
|
1199
|
-
}
|
1200
|
-
};
|
1201
|
-
|
1202
|
-
|
1203
|
-
/**
|
1204
|
-
* Returns true if the element is using right to left (rtl) direction.
|
1205
|
-
* @param {Element} el The element to test.
|
1206
|
-
* @return {boolean} True for right to left, false for left to right.
|
1207
|
-
*/
|
1208
|
-
goog.style.isRightToLeft = function(el) {
|
1209
|
-
return 'rtl' == goog.style.getStyle_(el, 'direction');
|
1210
|
-
};
|
1211
|
-
|
1212
|
-
|
1213
|
-
/**
|
1214
|
-
* The CSS style property corresponding to an element being
|
1215
|
-
* unselectable on the current browser platform (null if none).
|
1216
|
-
* Opera and IE instead use a DOM attribute 'unselectable'.
|
1217
|
-
* @type {?string}
|
1218
|
-
* @private
|
1219
|
-
*/
|
1220
|
-
goog.style.unselectableStyle_ =
|
1221
|
-
goog.userAgent.GECKO ? 'MozUserSelect' :
|
1222
|
-
goog.userAgent.WEBKIT ? 'WebkitUserSelect' :
|
1223
|
-
null;
|
1224
|
-
|
1225
|
-
|
1226
|
-
/**
|
1227
|
-
* Returns true if the element is set to be unselectable, false otherwise.
|
1228
|
-
* Note that on some platforms (e.g. Mozilla), even if an element isn't set
|
1229
|
-
* to be unselectable, it will behave as such if any of its ancestors is
|
1230
|
-
* unselectable.
|
1231
|
-
* @param {Element} el Element to check.
|
1232
|
-
* @return {boolean} Whether the element is set to be unselectable.
|
1233
|
-
*/
|
1234
|
-
goog.style.isUnselectable = function(el) {
|
1235
|
-
if (goog.style.unselectableStyle_) {
|
1236
|
-
return el.style[goog.style.unselectableStyle_].toLowerCase() == 'none';
|
1237
|
-
} else if (goog.userAgent.IE || goog.userAgent.OPERA) {
|
1238
|
-
return el.getAttribute('unselectable') == 'on';
|
1239
|
-
}
|
1240
|
-
return false;
|
1241
|
-
};
|
1242
|
-
|
1243
|
-
|
1244
|
-
/**
|
1245
|
-
* Makes the element and its descendants selectable or unselectable. Note
|
1246
|
-
* that on some platforms (e.g. Mozilla), even if an element isn't set to
|
1247
|
-
* be unselectable, it will behave as such if any of its ancestors is
|
1248
|
-
* unselectable.
|
1249
|
-
* @param {Element} el The element to alter.
|
1250
|
-
* @param {boolean} unselectable Whether the element and its descendants
|
1251
|
-
* should be made unselectable.
|
1252
|
-
* @param {boolean=} opt_noRecurse Whether to only alter the element's own
|
1253
|
-
* selectable state, and leave its descendants alone; defaults to false.
|
1254
|
-
*/
|
1255
|
-
goog.style.setUnselectable = function(el, unselectable, opt_noRecurse) {
|
1256
|
-
// TODO(user): Do we need all of TR_DomUtil.makeUnselectable() in Closure?
|
1257
|
-
var descendants = !opt_noRecurse ? el.getElementsByTagName('*') : null;
|
1258
|
-
var name = goog.style.unselectableStyle_;
|
1259
|
-
if (name) {
|
1260
|
-
// Add/remove the appropriate CSS style to/from the element and its
|
1261
|
-
// descendants.
|
1262
|
-
var value = unselectable ? 'none' : '';
|
1263
|
-
el.style[name] = value;
|
1264
|
-
if (descendants) {
|
1265
|
-
for (var i = 0, descendant; descendant = descendants[i]; i++) {
|
1266
|
-
descendant.style[name] = value;
|
1267
|
-
}
|
1268
|
-
}
|
1269
|
-
} else if (goog.userAgent.IE || goog.userAgent.OPERA) {
|
1270
|
-
// Toggle the 'unselectable' attribute on the element and its descendants.
|
1271
|
-
var value = unselectable ? 'on' : '';
|
1272
|
-
el.setAttribute('unselectable', value);
|
1273
|
-
if (descendants) {
|
1274
|
-
for (var i = 0, descendant; descendant = descendants[i]; i++) {
|
1275
|
-
descendant.setAttribute('unselectable', value);
|
1276
|
-
}
|
1277
|
-
}
|
1278
|
-
}
|
1279
|
-
};
|
1280
|
-
|
1281
|
-
|
1282
|
-
/**
|
1283
|
-
* Gets the border box size for an element.
|
1284
|
-
* @param {Element} element The element to get the size for.
|
1285
|
-
* @return {!goog.math.Size} The border box size.
|
1286
|
-
*/
|
1287
|
-
goog.style.getBorderBoxSize = function(element) {
|
1288
|
-
return new goog.math.Size(element.offsetWidth, element.offsetHeight);
|
1289
|
-
};
|
1290
|
-
|
1291
|
-
|
1292
|
-
/**
|
1293
|
-
* Sets the border box size of an element. This is potentially expensive in IE
|
1294
|
-
* if the document is CSS1Compat mode
|
1295
|
-
* @param {Element} element The element to set the size on.
|
1296
|
-
* @param {goog.math.Size} size The new size.
|
1297
|
-
*/
|
1298
|
-
goog.style.setBorderBoxSize = function(element, size) {
|
1299
|
-
var doc = goog.dom.getOwnerDocument(element);
|
1300
|
-
var isCss1CompatMode = goog.dom.getDomHelper(doc).isCss1CompatMode();
|
1301
|
-
|
1302
|
-
if (goog.userAgent.IE &&
|
1303
|
-
(!isCss1CompatMode || !goog.userAgent.isVersion('8'))) {
|
1304
|
-
var style = element.style;
|
1305
|
-
if (isCss1CompatMode) {
|
1306
|
-
var paddingBox = goog.style.getPaddingBox(element);
|
1307
|
-
var borderBox = goog.style.getBorderBox(element);
|
1308
|
-
style.pixelWidth = size.width - borderBox.left - paddingBox.left -
|
1309
|
-
paddingBox.right - borderBox.right;
|
1310
|
-
style.pixelHeight = size.height - borderBox.top - paddingBox.top -
|
1311
|
-
paddingBox.bottom - borderBox.bottom;
|
1312
|
-
} else {
|
1313
|
-
style.pixelWidth = size.width;
|
1314
|
-
style.pixelHeight = size.height;
|
1315
|
-
}
|
1316
|
-
} else {
|
1317
|
-
goog.style.setBoxSizingSize_(element, size, 'border-box');
|
1318
|
-
}
|
1319
|
-
};
|
1320
|
-
|
1321
|
-
|
1322
|
-
/**
|
1323
|
-
* Gets the content box size for an element. This is potentially expensive in
|
1324
|
-
* all browsers.
|
1325
|
-
* @param {Element} element The element to get the size for.
|
1326
|
-
* @return {!goog.math.Size} The content box size.
|
1327
|
-
*/
|
1328
|
-
goog.style.getContentBoxSize = function(element) {
|
1329
|
-
var doc = goog.dom.getOwnerDocument(element);
|
1330
|
-
var ieCurrentStyle = goog.userAgent.IE && element.currentStyle;
|
1331
|
-
if (ieCurrentStyle &&
|
1332
|
-
goog.dom.getDomHelper(doc).isCss1CompatMode() &&
|
1333
|
-
ieCurrentStyle.width != 'auto' && ieCurrentStyle.height != 'auto' &&
|
1334
|
-
!ieCurrentStyle.boxSizing) {
|
1335
|
-
// If IE in CSS1Compat mode than just use the width and height.
|
1336
|
-
// If we have a boxSizing then fall back on measuring the borders etc.
|
1337
|
-
var width = goog.style.getIePixelValue_(element, ieCurrentStyle.width,
|
1338
|
-
'width', 'pixelWidth');
|
1339
|
-
var height = goog.style.getIePixelValue_(element, ieCurrentStyle.height,
|
1340
|
-
'height', 'pixelHeight');
|
1341
|
-
return new goog.math.Size(width, height);
|
1342
|
-
} else {
|
1343
|
-
var borderBoxSize = goog.style.getBorderBoxSize(element);
|
1344
|
-
var paddingBox = goog.style.getPaddingBox(element);
|
1345
|
-
var borderBox = goog.style.getBorderBox(element);
|
1346
|
-
return new goog.math.Size(borderBoxSize.width -
|
1347
|
-
borderBox.left - paddingBox.left -
|
1348
|
-
paddingBox.right - borderBox.right,
|
1349
|
-
borderBoxSize.height -
|
1350
|
-
borderBox.top - paddingBox.top -
|
1351
|
-
paddingBox.bottom - borderBox.bottom);
|
1352
|
-
}
|
1353
|
-
};
|
1354
|
-
|
1355
|
-
|
1356
|
-
/**
|
1357
|
-
* Sets the content box size of an element. This is potentially expensive in IE
|
1358
|
-
* if the document is BackCompat mode.
|
1359
|
-
* @param {Element} element The element to set the size on.
|
1360
|
-
* @param {goog.math.Size} size The new size.
|
1361
|
-
*/
|
1362
|
-
goog.style.setContentBoxSize = function(element, size) {
|
1363
|
-
var doc = goog.dom.getOwnerDocument(element);
|
1364
|
-
var isCss1CompatMode = goog.dom.getDomHelper(doc).isCss1CompatMode();
|
1365
|
-
if (goog.userAgent.IE &&
|
1366
|
-
(!isCss1CompatMode || !goog.userAgent.isVersion('8'))) {
|
1367
|
-
var style = element.style;
|
1368
|
-
if (isCss1CompatMode) {
|
1369
|
-
style.pixelWidth = size.width;
|
1370
|
-
style.pixelHeight = size.height;
|
1371
|
-
} else {
|
1372
|
-
var paddingBox = goog.style.getPaddingBox(element);
|
1373
|
-
var borderBox = goog.style.getBorderBox(element);
|
1374
|
-
style.pixelWidth = size.width + borderBox.left + paddingBox.left +
|
1375
|
-
paddingBox.right + borderBox.right;
|
1376
|
-
style.pixelHeight = size.height + borderBox.top + paddingBox.top +
|
1377
|
-
paddingBox.bottom + borderBox.bottom;
|
1378
|
-
}
|
1379
|
-
} else {
|
1380
|
-
goog.style.setBoxSizingSize_(element, size, 'content-box');
|
1381
|
-
}
|
1382
|
-
};
|
1383
|
-
|
1384
|
-
|
1385
|
-
/**
|
1386
|
-
* Helper function that sets the box sizing as well as the width and height
|
1387
|
-
* @param {Element} element The element to set the size on.
|
1388
|
-
* @param {goog.math.Size} size The new size to set.
|
1389
|
-
* @param {string} boxSizing The box-sizing value.
|
1390
|
-
* @private
|
1391
|
-
*/
|
1392
|
-
goog.style.setBoxSizingSize_ = function(element, size, boxSizing) {
|
1393
|
-
var style = element.style;
|
1394
|
-
if (goog.userAgent.GECKO) {
|
1395
|
-
style.MozBoxSizing = boxSizing;
|
1396
|
-
} else if (goog.userAgent.WEBKIT) {
|
1397
|
-
style.WebkitBoxSizing = boxSizing;
|
1398
|
-
} else if (goog.userAgent.OPERA && !goog.userAgent.isVersion('9.50')) {
|
1399
|
-
// Opera pre-9.5 does not have CSSStyleDeclaration::boxSizing, but
|
1400
|
-
// box-sizing can still be set via CSSStyleDeclaration::setProperty.
|
1401
|
-
if (boxSizing) {
|
1402
|
-
style.setProperty('box-sizing', boxSizing);
|
1403
|
-
} else {
|
1404
|
-
style.removeProperty('box-sizing');
|
1405
|
-
}
|
1406
|
-
} else {
|
1407
|
-
// Includes IE8
|
1408
|
-
style.boxSizing = boxSizing;
|
1409
|
-
}
|
1410
|
-
style.width = size.width + 'px';
|
1411
|
-
style.height = size.height + 'px';
|
1412
|
-
};
|
1413
|
-
|
1414
|
-
|
1415
|
-
/**
|
1416
|
-
* IE specific function that converts a non pixel unit to pixels.
|
1417
|
-
* @param {Element} element The element to convert the value for.
|
1418
|
-
* @param {string} value The current value as a string. The value must not be
|
1419
|
-
* ''.
|
1420
|
-
* @param {string} name The CSS property name to use for the converstion. This
|
1421
|
-
* should be 'left', 'top', 'width' or 'height'.
|
1422
|
-
* @param {string} pixelName The CSS pixel property name to use to get the
|
1423
|
-
* value in pixels.
|
1424
|
-
* @return {number} The value in pixels.
|
1425
|
-
* @private
|
1426
|
-
*/
|
1427
|
-
goog.style.getIePixelValue_ = function(element, value, name, pixelName) {
|
1428
|
-
// Try if we already have a pixel value. IE does not do half pixels so we
|
1429
|
-
// only check if it matches a number followed by 'px'.
|
1430
|
-
if (/^\d+px?$/.test(value)) {
|
1431
|
-
return parseInt(value, 10);
|
1432
|
-
} else {
|
1433
|
-
var oldStyleValue = element.style[name];
|
1434
|
-
var oldRuntimeValue = element.runtimeStyle[name];
|
1435
|
-
// set runtime style to prevent changes
|
1436
|
-
element.runtimeStyle[name] = element.currentStyle[name];
|
1437
|
-
element.style[name] = value;
|
1438
|
-
var pixelValue = element.style[pixelName];
|
1439
|
-
// restore
|
1440
|
-
element.style[name] = oldStyleValue;
|
1441
|
-
element.runtimeStyle[name] = oldRuntimeValue;
|
1442
|
-
return pixelValue;
|
1443
|
-
}
|
1444
|
-
};
|
1445
|
-
|
1446
|
-
|
1447
|
-
/**
|
1448
|
-
* Helper function for getting the pixel padding or margin for IE.
|
1449
|
-
* @param {Element} element The element to get the padding for.
|
1450
|
-
* @param {string} propName The property name.
|
1451
|
-
* @return {number} The pixel padding.
|
1452
|
-
* @private
|
1453
|
-
*/
|
1454
|
-
goog.style.getIePixelDistance_ = function(element, propName) {
|
1455
|
-
return goog.style.getIePixelValue_(element,
|
1456
|
-
goog.style.getCascadedStyle(element, propName),
|
1457
|
-
'left', 'pixelLeft');
|
1458
|
-
};
|
1459
|
-
|
1460
|
-
|
1461
|
-
/**
|
1462
|
-
* Gets the computed paddings or margins (on all sides) in pixels.
|
1463
|
-
* @param {Element} element The element to get the padding for.
|
1464
|
-
* @param {string} stylePrefix Pass 'padding' to retrieve the padding box,
|
1465
|
-
* or 'margin' to retrieve the margin box.
|
1466
|
-
* @return {!goog.math.Box} The computed paddings or margins.
|
1467
|
-
* @private
|
1468
|
-
*/
|
1469
|
-
goog.style.getBox_ = function(element, stylePrefix) {
|
1470
|
-
if (goog.userAgent.IE) {
|
1471
|
-
var left = goog.style.getIePixelDistance_(element, stylePrefix + 'Left');
|
1472
|
-
var right = goog.style.getIePixelDistance_(element, stylePrefix + 'Right');
|
1473
|
-
var top = goog.style.getIePixelDistance_(element, stylePrefix + 'Top');
|
1474
|
-
var bottom = goog.style.getIePixelDistance_(
|
1475
|
-
element, stylePrefix + 'Bottom');
|
1476
|
-
return new goog.math.Box(top, right, bottom, left);
|
1477
|
-
} else {
|
1478
|
-
// On non-IE browsers, getComputedStyle is always non-null.
|
1479
|
-
var left = /** @type {string} */ (
|
1480
|
-
goog.style.getComputedStyle(element, stylePrefix + 'Left'));
|
1481
|
-
var right = /** @type {string} */ (
|
1482
|
-
goog.style.getComputedStyle(element, stylePrefix + 'Right'));
|
1483
|
-
var top = /** @type {string} */ (
|
1484
|
-
goog.style.getComputedStyle(element, stylePrefix + 'Top'));
|
1485
|
-
var bottom = /** @type {string} */ (
|
1486
|
-
goog.style.getComputedStyle(element, stylePrefix + 'Bottom'));
|
1487
|
-
|
1488
|
-
// NOTE(user): Gecko can return floating point numbers for the computed
|
1489
|
-
// style values.
|
1490
|
-
return new goog.math.Box(parseFloat(top),
|
1491
|
-
parseFloat(right),
|
1492
|
-
parseFloat(bottom),
|
1493
|
-
parseFloat(left));
|
1494
|
-
}
|
1495
|
-
};
|
1496
|
-
|
1497
|
-
|
1498
|
-
/**
|
1499
|
-
* Gets the computed paddings (on all sides) in pixels.
|
1500
|
-
* @param {Element} element The element to get the padding for.
|
1501
|
-
* @return {!goog.math.Box} The computed paddings.
|
1502
|
-
*/
|
1503
|
-
goog.style.getPaddingBox = function(element) {
|
1504
|
-
return goog.style.getBox_(element, 'padding');
|
1505
|
-
};
|
1506
|
-
|
1507
|
-
|
1508
|
-
/**
|
1509
|
-
* Gets the computed margins (on all sides) in pixels.
|
1510
|
-
* @param {Element} element The element to get the margins for.
|
1511
|
-
* @return {!goog.math.Box} The computed margins.
|
1512
|
-
*/
|
1513
|
-
goog.style.getMarginBox = function(element) {
|
1514
|
-
return goog.style.getBox_(element, 'margin');
|
1515
|
-
};
|
1516
|
-
|
1517
|
-
|
1518
|
-
/**
|
1519
|
-
* A map used to map the border width keywords to a pixel width.
|
1520
|
-
* @type {Object}
|
1521
|
-
* @private
|
1522
|
-
*/
|
1523
|
-
goog.style.ieBorderWidthKeywords_ = {
|
1524
|
-
'thin': 2,
|
1525
|
-
'medium': 4,
|
1526
|
-
'thick': 6
|
1527
|
-
};
|
1528
|
-
|
1529
|
-
|
1530
|
-
/**
|
1531
|
-
* Helper function for IE to get the pixel border.
|
1532
|
-
* @param {Element} element The element to get the pixel border for.
|
1533
|
-
* @param {string} prop The part of the property name.
|
1534
|
-
* @return {number} The value in pixels.
|
1535
|
-
* @private
|
1536
|
-
*/
|
1537
|
-
goog.style.getIePixelBorder_ = function(element, prop) {
|
1538
|
-
if (goog.style.getCascadedStyle(element, prop + 'Style') == 'none') {
|
1539
|
-
return 0;
|
1540
|
-
}
|
1541
|
-
var width = goog.style.getCascadedStyle(element, prop + 'Width');
|
1542
|
-
if (width in goog.style.ieBorderWidthKeywords_) {
|
1543
|
-
return goog.style.ieBorderWidthKeywords_[width];
|
1544
|
-
}
|
1545
|
-
return goog.style.getIePixelValue_(element, width, 'left', 'pixelLeft');
|
1546
|
-
};
|
1547
|
-
|
1548
|
-
|
1549
|
-
/**
|
1550
|
-
* Gets the computed border widths (on all sides) in pixels
|
1551
|
-
* @param {Element} element The element to get the border widths for.
|
1552
|
-
* @return {!goog.math.Box} The computed border widths.
|
1553
|
-
*/
|
1554
|
-
goog.style.getBorderBox = function(element) {
|
1555
|
-
if (goog.userAgent.IE) {
|
1556
|
-
var left = goog.style.getIePixelBorder_(element, 'borderLeft');
|
1557
|
-
var right = goog.style.getIePixelBorder_(element, 'borderRight');
|
1558
|
-
var top = goog.style.getIePixelBorder_(element, 'borderTop');
|
1559
|
-
var bottom = goog.style.getIePixelBorder_(element, 'borderBottom');
|
1560
|
-
return new goog.math.Box(top, right, bottom, left);
|
1561
|
-
} else {
|
1562
|
-
// On non-IE browsers, getComputedStyle is always non-null.
|
1563
|
-
var left = /** @type {string} */ (
|
1564
|
-
goog.style.getComputedStyle(element, 'borderLeftWidth'));
|
1565
|
-
var right = /** @type {string} */ (
|
1566
|
-
goog.style.getComputedStyle(element, 'borderRightWidth'));
|
1567
|
-
var top = /** @type {string} */ (
|
1568
|
-
goog.style.getComputedStyle(element, 'borderTopWidth'));
|
1569
|
-
var bottom = /** @type {string} */ (
|
1570
|
-
goog.style.getComputedStyle(element, 'borderBottomWidth'));
|
1571
|
-
|
1572
|
-
return new goog.math.Box(parseFloat(top),
|
1573
|
-
parseFloat(right),
|
1574
|
-
parseFloat(bottom),
|
1575
|
-
parseFloat(left));
|
1576
|
-
}
|
1577
|
-
};
|
1578
|
-
|
1579
|
-
|
1580
|
-
/**
|
1581
|
-
* Returns the font face applied to a given node. Opera and IE should return
|
1582
|
-
* the font actually displayed. Firefox returns the author's most-preferred
|
1583
|
-
* font (whether the browser is capable of displaying it or not.)
|
1584
|
-
* @param {Element} el The element whose font family is returned.
|
1585
|
-
* @return {string} The font family applied to el.
|
1586
|
-
*/
|
1587
|
-
goog.style.getFontFamily = function(el) {
|
1588
|
-
var doc = goog.dom.getOwnerDocument(el);
|
1589
|
-
var font = '';
|
1590
|
-
if (doc.body.createTextRange) {
|
1591
|
-
var range = doc.body.createTextRange();
|
1592
|
-
range.moveToElementText(el);
|
1593
|
-
/** @preserveTry */
|
1594
|
-
try {
|
1595
|
-
font = range.queryCommandValue('FontName');
|
1596
|
-
} catch (e) {
|
1597
|
-
// This is a workaround for a awkward exception.
|
1598
|
-
// On some IE, there is an exception coming from it.
|
1599
|
-
// The error description from this exception is:
|
1600
|
-
// This window has already been registered as a drop target
|
1601
|
-
// This is bogus description, likely due to a bug in ie.
|
1602
|
-
font = '';
|
1603
|
-
}
|
1604
|
-
}
|
1605
|
-
if (!font) {
|
1606
|
-
// Note if for some reason IE can't derive FontName with a TextRange, we
|
1607
|
-
// fallback to using currentStyle
|
1608
|
-
font = goog.style.getStyle_(el, 'fontFamily');
|
1609
|
-
// Opera on Linux provides the font vendor's name in square-brackets.
|
1610
|
-
if (goog.userAgent.OPERA && goog.userAgent.LINUX) {
|
1611
|
-
font = font.replace(/ \[[^\]]*\]/, '');
|
1612
|
-
}
|
1613
|
-
}
|
1614
|
-
|
1615
|
-
// Firefox returns the applied font-family string (author's list of
|
1616
|
-
// preferred fonts.) We want to return the most-preferred font, in lieu of
|
1617
|
-
// the *actually* applied font.
|
1618
|
-
var fontsArray = font.split(',');
|
1619
|
-
if (fontsArray.length > 1) font = fontsArray[0];
|
1620
|
-
|
1621
|
-
// Sanitize for x-browser consistency:
|
1622
|
-
// Strip quotes because browsers aren't consistent with how they're
|
1623
|
-
// applied; Opera always encloses, Firefox sometimes, and IE never.
|
1624
|
-
return goog.string.stripQuotes(font, '"\'');
|
1625
|
-
};
|
1626
|
-
|
1627
|
-
|
1628
|
-
/**
|
1629
|
-
* Regular expression used for getLengthUnits.
|
1630
|
-
* @type {RegExp}
|
1631
|
-
* @private
|
1632
|
-
*/
|
1633
|
-
goog.style.lengthUnitRegex_ = /[^\d]+$/;
|
1634
|
-
|
1635
|
-
|
1636
|
-
/**
|
1637
|
-
* Returns the units used for a CSS length measurement.
|
1638
|
-
* @param {string} value A CSS length quantity.
|
1639
|
-
* @return {?string} The units of measurement.
|
1640
|
-
*/
|
1641
|
-
goog.style.getLengthUnits = function(value) {
|
1642
|
-
var units = value.match(goog.style.lengthUnitRegex_);
|
1643
|
-
return units && units[0] || null;
|
1644
|
-
};
|
1645
|
-
|
1646
|
-
|
1647
|
-
/**
|
1648
|
-
* Map of absolute CSS length units
|
1649
|
-
* @type {Object}
|
1650
|
-
* @private
|
1651
|
-
*/
|
1652
|
-
goog.style.ABSOLUTE_CSS_LENGTH_UNITS_ = {
|
1653
|
-
'cm' : 1,
|
1654
|
-
'in' : 1,
|
1655
|
-
'mm' : 1,
|
1656
|
-
'pc' : 1,
|
1657
|
-
'pt' : 1
|
1658
|
-
};
|
1659
|
-
|
1660
|
-
|
1661
|
-
/**
|
1662
|
-
* Map of relative CSS length units that can be accurately converted to px
|
1663
|
-
* font-size values using getIePixelValue_. Only units that are defined in
|
1664
|
-
* relation to a font size are convertible (%, small, etc. are not).
|
1665
|
-
* @type {Object}
|
1666
|
-
* @private
|
1667
|
-
*/
|
1668
|
-
goog.style.CONVERTIBLE_RELATIVE_CSS_UNITS_ = {
|
1669
|
-
'em' : 1,
|
1670
|
-
'ex' : 1
|
1671
|
-
};
|
1672
|
-
|
1673
|
-
|
1674
|
-
/**
|
1675
|
-
* Returns the font size, in pixels, of text in an element.
|
1676
|
-
* @param {Element} el The element whose font size is returned.
|
1677
|
-
* @return {number} The font size (in pixels).
|
1678
|
-
*/
|
1679
|
-
goog.style.getFontSize = function(el) {
|
1680
|
-
var fontSize = goog.style.getStyle_(el, 'fontSize');
|
1681
|
-
var sizeUnits = goog.style.getLengthUnits(fontSize);
|
1682
|
-
if (fontSize && 'px' == sizeUnits) {
|
1683
|
-
// NOTE(user): This could be parseFloat instead, but IE doesn't return
|
1684
|
-
// decimal fractions in getStyle_ and Firefox reports the fractions, but
|
1685
|
-
// ignores them when rendering. Interestingly enough, when we force the
|
1686
|
-
// issue and size something to e.g., 50% of 25px, the browsers round in
|
1687
|
-
// opposite directions with Firefox reporting 12px and IE 13px. I punt.
|
1688
|
-
return parseInt(fontSize, 10);
|
1689
|
-
}
|
1690
|
-
|
1691
|
-
// In IE, we can convert absolute length units to a px value using
|
1692
|
-
// goog.style.getIePixelValue_. Units defined in relation to a font size
|
1693
|
-
// (em, ex) are applied relative to the element's parentNode and can also
|
1694
|
-
// be converted.
|
1695
|
-
if (goog.userAgent.IE) {
|
1696
|
-
if (sizeUnits in goog.style.ABSOLUTE_CSS_LENGTH_UNITS_) {
|
1697
|
-
return goog.style.getIePixelValue_(el,
|
1698
|
-
fontSize,
|
1699
|
-
'left',
|
1700
|
-
'pixelLeft');
|
1701
|
-
} else if (el.parentNode &&
|
1702
|
-
el.parentNode.nodeType == goog.dom.NodeType.ELEMENT &&
|
1703
|
-
sizeUnits in goog.style.CONVERTIBLE_RELATIVE_CSS_UNITS_) {
|
1704
|
-
// Check the parent size - if it is the same it means the relative size
|
1705
|
-
// value is inherited and we therefore don't want to count it twice. If
|
1706
|
-
// it is different, this element either has explicit style or has a CSS
|
1707
|
-
// rule applying to it.
|
1708
|
-
var parentElement = /** @type {Element} */ (el.parentNode);
|
1709
|
-
var parentSize = goog.style.getStyle_(parentElement, 'fontSize');
|
1710
|
-
return goog.style.getIePixelValue_(parentElement,
|
1711
|
-
fontSize == parentSize ?
|
1712
|
-
'1em' : fontSize,
|
1713
|
-
'left',
|
1714
|
-
'pixelLeft');
|
1715
|
-
}
|
1716
|
-
}
|
1717
|
-
|
1718
|
-
// Sometimes we can't cleanly find the font size (some units relative to a
|
1719
|
-
// node's parent's font size are difficult: %, smaller et al), so we create
|
1720
|
-
// an invisible, absolutely-positioned span sized to be the height of an 'M'
|
1721
|
-
// rendered in its parent's (i.e., our target element's) font size. This is
|
1722
|
-
// the definition of CSS's font size attribute.
|
1723
|
-
var sizeElement = goog.dom.createDom(
|
1724
|
-
'span',
|
1725
|
-
{'style': 'visibility:hidden;position:absolute;' +
|
1726
|
-
'line-height:0;padding:0;margin:0;border:0;height:1em;'});
|
1727
|
-
goog.dom.appendChild(el, sizeElement);
|
1728
|
-
fontSize = sizeElement.offsetHeight;
|
1729
|
-
goog.dom.removeNode(sizeElement);
|
1730
|
-
|
1731
|
-
return fontSize;
|
1732
|
-
};
|
1733
|
-
|
1734
|
-
|
1735
|
-
/**
|
1736
|
-
* Parses a style attribute value. Converts CSS property names to camel case.
|
1737
|
-
* @param {string} value The style attribute value.
|
1738
|
-
* @return {!Object} Map of CSS properties to string values.
|
1739
|
-
*/
|
1740
|
-
goog.style.parseStyleAttribute = function(value) {
|
1741
|
-
var result = {};
|
1742
|
-
goog.array.forEach(value.split(/\s*;\s*/), function(pair) {
|
1743
|
-
var keyValue = pair.split(/\s*:\s*/);
|
1744
|
-
if (keyValue.length == 2) {
|
1745
|
-
result[goog.string.toCamelCase(keyValue[0].toLowerCase())] = keyValue[1];
|
1746
|
-
}
|
1747
|
-
});
|
1748
|
-
return result;
|
1749
|
-
};
|
1750
|
-
|
1751
|
-
|
1752
|
-
/**
|
1753
|
-
* Reverse of parseStyleAttribute; that is, takes a style object and returns the
|
1754
|
-
* corresponding attribute value. Converts camel case property names to proper
|
1755
|
-
* CSS selector names.
|
1756
|
-
* @param {Object} obj Map of CSS properties to values.
|
1757
|
-
* @return {string} The style attribute value.
|
1758
|
-
*/
|
1759
|
-
goog.style.toStyleAttribute = function(obj) {
|
1760
|
-
var buffer = [];
|
1761
|
-
goog.object.forEach(obj, function(value, key) {
|
1762
|
-
buffer.push(goog.string.toSelectorCase(key), ':', value, ';');
|
1763
|
-
});
|
1764
|
-
return buffer.join('');
|
1765
|
-
};
|
1766
|
-
|
1767
|
-
|
1768
|
-
/**
|
1769
|
-
* Sets CSS float property on an element.
|
1770
|
-
* @param {Element} el The element to set float property on.
|
1771
|
-
* @param {string} value The value of float CSS property to set on this element.
|
1772
|
-
*/
|
1773
|
-
goog.style.setFloat = function(el, value) {
|
1774
|
-
el.style[goog.userAgent.IE ? 'styleFloat' : 'cssFloat'] = value;
|
1775
|
-
};
|
1776
|
-
|
1777
|
-
|
1778
|
-
/**
|
1779
|
-
* Gets value of explicitly-set float CSS property on an element.
|
1780
|
-
* @param {Element} el The element to get float property of.
|
1781
|
-
* @return {string} The value of explicitly-set float CSS property on this
|
1782
|
-
* element.
|
1783
|
-
*/
|
1784
|
-
goog.style.getFloat = function(el) {
|
1785
|
-
return el.style[goog.userAgent.IE ? 'styleFloat' : 'cssFloat'] || '';
|
1786
|
-
};
|
1787
|
-
|
1788
|
-
|
1789
|
-
/**
|
1790
|
-
* Returns the scroll bar width (represents the width of both horizontal
|
1791
|
-
* and vertical scroll).
|
1792
|
-
*
|
1793
|
-
* @return {number} The scroll bar width in px.
|
1794
|
-
*/
|
1795
|
-
goog.style.getScrollbarWidth = function() {
|
1796
|
-
// Add a div outside of the viewport.
|
1797
|
-
var mockElement = goog.dom.createElement('div');
|
1798
|
-
mockElement.style.cssText = 'visibility:hidden;overflow:scroll;' +
|
1799
|
-
'position:absolute;top:0;width:100px;height:100px';
|
1800
|
-
goog.dom.appendChild(goog.dom.getDocument().body, mockElement);
|
1801
|
-
var width = mockElement.offsetWidth - mockElement.clientWidth;
|
1802
|
-
goog.dom.removeNode(mockElement);
|
1803
|
-
return width;
|
1804
|
-
};
|