extjs-rails 4.1.0.alpha5 → 4.1.0.alpha6
Sign up to get free protection for your applications and to get access to all the features.
- data/app/assets/javascripts/extjs-rails.js +95613 -11000
- data/lib/extjs-rails/version.rb +1 -1
- metadata +2 -509
- data/app/assets/javascripts/src/AbstractComponent.js +0 -3290
- data/app/assets/javascripts/src/AbstractManager.js +0 -144
- data/app/assets/javascripts/src/AbstractPlugin.js +0 -72
- data/app/assets/javascripts/src/Action.js +0 -276
- data/app/assets/javascripts/src/Ajax.js +0 -99
- data/app/assets/javascripts/src/Component.js +0 -1344
- data/app/assets/javascripts/src/ComponentLoader.js +0 -202
- data/app/assets/javascripts/src/ComponentManager.js +0 -47
- data/app/assets/javascripts/src/ComponentQuery.js +0 -521
- data/app/assets/javascripts/src/Editor.js +0 -494
- data/app/assets/javascripts/src/ElementLoader.js +0 -404
- data/app/assets/javascripts/src/FocusManager.js +0 -712
- data/app/assets/javascripts/src/Img.js +0 -111
- data/app/assets/javascripts/src/Layer.js +0 -543
- data/app/assets/javascripts/src/LoadMask.js +0 -432
- data/app/assets/javascripts/src/ModelManager.js +0 -186
- data/app/assets/javascripts/src/PluginManager.js +0 -110
- data/app/assets/javascripts/src/ProgressBar.js +0 -336
- data/app/assets/javascripts/src/Shadow.js +0 -233
- data/app/assets/javascripts/src/ShadowPool.js +0 -43
- data/app/assets/javascripts/src/Template.js +0 -331
- data/app/assets/javascripts/src/XTemplate.js +0 -365
- data/app/assets/javascripts/src/XTemplateCompiler.js +0 -450
- data/app/assets/javascripts/src/XTemplateParser.js +0 -249
- data/app/assets/javascripts/src/ZIndexManager.js +0 -519
- data/app/assets/javascripts/src/app/Application.js +0 -271
- data/app/assets/javascripts/src/app/Controller.js +0 -458
- data/app/assets/javascripts/src/app/EventBus.js +0 -112
- data/app/assets/javascripts/src/button/Button.js +0 -1483
- data/app/assets/javascripts/src/button/Cycle.js +0 -215
- data/app/assets/javascripts/src/button/Split.js +0 -99
- data/app/assets/javascripts/src/chart/Callout.js +0 -140
- data/app/assets/javascripts/src/chart/Chart.js +0 -966
- data/app/assets/javascripts/src/chart/Highlight.js +0 -172
- data/app/assets/javascripts/src/chart/Label.js +0 -241
- data/app/assets/javascripts/src/chart/Legend.js +0 -474
- data/app/assets/javascripts/src/chart/LegendItem.js +0 -217
- data/app/assets/javascripts/src/chart/Mask.js +0 -230
- data/app/assets/javascripts/src/chart/MaskLayer.js +0 -48
- data/app/assets/javascripts/src/chart/Navigation.js +0 -79
- data/app/assets/javascripts/src/chart/Shape.js +0 -106
- data/app/assets/javascripts/src/chart/Tip.js +0 -98
- data/app/assets/javascripts/src/chart/TipSurface.js +0 -42
- data/app/assets/javascripts/src/chart/axis/Abstract.js +0 -73
- data/app/assets/javascripts/src/chart/axis/Axis.js +0 -961
- data/app/assets/javascripts/src/chart/axis/Category.js +0 -130
- data/app/assets/javascripts/src/chart/axis/Gauge.js +0 -203
- data/app/assets/javascripts/src/chart/axis/Numeric.js +0 -235
- data/app/assets/javascripts/src/chart/axis/Radial.js +0 -204
- data/app/assets/javascripts/src/chart/axis/Time.js +0 -135
- data/app/assets/javascripts/src/chart/series/Area.js +0 -803
- data/app/assets/javascripts/src/chart/series/Bar.js +0 -853
- data/app/assets/javascripts/src/chart/series/Cartesian.js +0 -328
- data/app/assets/javascripts/src/chart/series/Column.js +0 -104
- data/app/assets/javascripts/src/chart/series/Gauge.js +0 -490
- data/app/assets/javascripts/src/chart/series/Line.js +0 -1104
- data/app/assets/javascripts/src/chart/series/Pie.js +0 -1072
- data/app/assets/javascripts/src/chart/series/Radar.js +0 -440
- data/app/assets/javascripts/src/chart/series/Scatter.js +0 -668
- data/app/assets/javascripts/src/chart/series/Series.js +0 -443
- data/app/assets/javascripts/src/chart/theme/Base.js +0 -175
- data/app/assets/javascripts/src/chart/theme/Theme.js +0 -253
- data/app/assets/javascripts/src/container/AbstractContainer.js +0 -1062
- data/app/assets/javascripts/src/container/ButtonGroup.js +0 -143
- data/app/assets/javascripts/src/container/Container.js +0 -212
- data/app/assets/javascripts/src/container/DockingContainer.js +0 -265
- data/app/assets/javascripts/src/container/Viewport.js +0 -184
- data/app/assets/javascripts/src/core/dom/Element.form.js +0 -50
- data/app/assets/javascripts/src/core/dom/Element.static-more.js +0 -159
- data/app/assets/javascripts/src/core/examples/index.html +0 -321
- data/app/assets/javascripts/src/core/examples/index.js +0 -6
- data/app/assets/javascripts/src/core/examples/src/Sample/CTO.js +0 -25
- data/app/assets/javascripts/src/core/examples/src/Sample/CoolGuy.js +0 -20
- data/app/assets/javascripts/src/core/examples/src/Sample/Developer.js +0 -43
- data/app/assets/javascripts/src/core/examples/src/Sample/Gun.js +0 -3
- data/app/assets/javascripts/src/core/examples/src/Sample/HumanResource.js +0 -23
- data/app/assets/javascripts/src/core/examples/src/Sample/Musician.js +0 -20
- data/app/assets/javascripts/src/core/examples/src/Sample/Person.js +0 -50
- data/app/assets/javascripts/src/core/examples/src/Sample/ability/CanComposeSongs.js +0 -9
- data/app/assets/javascripts/src/core/examples/src/Sample/ability/CanPlayGuitar.js +0 -9
- data/app/assets/javascripts/src/core/examples/src/Sample/ability/CanSing.js +0 -18
- data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/A.js +0 -3
- data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/B.js +0 -3
- data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/C.js +0 -3
- data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/D.js +0 -3
- data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/E.js +0 -3
- data/app/assets/javascripts/src/core/examples/src/Sample/notdeadlock/A.js +0 -3
- data/app/assets/javascripts/src/core/examples/src/Sample/notdeadlock/B.js +0 -4
- data/app/assets/javascripts/src/core/examples/src/Sample/notdeadlock/C.js +0 -3
- data/app/assets/javascripts/src/core/src/EventManager.js +0 -1167
- data/app/assets/javascripts/src/core/src/EventObject.js +0 -883
- data/app/assets/javascripts/src/core/src/Ext-more.js +0 -1283
- data/app/assets/javascripts/src/core/src/Ext.js +0 -736
- data/app/assets/javascripts/src/core/src/Support.js +0 -662
- data/app/assets/javascripts/src/core/src/class/Base.js +0 -1085
- data/app/assets/javascripts/src/core/src/class/Class.js +0 -676
- data/app/assets/javascripts/src/core/src/class/ClassManager.js +0 -1591
- data/app/assets/javascripts/src/core/src/class/Loader.js +0 -1423
- data/app/assets/javascripts/src/core/src/dom/AbstractElement.alignment.js +0 -173
- data/app/assets/javascripts/src/core/src/dom/AbstractElement.insertion.js +0 -193
- data/app/assets/javascripts/src/core/src/dom/AbstractElement.js +0 -681
- data/app/assets/javascripts/src/core/src/dom/AbstractElement.position.js +0 -356
- data/app/assets/javascripts/src/core/src/dom/AbstractElement.static.js +0 -474
- data/app/assets/javascripts/src/core/src/dom/AbstractElement.style.js +0 -851
- data/app/assets/javascripts/src/core/src/dom/AbstractElement.traversal.js +0 -180
- data/app/assets/javascripts/src/core/src/dom/AbstractHelper.js +0 -291
- data/app/assets/javascripts/src/core/src/dom/AbstractQuery.js +0 -72
- data/app/assets/javascripts/src/core/src/dom/CompositeElement.js +0 -75
- data/app/assets/javascripts/src/core/src/dom/CompositeElementLite.js +0 -436
- data/app/assets/javascripts/src/core/src/dom/DomQuery-aria.js +0 -1049
- data/app/assets/javascripts/src/core/src/env/Browser.js +0 -186
- data/app/assets/javascripts/src/core/src/env/FeatureDetector.js +0 -274
- data/app/assets/javascripts/src/core/src/env/OS.js +0 -141
- data/app/assets/javascripts/src/core/src/lang/Array.js +0 -1205
- data/app/assets/javascripts/src/core/src/lang/Date.js +0 -1463
- data/app/assets/javascripts/src/core/src/lang/Error.js +0 -326
- data/app/assets/javascripts/src/core/src/lang/Function.js +0 -485
- data/app/assets/javascripts/src/core/src/lang/Number.js +0 -175
- data/app/assets/javascripts/src/core/src/lang/Object.js +0 -606
- data/app/assets/javascripts/src/core/src/lang/String.js +0 -333
- data/app/assets/javascripts/src/core/src/misc/JSON.js +0 -236
- data/app/assets/javascripts/src/core/src/perf/Accumulator.js +0 -244
- data/app/assets/javascripts/src/core/src/perf/Monitor.js +0 -197
- data/app/assets/javascripts/src/core/src/util/DelayedTask.js +0 -71
- data/app/assets/javascripts/src/core/src/util/Event.js +0 -215
- data/app/assets/javascripts/src/core/src/util/Format.js +0 -551
- data/app/assets/javascripts/src/core/src/util/TaskManager.js +0 -417
- data/app/assets/javascripts/src/core/src/version/Version.js +0 -364
- data/app/assets/javascripts/src/core/test/unit/README.MD +0 -91
- data/app/assets/javascripts/src/core/test/unit/bootstrap.js +0 -39
- data/app/assets/javascripts/src/core/test/unit/build/build-data.js +0 -34
- data/app/assets/javascripts/src/core/test/unit/build/build.sh +0 -2
- data/app/assets/javascripts/src/core/test/unit/data.js +0 -27
- data/app/assets/javascripts/src/core/test/unit/index.html +0 -15
- data/app/assets/javascripts/src/core/test/unit/other_specs/dom.html +0 -40
- data/app/assets/javascripts/src/core/test/unit/other_specs/dom/extjs-api.js +0 -12
- data/app/assets/javascripts/src/core/test/unit/other_specs/dom/platform-api.js +0 -134
- data/app/assets/javascripts/src/core/test/unit/other_specs/dom/sanity.js +0 -4
- data/app/assets/javascripts/src/core/test/unit/other_specs/dom/touch-api-out.js +0 -128
- data/app/assets/javascripts/src/core/test/unit/other_specs/dom/touch-api.js +0 -89
- data/app/assets/javascripts/src/core/test/unit/other_specs/env/Environment.js +0 -357
- data/app/assets/javascripts/src/core/test/unit/resources/APITest.js +0 -37
- data/app/assets/javascripts/src/core/test/unit/resources/jsb3.js +0 -14
- data/app/assets/javascripts/src/core/test/unit/resources/test-setup.js +0 -137
- data/app/assets/javascripts/src/core/test/unit/spec/EventManager.js +0 -629
- data/app/assets/javascripts/src/core/test/unit/spec/Ext-mess.backup +0 -198
- data/app/assets/javascripts/src/core/test/unit/spec/Ext-more.js +0 -520
- data/app/assets/javascripts/src/core/test/unit/spec/Ext.js +0 -1550
- data/app/assets/javascripts/src/core/test/unit/spec/Support.js +0 -250
- data/app/assets/javascripts/src/core/test/unit/spec/class/Base.js +0 -47
- data/app/assets/javascripts/src/core/test/unit/spec/class/Class.js +0 -561
- data/app/assets/javascripts/src/core/test/unit/spec/class/ClassManager.js +0 -555
- data/app/assets/javascripts/src/core/test/unit/spec/dom/CompositeElementLite.js +0 -409
- data/app/assets/javascripts/src/core/test/unit/spec/dom/DomHelper.js +0 -444
- data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.insertion.js +0 -342
- data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.js +0 -731
- data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.static.js +0 -201
- data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.style.js +0 -118
- data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.traversal.js +0 -336
- data/app/assets/javascripts/src/core/test/unit/spec/lang/Array.js +0 -1229
- data/app/assets/javascripts/src/core/test/unit/spec/lang/Date.js +0 -697
- data/app/assets/javascripts/src/core/test/unit/spec/lang/Error.js +0 -277
- data/app/assets/javascripts/src/core/test/unit/spec/lang/Function.js +0 -536
- data/app/assets/javascripts/src/core/test/unit/spec/lang/Number.js +0 -323
- data/app/assets/javascripts/src/core/test/unit/spec/lang/Object.js +0 -591
- data/app/assets/javascripts/src/core/test/unit/spec/lang/String.js +0 -451
- data/app/assets/javascripts/src/core/test/unit/spec/misc/JSON.js +0 -252
- data/app/assets/javascripts/src/core/test/unit/spec/util/Format.js +0 -521
- data/app/assets/javascripts/src/core/test/unit/spec/version/Version.js +0 -148
- data/app/assets/javascripts/src/core/test/unit/specs.html +0 -19
- data/app/assets/javascripts/src/data/AbstractStore.js +0 -887
- data/app/assets/javascripts/src/data/ArrayStore.js +0 -74
- data/app/assets/javascripts/src/data/Batch.js +0 -236
- data/app/assets/javascripts/src/data/BufferStore.js +0 -13
- data/app/assets/javascripts/src/data/Connection.js +0 -969
- data/app/assets/javascripts/src/data/DirectStore.js +0 -50
- data/app/assets/javascripts/src/data/Errors.js +0 -52
- data/app/assets/javascripts/src/data/Field.js +0 -341
- data/app/assets/javascripts/src/data/IdGenerator.js +0 -198
- data/app/assets/javascripts/src/data/JsonP.js +0 -253
- data/app/assets/javascripts/src/data/JsonPStore.js +0 -51
- data/app/assets/javascripts/src/data/JsonStore.js +0 -60
- data/app/assets/javascripts/src/data/Model.js +0 -1673
- data/app/assets/javascripts/src/data/NodeInterface.js +0 -1294
- data/app/assets/javascripts/src/data/NodeStore.js +0 -254
- data/app/assets/javascripts/src/data/Operation.js +0 -331
- data/app/assets/javascripts/src/data/Request.js +0 -40
- data/app/assets/javascripts/src/data/ResultSet.js +0 -56
- data/app/assets/javascripts/src/data/SequentialIdGenerator.js +0 -61
- data/app/assets/javascripts/src/data/SortTypes.js +0 -125
- data/app/assets/javascripts/src/data/Store.js +0 -2609
- data/app/assets/javascripts/src/data/StoreManager.js +0 -156
- data/app/assets/javascripts/src/data/Tree.js +0 -290
- data/app/assets/javascripts/src/data/TreeStore.js +0 -655
- data/app/assets/javascripts/src/data/Types.js +0 -190
- data/app/assets/javascripts/src/data/UuidGenerator.js +0 -215
- data/app/assets/javascripts/src/data/XmlStore.js +0 -76
- data/app/assets/javascripts/src/data/association/Association.js +0 -243
- data/app/assets/javascripts/src/data/association/BelongsTo.js +0 -291
- data/app/assets/javascripts/src/data/association/HasMany.js +0 -289
- data/app/assets/javascripts/src/data/association/HasOne.js +0 -304
- data/app/assets/javascripts/src/data/proxy/Ajax.js +0 -282
- data/app/assets/javascripts/src/data/proxy/Client.js +0 -21
- data/app/assets/javascripts/src/data/proxy/Direct.js +0 -181
- data/app/assets/javascripts/src/data/proxy/JsonP.js +0 -313
- data/app/assets/javascripts/src/data/proxy/LocalStorage.js +0 -69
- data/app/assets/javascripts/src/data/proxy/Memory.js +0 -156
- data/app/assets/javascripts/src/data/proxy/Proxy.js +0 -433
- data/app/assets/javascripts/src/data/proxy/Rest.js +0 -173
- data/app/assets/javascripts/src/data/proxy/Server.js +0 -460
- data/app/assets/javascripts/src/data/proxy/SessionStorage.js +0 -39
- data/app/assets/javascripts/src/data/proxy/WebStorage.js +0 -546
- data/app/assets/javascripts/src/data/reader/Array.js +0 -68
- data/app/assets/javascripts/src/data/reader/Json.js +0 -383
- data/app/assets/javascripts/src/data/reader/Reader.js +0 -735
- data/app/assets/javascripts/src/data/reader/Xml.js +0 -292
- data/app/assets/javascripts/src/data/validations.js +0 -149
- data/app/assets/javascripts/src/data/writer/Json.js +0 -81
- data/app/assets/javascripts/src/data/writer/Writer.js +0 -147
- data/app/assets/javascripts/src/data/writer/Xml.js +0 -88
- data/app/assets/javascripts/src/dd/DD.js +0 -300
- data/app/assets/javascripts/src/dd/DDProxy.js +0 -204
- data/app/assets/javascripts/src/dd/DDTarget.js +0 -171
- data/app/assets/javascripts/src/dd/DragDrop.js +0 -1101
- data/app/assets/javascripts/src/dd/DragDropManager.js +0 -1264
- data/app/assets/javascripts/src/dd/DragSource.js +0 -392
- data/app/assets/javascripts/src/dd/DragTracker.js +0 -562
- data/app/assets/javascripts/src/dd/DragZone.js +0 -137
- data/app/assets/javascripts/src/dd/DropTarget.js +0 -118
- data/app/assets/javascripts/src/dd/DropZone.js +0 -254
- data/app/assets/javascripts/src/dd/Registry.js +0 -117
- data/app/assets/javascripts/src/dd/ScrollManager.js +0 -218
- data/app/assets/javascripts/src/dd/StatusProxy.js +0 -179
- data/app/assets/javascripts/src/diag/layout/Context.js +0 -523
- data/app/assets/javascripts/src/diag/layout/ContextItem.js +0 -179
- data/app/assets/javascripts/src/direct/Event.js +0 -35
- data/app/assets/javascripts/src/direct/ExceptionEvent.js +0 -16
- data/app/assets/javascripts/src/direct/JsonProvider.js +0 -82
- data/app/assets/javascripts/src/direct/Manager.js +0 -263
- data/app/assets/javascripts/src/direct/PollingProvider.js +0 -156
- data/app/assets/javascripts/src/direct/Provider.js +0 -96
- data/app/assets/javascripts/src/direct/RemotingEvent.js +0 -24
- data/app/assets/javascripts/src/direct/RemotingMethod.js +0 -100
- data/app/assets/javascripts/src/direct/RemotingProvider.js +0 -510
- data/app/assets/javascripts/src/direct/Transaction.js +0 -41
- data/app/assets/javascripts/src/dom/Element.alignment.js +0 -378
- data/app/assets/javascripts/src/dom/Element.anim.js +0 -962
- data/app/assets/javascripts/src/dom/Element.dd.js +0 -40
- data/app/assets/javascripts/src/dom/Element.fx.js +0 -194
- data/app/assets/javascripts/src/dom/Element.js +0 -1407
- data/app/assets/javascripts/src/dom/Element.position.js +0 -501
- data/app/assets/javascripts/src/dom/Element.scroll.js +0 -214
- data/app/assets/javascripts/src/dom/Element.style.js +0 -792
- data/app/assets/javascripts/src/dom/Element.traversal.js +0 -8
- data/app/assets/javascripts/src/dom/Helper.js +0 -466
- data/app/assets/javascripts/src/dom/Query.js +0 -1067
- data/app/assets/javascripts/src/draw/Color.js +0 -303
- data/app/assets/javascripts/src/draw/Component.js +0 -245
- data/app/assets/javascripts/src/draw/CompositeSprite.js +0 -299
- data/app/assets/javascripts/src/draw/Draw.js +0 -1217
- data/app/assets/javascripts/src/draw/Matrix.js +0 -183
- data/app/assets/javascripts/src/draw/Sprite.js +0 -554
- data/app/assets/javascripts/src/draw/SpriteDD.js +0 -87
- data/app/assets/javascripts/src/draw/Surface.js +0 -1001
- data/app/assets/javascripts/src/draw/Text.js +0 -175
- data/app/assets/javascripts/src/draw/engine/ImageExporter.js +0 -106
- data/app/assets/javascripts/src/draw/engine/Svg.js +0 -734
- data/app/assets/javascripts/src/draw/engine/SvgExporter.js +0 -280
- data/app/assets/javascripts/src/draw/engine/Vml.js +0 -916
- data/app/assets/javascripts/src/flash/Component.js +0 -248
- data/app/assets/javascripts/src/form/Basic.js +0 -1018
- data/app/assets/javascripts/src/form/CheckboxGroup.js +0 -441
- data/app/assets/javascripts/src/form/CheckboxManager.js +0 -26
- data/app/assets/javascripts/src/form/FieldAncestor.js +0 -210
- data/app/assets/javascripts/src/form/FieldContainer.js +0 -290
- data/app/assets/javascripts/src/form/FieldSet.js +0 -506
- data/app/assets/javascripts/src/form/Label.js +0 -110
- data/app/assets/javascripts/src/form/Labelable.js +0 -764
- data/app/assets/javascripts/src/form/Panel.js +0 -335
- data/app/assets/javascripts/src/form/RadioGroup.js +0 -124
- data/app/assets/javascripts/src/form/RadioManager.js +0 -26
- data/app/assets/javascripts/src/form/action/Action.js +0 -307
- data/app/assets/javascripts/src/form/action/DirectLoad.js +0 -107
- data/app/assets/javascripts/src/form/action/DirectSubmit.js +0 -119
- data/app/assets/javascripts/src/form/action/Load.js +0 -120
- data/app/assets/javascripts/src/form/action/StandardSubmit.js +0 -34
- data/app/assets/javascripts/src/form/action/Submit.js +0 -257
- data/app/assets/javascripts/src/form/field/Base.js +0 -813
- data/app/assets/javascripts/src/form/field/Checkbox.js +0 -505
- data/app/assets/javascripts/src/form/field/ComboBox.js +0 -1427
- data/app/assets/javascripts/src/form/field/Date.js +0 -578
- data/app/assets/javascripts/src/form/field/Display.js +0 -155
- data/app/assets/javascripts/src/form/field/Field.js +0 -430
- data/app/assets/javascripts/src/form/field/File.js +0 -265
- data/app/assets/javascripts/src/form/field/Hidden.js +0 -75
- data/app/assets/javascripts/src/form/field/HtmlEditor.js +0 -1439
- data/app/assets/javascripts/src/form/field/Number.js +0 -380
- data/app/assets/javascripts/src/form/field/Picker.js +0 -321
- data/app/assets/javascripts/src/form/field/Radio.js +0 -279
- data/app/assets/javascripts/src/form/field/Spinner.js +0 -321
- data/app/assets/javascripts/src/form/field/Text.js +0 -727
- data/app/assets/javascripts/src/form/field/TextArea.js +0 -228
- data/app/assets/javascripts/src/form/field/Time.js +0 -459
- data/app/assets/javascripts/src/form/field/Trigger.js +0 -469
- data/app/assets/javascripts/src/form/field/VTypes.js +0 -172
- data/app/assets/javascripts/src/fx/Anim.js +0 -472
- data/app/assets/javascripts/src/fx/Animator.js +0 -410
- data/app/assets/javascripts/src/fx/CubicBezier.js +0 -77
- data/app/assets/javascripts/src/fx/Easing.js +0 -136
- data/app/assets/javascripts/src/fx/Manager.js +0 -353
- data/app/assets/javascripts/src/fx/PropertyHandler.js +0 -381
- data/app/assets/javascripts/src/fx/Queue.js +0 -123
- data/app/assets/javascripts/src/fx/target/Component.js +0 -118
- data/app/assets/javascripts/src/fx/target/CompositeElement.js +0 -46
- data/app/assets/javascripts/src/fx/target/CompositeElementCSS.js +0 -22
- data/app/assets/javascripts/src/fx/target/CompositeSprite.js +0 -34
- data/app/assets/javascripts/src/fx/target/Element.js +0 -83
- data/app/assets/javascripts/src/fx/target/ElementCSS.js +0 -77
- data/app/assets/javascripts/src/fx/target/Sprite.js +0 -128
- data/app/assets/javascripts/src/fx/target/Target.js +0 -36
- data/app/assets/javascripts/src/grid/CellEditor.js +0 -172
- data/app/assets/javascripts/src/grid/ColumnComponentLayout.js +0 -34
- data/app/assets/javascripts/src/grid/ColumnLayout.js +0 -201
- data/app/assets/javascripts/src/grid/Lockable.js +0 -863
- data/app/assets/javascripts/src/grid/LockingView.js +0 -169
- data/app/assets/javascripts/src/grid/PagingScroller.js +0 -539
- data/app/assets/javascripts/src/grid/Panel.js +0 -393
- data/app/assets/javascripts/src/grid/RowEditor.js +0 -731
- data/app/assets/javascripts/src/grid/RowNumberer.js +0 -76
- data/app/assets/javascripts/src/grid/Scroller.js +0 -5
- data/app/assets/javascripts/src/grid/View.js +0 -44
- data/app/assets/javascripts/src/grid/ViewDropZone.js +0 -41
- data/app/assets/javascripts/src/grid/column/Action.js +0 -318
- data/app/assets/javascripts/src/grid/column/Boolean.js +0 -82
- data/app/assets/javascripts/src/grid/column/Column.js +0 -835
- data/app/assets/javascripts/src/grid/column/Date.js +0 -63
- data/app/assets/javascripts/src/grid/column/Number.js +0 -52
- data/app/assets/javascripts/src/grid/column/Template.js +0 -58
- data/app/assets/javascripts/src/grid/feature/AbstractSummary.js +0 -154
- data/app/assets/javascripts/src/grid/feature/Chunking.js +0 -77
- data/app/assets/javascripts/src/grid/feature/Feature.js +0 -158
- data/app/assets/javascripts/src/grid/feature/Grouping.js +0 -822
- data/app/assets/javascripts/src/grid/feature/GroupingSummary.js +0 -243
- data/app/assets/javascripts/src/grid/feature/RowBody.js +0 -116
- data/app/assets/javascripts/src/grid/feature/RowWrap.js +0 -120
- data/app/assets/javascripts/src/grid/feature/Summary.js +0 -167
- data/app/assets/javascripts/src/grid/header/Container.js +0 -965
- data/app/assets/javascripts/src/grid/header/DragZone.js +0 -69
- data/app/assets/javascripts/src/grid/header/DropZone.js +0 -265
- data/app/assets/javascripts/src/grid/plugin/CellEditing.js +0 -453
- data/app/assets/javascripts/src/grid/plugin/DragDrop.js +0 -254
- data/app/assets/javascripts/src/grid/plugin/Editing.js +0 -561
- data/app/assets/javascripts/src/grid/plugin/HeaderReorderer.js +0 -49
- data/app/assets/javascripts/src/grid/plugin/HeaderResizer.js +0 -292
- data/app/assets/javascripts/src/grid/plugin/RowEditing.js +0 -339
- data/app/assets/javascripts/src/grid/property/Grid.js +0 -351
- data/app/assets/javascripts/src/grid/property/HeaderContainer.js +0 -109
- data/app/assets/javascripts/src/grid/property/Property.js +0 -36
- data/app/assets/javascripts/src/grid/property/Store.js +0 -141
- data/app/assets/javascripts/src/layout/ClassList.js +0 -90
- data/app/assets/javascripts/src/layout/Context.js +0 -1232
- data/app/assets/javascripts/src/layout/ContextItem.js +0 -1470
- data/app/assets/javascripts/src/layout/Layout.js +0 -761
- data/app/assets/javascripts/src/layout/component/Auto.js +0 -220
- data/app/assets/javascripts/src/layout/component/Body.js +0 -80
- data/app/assets/javascripts/src/layout/component/BoundList.js +0 -95
- data/app/assets/javascripts/src/layout/component/Button.js +0 -261
- data/app/assets/javascripts/src/layout/component/Component.js +0 -427
- data/app/assets/javascripts/src/layout/component/Dock.js +0 -1132
- data/app/assets/javascripts/src/layout/component/Draw.js +0 -79
- data/app/assets/javascripts/src/layout/component/FieldSet.js +0 -62
- data/app/assets/javascripts/src/layout/component/ProgressBar.js +0 -54
- data/app/assets/javascripts/src/layout/component/Tab.js +0 -23
- data/app/assets/javascripts/src/layout/component/field/ComboBox.js +0 -52
- data/app/assets/javascripts/src/layout/component/field/Field.js +0 -372
- data/app/assets/javascripts/src/layout/component/field/FieldContainer.js +0 -48
- data/app/assets/javascripts/src/layout/component/field/HtmlEditor.js +0 -54
- data/app/assets/javascripts/src/layout/component/field/Slider.js +0 -58
- data/app/assets/javascripts/src/layout/component/field/Text.js +0 -75
- data/app/assets/javascripts/src/layout/component/field/TextArea.js +0 -51
- data/app/assets/javascripts/src/layout/component/field/Trigger.js +0 -132
- data/app/assets/javascripts/src/layout/container/Absolute.js +0 -121
- data/app/assets/javascripts/src/layout/container/Accordion.js +0 -308
- data/app/assets/javascripts/src/layout/container/Anchor.js +0 -403
- data/app/assets/javascripts/src/layout/container/Auto.js +0 -70
- data/app/assets/javascripts/src/layout/container/Border-old-js +0 -1079
- data/app/assets/javascripts/src/layout/container/Border.js +0 -816
- data/app/assets/javascripts/src/layout/container/Box.js +0 -929
- data/app/assets/javascripts/src/layout/container/Card.js +0 -361
- data/app/assets/javascripts/src/layout/container/CheckboxGroup.js +0 -376
- data/app/assets/javascripts/src/layout/container/Column.js +0 -234
- data/app/assets/javascripts/src/layout/container/Container.js +0 -961
- data/app/assets/javascripts/src/layout/container/Editor.js +0 -74
- data/app/assets/javascripts/src/layout/container/Fit.js +0 -287
- data/app/assets/javascripts/src/layout/container/Form.js +0 -157
- data/app/assets/javascripts/src/layout/container/HBox.js +0 -134
- data/app/assets/javascripts/src/layout/container/Table.js +0 -412
- data/app/assets/javascripts/src/layout/container/VBox.js +0 -139
- data/app/assets/javascripts/src/layout/container/boxOverflow/Menu.js +0 -365
- data/app/assets/javascripts/src/layout/container/boxOverflow/None.js +0 -83
- data/app/assets/javascripts/src/layout/container/boxOverflow/Scroller.js +0 -475
- data/app/assets/javascripts/src/menu/CheckItem.js +0 -169
- data/app/assets/javascripts/src/menu/ColorPicker.js +0 -110
- data/app/assets/javascripts/src/menu/DatePicker.js +0 -100
- data/app/assets/javascripts/src/menu/Item.js +0 -553
- data/app/assets/javascripts/src/menu/KeyNav.js +0 -134
- data/app/assets/javascripts/src/menu/Manager.js +0 -219
- data/app/assets/javascripts/src/menu/Menu.js +0 -579
- data/app/assets/javascripts/src/menu/Separator.js +0 -126
- data/app/assets/javascripts/src/panel/AbstractPanel.js +0 -323
- data/app/assets/javascripts/src/panel/DD.js +0 -99
- data/app/assets/javascripts/src/panel/Header.js +0 -518
- data/app/assets/javascripts/src/panel/Panel.js +0 -2150
- data/app/assets/javascripts/src/panel/Proxy.js +0 -131
- data/app/assets/javascripts/src/panel/Table.js +0 -1018
- data/app/assets/javascripts/src/panel/Tool.js +0 -304
- data/app/assets/javascripts/src/picker/Color.js +0 -219
- data/app/assets/javascripts/src/picker/Date.js +0 -1140
- data/app/assets/javascripts/src/picker/Month.js +0 -490
- data/app/assets/javascripts/src/picker/Time.js +0 -165
- data/app/assets/javascripts/src/resizer/BorderSplitter.js +0 -22
- data/app/assets/javascripts/src/resizer/BorderSplitterTracker.js +0 -210
- data/app/assets/javascripts/src/resizer/Handle.js +0 -29
- data/app/assets/javascripts/src/resizer/ResizeTracker.js +0 -346
- data/app/assets/javascripts/src/resizer/Resizer.js +0 -477
- data/app/assets/javascripts/src/resizer/Splitter.js +0 -242
- data/app/assets/javascripts/src/resizer/SplitterTracker.js +0 -230
- data/app/assets/javascripts/src/selection/CellModel.js +0 -395
- data/app/assets/javascripts/src/selection/CheckboxModel.js +0 -234
- data/app/assets/javascripts/src/selection/DataViewModel.js +0 -160
- data/app/assets/javascripts/src/selection/Model.js +0 -646
- data/app/assets/javascripts/src/selection/RowModel.js +0 -499
- data/app/assets/javascripts/src/selection/TreeModel.js +0 -78
- data/app/assets/javascripts/src/slider/Multi.js +0 -835
- data/app/assets/javascripts/src/slider/Single.js +0 -56
- data/app/assets/javascripts/src/slider/Thumb.js +0 -259
- data/app/assets/javascripts/src/slider/Tip.js +0 -130
- data/app/assets/javascripts/src/state/CookieProvider.js +0 -120
- data/app/assets/javascripts/src/state/LocalStorageProvider.js +0 -72
- data/app/assets/javascripts/src/state/Manager.js +0 -70
- data/app/assets/javascripts/src/state/Provider.js +0 -182
- data/app/assets/javascripts/src/state/Stateful.js +0 -364
- data/app/assets/javascripts/src/tab/Bar.js +0 -258
- data/app/assets/javascripts/src/tab/Panel.js +0 -654
- data/app/assets/javascripts/src/tab/Tab.js +0 -358
- data/app/assets/javascripts/src/tail.js +0 -10
- data/app/assets/javascripts/src/tip/QuickTip.js +0 -335
- data/app/assets/javascripts/src/tip/QuickTipManager.js +0 -239
- data/app/assets/javascripts/src/tip/Tip.js +0 -160
- data/app/assets/javascripts/src/tip/ToolTip.js +0 -691
- data/app/assets/javascripts/src/toolbar/Fill.js +0 -28
- data/app/assets/javascripts/src/toolbar/Item.js +0 -16
- data/app/assets/javascripts/src/toolbar/Paging.js +0 -600
- data/app/assets/javascripts/src/toolbar/Separator.js +0 -23
- data/app/assets/javascripts/src/toolbar/Spacer.js +0 -33
- data/app/assets/javascripts/src/toolbar/TextItem.js +0 -57
- data/app/assets/javascripts/src/toolbar/Toolbar-legacy.js +0 -123
- data/app/assets/javascripts/src/toolbar/Toolbar.js +0 -447
- data/app/assets/javascripts/src/tree/Column.js +0 -90
- data/app/assets/javascripts/src/tree/Panel.js +0 -505
- data/app/assets/javascripts/src/tree/View.js +0 -658
- data/app/assets/javascripts/src/tree/ViewDragZone.js +0 -49
- data/app/assets/javascripts/src/tree/ViewDropZone.js +0 -287
- data/app/assets/javascripts/src/tree/plugin/TreeViewDragDrop.js +0 -244
- data/app/assets/javascripts/src/util/AbstractMixedCollection.js +0 -772
- data/app/assets/javascripts/src/util/Animate.js +0 -426
- data/app/assets/javascripts/src/util/Bindable.js +0 -102
- data/app/assets/javascripts/src/util/CSS.js +0 -185
- data/app/assets/javascripts/src/util/ClickRepeater.js +0 -238
- data/app/assets/javascripts/src/util/ComponentDragger.js +0 -126
- data/app/assets/javascripts/src/util/Cookies.js +0 -91
- data/app/assets/javascripts/src/util/ElementContainer.js +0 -293
- data/app/assets/javascripts/src/util/Filter.js +0 -159
- data/app/assets/javascripts/src/util/Floating.js +0 -321
- data/app/assets/javascripts/src/util/Grouper.js +0 -26
- data/app/assets/javascripts/src/util/HashMap.js +0 -356
- data/app/assets/javascripts/src/util/History.js +0 -285
- data/app/assets/javascripts/src/util/Inflector.js +0 -297
- data/app/assets/javascripts/src/util/KeyMap.js +0 -427
- data/app/assets/javascripts/src/util/KeyNav.js +0 -239
- data/app/assets/javascripts/src/util/LruCache.js +0 -257
- data/app/assets/javascripts/src/util/Memento.js +0 -131
- data/app/assets/javascripts/src/util/MixedCollection.js +0 -239
- data/app/assets/javascripts/src/util/Observable.js +0 -1003
- data/app/assets/javascripts/src/util/Offset.js +0 -60
- data/app/assets/javascripts/src/util/Point.js +0 -93
- data/app/assets/javascripts/src/util/ProtoElement.js +0 -205
- data/app/assets/javascripts/src/util/Queue.js +0 -76
- data/app/assets/javascripts/src/util/Region.js +0 -388
- data/app/assets/javascripts/src/util/Renderable.js +0 -1079
- data/app/assets/javascripts/src/util/Sortable.js +0 -248
- data/app/assets/javascripts/src/util/Sorter.js +0 -179
- data/app/assets/javascripts/src/util/TextMetrics.js +0 -148
- data/app/assets/javascripts/src/view/AbstractView.js +0 -1103
- data/app/assets/javascripts/src/view/BoundList.js +0 -207
- data/app/assets/javascripts/src/view/BoundListKeyNav.js +0 -92
- data/app/assets/javascripts/src/view/DragZone.js +0 -106
- data/app/assets/javascripts/src/view/DropZone.js +0 -240
- data/app/assets/javascripts/src/view/Table.js +0 -1229
- data/app/assets/javascripts/src/view/TableChunker.js +0 -139
- data/app/assets/javascripts/src/view/View.js +0 -636
- data/app/assets/javascripts/src/window/MessageBox.js +0 -880
- data/app/assets/javascripts/src/window/Window-legacy.js +0 -56
- data/app/assets/javascripts/src/window/Window.js +0 -793
@@ -1,1079 +0,0 @@
|
|
1
|
-
/**
|
2
|
-
* Given a component hierarchy of this:
|
3
|
-
*
|
4
|
-
* {
|
5
|
-
* xtype: 'panel',
|
6
|
-
* id: 'ContainerA',
|
7
|
-
* layout: 'hbox',
|
8
|
-
* renderTo: Ext.getBody(),
|
9
|
-
* items: [
|
10
|
-
* {
|
11
|
-
* id: 'ContainerB',
|
12
|
-
* xtype: 'container',
|
13
|
-
* items: [
|
14
|
-
* { id: 'ComponentA' }
|
15
|
-
* ]
|
16
|
-
* }
|
17
|
-
* ]
|
18
|
-
* }
|
19
|
-
*
|
20
|
-
* The rendering of the above proceeds roughly like this:
|
21
|
-
*
|
22
|
-
* - ContainerA's initComponent calls #render passing the `renderTo` property as the
|
23
|
-
* container argument.
|
24
|
-
* - `render` calls the `getRenderTree` method to get a complete {@link Ext.DomHelper} spec.
|
25
|
-
* - `getRenderTree` fires the "beforerender" event and calls the #beforeRender
|
26
|
-
* method. Its result is obtained by calling #getElConfig.
|
27
|
-
* - The #getElConfig method uses the `renderTpl` and its render data as the content
|
28
|
-
* of the `autoEl` described element.
|
29
|
-
* - The result of `getRenderTree` is passed to {@link Ext.DomHelper#append}.
|
30
|
-
* - The `renderTpl` contains calls to render things like docked items, container items
|
31
|
-
* and raw markup (such as the `html` or `tpl` config properties). These calls are to
|
32
|
-
* methods added to the {@link Ext.XTemplate} instance by #setupRenderTpl.
|
33
|
-
* - The #setupRenderTpl method adds methods such as `renderItems`, `renderContent`, etc.
|
34
|
-
* to the template. These are directed to "doRenderItems", "doRenderContent" etc..
|
35
|
-
* - The #setupRenderTpl calls traverse from components to their {@link Ext.layout.Layout}
|
36
|
-
* object.
|
37
|
-
* - When a container is rendered, it also has a `renderTpl`. This is processed when the
|
38
|
-
* `renderContainer` method is called in the component's `renderTpl`. This call goes to
|
39
|
-
* Ext.layout.container.Container#doRenderContainer. This method repeats this
|
40
|
-
* process for all components in the container.
|
41
|
-
* - After the top-most component's markup is generated and placed in to the DOM, the next
|
42
|
-
* step is to link elements to their components and finish calling the component methods
|
43
|
-
* `onRender` and `afterRender` as well as fire the corresponding events.
|
44
|
-
* - The first step in this is to call #finishRender. This method descends the
|
45
|
-
* component hierarchy and calls `onRender` and fires the `render` event. These calls
|
46
|
-
* are delivered top-down to approximate the timing of these calls/events from previous
|
47
|
-
* versions.
|
48
|
-
* - During the pass, the component's `el` is set. Likewise, the `renderSelectors` and
|
49
|
-
* `childEls` are applied to capture references to the component's elements.
|
50
|
-
* - These calls are also made on the {@link Ext.layout.container.Container} layout to
|
51
|
-
* capture its elements. Both of these classes use {@link Ext.util.ElementContainer} to
|
52
|
-
* handle `childEls` processing.
|
53
|
-
* - Once this is complete, a similar pass is made by calling #finishAfterRender.
|
54
|
-
* This call also descends the component hierarchy, but this time the calls are made in
|
55
|
-
* a bottom-up order to `afterRender`.
|
56
|
-
*
|
57
|
-
* @private
|
58
|
-
*/
|
59
|
-
Ext.define('Ext.util.Renderable', {
|
60
|
-
requires: [
|
61
|
-
'Ext.dom.Element'
|
62
|
-
],
|
63
|
-
|
64
|
-
frameCls: Ext.baseCSSPrefix + 'frame',
|
65
|
-
|
66
|
-
frameIdRegex: /[\-]frame\d+[TMB][LCR]$/,
|
67
|
-
|
68
|
-
frameElementCls: {
|
69
|
-
tl: [],
|
70
|
-
tc: [],
|
71
|
-
tr: [],
|
72
|
-
ml: [],
|
73
|
-
mc: [],
|
74
|
-
mr: [],
|
75
|
-
bl: [],
|
76
|
-
bc: [],
|
77
|
-
br: []
|
78
|
-
},
|
79
|
-
|
80
|
-
frameElNames: ['TL','TC','TR','ML','MC','MR','BL','BC','BR'],
|
81
|
-
|
82
|
-
frameTpl: [
|
83
|
-
'{%this.renderDockedItems(out,values,0);%}',
|
84
|
-
'<tpl if="top">',
|
85
|
-
'<tpl if="left"><div id="{fgid}TL" class="{frameCls}-tl {baseCls}-tl {baseCls}-{ui}-tl<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-tl</tpl>" style="background-position: {tl}; padding-left: {frameWidth}px" role="presentation"></tpl>',
|
86
|
-
'<tpl if="right"><div id="{fgid}TR" class="{frameCls}-tr {baseCls}-tr {baseCls}-{ui}-tr<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-tr</tpl>" style="background-position: {tr}; padding-right: {frameWidth}px" role="presentation"></tpl>',
|
87
|
-
'<div id="{fgid}TC" class="{frameCls}-tc {baseCls}-tc {baseCls}-{ui}-tc<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-tc</tpl>" style="background-position: {tc}; height: {frameWidth}px" role="presentation"></div>',
|
88
|
-
'<tpl if="right"></div></tpl>',
|
89
|
-
'<tpl if="left"></div></tpl>',
|
90
|
-
'</tpl>',
|
91
|
-
'<tpl if="left"><div id="{fgid}ML" class="{frameCls}-ml {baseCls}-ml {baseCls}-{ui}-ml<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-ml</tpl>" style="background-position: {ml}; padding-left: {frameWidth}px" role="presentation"></tpl>',
|
92
|
-
'<tpl if="right"><div id="{fgid}MR" class="{frameCls}-mr {baseCls}-mr {baseCls}-{ui}-mr<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-mr</tpl>" style="background-position: {mr}; padding-right: {frameWidth}px" role="presentation"></tpl>',
|
93
|
-
'<div id="{fgid}MC" class="{frameCls}-mc {baseCls}-mc {baseCls}-{ui}-mc<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-mc</tpl>" role="presentation">',
|
94
|
-
'{%this.applyRenderTpl(out, values)%}',
|
95
|
-
'</div>',
|
96
|
-
'<tpl if="right"></div></tpl>',
|
97
|
-
'<tpl if="left"></div></tpl>',
|
98
|
-
'<tpl if="bottom">',
|
99
|
-
'<tpl if="left"><div id="{fgid}BL" class="{frameCls}-bl {baseCls}-bl {baseCls}-{ui}-bl<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-bl</tpl>" style="background-position: {bl}; padding-left: {frameWidth}px" role="presentation"></tpl>',
|
100
|
-
'<tpl if="right"><div id="{fgid}BR" class="{frameCls}-br {baseCls}-br {baseCls}-{ui}-br<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-br</tpl>" style="background-position: {br}; padding-right: {frameWidth}px" role="presentation"></tpl>',
|
101
|
-
'<div id="{fgid}BC" class="{frameCls}-bc {baseCls}-bc {baseCls}-{ui}-bc<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-bc</tpl>" style="background-position: {bc}; height: {frameWidth}px" role="presentation"></div>',
|
102
|
-
'<tpl if="right"></div></tpl>',
|
103
|
-
'<tpl if="left"></div></tpl>',
|
104
|
-
'</tpl>',
|
105
|
-
'{%this.renderDockedItems(out,values,1);%}'
|
106
|
-
],
|
107
|
-
|
108
|
-
frameTableTpl: [
|
109
|
-
'{%this.renderDockedItems(out,values,0);%}',
|
110
|
-
'<table><tbody>',
|
111
|
-
'<tpl if="top">',
|
112
|
-
'<tr>',
|
113
|
-
'<tpl if="left"><td id="{fgid}TL" class="{frameCls}-tl {baseCls}-tl {baseCls}-{ui}-tl<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-tl</tpl>" style="background-position: {tl}; padding-left:{frameWidth}px" role="presentation"></td></tpl>',
|
114
|
-
'<td id="{fgid}TC" class="{frameCls}-tc {baseCls}-tc {baseCls}-{ui}-tc<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-tc</tpl>" style="background-position: {tc}; height: {frameWidth}px" role="presentation"></td>',
|
115
|
-
'<tpl if="right"><td id="{fgid}TR" class="{frameCls}-tr {baseCls}-tr {baseCls}-{ui}-tr<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-tr</tpl>" style="background-position: {tr}; padding-left: {frameWidth}px" role="presentation"></td></tpl>',
|
116
|
-
'</tr>',
|
117
|
-
'</tpl>',
|
118
|
-
'<tr>',
|
119
|
-
'<tpl if="left"><td id="{fgid}ML" class="{frameCls}-ml {baseCls}-ml {baseCls}-{ui}-ml<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-ml</tpl>" style="background-position: {ml}; padding-left: {frameWidth}px" role="presentation"></td></tpl>',
|
120
|
-
'<td id="{fgid}MC" class="{frameCls}-mc {baseCls}-mc {baseCls}-{ui}-mc<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-mc</tpl>" style="background-position: 0 0;" role="presentation">',
|
121
|
-
'{%this.applyRenderTpl(out, values)%}',
|
122
|
-
'</td>',
|
123
|
-
'<tpl if="right"><td id="{fgid}MR" class="{frameCls}-mr {baseCls}-mr {baseCls}-{ui}-mr<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-mr</tpl>" style="background-position: {mr}; padding-left: {frameWidth}px" role="presentation"></td></tpl>',
|
124
|
-
'</tr>',
|
125
|
-
'<tpl if="bottom">',
|
126
|
-
'<tr>',
|
127
|
-
'<tpl if="left"><td id="{fgid}BL" class="{frameCls}-bl {baseCls}-bl {baseCls}-{ui}-bl<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-bl</tpl>" style="background-position: {bl}; padding-left: {frameWidth}px" role="presentation"></td></tpl>',
|
128
|
-
'<td id="{fgid}BC" class="{frameCls}-bc {baseCls}-bc {baseCls}-{ui}-bc<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-bc</tpl>" style="background-position: {bc}; height: {frameWidth}px" role="presentation"></td>',
|
129
|
-
'<tpl if="right"><td id="{fgid}BR" class="{frameCls}-br {baseCls}-br {baseCls}-{ui}-br<tpl for="uiCls"> {parent.baseCls}-{parent.ui}-{.}-br</tpl>" style="background-position: {br}; padding-left: {frameWidth}px" role="presentation"></td></tpl>',
|
130
|
-
'</tr>',
|
131
|
-
'</tpl>',
|
132
|
-
'</tbody></table>',
|
133
|
-
'{%this.renderDockedItems(out,values,1);%}'
|
134
|
-
],
|
135
|
-
|
136
|
-
/**
|
137
|
-
* Allows addition of behavior after rendering is complete. At this stage the Component’s Element
|
138
|
-
* will have been styled according to the configuration, will have had any configured CSS class
|
139
|
-
* names added, and will be in the configured visibility and the configured enable state.
|
140
|
-
*
|
141
|
-
* @template
|
142
|
-
* @protected
|
143
|
-
*/
|
144
|
-
afterRender : function() {
|
145
|
-
var me = this,
|
146
|
-
data = {},
|
147
|
-
protoEl = me.protoEl,
|
148
|
-
target = me.getTargetEl(),
|
149
|
-
item;
|
150
|
-
|
151
|
-
me.finishRenderChildren();
|
152
|
-
|
153
|
-
if (me.styleHtmlContent) {
|
154
|
-
target.addCls(me.styleHtmlCls);
|
155
|
-
}
|
156
|
-
|
157
|
-
protoEl.writeTo(data);
|
158
|
-
|
159
|
-
// Here we apply any styles that were set on the protoEl during the rendering phase
|
160
|
-
// A majority of times this will not happen, but we still need to handle it
|
161
|
-
|
162
|
-
item = data.removed;
|
163
|
-
if (item) {
|
164
|
-
target.removeCls(item);
|
165
|
-
}
|
166
|
-
|
167
|
-
item = data.cls;
|
168
|
-
if (item.length) {
|
169
|
-
target.addCls(item);
|
170
|
-
}
|
171
|
-
|
172
|
-
item = data.style;
|
173
|
-
if (data.style) {
|
174
|
-
target.setStyle(item);
|
175
|
-
}
|
176
|
-
|
177
|
-
me.protoEl = null;
|
178
|
-
|
179
|
-
// If this is the outermost Container, lay it out as soon as it is rendered.
|
180
|
-
if (!me.ownerCt) {
|
181
|
-
me.updateLayout();
|
182
|
-
}
|
183
|
-
},
|
184
|
-
|
185
|
-
afterFirstLayout : function(width, height) {
|
186
|
-
var me = this,
|
187
|
-
hasX = Ext.isDefined(me.x),
|
188
|
-
hasY = Ext.isDefined(me.y),
|
189
|
-
pos, xy;
|
190
|
-
|
191
|
-
// For floaters, calculate x and y if they aren't defined by aligning
|
192
|
-
// the sized element to the center of either the container or the ownerCt
|
193
|
-
if (me.floating && (!hasX || !hasY)) {
|
194
|
-
if (me.floatParent) {
|
195
|
-
xy = me.el.getAlignToXY(me.floatParent.getTargetEl(), 'c-c');
|
196
|
-
pos = me.floatParent.getTargetEl().translatePoints(xy[0], xy[1]);
|
197
|
-
} else {
|
198
|
-
xy = me.el.getAlignToXY(me.container, 'c-c');
|
199
|
-
pos = me.container.translatePoints(xy[0], xy[1]);
|
200
|
-
}
|
201
|
-
me.x = hasX ? me.x : pos.left;
|
202
|
-
me.y = hasY ? me.y : pos.top;
|
203
|
-
hasX = hasY = true;
|
204
|
-
}
|
205
|
-
|
206
|
-
if (hasX || hasY) {
|
207
|
-
me.setPosition(me.x, me.y);
|
208
|
-
}
|
209
|
-
me.onBoxReady(width, height);
|
210
|
-
if (me.hasListeners.boxready) {
|
211
|
-
me.fireEvent('boxready', me, width, height);
|
212
|
-
}
|
213
|
-
},
|
214
|
-
|
215
|
-
onBoxReady: Ext.emptyFn,
|
216
|
-
|
217
|
-
/**
|
218
|
-
* Sets references to elements inside the component. This applies {@link #renderSelectors}
|
219
|
-
* as well as {@link #childEls}.
|
220
|
-
* @private
|
221
|
-
*/
|
222
|
-
applyRenderSelectors: function() {
|
223
|
-
var me = this,
|
224
|
-
selectors = me.renderSelectors,
|
225
|
-
el = me.el,
|
226
|
-
dom = el.dom,
|
227
|
-
selector;
|
228
|
-
|
229
|
-
me.applyChildEls(el);
|
230
|
-
|
231
|
-
// We still support renderSelectors. There are a few places in the framework that
|
232
|
-
// need them and they are a documented part of the API. In fact, we support mixing
|
233
|
-
// childEls and renderSelectors (no reason not to).
|
234
|
-
if (selectors) {
|
235
|
-
for (selector in selectors) {
|
236
|
-
if (selectors.hasOwnProperty(selector) && selectors[selector]) {
|
237
|
-
me[selector] = Ext.get(Ext.DomQuery.selectNode(selectors[selector], dom));
|
238
|
-
}
|
239
|
-
}
|
240
|
-
}
|
241
|
-
},
|
242
|
-
|
243
|
-
beforeRender: function () {
|
244
|
-
var me = this,
|
245
|
-
target = me.getTargetEl(),
|
246
|
-
layout = me.getComponentLayout();
|
247
|
-
|
248
|
-
// Just before rendering, set the frame flag if we are an always-framed component like Window or Tip.
|
249
|
-
me.frame = me.frame || me.alwaysFramed;
|
250
|
-
|
251
|
-
if (!layout.initialized) {
|
252
|
-
layout.initLayout();
|
253
|
-
}
|
254
|
-
|
255
|
-
// Attempt to set overflow style prior to render if the targetEl can be accessed.
|
256
|
-
// If the targetEl does not exist yet, this will take place in finishRender
|
257
|
-
if (target) {
|
258
|
-
target.setStyle(me.getOverflowStyle());
|
259
|
-
me.overflowStyleSet = true;
|
260
|
-
}
|
261
|
-
|
262
|
-
me.setUI(me.ui);
|
263
|
-
|
264
|
-
if (me.disabled) {
|
265
|
-
// pass silent so the event doesn't fire the first time.
|
266
|
-
me.disable(true);
|
267
|
-
}
|
268
|
-
},
|
269
|
-
|
270
|
-
/**
|
271
|
-
* @private
|
272
|
-
* Called from the selected frame generation template to insert this Component's inner structure inside the framing structure.
|
273
|
-
*
|
274
|
-
* When framing is used, a selected frame generation template is used as the primary template of the #getElConfig instead
|
275
|
-
* of the configured {@link #renderTpl}. The {@link #renderTpl} is invoked by this method which is injected into the framing template.
|
276
|
-
*/
|
277
|
-
doApplyRenderTpl: function(out, values) {
|
278
|
-
// Careful! This method is bolted on to the frameTpl so all we get for context is
|
279
|
-
// the renderData! The "this" pointer is the frameTpl instance!
|
280
|
-
|
281
|
-
var me = values.$comp,
|
282
|
-
tpl;
|
283
|
-
|
284
|
-
// Don't do this if the component is already rendered:
|
285
|
-
if (!me.rendered) {
|
286
|
-
tpl = me.initRenderTpl();
|
287
|
-
tpl.applyOut(values.renderData, out);
|
288
|
-
}
|
289
|
-
},
|
290
|
-
|
291
|
-
/**
|
292
|
-
* Handles autoRender.
|
293
|
-
* Floating Components may have an ownerCt. If they are asking to be constrained, constrain them within that
|
294
|
-
* ownerCt, and have their z-index managed locally. Floating Components are always rendered to document.body
|
295
|
-
*/
|
296
|
-
doAutoRender: function() {
|
297
|
-
var me = this;
|
298
|
-
if (!me.rendered) {
|
299
|
-
if (me.floating) {
|
300
|
-
me.render(document.body);
|
301
|
-
} else {
|
302
|
-
me.render(Ext.isBoolean(me.autoRender) ? Ext.getBody() : me.autoRender);
|
303
|
-
}
|
304
|
-
}
|
305
|
-
},
|
306
|
-
|
307
|
-
doRenderContent: function (out, renderData) {
|
308
|
-
// Careful! This method is bolted on to the renderTpl so all we get for context is
|
309
|
-
// the renderData! The "this" pointer is the renderTpl instance!
|
310
|
-
|
311
|
-
var me = renderData.$comp;
|
312
|
-
|
313
|
-
if (me.html) {
|
314
|
-
Ext.DomHelper.generateMarkup(me.html, out);
|
315
|
-
delete me.html;
|
316
|
-
}
|
317
|
-
|
318
|
-
if (me.tpl) {
|
319
|
-
// Make sure this.tpl is an instantiated XTemplate
|
320
|
-
if (!me.tpl.isTemplate) {
|
321
|
-
me.tpl = new Ext.XTemplate(me.tpl);
|
322
|
-
}
|
323
|
-
|
324
|
-
if (me.data) {
|
325
|
-
//me.tpl[me.tplWriteMode](target, me.data);
|
326
|
-
me.tpl.applyOut(me.data, out);
|
327
|
-
delete me.data;
|
328
|
-
}
|
329
|
-
}
|
330
|
-
},
|
331
|
-
|
332
|
-
doRenderFramingDockedItems: function (out, renderData, after) {
|
333
|
-
// Careful! This method is bolted on to the frameTpl so all we get for context is
|
334
|
-
// the renderData! The "this" pointer is the frameTpl instance!
|
335
|
-
|
336
|
-
var me = renderData.$comp;
|
337
|
-
|
338
|
-
// Most components don't have dockedItems, so check for doRenderDockedItems on the
|
339
|
-
// component (also, don't do this if the component is already rendered):
|
340
|
-
if (!me.rendered && me.doRenderDockedItems) {
|
341
|
-
// The "renderData" property is placed in scope for the renderTpl, but we don't
|
342
|
-
// want to render docked items at that level in addition to the framing level:
|
343
|
-
renderData.renderData.$skipDockedItems = true;
|
344
|
-
|
345
|
-
// doRenderDockedItems requires the $comp property on renderData, but this is
|
346
|
-
// set on the frameTpl's renderData as well:
|
347
|
-
me.doRenderDockedItems.call(this, out, renderData, after);
|
348
|
-
}
|
349
|
-
},
|
350
|
-
|
351
|
-
/**
|
352
|
-
* This method visits the rendered component tree in a "top-down" order. That is, this
|
353
|
-
* code runs on a parent component before running on a child. This method calls the
|
354
|
-
* {@link #onRender} method of each component.
|
355
|
-
* @param {Number} containerIdx The index into the Container items of this Component.
|
356
|
-
*
|
357
|
-
* @private
|
358
|
-
*/
|
359
|
-
finishRender: function(containerIdx) {
|
360
|
-
var me = this,
|
361
|
-
tpl, data, contentEl, el, pre, hide;
|
362
|
-
|
363
|
-
// We are typically called w/me.el==null as a child of some ownerCt that is being
|
364
|
-
// rendered. We are also called by render for a normal component (w/o a configured
|
365
|
-
// me.el). In this case, render sets me.el and me.rendering (indirectly). Lastly
|
366
|
-
// we are also called on a component (like a Viewport) that has a configured me.el
|
367
|
-
// (body for a Viewport) when render is called. In this case, it is not flagged as
|
368
|
-
// "me.rendering" yet becasue it does not produce a renderTree. We use this to know
|
369
|
-
// not to regen the renderTpl.
|
370
|
-
|
371
|
-
if (!me.el || me.$pid) {
|
372
|
-
if (me.container) {
|
373
|
-
el = me.container.getById(me.id, true);
|
374
|
-
} else {
|
375
|
-
el = Ext.getDom(me.id);
|
376
|
-
}
|
377
|
-
|
378
|
-
if (!me.el) {
|
379
|
-
// Typical case: we produced the el during render
|
380
|
-
me.wrapPrimaryEl(el);
|
381
|
-
} else {
|
382
|
-
// We were configured with an el and created a proxy, so now we can swap
|
383
|
-
// the proxy for me.el:
|
384
|
-
delete me.$pid;
|
385
|
-
|
386
|
-
if (!me.el.dom) {
|
387
|
-
// make sure me.el is an Element
|
388
|
-
me.wrapPrimaryEl(me.el);
|
389
|
-
}
|
390
|
-
el.parentNode.insertBefore(me.el.dom, el);
|
391
|
-
Ext.removeNode(el); // remove placeholder el
|
392
|
-
// TODO - what about class/style?
|
393
|
-
}
|
394
|
-
} else if (!me.rendering) {
|
395
|
-
// We were configured with an el and then told to render (e.g., Viewport). We
|
396
|
-
// need to generate the proper DOM. Insert first because the layout system
|
397
|
-
// insists that child Component elements indices match the Component indices.
|
398
|
-
tpl = me.initRenderTpl();
|
399
|
-
if (tpl) {
|
400
|
-
data = me.initRenderData();
|
401
|
-
tpl.insertFirst(me.getTargetEl(), data);
|
402
|
-
}
|
403
|
-
}
|
404
|
-
// else we are rendering
|
405
|
-
|
406
|
-
if (!me.container) {
|
407
|
-
// top-level rendered components will already have me.container set up
|
408
|
-
me.container = Ext.get(me.el.dom.parentNode);
|
409
|
-
}
|
410
|
-
|
411
|
-
if (me.ctCls) {
|
412
|
-
me.container.addCls(me.ctCls);
|
413
|
-
}
|
414
|
-
|
415
|
-
// Sets the rendered flag and clears the redering flag
|
416
|
-
me.onRender(me.container, containerIdx);
|
417
|
-
|
418
|
-
// If we could not access a target protoEl in bewforeRender, we have to set the overflow styles here.
|
419
|
-
if (!me.overflowStyleSet) {
|
420
|
-
me.getTargetEl().setStyle(me.getOverflowStyle());
|
421
|
-
}
|
422
|
-
|
423
|
-
// Tell the encapsulating element to hide itself in the way the Component is configured to hide
|
424
|
-
// This means DISPLAY, VISIBILITY or OFFSETS.
|
425
|
-
me.el.setVisibilityMode(Ext.Element[me.hideMode.toUpperCase()]);
|
426
|
-
|
427
|
-
if (me.overCls) {
|
428
|
-
me.el.hover(me.addOverCls, me.removeOverCls, me);
|
429
|
-
}
|
430
|
-
|
431
|
-
if (me.hasListeners.render) {
|
432
|
-
me.fireEvent('render', me);
|
433
|
-
}
|
434
|
-
|
435
|
-
if (me.contentEl) {
|
436
|
-
pre = Ext.baseCSSPrefix;
|
437
|
-
hide = pre + 'hide-';
|
438
|
-
contentEl = Ext.get(me.contentEl);
|
439
|
-
contentEl.removeCls([pre+'hidden', hide+'display', hide+'offsets', hide+'nosize']);
|
440
|
-
me.getTargetEl().appendChild(contentEl.dom);
|
441
|
-
}
|
442
|
-
|
443
|
-
me.afterRender(); // this can cause a layout
|
444
|
-
if (me.hasListeners.afterrender) {
|
445
|
-
me.fireEvent('afterrender', me);
|
446
|
-
}
|
447
|
-
me.initEvents();
|
448
|
-
|
449
|
-
if (me.hidden) {
|
450
|
-
// Hiding during the render process should not perform any ancillary
|
451
|
-
// actions that the full hide process does; It is not hiding, it begins in a hidden state.'
|
452
|
-
// So just make the element hidden according to the configured hideMode
|
453
|
-
me.el.hide();
|
454
|
-
}
|
455
|
-
},
|
456
|
-
|
457
|
-
finishRenderChildren: function () {
|
458
|
-
var layout = this.getComponentLayout();
|
459
|
-
|
460
|
-
layout.finishRender();
|
461
|
-
},
|
462
|
-
|
463
|
-
getElConfig : function() {
|
464
|
-
var me = this,
|
465
|
-
autoEl = me.autoEl,
|
466
|
-
frameInfo = me.getFrameInfo(),
|
467
|
-
config = {
|
468
|
-
tag: 'div',
|
469
|
-
id: me.id,
|
470
|
-
tpl: frameInfo ? me.initFramingTpl(frameInfo.table) : me.initRenderTpl()
|
471
|
-
},
|
472
|
-
i, frameElNames, len, suffix, frameGenId;
|
473
|
-
|
474
|
-
me.initStyles(me.protoEl);
|
475
|
-
me.protoEl.writeTo(config);
|
476
|
-
me.protoEl.flush();
|
477
|
-
|
478
|
-
if (Ext.isString(autoEl)) {
|
479
|
-
config.tag = autoEl;
|
480
|
-
} else {
|
481
|
-
Ext.apply(config, autoEl); // harmless if !autoEl
|
482
|
-
}
|
483
|
-
|
484
|
-
if (config.tpl) {
|
485
|
-
// Use the framingTpl as the main content creating template. It will call out to this.applyRenderTpl(out, values)
|
486
|
-
if (frameInfo) {
|
487
|
-
frameElNames = me.frameElNames;
|
488
|
-
len = frameElNames.length;
|
489
|
-
frameGenId = me.id + '-frame1';
|
490
|
-
|
491
|
-
me.frameGenId = 1;
|
492
|
-
config.tplData = Ext.apply({}, {
|
493
|
-
$comp: me,
|
494
|
-
fgid: frameGenId,
|
495
|
-
ui: me.ui,
|
496
|
-
uiCls: me.uiCls,
|
497
|
-
frameCls: me.frameCls,
|
498
|
-
baseCls: me.baseCls,
|
499
|
-
frameWidth: frameInfo.maxWidth,
|
500
|
-
top: !!frameInfo.top,
|
501
|
-
left: !!frameInfo.left,
|
502
|
-
right: !!frameInfo.right,
|
503
|
-
bottom: !!frameInfo.bottom,
|
504
|
-
renderData: me.initRenderData()
|
505
|
-
}, me.getFramePositions(frameInfo));
|
506
|
-
|
507
|
-
// Add the childEls for each of the frame elements
|
508
|
-
for (i = 0; i < len; i++) {
|
509
|
-
suffix = frameElNames[i];
|
510
|
-
me.addChildEls({ name: 'frame' + suffix, id: frameGenId + suffix });
|
511
|
-
}
|
512
|
-
|
513
|
-
// Panel must have a frameBody
|
514
|
-
me.addChildEls({
|
515
|
-
name: 'frameBody',
|
516
|
-
id: frameGenId + 'MC'
|
517
|
-
});
|
518
|
-
} else {
|
519
|
-
config.tplData = me.initRenderData();
|
520
|
-
}
|
521
|
-
}
|
522
|
-
|
523
|
-
return config;
|
524
|
-
},
|
525
|
-
|
526
|
-
// Create the framingTpl from the string.
|
527
|
-
// Poke in a reference to applyRenderTpl(frameInfo, out)
|
528
|
-
initFramingTpl: function(table) {
|
529
|
-
var tpl = table ? this.getTpl('frameTableTpl') : this.getTpl('frameTpl');
|
530
|
-
|
531
|
-
if (tpl && !tpl.applyRenderTpl) {
|
532
|
-
this.setupFramingTpl(tpl);
|
533
|
-
}
|
534
|
-
|
535
|
-
return tpl;
|
536
|
-
},
|
537
|
-
|
538
|
-
/**
|
539
|
-
* @private
|
540
|
-
* Inject a reference to the function which applies the render template into the framing template. The framing template
|
541
|
-
* wraps the content.
|
542
|
-
*/
|
543
|
-
setupFramingTpl: function(frameTpl) {
|
544
|
-
frameTpl.applyRenderTpl = this.doApplyRenderTpl;
|
545
|
-
frameTpl.renderDockedItems = this.doRenderFramingDockedItems;
|
546
|
-
},
|
547
|
-
|
548
|
-
/**
|
549
|
-
* This function takes the position argument passed to onRender and returns a
|
550
|
-
* DOM element that you can use in the insertBefore.
|
551
|
-
* @param {String/Number/Ext.dom.Element/HTMLElement} position Index, element id or element you want
|
552
|
-
* to put this component before.
|
553
|
-
* @return {HTMLElement} DOM element that you can use in the insertBefore
|
554
|
-
*/
|
555
|
-
getInsertPosition: function(position) {
|
556
|
-
// Convert the position to an element to insert before
|
557
|
-
if (position !== undefined) {
|
558
|
-
if (Ext.isNumber(position)) {
|
559
|
-
position = this.container.dom.childNodes[position];
|
560
|
-
}
|
561
|
-
else {
|
562
|
-
position = Ext.getDom(position);
|
563
|
-
}
|
564
|
-
}
|
565
|
-
|
566
|
-
return position;
|
567
|
-
},
|
568
|
-
|
569
|
-
getRenderTree: function() {
|
570
|
-
var me = this;
|
571
|
-
|
572
|
-
if (!me.hasListeners.beforerender || me.fireEvent('beforerender', me) !== false) {
|
573
|
-
me.beforeRender();
|
574
|
-
|
575
|
-
// Flag to let the layout's finishRenderItems and afterFinishRenderItems
|
576
|
-
// know which items to process
|
577
|
-
me.rendering = true;
|
578
|
-
|
579
|
-
if (me.el) {
|
580
|
-
// Since we are producing a render tree, we produce a "proxy el" that will
|
581
|
-
// sit in the rendered DOM precisely where me.el belongs. We replace the
|
582
|
-
// proxy el in the finishRender phase.
|
583
|
-
return {
|
584
|
-
tag: 'div',
|
585
|
-
id: (me.$pid = Ext.id())
|
586
|
-
};
|
587
|
-
}
|
588
|
-
|
589
|
-
return me.getElConfig();
|
590
|
-
}
|
591
|
-
|
592
|
-
return null;
|
593
|
-
},
|
594
|
-
|
595
|
-
initContainer: function(container) {
|
596
|
-
var me = this;
|
597
|
-
|
598
|
-
// If you render a component specifying the el, we get the container
|
599
|
-
// of the el, and make sure we dont move the el around in the dom
|
600
|
-
// during the render
|
601
|
-
if (!container && me.el) {
|
602
|
-
container = me.el.dom.parentNode;
|
603
|
-
me.allowDomMove = false;
|
604
|
-
}
|
605
|
-
me.container = container.dom ? container : Ext.get(container);
|
606
|
-
|
607
|
-
return me.container;
|
608
|
-
},
|
609
|
-
|
610
|
-
/**
|
611
|
-
* Initialized the renderData to be used when rendering the renderTpl.
|
612
|
-
* @return {Object} Object with keys and values that are going to be applied to the renderTpl
|
613
|
-
* @private
|
614
|
-
*/
|
615
|
-
initRenderData: function() {
|
616
|
-
var me = this;
|
617
|
-
|
618
|
-
return Ext.apply({
|
619
|
-
$comp: me,
|
620
|
-
id: me.id,
|
621
|
-
ui: me.ui,
|
622
|
-
uiCls: me.uiCls,
|
623
|
-
baseCls: me.baseCls,
|
624
|
-
componentCls: me.componentCls,
|
625
|
-
frame: me.frame
|
626
|
-
}, me.renderData);
|
627
|
-
},
|
628
|
-
|
629
|
-
/**
|
630
|
-
* Initializes the renderTpl.
|
631
|
-
* @return {Ext.XTemplate} The renderTpl XTemplate instance.
|
632
|
-
* @private
|
633
|
-
*/
|
634
|
-
initRenderTpl: function() {
|
635
|
-
var tpl = this.getTpl('renderTpl');
|
636
|
-
|
637
|
-
if (tpl && !tpl.renderContent) {
|
638
|
-
this.setupRenderTpl(tpl);
|
639
|
-
}
|
640
|
-
|
641
|
-
return tpl;
|
642
|
-
},
|
643
|
-
|
644
|
-
/**
|
645
|
-
* Template method called when this Component's DOM structure is created.
|
646
|
-
*
|
647
|
-
* At this point, this Component's (and all descendants') DOM structure *exists* but it has not
|
648
|
-
* been layed out (positioned and sized).
|
649
|
-
*
|
650
|
-
* Subclasses which override this to gain access to the structure at render time should
|
651
|
-
* call the parent class's method before attempting to access any child elements of the Component.
|
652
|
-
*
|
653
|
-
* @param {Ext.core.Element} parentNode The parent Element in which this Component's encapsulating element is contained.
|
654
|
-
* @param {Number} containerIdx The index within the parent Container's child collection of this Component.
|
655
|
-
*
|
656
|
-
* @template
|
657
|
-
* @protected
|
658
|
-
*/
|
659
|
-
onRender: function(parentNode, containerIdx) {
|
660
|
-
var me = this,
|
661
|
-
x = me.x,
|
662
|
-
y = me.y,
|
663
|
-
lastBox, width, height,
|
664
|
-
el = me.el;
|
665
|
-
|
666
|
-
// After the container property has been collected, we can wrap the Component in a reset wraper if necessary
|
667
|
-
if (Ext.scopeResetCSS && !me.ownerCt) {
|
668
|
-
// If this component's el is the body element, we add the reset class to the html tag
|
669
|
-
if (el.dom == Ext.getBody().dom) {
|
670
|
-
el.parent().addCls(Ext.resetCls);
|
671
|
-
}
|
672
|
-
else {
|
673
|
-
// Else we wrap this element in an element that adds the reset class.
|
674
|
-
me.resetEl = el.wrap({
|
675
|
-
cls: Ext.resetCls
|
676
|
-
});
|
677
|
-
}
|
678
|
-
}
|
679
|
-
|
680
|
-
me.applyRenderSelectors();
|
681
|
-
|
682
|
-
// Flag set on getRenderTree to flag to the layout's postprocessing routine that
|
683
|
-
// the Component is in the process of being rendered and needs postprocessing.
|
684
|
-
delete me.rendering;
|
685
|
-
|
686
|
-
me.rendered = true;
|
687
|
-
|
688
|
-
// We need to remember these to avoid writing them during the initial layout:
|
689
|
-
lastBox = null;
|
690
|
-
|
691
|
-
if (x !== undefined) {
|
692
|
-
lastBox = lastBox || {};
|
693
|
-
lastBox.x = x;
|
694
|
-
}
|
695
|
-
if (y !== undefined) {
|
696
|
-
lastBox = lastBox || {};
|
697
|
-
lastBox.y = y;
|
698
|
-
}
|
699
|
-
// Framed components need their width/height to apply to the frame, which is
|
700
|
-
// best handled in layout at present.
|
701
|
-
// If we're using the content box model, we also cannot assign initial sizes since we do not know the border widths to subtract
|
702
|
-
if (!me.getFrameInfo() && Ext.isBorderBox) {
|
703
|
-
width = me.width;
|
704
|
-
height = me.height;
|
705
|
-
|
706
|
-
if (typeof width == 'number') {
|
707
|
-
lastBox = lastBox || {};
|
708
|
-
lastBox.width = width;
|
709
|
-
}
|
710
|
-
if (typeof height == 'number') {
|
711
|
-
lastBox = lastBox || {};
|
712
|
-
lastBox.height = height;
|
713
|
-
}
|
714
|
-
}
|
715
|
-
|
716
|
-
me.lastBox = me.el.lastBox = lastBox;
|
717
|
-
},
|
718
|
-
|
719
|
-
render: function(container, position) {
|
720
|
-
var me = this,
|
721
|
-
el = me.el && (me.el = Ext.get(me.el)), // ensure me.el is wrapped
|
722
|
-
tree,
|
723
|
-
nextSibling;
|
724
|
-
|
725
|
-
Ext.suspendLayouts();
|
726
|
-
|
727
|
-
container = me.initContainer(container);
|
728
|
-
|
729
|
-
nextSibling = me.getInsertPosition(position);
|
730
|
-
|
731
|
-
if (!el) {
|
732
|
-
tree = me.getRenderTree();
|
733
|
-
|
734
|
-
// tree will be null if a beforerender listener returns false
|
735
|
-
if (tree) {
|
736
|
-
if (nextSibling) {
|
737
|
-
el = Ext.DomHelper.insertBefore(nextSibling, tree);
|
738
|
-
} else {
|
739
|
-
el = Ext.DomHelper.append(container, tree);
|
740
|
-
}
|
741
|
-
|
742
|
-
me.wrapPrimaryEl(el);
|
743
|
-
}
|
744
|
-
} else {
|
745
|
-
// Set configured styles on pre-rendered Component's element
|
746
|
-
me.initStyles(el);
|
747
|
-
if (me.allowDomMove !== false) {
|
748
|
-
//debugger; // TODO
|
749
|
-
if (nextSibling) {
|
750
|
-
container.dom.insertBefore(el.dom, nextSibling);
|
751
|
-
} else {
|
752
|
-
container.dom.appendChild(el.dom);
|
753
|
-
}
|
754
|
-
}
|
755
|
-
}
|
756
|
-
|
757
|
-
if (el) {
|
758
|
-
me.finishRender(position);
|
759
|
-
}
|
760
|
-
|
761
|
-
Ext.resumeLayouts(!container.isDetachedBody);
|
762
|
-
},
|
763
|
-
|
764
|
-
/**
|
765
|
-
* Ensures that this component is attached to `document.body`. If the component was
|
766
|
-
* rendered to {@link Ext#getDetachedBody}, then it will be appended to `document.body`.
|
767
|
-
* Any configured position is also restored.
|
768
|
-
* @param {Boolean} [runLayout=false] True to run the component's layout.
|
769
|
-
*/
|
770
|
-
ensureAttachedToBody: function (runLayout) {
|
771
|
-
var comp = this,
|
772
|
-
body;
|
773
|
-
|
774
|
-
while (comp.ownerCt) {
|
775
|
-
comp = comp.ownerCt;
|
776
|
-
}
|
777
|
-
|
778
|
-
if (comp.container.isDetachedBody) {
|
779
|
-
comp.container = body = Ext.getBody();
|
780
|
-
body.appendChild(comp.el.dom);
|
781
|
-
if (runLayout) {
|
782
|
-
comp.updateLayout();
|
783
|
-
}
|
784
|
-
if (typeof comp.x == 'number' || typeof comp.y == 'number') {
|
785
|
-
comp.setPosition(comp.x, comp.y);
|
786
|
-
}
|
787
|
-
}
|
788
|
-
},
|
789
|
-
|
790
|
-
setupRenderTpl: function (renderTpl) {
|
791
|
-
renderTpl.renderBody = renderTpl.renderContent = this.doRenderContent;
|
792
|
-
},
|
793
|
-
|
794
|
-
wrapPrimaryEl: function (dom) {
|
795
|
-
this.el = Ext.get(dom, true);
|
796
|
-
},
|
797
|
-
|
798
|
-
/**
|
799
|
-
* @private
|
800
|
-
*/
|
801
|
-
initFrame : function() {
|
802
|
-
if (Ext.supports.CSS3BorderRadius || !this.frame) {
|
803
|
-
return;
|
804
|
-
}
|
805
|
-
|
806
|
-
var me = this,
|
807
|
-
frameInfo = me.getFrameInfo(),
|
808
|
-
frameWidth, frameTpl, frameGenId,
|
809
|
-
i,
|
810
|
-
frameElNames = me.frameElNames,
|
811
|
-
len = frameElNames.length,
|
812
|
-
suffix;
|
813
|
-
|
814
|
-
if (frameInfo) {
|
815
|
-
frameWidth = frameInfo.maxWidth;
|
816
|
-
frameTpl = me.getFrameTpl(frameInfo.table);
|
817
|
-
|
818
|
-
// since we render id's into the markup and id's NEED to be unique, we have a
|
819
|
-
// simple strategy for numbering their generations.
|
820
|
-
me.frameGenId = frameGenId = (me.frameGenId || 0) + 1;
|
821
|
-
frameGenId = me.id + '-frame' + frameGenId;
|
822
|
-
|
823
|
-
// Here we render the frameTpl to this component. This inserts the 9point div or the table framing.
|
824
|
-
frameTpl.insertFirst(me.el, Ext.apply({
|
825
|
-
$comp: me,
|
826
|
-
fgid: frameGenId,
|
827
|
-
ui: me.ui,
|
828
|
-
uiCls: me.uiCls,
|
829
|
-
frameCls: me.frameCls,
|
830
|
-
baseCls: me.baseCls,
|
831
|
-
frameWidth: frameWidth,
|
832
|
-
top: !!frameInfo.top,
|
833
|
-
left: !!frameInfo.left,
|
834
|
-
right: !!frameInfo.right,
|
835
|
-
bottom: !!frameInfo.bottom
|
836
|
-
}, me.getFramePositions(frameInfo)));
|
837
|
-
|
838
|
-
// The frameBody is returned in getTargetEl, so that layouts render items to the correct target.
|
839
|
-
me.frameBody = me.el.down('.' + me.frameCls + '-mc');
|
840
|
-
|
841
|
-
// Clean out the childEls for the old frame elements (the majority of the els)
|
842
|
-
me.removeChildEls(function (c) {
|
843
|
-
return c.id && me.frameIdRegex.test(c.id);
|
844
|
-
});
|
845
|
-
|
846
|
-
// Grab references to the childEls for each of the new frame elements
|
847
|
-
for (i = 0; i < len; i++) {
|
848
|
-
suffix = frameElNames[i];
|
849
|
-
me['frame' + suffix] = me.el.getById(frameGenId + suffix);
|
850
|
-
}
|
851
|
-
}
|
852
|
-
},
|
853
|
-
|
854
|
-
updateFrame: function() {
|
855
|
-
if (Ext.supports.CSS3BorderRadius || !this.frame) {
|
856
|
-
return;
|
857
|
-
}
|
858
|
-
|
859
|
-
var me = this,
|
860
|
-
wasTable = this.frameSize && this.frameSize.table,
|
861
|
-
oldFrameTL = this.frameTL,
|
862
|
-
oldFrameBL = this.frameBL,
|
863
|
-
oldFrameML = this.frameML,
|
864
|
-
oldFrameMC = this.frameMC,
|
865
|
-
newMCClassName;
|
866
|
-
|
867
|
-
this.initFrame();
|
868
|
-
|
869
|
-
if (oldFrameMC) {
|
870
|
-
if (me.frame) {
|
871
|
-
|
872
|
-
// Store the class names set on the new MC
|
873
|
-
newMCClassName = this.frameMC.dom.className;
|
874
|
-
|
875
|
-
// Framing elements have been selected in initFrame, no need to run applyRenderSelectors
|
876
|
-
// Replace the new mc with the old mc
|
877
|
-
oldFrameMC.insertAfter(this.frameMC);
|
878
|
-
this.frameMC.remove();
|
879
|
-
|
880
|
-
// Restore the reference to the old frame mc as the framebody
|
881
|
-
this.frameBody = this.frameMC = oldFrameMC;
|
882
|
-
|
883
|
-
// Apply the new mc classes to the old mc element
|
884
|
-
oldFrameMC.dom.className = newMCClassName;
|
885
|
-
|
886
|
-
// Remove the old framing
|
887
|
-
if (wasTable) {
|
888
|
-
me.el.query('> table')[1].remove();
|
889
|
-
}
|
890
|
-
else {
|
891
|
-
if (oldFrameTL) {
|
892
|
-
oldFrameTL.remove();
|
893
|
-
}
|
894
|
-
if (oldFrameBL) {
|
895
|
-
oldFrameBL.remove();
|
896
|
-
}
|
897
|
-
if (oldFrameML) {
|
898
|
-
oldFrameML.remove();
|
899
|
-
}
|
900
|
-
}
|
901
|
-
}
|
902
|
-
}
|
903
|
-
else if (me.frame) {
|
904
|
-
this.applyRenderSelectors();
|
905
|
-
}
|
906
|
-
},
|
907
|
-
|
908
|
-
/**
|
909
|
-
* @private
|
910
|
-
* On render, reads an encoded style attribute, "background-position" from the style of this Component's element.
|
911
|
-
* This information is memoized based upon the CSS class name of this Component's element.
|
912
|
-
* Because child Components are rendered as textual HTML as part of the topmost Container, a dummy div is inserted
|
913
|
-
* into the document to receive the document element's CSS class name, and therefore style attributes.
|
914
|
-
*/
|
915
|
-
getFrameInfo: function() {
|
916
|
-
// If native framing can be used, or this component is not going to be framed, then do not attempt to read CSS framing info.
|
917
|
-
if (Ext.supports.CSS3BorderRadius || !this.frame) {
|
918
|
-
return false;
|
919
|
-
}
|
920
|
-
|
921
|
-
var me = this,
|
922
|
-
frameInfoCache = me.frameInfoCache,
|
923
|
-
el = me.el || me.protoEl,
|
924
|
-
cls = el.dom ? el.dom.className : el.classList.join(' '),
|
925
|
-
frameInfo = frameInfoCache[cls],
|
926
|
-
styleEl, left, top, info;
|
927
|
-
|
928
|
-
if (frameInfo == null) {
|
929
|
-
// Get the singleton frame style proxy with our el class name stamped into it.
|
930
|
-
styleEl = Ext.fly(me.getStyleProxy(cls), 'frame-style-el');
|
931
|
-
left = styleEl.getStyle('background-position-x');
|
932
|
-
top = styleEl.getStyle('background-position-y');
|
933
|
-
|
934
|
-
// Some browsers don't support background-position-x and y, so for those
|
935
|
-
// browsers let's split background-position into two parts.
|
936
|
-
if (!left && !top) {
|
937
|
-
info = styleEl.getStyle('background-position').split(' ');
|
938
|
-
left = info[0];
|
939
|
-
top = info[1];
|
940
|
-
}
|
941
|
-
|
942
|
-
frameInfo = me.calculateFrame(left, top);
|
943
|
-
|
944
|
-
if (frameInfo) {
|
945
|
-
// Just to be sure we set the background image of the el to none.
|
946
|
-
el.setStyle('background-image', 'none');
|
947
|
-
}
|
948
|
-
|
949
|
-
//<debug error>
|
950
|
-
// This happens when you set frame: true explicitly without using the x-frame mixin in sass.
|
951
|
-
// This way IE can't figure out what sizes to use and thus framing can't work.
|
952
|
-
if (me.frame === true && !frameInfo) {
|
953
|
-
Ext.log.error('You have set frame: true explicity on this component (' + me.getXType() + ') and it ' +
|
954
|
-
'does not have any framing defined in the CSS template. In this case IE cannot figure out ' +
|
955
|
-
'what sizes to use and thus framing on this component will be disabled.');
|
956
|
-
}
|
957
|
-
//</debug>
|
958
|
-
|
959
|
-
frameInfoCache[cls] = frameInfo;
|
960
|
-
}
|
961
|
-
|
962
|
-
me.frame = !!frameInfo;
|
963
|
-
me.frameSize = frameInfo;
|
964
|
-
|
965
|
-
return frameInfo;
|
966
|
-
},
|
967
|
-
|
968
|
-
calculateFrame: function(left, top){
|
969
|
-
// We actually pass a string in the form of '[type][tl][tr]px [direction][br][bl]px' as
|
970
|
-
// the background position of this.el from the CSS to indicate to IE that this component needs
|
971
|
-
// framing. We parse it here.
|
972
|
-
if (!(parseInt(left, 10) >= 1000000 && parseInt(top, 10) >= 1000000)) {
|
973
|
-
return false;
|
974
|
-
}
|
975
|
-
var max = Math.max,
|
976
|
-
tl = parseInt(left.substr(3, 2), 10),
|
977
|
-
tr = parseInt(left.substr(5, 2), 10),
|
978
|
-
br = parseInt(top.substr(3, 2), 10),
|
979
|
-
bl = parseInt(top.substr(5, 2), 10),
|
980
|
-
frameInfo = {
|
981
|
-
// Table markup starts with 110, div markup with 100.
|
982
|
-
table: left.substr(0, 3) == '110',
|
983
|
-
|
984
|
-
// Determine if we are dealing with a horizontal or vertical component
|
985
|
-
vertical: top.substr(0, 3) == '110',
|
986
|
-
|
987
|
-
// Get and parse the different border radius sizes
|
988
|
-
top: max(tl, tr),
|
989
|
-
right: max(tr, br),
|
990
|
-
bottom: max(bl, br),
|
991
|
-
left: max(tl, bl)
|
992
|
-
};
|
993
|
-
|
994
|
-
frameInfo.maxWidth = max(frameInfo.top, frameInfo.right, frameInfo.bottom, frameInfo.left);
|
995
|
-
frameInfo.width = frameInfo.left + frameInfo.right;
|
996
|
-
frameInfo.height = frameInfo.top + frameInfo.bottom;
|
997
|
-
return frameInfo;
|
998
|
-
},
|
999
|
-
|
1000
|
-
/**
|
1001
|
-
* @private
|
1002
|
-
* Returns an offscreen div with the same class name as the element this is being rendered.
|
1003
|
-
* This is because child item rendering takes place in a detached div which, being not part of the document, has no styling.
|
1004
|
-
*/
|
1005
|
-
getStyleProxy: function(cls) {
|
1006
|
-
var result = this.styleProxyEl || (Ext.AbstractComponent.prototype.styleProxyEl = Ext.getBody().createChild({
|
1007
|
-
style: {
|
1008
|
-
position: 'absolute',
|
1009
|
-
top: '-10000px'
|
1010
|
-
}
|
1011
|
-
}, null, true));
|
1012
|
-
|
1013
|
-
result.className = cls;
|
1014
|
-
return result;
|
1015
|
-
},
|
1016
|
-
|
1017
|
-
getFramePositions: function(frameInfo) {
|
1018
|
-
var me = this,
|
1019
|
-
frameWidth = frameInfo.maxWidth,
|
1020
|
-
dock = me.dock,
|
1021
|
-
positions, tc, bc, ml, mr;
|
1022
|
-
|
1023
|
-
if (frameInfo.vertical) {
|
1024
|
-
tc = '0 -' + (frameWidth * 0) + 'px';
|
1025
|
-
bc = '0 -' + (frameWidth * 1) + 'px';
|
1026
|
-
|
1027
|
-
if (dock && dock == "right") {
|
1028
|
-
tc = 'right -' + (frameWidth * 0) + 'px';
|
1029
|
-
bc = 'right -' + (frameWidth * 1) + 'px';
|
1030
|
-
}
|
1031
|
-
|
1032
|
-
positions = {
|
1033
|
-
tl: '0 -' + (frameWidth * 0) + 'px',
|
1034
|
-
tr: '0 -' + (frameWidth * 1) + 'px',
|
1035
|
-
bl: '0 -' + (frameWidth * 2) + 'px',
|
1036
|
-
br: '0 -' + (frameWidth * 3) + 'px',
|
1037
|
-
|
1038
|
-
ml: '-' + (frameWidth * 1) + 'px 0',
|
1039
|
-
mr: 'right 0',
|
1040
|
-
|
1041
|
-
tc: tc,
|
1042
|
-
bc: bc
|
1043
|
-
};
|
1044
|
-
} else {
|
1045
|
-
ml = '-' + (frameWidth * 0) + 'px 0';
|
1046
|
-
mr = 'right 0';
|
1047
|
-
|
1048
|
-
if (dock && dock == "bottom") {
|
1049
|
-
ml = 'left bottom';
|
1050
|
-
mr = 'right bottom';
|
1051
|
-
}
|
1052
|
-
|
1053
|
-
positions = {
|
1054
|
-
tl: '0 -' + (frameWidth * 2) + 'px',
|
1055
|
-
tr: 'right -' + (frameWidth * 3) + 'px',
|
1056
|
-
bl: '0 -' + (frameWidth * 4) + 'px',
|
1057
|
-
br: 'right -' + (frameWidth * 5) + 'px',
|
1058
|
-
|
1059
|
-
ml: ml,
|
1060
|
-
mr: mr,
|
1061
|
-
|
1062
|
-
tc: '0 -' + (frameWidth * 0) + 'px',
|
1063
|
-
bc: '0 -' + (frameWidth * 1) + 'px'
|
1064
|
-
};
|
1065
|
-
}
|
1066
|
-
|
1067
|
-
return positions;
|
1068
|
-
},
|
1069
|
-
|
1070
|
-
/**
|
1071
|
-
* @private
|
1072
|
-
*/
|
1073
|
-
getFrameTpl : function(table) {
|
1074
|
-
return this.getTpl(table ? 'frameTableTpl' : 'frameTpl');
|
1075
|
-
},
|
1076
|
-
|
1077
|
-
// Cache the frame information object so as not to cause style recalculations
|
1078
|
-
frameInfoCache: {}
|
1079
|
-
});
|