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.
Files changed (507) hide show
  1. data/app/assets/javascripts/extjs-rails.js +95613 -11000
  2. data/lib/extjs-rails/version.rb +1 -1
  3. metadata +2 -509
  4. data/app/assets/javascripts/src/AbstractComponent.js +0 -3290
  5. data/app/assets/javascripts/src/AbstractManager.js +0 -144
  6. data/app/assets/javascripts/src/AbstractPlugin.js +0 -72
  7. data/app/assets/javascripts/src/Action.js +0 -276
  8. data/app/assets/javascripts/src/Ajax.js +0 -99
  9. data/app/assets/javascripts/src/Component.js +0 -1344
  10. data/app/assets/javascripts/src/ComponentLoader.js +0 -202
  11. data/app/assets/javascripts/src/ComponentManager.js +0 -47
  12. data/app/assets/javascripts/src/ComponentQuery.js +0 -521
  13. data/app/assets/javascripts/src/Editor.js +0 -494
  14. data/app/assets/javascripts/src/ElementLoader.js +0 -404
  15. data/app/assets/javascripts/src/FocusManager.js +0 -712
  16. data/app/assets/javascripts/src/Img.js +0 -111
  17. data/app/assets/javascripts/src/Layer.js +0 -543
  18. data/app/assets/javascripts/src/LoadMask.js +0 -432
  19. data/app/assets/javascripts/src/ModelManager.js +0 -186
  20. data/app/assets/javascripts/src/PluginManager.js +0 -110
  21. data/app/assets/javascripts/src/ProgressBar.js +0 -336
  22. data/app/assets/javascripts/src/Shadow.js +0 -233
  23. data/app/assets/javascripts/src/ShadowPool.js +0 -43
  24. data/app/assets/javascripts/src/Template.js +0 -331
  25. data/app/assets/javascripts/src/XTemplate.js +0 -365
  26. data/app/assets/javascripts/src/XTemplateCompiler.js +0 -450
  27. data/app/assets/javascripts/src/XTemplateParser.js +0 -249
  28. data/app/assets/javascripts/src/ZIndexManager.js +0 -519
  29. data/app/assets/javascripts/src/app/Application.js +0 -271
  30. data/app/assets/javascripts/src/app/Controller.js +0 -458
  31. data/app/assets/javascripts/src/app/EventBus.js +0 -112
  32. data/app/assets/javascripts/src/button/Button.js +0 -1483
  33. data/app/assets/javascripts/src/button/Cycle.js +0 -215
  34. data/app/assets/javascripts/src/button/Split.js +0 -99
  35. data/app/assets/javascripts/src/chart/Callout.js +0 -140
  36. data/app/assets/javascripts/src/chart/Chart.js +0 -966
  37. data/app/assets/javascripts/src/chart/Highlight.js +0 -172
  38. data/app/assets/javascripts/src/chart/Label.js +0 -241
  39. data/app/assets/javascripts/src/chart/Legend.js +0 -474
  40. data/app/assets/javascripts/src/chart/LegendItem.js +0 -217
  41. data/app/assets/javascripts/src/chart/Mask.js +0 -230
  42. data/app/assets/javascripts/src/chart/MaskLayer.js +0 -48
  43. data/app/assets/javascripts/src/chart/Navigation.js +0 -79
  44. data/app/assets/javascripts/src/chart/Shape.js +0 -106
  45. data/app/assets/javascripts/src/chart/Tip.js +0 -98
  46. data/app/assets/javascripts/src/chart/TipSurface.js +0 -42
  47. data/app/assets/javascripts/src/chart/axis/Abstract.js +0 -73
  48. data/app/assets/javascripts/src/chart/axis/Axis.js +0 -961
  49. data/app/assets/javascripts/src/chart/axis/Category.js +0 -130
  50. data/app/assets/javascripts/src/chart/axis/Gauge.js +0 -203
  51. data/app/assets/javascripts/src/chart/axis/Numeric.js +0 -235
  52. data/app/assets/javascripts/src/chart/axis/Radial.js +0 -204
  53. data/app/assets/javascripts/src/chart/axis/Time.js +0 -135
  54. data/app/assets/javascripts/src/chart/series/Area.js +0 -803
  55. data/app/assets/javascripts/src/chart/series/Bar.js +0 -853
  56. data/app/assets/javascripts/src/chart/series/Cartesian.js +0 -328
  57. data/app/assets/javascripts/src/chart/series/Column.js +0 -104
  58. data/app/assets/javascripts/src/chart/series/Gauge.js +0 -490
  59. data/app/assets/javascripts/src/chart/series/Line.js +0 -1104
  60. data/app/assets/javascripts/src/chart/series/Pie.js +0 -1072
  61. data/app/assets/javascripts/src/chart/series/Radar.js +0 -440
  62. data/app/assets/javascripts/src/chart/series/Scatter.js +0 -668
  63. data/app/assets/javascripts/src/chart/series/Series.js +0 -443
  64. data/app/assets/javascripts/src/chart/theme/Base.js +0 -175
  65. data/app/assets/javascripts/src/chart/theme/Theme.js +0 -253
  66. data/app/assets/javascripts/src/container/AbstractContainer.js +0 -1062
  67. data/app/assets/javascripts/src/container/ButtonGroup.js +0 -143
  68. data/app/assets/javascripts/src/container/Container.js +0 -212
  69. data/app/assets/javascripts/src/container/DockingContainer.js +0 -265
  70. data/app/assets/javascripts/src/container/Viewport.js +0 -184
  71. data/app/assets/javascripts/src/core/dom/Element.form.js +0 -50
  72. data/app/assets/javascripts/src/core/dom/Element.static-more.js +0 -159
  73. data/app/assets/javascripts/src/core/examples/index.html +0 -321
  74. data/app/assets/javascripts/src/core/examples/index.js +0 -6
  75. data/app/assets/javascripts/src/core/examples/src/Sample/CTO.js +0 -25
  76. data/app/assets/javascripts/src/core/examples/src/Sample/CoolGuy.js +0 -20
  77. data/app/assets/javascripts/src/core/examples/src/Sample/Developer.js +0 -43
  78. data/app/assets/javascripts/src/core/examples/src/Sample/Gun.js +0 -3
  79. data/app/assets/javascripts/src/core/examples/src/Sample/HumanResource.js +0 -23
  80. data/app/assets/javascripts/src/core/examples/src/Sample/Musician.js +0 -20
  81. data/app/assets/javascripts/src/core/examples/src/Sample/Person.js +0 -50
  82. data/app/assets/javascripts/src/core/examples/src/Sample/ability/CanComposeSongs.js +0 -9
  83. data/app/assets/javascripts/src/core/examples/src/Sample/ability/CanPlayGuitar.js +0 -9
  84. data/app/assets/javascripts/src/core/examples/src/Sample/ability/CanSing.js +0 -18
  85. data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/A.js +0 -3
  86. data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/B.js +0 -3
  87. data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/C.js +0 -3
  88. data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/D.js +0 -3
  89. data/app/assets/javascripts/src/core/examples/src/Sample/deadlock/E.js +0 -3
  90. data/app/assets/javascripts/src/core/examples/src/Sample/notdeadlock/A.js +0 -3
  91. data/app/assets/javascripts/src/core/examples/src/Sample/notdeadlock/B.js +0 -4
  92. data/app/assets/javascripts/src/core/examples/src/Sample/notdeadlock/C.js +0 -3
  93. data/app/assets/javascripts/src/core/src/EventManager.js +0 -1167
  94. data/app/assets/javascripts/src/core/src/EventObject.js +0 -883
  95. data/app/assets/javascripts/src/core/src/Ext-more.js +0 -1283
  96. data/app/assets/javascripts/src/core/src/Ext.js +0 -736
  97. data/app/assets/javascripts/src/core/src/Support.js +0 -662
  98. data/app/assets/javascripts/src/core/src/class/Base.js +0 -1085
  99. data/app/assets/javascripts/src/core/src/class/Class.js +0 -676
  100. data/app/assets/javascripts/src/core/src/class/ClassManager.js +0 -1591
  101. data/app/assets/javascripts/src/core/src/class/Loader.js +0 -1423
  102. data/app/assets/javascripts/src/core/src/dom/AbstractElement.alignment.js +0 -173
  103. data/app/assets/javascripts/src/core/src/dom/AbstractElement.insertion.js +0 -193
  104. data/app/assets/javascripts/src/core/src/dom/AbstractElement.js +0 -681
  105. data/app/assets/javascripts/src/core/src/dom/AbstractElement.position.js +0 -356
  106. data/app/assets/javascripts/src/core/src/dom/AbstractElement.static.js +0 -474
  107. data/app/assets/javascripts/src/core/src/dom/AbstractElement.style.js +0 -851
  108. data/app/assets/javascripts/src/core/src/dom/AbstractElement.traversal.js +0 -180
  109. data/app/assets/javascripts/src/core/src/dom/AbstractHelper.js +0 -291
  110. data/app/assets/javascripts/src/core/src/dom/AbstractQuery.js +0 -72
  111. data/app/assets/javascripts/src/core/src/dom/CompositeElement.js +0 -75
  112. data/app/assets/javascripts/src/core/src/dom/CompositeElementLite.js +0 -436
  113. data/app/assets/javascripts/src/core/src/dom/DomQuery-aria.js +0 -1049
  114. data/app/assets/javascripts/src/core/src/env/Browser.js +0 -186
  115. data/app/assets/javascripts/src/core/src/env/FeatureDetector.js +0 -274
  116. data/app/assets/javascripts/src/core/src/env/OS.js +0 -141
  117. data/app/assets/javascripts/src/core/src/lang/Array.js +0 -1205
  118. data/app/assets/javascripts/src/core/src/lang/Date.js +0 -1463
  119. data/app/assets/javascripts/src/core/src/lang/Error.js +0 -326
  120. data/app/assets/javascripts/src/core/src/lang/Function.js +0 -485
  121. data/app/assets/javascripts/src/core/src/lang/Number.js +0 -175
  122. data/app/assets/javascripts/src/core/src/lang/Object.js +0 -606
  123. data/app/assets/javascripts/src/core/src/lang/String.js +0 -333
  124. data/app/assets/javascripts/src/core/src/misc/JSON.js +0 -236
  125. data/app/assets/javascripts/src/core/src/perf/Accumulator.js +0 -244
  126. data/app/assets/javascripts/src/core/src/perf/Monitor.js +0 -197
  127. data/app/assets/javascripts/src/core/src/util/DelayedTask.js +0 -71
  128. data/app/assets/javascripts/src/core/src/util/Event.js +0 -215
  129. data/app/assets/javascripts/src/core/src/util/Format.js +0 -551
  130. data/app/assets/javascripts/src/core/src/util/TaskManager.js +0 -417
  131. data/app/assets/javascripts/src/core/src/version/Version.js +0 -364
  132. data/app/assets/javascripts/src/core/test/unit/README.MD +0 -91
  133. data/app/assets/javascripts/src/core/test/unit/bootstrap.js +0 -39
  134. data/app/assets/javascripts/src/core/test/unit/build/build-data.js +0 -34
  135. data/app/assets/javascripts/src/core/test/unit/build/build.sh +0 -2
  136. data/app/assets/javascripts/src/core/test/unit/data.js +0 -27
  137. data/app/assets/javascripts/src/core/test/unit/index.html +0 -15
  138. data/app/assets/javascripts/src/core/test/unit/other_specs/dom.html +0 -40
  139. data/app/assets/javascripts/src/core/test/unit/other_specs/dom/extjs-api.js +0 -12
  140. data/app/assets/javascripts/src/core/test/unit/other_specs/dom/platform-api.js +0 -134
  141. data/app/assets/javascripts/src/core/test/unit/other_specs/dom/sanity.js +0 -4
  142. data/app/assets/javascripts/src/core/test/unit/other_specs/dom/touch-api-out.js +0 -128
  143. data/app/assets/javascripts/src/core/test/unit/other_specs/dom/touch-api.js +0 -89
  144. data/app/assets/javascripts/src/core/test/unit/other_specs/env/Environment.js +0 -357
  145. data/app/assets/javascripts/src/core/test/unit/resources/APITest.js +0 -37
  146. data/app/assets/javascripts/src/core/test/unit/resources/jsb3.js +0 -14
  147. data/app/assets/javascripts/src/core/test/unit/resources/test-setup.js +0 -137
  148. data/app/assets/javascripts/src/core/test/unit/spec/EventManager.js +0 -629
  149. data/app/assets/javascripts/src/core/test/unit/spec/Ext-mess.backup +0 -198
  150. data/app/assets/javascripts/src/core/test/unit/spec/Ext-more.js +0 -520
  151. data/app/assets/javascripts/src/core/test/unit/spec/Ext.js +0 -1550
  152. data/app/assets/javascripts/src/core/test/unit/spec/Support.js +0 -250
  153. data/app/assets/javascripts/src/core/test/unit/spec/class/Base.js +0 -47
  154. data/app/assets/javascripts/src/core/test/unit/spec/class/Class.js +0 -561
  155. data/app/assets/javascripts/src/core/test/unit/spec/class/ClassManager.js +0 -555
  156. data/app/assets/javascripts/src/core/test/unit/spec/dom/CompositeElementLite.js +0 -409
  157. data/app/assets/javascripts/src/core/test/unit/spec/dom/DomHelper.js +0 -444
  158. data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.insertion.js +0 -342
  159. data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.js +0 -731
  160. data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.static.js +0 -201
  161. data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.style.js +0 -118
  162. data/app/assets/javascripts/src/core/test/unit/spec/dom/Element.traversal.js +0 -336
  163. data/app/assets/javascripts/src/core/test/unit/spec/lang/Array.js +0 -1229
  164. data/app/assets/javascripts/src/core/test/unit/spec/lang/Date.js +0 -697
  165. data/app/assets/javascripts/src/core/test/unit/spec/lang/Error.js +0 -277
  166. data/app/assets/javascripts/src/core/test/unit/spec/lang/Function.js +0 -536
  167. data/app/assets/javascripts/src/core/test/unit/spec/lang/Number.js +0 -323
  168. data/app/assets/javascripts/src/core/test/unit/spec/lang/Object.js +0 -591
  169. data/app/assets/javascripts/src/core/test/unit/spec/lang/String.js +0 -451
  170. data/app/assets/javascripts/src/core/test/unit/spec/misc/JSON.js +0 -252
  171. data/app/assets/javascripts/src/core/test/unit/spec/util/Format.js +0 -521
  172. data/app/assets/javascripts/src/core/test/unit/spec/version/Version.js +0 -148
  173. data/app/assets/javascripts/src/core/test/unit/specs.html +0 -19
  174. data/app/assets/javascripts/src/data/AbstractStore.js +0 -887
  175. data/app/assets/javascripts/src/data/ArrayStore.js +0 -74
  176. data/app/assets/javascripts/src/data/Batch.js +0 -236
  177. data/app/assets/javascripts/src/data/BufferStore.js +0 -13
  178. data/app/assets/javascripts/src/data/Connection.js +0 -969
  179. data/app/assets/javascripts/src/data/DirectStore.js +0 -50
  180. data/app/assets/javascripts/src/data/Errors.js +0 -52
  181. data/app/assets/javascripts/src/data/Field.js +0 -341
  182. data/app/assets/javascripts/src/data/IdGenerator.js +0 -198
  183. data/app/assets/javascripts/src/data/JsonP.js +0 -253
  184. data/app/assets/javascripts/src/data/JsonPStore.js +0 -51
  185. data/app/assets/javascripts/src/data/JsonStore.js +0 -60
  186. data/app/assets/javascripts/src/data/Model.js +0 -1673
  187. data/app/assets/javascripts/src/data/NodeInterface.js +0 -1294
  188. data/app/assets/javascripts/src/data/NodeStore.js +0 -254
  189. data/app/assets/javascripts/src/data/Operation.js +0 -331
  190. data/app/assets/javascripts/src/data/Request.js +0 -40
  191. data/app/assets/javascripts/src/data/ResultSet.js +0 -56
  192. data/app/assets/javascripts/src/data/SequentialIdGenerator.js +0 -61
  193. data/app/assets/javascripts/src/data/SortTypes.js +0 -125
  194. data/app/assets/javascripts/src/data/Store.js +0 -2609
  195. data/app/assets/javascripts/src/data/StoreManager.js +0 -156
  196. data/app/assets/javascripts/src/data/Tree.js +0 -290
  197. data/app/assets/javascripts/src/data/TreeStore.js +0 -655
  198. data/app/assets/javascripts/src/data/Types.js +0 -190
  199. data/app/assets/javascripts/src/data/UuidGenerator.js +0 -215
  200. data/app/assets/javascripts/src/data/XmlStore.js +0 -76
  201. data/app/assets/javascripts/src/data/association/Association.js +0 -243
  202. data/app/assets/javascripts/src/data/association/BelongsTo.js +0 -291
  203. data/app/assets/javascripts/src/data/association/HasMany.js +0 -289
  204. data/app/assets/javascripts/src/data/association/HasOne.js +0 -304
  205. data/app/assets/javascripts/src/data/proxy/Ajax.js +0 -282
  206. data/app/assets/javascripts/src/data/proxy/Client.js +0 -21
  207. data/app/assets/javascripts/src/data/proxy/Direct.js +0 -181
  208. data/app/assets/javascripts/src/data/proxy/JsonP.js +0 -313
  209. data/app/assets/javascripts/src/data/proxy/LocalStorage.js +0 -69
  210. data/app/assets/javascripts/src/data/proxy/Memory.js +0 -156
  211. data/app/assets/javascripts/src/data/proxy/Proxy.js +0 -433
  212. data/app/assets/javascripts/src/data/proxy/Rest.js +0 -173
  213. data/app/assets/javascripts/src/data/proxy/Server.js +0 -460
  214. data/app/assets/javascripts/src/data/proxy/SessionStorage.js +0 -39
  215. data/app/assets/javascripts/src/data/proxy/WebStorage.js +0 -546
  216. data/app/assets/javascripts/src/data/reader/Array.js +0 -68
  217. data/app/assets/javascripts/src/data/reader/Json.js +0 -383
  218. data/app/assets/javascripts/src/data/reader/Reader.js +0 -735
  219. data/app/assets/javascripts/src/data/reader/Xml.js +0 -292
  220. data/app/assets/javascripts/src/data/validations.js +0 -149
  221. data/app/assets/javascripts/src/data/writer/Json.js +0 -81
  222. data/app/assets/javascripts/src/data/writer/Writer.js +0 -147
  223. data/app/assets/javascripts/src/data/writer/Xml.js +0 -88
  224. data/app/assets/javascripts/src/dd/DD.js +0 -300
  225. data/app/assets/javascripts/src/dd/DDProxy.js +0 -204
  226. data/app/assets/javascripts/src/dd/DDTarget.js +0 -171
  227. data/app/assets/javascripts/src/dd/DragDrop.js +0 -1101
  228. data/app/assets/javascripts/src/dd/DragDropManager.js +0 -1264
  229. data/app/assets/javascripts/src/dd/DragSource.js +0 -392
  230. data/app/assets/javascripts/src/dd/DragTracker.js +0 -562
  231. data/app/assets/javascripts/src/dd/DragZone.js +0 -137
  232. data/app/assets/javascripts/src/dd/DropTarget.js +0 -118
  233. data/app/assets/javascripts/src/dd/DropZone.js +0 -254
  234. data/app/assets/javascripts/src/dd/Registry.js +0 -117
  235. data/app/assets/javascripts/src/dd/ScrollManager.js +0 -218
  236. data/app/assets/javascripts/src/dd/StatusProxy.js +0 -179
  237. data/app/assets/javascripts/src/diag/layout/Context.js +0 -523
  238. data/app/assets/javascripts/src/diag/layout/ContextItem.js +0 -179
  239. data/app/assets/javascripts/src/direct/Event.js +0 -35
  240. data/app/assets/javascripts/src/direct/ExceptionEvent.js +0 -16
  241. data/app/assets/javascripts/src/direct/JsonProvider.js +0 -82
  242. data/app/assets/javascripts/src/direct/Manager.js +0 -263
  243. data/app/assets/javascripts/src/direct/PollingProvider.js +0 -156
  244. data/app/assets/javascripts/src/direct/Provider.js +0 -96
  245. data/app/assets/javascripts/src/direct/RemotingEvent.js +0 -24
  246. data/app/assets/javascripts/src/direct/RemotingMethod.js +0 -100
  247. data/app/assets/javascripts/src/direct/RemotingProvider.js +0 -510
  248. data/app/assets/javascripts/src/direct/Transaction.js +0 -41
  249. data/app/assets/javascripts/src/dom/Element.alignment.js +0 -378
  250. data/app/assets/javascripts/src/dom/Element.anim.js +0 -962
  251. data/app/assets/javascripts/src/dom/Element.dd.js +0 -40
  252. data/app/assets/javascripts/src/dom/Element.fx.js +0 -194
  253. data/app/assets/javascripts/src/dom/Element.js +0 -1407
  254. data/app/assets/javascripts/src/dom/Element.position.js +0 -501
  255. data/app/assets/javascripts/src/dom/Element.scroll.js +0 -214
  256. data/app/assets/javascripts/src/dom/Element.style.js +0 -792
  257. data/app/assets/javascripts/src/dom/Element.traversal.js +0 -8
  258. data/app/assets/javascripts/src/dom/Helper.js +0 -466
  259. data/app/assets/javascripts/src/dom/Query.js +0 -1067
  260. data/app/assets/javascripts/src/draw/Color.js +0 -303
  261. data/app/assets/javascripts/src/draw/Component.js +0 -245
  262. data/app/assets/javascripts/src/draw/CompositeSprite.js +0 -299
  263. data/app/assets/javascripts/src/draw/Draw.js +0 -1217
  264. data/app/assets/javascripts/src/draw/Matrix.js +0 -183
  265. data/app/assets/javascripts/src/draw/Sprite.js +0 -554
  266. data/app/assets/javascripts/src/draw/SpriteDD.js +0 -87
  267. data/app/assets/javascripts/src/draw/Surface.js +0 -1001
  268. data/app/assets/javascripts/src/draw/Text.js +0 -175
  269. data/app/assets/javascripts/src/draw/engine/ImageExporter.js +0 -106
  270. data/app/assets/javascripts/src/draw/engine/Svg.js +0 -734
  271. data/app/assets/javascripts/src/draw/engine/SvgExporter.js +0 -280
  272. data/app/assets/javascripts/src/draw/engine/Vml.js +0 -916
  273. data/app/assets/javascripts/src/flash/Component.js +0 -248
  274. data/app/assets/javascripts/src/form/Basic.js +0 -1018
  275. data/app/assets/javascripts/src/form/CheckboxGroup.js +0 -441
  276. data/app/assets/javascripts/src/form/CheckboxManager.js +0 -26
  277. data/app/assets/javascripts/src/form/FieldAncestor.js +0 -210
  278. data/app/assets/javascripts/src/form/FieldContainer.js +0 -290
  279. data/app/assets/javascripts/src/form/FieldSet.js +0 -506
  280. data/app/assets/javascripts/src/form/Label.js +0 -110
  281. data/app/assets/javascripts/src/form/Labelable.js +0 -764
  282. data/app/assets/javascripts/src/form/Panel.js +0 -335
  283. data/app/assets/javascripts/src/form/RadioGroup.js +0 -124
  284. data/app/assets/javascripts/src/form/RadioManager.js +0 -26
  285. data/app/assets/javascripts/src/form/action/Action.js +0 -307
  286. data/app/assets/javascripts/src/form/action/DirectLoad.js +0 -107
  287. data/app/assets/javascripts/src/form/action/DirectSubmit.js +0 -119
  288. data/app/assets/javascripts/src/form/action/Load.js +0 -120
  289. data/app/assets/javascripts/src/form/action/StandardSubmit.js +0 -34
  290. data/app/assets/javascripts/src/form/action/Submit.js +0 -257
  291. data/app/assets/javascripts/src/form/field/Base.js +0 -813
  292. data/app/assets/javascripts/src/form/field/Checkbox.js +0 -505
  293. data/app/assets/javascripts/src/form/field/ComboBox.js +0 -1427
  294. data/app/assets/javascripts/src/form/field/Date.js +0 -578
  295. data/app/assets/javascripts/src/form/field/Display.js +0 -155
  296. data/app/assets/javascripts/src/form/field/Field.js +0 -430
  297. data/app/assets/javascripts/src/form/field/File.js +0 -265
  298. data/app/assets/javascripts/src/form/field/Hidden.js +0 -75
  299. data/app/assets/javascripts/src/form/field/HtmlEditor.js +0 -1439
  300. data/app/assets/javascripts/src/form/field/Number.js +0 -380
  301. data/app/assets/javascripts/src/form/field/Picker.js +0 -321
  302. data/app/assets/javascripts/src/form/field/Radio.js +0 -279
  303. data/app/assets/javascripts/src/form/field/Spinner.js +0 -321
  304. data/app/assets/javascripts/src/form/field/Text.js +0 -727
  305. data/app/assets/javascripts/src/form/field/TextArea.js +0 -228
  306. data/app/assets/javascripts/src/form/field/Time.js +0 -459
  307. data/app/assets/javascripts/src/form/field/Trigger.js +0 -469
  308. data/app/assets/javascripts/src/form/field/VTypes.js +0 -172
  309. data/app/assets/javascripts/src/fx/Anim.js +0 -472
  310. data/app/assets/javascripts/src/fx/Animator.js +0 -410
  311. data/app/assets/javascripts/src/fx/CubicBezier.js +0 -77
  312. data/app/assets/javascripts/src/fx/Easing.js +0 -136
  313. data/app/assets/javascripts/src/fx/Manager.js +0 -353
  314. data/app/assets/javascripts/src/fx/PropertyHandler.js +0 -381
  315. data/app/assets/javascripts/src/fx/Queue.js +0 -123
  316. data/app/assets/javascripts/src/fx/target/Component.js +0 -118
  317. data/app/assets/javascripts/src/fx/target/CompositeElement.js +0 -46
  318. data/app/assets/javascripts/src/fx/target/CompositeElementCSS.js +0 -22
  319. data/app/assets/javascripts/src/fx/target/CompositeSprite.js +0 -34
  320. data/app/assets/javascripts/src/fx/target/Element.js +0 -83
  321. data/app/assets/javascripts/src/fx/target/ElementCSS.js +0 -77
  322. data/app/assets/javascripts/src/fx/target/Sprite.js +0 -128
  323. data/app/assets/javascripts/src/fx/target/Target.js +0 -36
  324. data/app/assets/javascripts/src/grid/CellEditor.js +0 -172
  325. data/app/assets/javascripts/src/grid/ColumnComponentLayout.js +0 -34
  326. data/app/assets/javascripts/src/grid/ColumnLayout.js +0 -201
  327. data/app/assets/javascripts/src/grid/Lockable.js +0 -863
  328. data/app/assets/javascripts/src/grid/LockingView.js +0 -169
  329. data/app/assets/javascripts/src/grid/PagingScroller.js +0 -539
  330. data/app/assets/javascripts/src/grid/Panel.js +0 -393
  331. data/app/assets/javascripts/src/grid/RowEditor.js +0 -731
  332. data/app/assets/javascripts/src/grid/RowNumberer.js +0 -76
  333. data/app/assets/javascripts/src/grid/Scroller.js +0 -5
  334. data/app/assets/javascripts/src/grid/View.js +0 -44
  335. data/app/assets/javascripts/src/grid/ViewDropZone.js +0 -41
  336. data/app/assets/javascripts/src/grid/column/Action.js +0 -318
  337. data/app/assets/javascripts/src/grid/column/Boolean.js +0 -82
  338. data/app/assets/javascripts/src/grid/column/Column.js +0 -835
  339. data/app/assets/javascripts/src/grid/column/Date.js +0 -63
  340. data/app/assets/javascripts/src/grid/column/Number.js +0 -52
  341. data/app/assets/javascripts/src/grid/column/Template.js +0 -58
  342. data/app/assets/javascripts/src/grid/feature/AbstractSummary.js +0 -154
  343. data/app/assets/javascripts/src/grid/feature/Chunking.js +0 -77
  344. data/app/assets/javascripts/src/grid/feature/Feature.js +0 -158
  345. data/app/assets/javascripts/src/grid/feature/Grouping.js +0 -822
  346. data/app/assets/javascripts/src/grid/feature/GroupingSummary.js +0 -243
  347. data/app/assets/javascripts/src/grid/feature/RowBody.js +0 -116
  348. data/app/assets/javascripts/src/grid/feature/RowWrap.js +0 -120
  349. data/app/assets/javascripts/src/grid/feature/Summary.js +0 -167
  350. data/app/assets/javascripts/src/grid/header/Container.js +0 -965
  351. data/app/assets/javascripts/src/grid/header/DragZone.js +0 -69
  352. data/app/assets/javascripts/src/grid/header/DropZone.js +0 -265
  353. data/app/assets/javascripts/src/grid/plugin/CellEditing.js +0 -453
  354. data/app/assets/javascripts/src/grid/plugin/DragDrop.js +0 -254
  355. data/app/assets/javascripts/src/grid/plugin/Editing.js +0 -561
  356. data/app/assets/javascripts/src/grid/plugin/HeaderReorderer.js +0 -49
  357. data/app/assets/javascripts/src/grid/plugin/HeaderResizer.js +0 -292
  358. data/app/assets/javascripts/src/grid/plugin/RowEditing.js +0 -339
  359. data/app/assets/javascripts/src/grid/property/Grid.js +0 -351
  360. data/app/assets/javascripts/src/grid/property/HeaderContainer.js +0 -109
  361. data/app/assets/javascripts/src/grid/property/Property.js +0 -36
  362. data/app/assets/javascripts/src/grid/property/Store.js +0 -141
  363. data/app/assets/javascripts/src/layout/ClassList.js +0 -90
  364. data/app/assets/javascripts/src/layout/Context.js +0 -1232
  365. data/app/assets/javascripts/src/layout/ContextItem.js +0 -1470
  366. data/app/assets/javascripts/src/layout/Layout.js +0 -761
  367. data/app/assets/javascripts/src/layout/component/Auto.js +0 -220
  368. data/app/assets/javascripts/src/layout/component/Body.js +0 -80
  369. data/app/assets/javascripts/src/layout/component/BoundList.js +0 -95
  370. data/app/assets/javascripts/src/layout/component/Button.js +0 -261
  371. data/app/assets/javascripts/src/layout/component/Component.js +0 -427
  372. data/app/assets/javascripts/src/layout/component/Dock.js +0 -1132
  373. data/app/assets/javascripts/src/layout/component/Draw.js +0 -79
  374. data/app/assets/javascripts/src/layout/component/FieldSet.js +0 -62
  375. data/app/assets/javascripts/src/layout/component/ProgressBar.js +0 -54
  376. data/app/assets/javascripts/src/layout/component/Tab.js +0 -23
  377. data/app/assets/javascripts/src/layout/component/field/ComboBox.js +0 -52
  378. data/app/assets/javascripts/src/layout/component/field/Field.js +0 -372
  379. data/app/assets/javascripts/src/layout/component/field/FieldContainer.js +0 -48
  380. data/app/assets/javascripts/src/layout/component/field/HtmlEditor.js +0 -54
  381. data/app/assets/javascripts/src/layout/component/field/Slider.js +0 -58
  382. data/app/assets/javascripts/src/layout/component/field/Text.js +0 -75
  383. data/app/assets/javascripts/src/layout/component/field/TextArea.js +0 -51
  384. data/app/assets/javascripts/src/layout/component/field/Trigger.js +0 -132
  385. data/app/assets/javascripts/src/layout/container/Absolute.js +0 -121
  386. data/app/assets/javascripts/src/layout/container/Accordion.js +0 -308
  387. data/app/assets/javascripts/src/layout/container/Anchor.js +0 -403
  388. data/app/assets/javascripts/src/layout/container/Auto.js +0 -70
  389. data/app/assets/javascripts/src/layout/container/Border-old-js +0 -1079
  390. data/app/assets/javascripts/src/layout/container/Border.js +0 -816
  391. data/app/assets/javascripts/src/layout/container/Box.js +0 -929
  392. data/app/assets/javascripts/src/layout/container/Card.js +0 -361
  393. data/app/assets/javascripts/src/layout/container/CheckboxGroup.js +0 -376
  394. data/app/assets/javascripts/src/layout/container/Column.js +0 -234
  395. data/app/assets/javascripts/src/layout/container/Container.js +0 -961
  396. data/app/assets/javascripts/src/layout/container/Editor.js +0 -74
  397. data/app/assets/javascripts/src/layout/container/Fit.js +0 -287
  398. data/app/assets/javascripts/src/layout/container/Form.js +0 -157
  399. data/app/assets/javascripts/src/layout/container/HBox.js +0 -134
  400. data/app/assets/javascripts/src/layout/container/Table.js +0 -412
  401. data/app/assets/javascripts/src/layout/container/VBox.js +0 -139
  402. data/app/assets/javascripts/src/layout/container/boxOverflow/Menu.js +0 -365
  403. data/app/assets/javascripts/src/layout/container/boxOverflow/None.js +0 -83
  404. data/app/assets/javascripts/src/layout/container/boxOverflow/Scroller.js +0 -475
  405. data/app/assets/javascripts/src/menu/CheckItem.js +0 -169
  406. data/app/assets/javascripts/src/menu/ColorPicker.js +0 -110
  407. data/app/assets/javascripts/src/menu/DatePicker.js +0 -100
  408. data/app/assets/javascripts/src/menu/Item.js +0 -553
  409. data/app/assets/javascripts/src/menu/KeyNav.js +0 -134
  410. data/app/assets/javascripts/src/menu/Manager.js +0 -219
  411. data/app/assets/javascripts/src/menu/Menu.js +0 -579
  412. data/app/assets/javascripts/src/menu/Separator.js +0 -126
  413. data/app/assets/javascripts/src/panel/AbstractPanel.js +0 -323
  414. data/app/assets/javascripts/src/panel/DD.js +0 -99
  415. data/app/assets/javascripts/src/panel/Header.js +0 -518
  416. data/app/assets/javascripts/src/panel/Panel.js +0 -2150
  417. data/app/assets/javascripts/src/panel/Proxy.js +0 -131
  418. data/app/assets/javascripts/src/panel/Table.js +0 -1018
  419. data/app/assets/javascripts/src/panel/Tool.js +0 -304
  420. data/app/assets/javascripts/src/picker/Color.js +0 -219
  421. data/app/assets/javascripts/src/picker/Date.js +0 -1140
  422. data/app/assets/javascripts/src/picker/Month.js +0 -490
  423. data/app/assets/javascripts/src/picker/Time.js +0 -165
  424. data/app/assets/javascripts/src/resizer/BorderSplitter.js +0 -22
  425. data/app/assets/javascripts/src/resizer/BorderSplitterTracker.js +0 -210
  426. data/app/assets/javascripts/src/resizer/Handle.js +0 -29
  427. data/app/assets/javascripts/src/resizer/ResizeTracker.js +0 -346
  428. data/app/assets/javascripts/src/resizer/Resizer.js +0 -477
  429. data/app/assets/javascripts/src/resizer/Splitter.js +0 -242
  430. data/app/assets/javascripts/src/resizer/SplitterTracker.js +0 -230
  431. data/app/assets/javascripts/src/selection/CellModel.js +0 -395
  432. data/app/assets/javascripts/src/selection/CheckboxModel.js +0 -234
  433. data/app/assets/javascripts/src/selection/DataViewModel.js +0 -160
  434. data/app/assets/javascripts/src/selection/Model.js +0 -646
  435. data/app/assets/javascripts/src/selection/RowModel.js +0 -499
  436. data/app/assets/javascripts/src/selection/TreeModel.js +0 -78
  437. data/app/assets/javascripts/src/slider/Multi.js +0 -835
  438. data/app/assets/javascripts/src/slider/Single.js +0 -56
  439. data/app/assets/javascripts/src/slider/Thumb.js +0 -259
  440. data/app/assets/javascripts/src/slider/Tip.js +0 -130
  441. data/app/assets/javascripts/src/state/CookieProvider.js +0 -120
  442. data/app/assets/javascripts/src/state/LocalStorageProvider.js +0 -72
  443. data/app/assets/javascripts/src/state/Manager.js +0 -70
  444. data/app/assets/javascripts/src/state/Provider.js +0 -182
  445. data/app/assets/javascripts/src/state/Stateful.js +0 -364
  446. data/app/assets/javascripts/src/tab/Bar.js +0 -258
  447. data/app/assets/javascripts/src/tab/Panel.js +0 -654
  448. data/app/assets/javascripts/src/tab/Tab.js +0 -358
  449. data/app/assets/javascripts/src/tail.js +0 -10
  450. data/app/assets/javascripts/src/tip/QuickTip.js +0 -335
  451. data/app/assets/javascripts/src/tip/QuickTipManager.js +0 -239
  452. data/app/assets/javascripts/src/tip/Tip.js +0 -160
  453. data/app/assets/javascripts/src/tip/ToolTip.js +0 -691
  454. data/app/assets/javascripts/src/toolbar/Fill.js +0 -28
  455. data/app/assets/javascripts/src/toolbar/Item.js +0 -16
  456. data/app/assets/javascripts/src/toolbar/Paging.js +0 -600
  457. data/app/assets/javascripts/src/toolbar/Separator.js +0 -23
  458. data/app/assets/javascripts/src/toolbar/Spacer.js +0 -33
  459. data/app/assets/javascripts/src/toolbar/TextItem.js +0 -57
  460. data/app/assets/javascripts/src/toolbar/Toolbar-legacy.js +0 -123
  461. data/app/assets/javascripts/src/toolbar/Toolbar.js +0 -447
  462. data/app/assets/javascripts/src/tree/Column.js +0 -90
  463. data/app/assets/javascripts/src/tree/Panel.js +0 -505
  464. data/app/assets/javascripts/src/tree/View.js +0 -658
  465. data/app/assets/javascripts/src/tree/ViewDragZone.js +0 -49
  466. data/app/assets/javascripts/src/tree/ViewDropZone.js +0 -287
  467. data/app/assets/javascripts/src/tree/plugin/TreeViewDragDrop.js +0 -244
  468. data/app/assets/javascripts/src/util/AbstractMixedCollection.js +0 -772
  469. data/app/assets/javascripts/src/util/Animate.js +0 -426
  470. data/app/assets/javascripts/src/util/Bindable.js +0 -102
  471. data/app/assets/javascripts/src/util/CSS.js +0 -185
  472. data/app/assets/javascripts/src/util/ClickRepeater.js +0 -238
  473. data/app/assets/javascripts/src/util/ComponentDragger.js +0 -126
  474. data/app/assets/javascripts/src/util/Cookies.js +0 -91
  475. data/app/assets/javascripts/src/util/ElementContainer.js +0 -293
  476. data/app/assets/javascripts/src/util/Filter.js +0 -159
  477. data/app/assets/javascripts/src/util/Floating.js +0 -321
  478. data/app/assets/javascripts/src/util/Grouper.js +0 -26
  479. data/app/assets/javascripts/src/util/HashMap.js +0 -356
  480. data/app/assets/javascripts/src/util/History.js +0 -285
  481. data/app/assets/javascripts/src/util/Inflector.js +0 -297
  482. data/app/assets/javascripts/src/util/KeyMap.js +0 -427
  483. data/app/assets/javascripts/src/util/KeyNav.js +0 -239
  484. data/app/assets/javascripts/src/util/LruCache.js +0 -257
  485. data/app/assets/javascripts/src/util/Memento.js +0 -131
  486. data/app/assets/javascripts/src/util/MixedCollection.js +0 -239
  487. data/app/assets/javascripts/src/util/Observable.js +0 -1003
  488. data/app/assets/javascripts/src/util/Offset.js +0 -60
  489. data/app/assets/javascripts/src/util/Point.js +0 -93
  490. data/app/assets/javascripts/src/util/ProtoElement.js +0 -205
  491. data/app/assets/javascripts/src/util/Queue.js +0 -76
  492. data/app/assets/javascripts/src/util/Region.js +0 -388
  493. data/app/assets/javascripts/src/util/Renderable.js +0 -1079
  494. data/app/assets/javascripts/src/util/Sortable.js +0 -248
  495. data/app/assets/javascripts/src/util/Sorter.js +0 -179
  496. data/app/assets/javascripts/src/util/TextMetrics.js +0 -148
  497. data/app/assets/javascripts/src/view/AbstractView.js +0 -1103
  498. data/app/assets/javascripts/src/view/BoundList.js +0 -207
  499. data/app/assets/javascripts/src/view/BoundListKeyNav.js +0 -92
  500. data/app/assets/javascripts/src/view/DragZone.js +0 -106
  501. data/app/assets/javascripts/src/view/DropZone.js +0 -240
  502. data/app/assets/javascripts/src/view/Table.js +0 -1229
  503. data/app/assets/javascripts/src/view/TableChunker.js +0 -139
  504. data/app/assets/javascripts/src/view/View.js +0 -636
  505. data/app/assets/javascripts/src/window/MessageBox.js +0 -880
  506. data/app/assets/javascripts/src/window/Window-legacy.js +0 -56
  507. data/app/assets/javascripts/src/window/Window.js +0 -793
@@ -1,1283 +0,0 @@
1
- /**
2
- * @class Ext
3
- *
4
- * The Ext namespace (global object) encapsulates all classes, singletons, and
5
- * utility methods provided by Sencha's libraries.
6
- *
7
- * Most user interface Components are at a lower level of nesting in the namespace,
8
- * but many common utility functions are provided as direct properties of the Ext namespace.
9
- *
10
- * Also many frequently used methods from other classes are provided as shortcuts
11
- * within the Ext namespace. For example {@link Ext#getCmp Ext.getCmp} aliases
12
- * {@link Ext.ComponentManager#get Ext.ComponentManager.get}.
13
- *
14
- * Many applications are initiated with {@link Ext#onReady Ext.onReady} which is
15
- * called once the DOM is ready. This ensures all scripts have been loaded,
16
- * preventing dependency issues. For example:
17
- *
18
- * Ext.onReady(function(){
19
- * new Ext.Component({
20
- * renderTo: document.body,
21
- * html: 'DOM ready!'
22
- * });
23
- * });
24
- *
25
- * For more information about how to use the Ext classes, see:
26
- *
27
- * - <a href="http://www.sencha.com/learn/">The Learning Center</a>
28
- * - <a href="http://www.sencha.com/learn/Ext_FAQ">The FAQ</a>
29
- * - <a href="http://www.sencha.com/forum/">The forums</a>
30
- *
31
- * @singleton
32
- */
33
- Ext.apply(Ext, {
34
- userAgent: navigator.userAgent.toLowerCase(),
35
- cache: {},
36
- idSeed: 1000,
37
- windowId: 'ext-window',
38
- documentId: 'ext-document',
39
-
40
- /**
41
- * True when the document is fully initialized and ready for action
42
- */
43
- isReady: false,
44
-
45
- /**
46
- * True to automatically uncache orphaned Ext.Elements periodically
47
- */
48
- enableGarbageCollector: true,
49
-
50
- /**
51
- * True to automatically purge event listeners during garbageCollection.
52
- */
53
- enableListenerCollection: true,
54
-
55
- addCacheEntry: function(id, el, dom) {
56
- dom = dom || el.dom;
57
-
58
- //<debug>
59
- if (!dom) {
60
- // Without the DOM node we can't GC the entry
61
- Ext.Error.raise('Cannot add an entry to the element cache without the DOM node');
62
- }
63
- //</debug>
64
-
65
- var key = id || (el && el.id) || dom.id,
66
- entry = Ext.cache[key] || (Ext.cache[key] = {
67
- data: {},
68
- events: {},
69
-
70
- dom: dom,
71
-
72
- // Skip garbage collection for special elements (window, document, iframes)
73
- skipGarbageCollection: !!(dom.getElementById || dom.navigator)
74
- });
75
-
76
- if (el) {
77
- el.$cache = entry;
78
- // Inject the back link from the cache in case the cache entry
79
- // had already been created by Ext.fly. Ext.fly creates a cache entry with no el link.
80
- entry.el = el;
81
- }
82
-
83
- return entry;
84
- },
85
-
86
- /**
87
- * Generates unique ids. If the element already has an id, it is unchanged
88
- * @param {HTMLElement/Ext.Element} [el] The element to generate an id for
89
- * @param {String} prefix (optional) Id prefix (defaults "ext-gen")
90
- * @return {String} The generated Id.
91
- */
92
- id: function(el, prefix) {
93
- var me = this,
94
- sandboxPrefix = '';
95
- el = Ext.getDom(el, true) || {};
96
- if (el === document) {
97
- el.id = me.documentId;
98
- }
99
- else if (el === window) {
100
- el.id = me.windowId;
101
- }
102
- if (!el.id) {
103
- if (me.isSandboxed) {
104
- sandboxPrefix = Ext.sandboxName.toLowerCase() + '-';
105
- }
106
- el.id = sandboxPrefix + (prefix || "ext-gen") + (++Ext.idSeed);
107
- }
108
- return el.id;
109
- },
110
-
111
- escapeId: (function(){
112
- var validIdRe = /^[a-zA-Z_][a-zA-Z0-9_\-]*$/i,
113
- escapeRx = /([\W]{1})/g,
114
- leadingNumRx = /^(\d)/g,
115
- escapeFn = function(match, capture){
116
- return "\\" + capture;
117
- },
118
- numEscapeFn = function(match, capture){
119
- return '\\00' + capture.charCodeAt(0).toString(16) + ' ';
120
- };
121
-
122
- return function(id) {
123
- return validIdRe.test(id)
124
- ? id
125
- // replace the number portion last to keep the trailing ' '
126
- // from being escaped
127
- : id.replace(escapeRx, escapeFn)
128
- .replace(leadingNumRx, numEscapeFn);
129
- };
130
- }()),
131
-
132
- /**
133
- * Returns the current document body as an {@link Ext.Element}.
134
- * @return Ext.Element The document body
135
- */
136
- getBody: (function() {
137
- var body;
138
- return function() {
139
- return body || (body = Ext.get(document.body));
140
- };
141
- }()),
142
-
143
- /**
144
- * Returns the current document head as an {@link Ext.Element}.
145
- * @return Ext.Element The document head
146
- * @method
147
- */
148
- getHead: (function() {
149
- var head;
150
- return function() {
151
- return head || (head = Ext.get(document.getElementsByTagName("head")[0]));
152
- };
153
- }()),
154
-
155
- /**
156
- * Returns the current HTML document object as an {@link Ext.Element}.
157
- * @return Ext.Element The document
158
- */
159
- getDoc: (function() {
160
- var doc;
161
- return function() {
162
- return doc || (doc = Ext.get(document));
163
- };
164
- }()),
165
-
166
- /**
167
- * This is shorthand reference to {@link Ext.ComponentManager#get}.
168
- * Looks up an existing {@link Ext.Component Component} by {@link Ext.Component#id id}
169
- *
170
- * @param {String} id The component {@link Ext.Component#id id}
171
- * @return Ext.Component The Component, `undefined` if not found, or `null` if a
172
- * Class was found.
173
- */
174
- getCmp: function(id) {
175
- return Ext.ComponentManager.get(id);
176
- },
177
-
178
- /**
179
- * Returns the current orientation of the mobile device
180
- * @return {String} Either 'portrait' or 'landscape'
181
- */
182
- getOrientation: function() {
183
- return window.innerHeight > window.innerWidth ? 'portrait' : 'landscape';
184
- },
185
-
186
- /**
187
- * Attempts to destroy any objects passed to it by removing all event listeners, removing them from the
188
- * DOM (if applicable) and calling their destroy functions (if available). This method is primarily
189
- * intended for arguments of type {@link Ext.Element} and {@link Ext.Component}, but any subclass of
190
- * {@link Ext.util.Observable} can be passed in. Any number of elements and/or components can be
191
- * passed into this function in a single call as separate arguments.
192
- *
193
- * @param {Ext.Element/Ext.Component/Ext.Element[]/Ext.Component[]...} args
194
- * An {@link Ext.Element}, {@link Ext.Component}, or an Array of either of these to destroy
195
- */
196
- destroy: function() {
197
- var ln = arguments.length,
198
- i, arg;
199
-
200
- for (i = 0; i < ln; i++) {
201
- arg = arguments[i];
202
- if (arg) {
203
- if (Ext.isArray(arg)) {
204
- this.destroy.apply(this, arg);
205
- }
206
- else if (Ext.isFunction(arg.destroy)) {
207
- arg.destroy();
208
- }
209
- else if (arg.dom) {
210
- arg.remove();
211
- }
212
- }
213
- }
214
- },
215
-
216
- /**
217
- * Execute a callback function in a particular scope. If no function is passed the call is ignored.
218
- *
219
- * For example, these lines are equivalent:
220
- *
221
- * Ext.callback(myFunc, this, [arg1, arg2]);
222
- * Ext.isFunction(myFunc) && myFunc.apply(this, [arg1, arg2]);
223
- *
224
- * @param {Function} callback The callback to execute
225
- * @param {Object} [scope] The scope to execute in
226
- * @param {Array} [args] The arguments to pass to the function
227
- * @param {Number} [delay] Pass a number to delay the call by a number of milliseconds.
228
- */
229
- callback: function(callback, scope, args, delay){
230
- if(Ext.isFunction(callback)){
231
- args = args || [];
232
- scope = scope || window;
233
- if (delay) {
234
- Ext.defer(callback, delay, scope, args);
235
- } else {
236
- callback.apply(scope, args);
237
- }
238
- }
239
- },
240
-
241
- /**
242
- * Alias for {@link Ext.String#htmlEncode}.
243
- * @inheritdoc Ext.String#htmlEncode
244
- */
245
- htmlEncode : function(value) {
246
- return Ext.String.htmlEncode(value);
247
- },
248
-
249
- /**
250
- * Alias for {@link Ext.String#htmlDecode}.
251
- * @inheritdoc Ext.String#htmlDecode
252
- */
253
- htmlDecode : function(value) {
254
- return Ext.String.htmlDecode(value);
255
- },
256
-
257
- /**
258
- * Alias for {@link Ext.String#urlAppend}.
259
- * @inheritdoc Ext.String#urlAppend
260
- */
261
- urlAppend : function(url, s) {
262
- return Ext.String.urlAppend(url, s);
263
- }
264
- });
265
-
266
-
267
- Ext.ns = Ext.namespace;
268
-
269
- // for old browsers
270
- window.undefined = window.undefined;
271
-
272
- /**
273
- * @class Ext
274
- */
275
- (function(){
276
- /*
277
- FF 3.6 - Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.17) Gecko/20110420 Firefox/3.6.17
278
- FF 4.0.1 - Mozilla/5.0 (Windows NT 5.1; rv:2.0.1) Gecko/20100101 Firefox/4.0.1
279
- FF 5.0 - Mozilla/5.0 (Windows NT 6.1; WOW64; rv:5.0) Gecko/20100101 Firefox/5.0
280
-
281
- IE6 - Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1;)
282
- IE7 - Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; SV1;)
283
- IE8 - Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)
284
- IE9 - Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E)
285
-
286
- Chrome 11 - Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/534.24 (KHTML, like Gecko) Chrome/11.0.696.60 Safari/534.24
287
-
288
- Safari 5 - Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/533.21.1 (KHTML, like Gecko) Version/5.0.5 Safari/533.21.1
289
-
290
- Opera 11.11 - Opera/9.80 (Windows NT 6.1; U; en) Presto/2.8.131 Version/11.11
291
- */
292
- var check = function(regex){
293
- return regex.test(Ext.userAgent);
294
- },
295
- isStrict = document.compatMode == "CSS1Compat",
296
- version = function (is, regex) {
297
- var m;
298
- return (is && (m = regex.exec(Ext.userAgent))) ? parseFloat(m[1]) : 0;
299
- },
300
- docMode = document.documentMode,
301
- isOpera = check(/opera/),
302
- isOpera10_5 = isOpera && check(/version\/10\.5/),
303
- isChrome = check(/\bchrome\b/),
304
- isWebKit = check(/webkit/),
305
- isSafari = !isChrome && check(/safari/),
306
- isSafari2 = isSafari && check(/applewebkit\/4/), // unique to Safari 2
307
- isSafari3 = isSafari && check(/version\/3/),
308
- isSafari4 = isSafari && check(/version\/4/),
309
- isSafari5_0 = isSafari && check(/version\/5\.0/),
310
- isSafari5 = isSafari && check(/version\/5/),
311
- isIE = !isOpera && check(/msie/),
312
- isIE7 = isIE && ((check(/msie 7/) && docMode != 8 && docMode != 9) || docMode == 7),
313
- isIE8 = isIE && ((check(/msie 8/) && docMode != 7 && docMode != 9) || docMode == 8),
314
- isIE9 = isIE && ((check(/msie 9/) && docMode != 7 && docMode != 8) || docMode == 9),
315
- isIE6 = isIE && check(/msie 6/),
316
- isGecko = !isWebKit && check(/gecko/),
317
- isGecko3 = isGecko && check(/rv:1\.9/),
318
- isGecko4 = isGecko && check(/rv:2\.0/),
319
- isGecko5 = isGecko && check(/rv:5\./),
320
- isGecko10 = isGecko && check(/rv:10\./),
321
- isFF3_0 = isGecko3 && check(/rv:1\.9\.0/),
322
- isFF3_5 = isGecko3 && check(/rv:1\.9\.1/),
323
- isFF3_6 = isGecko3 && check(/rv:1\.9\.2/),
324
- isWindows = check(/windows|win32/),
325
- isMac = check(/macintosh|mac os x/),
326
- isLinux = check(/linux/),
327
- scrollbarSize = null,
328
- chromeVersion = version(true, /\bchrome\/(\d+\.\d+)/),
329
- firefoxVersion = version(true, /\bfirefox\/(\d+\.\d+)/),
330
- ieVersion = version(isIE, /msie (\d+\.\d+)/),
331
- operaVersion = version(isOpera, /version\/(\d+\.\d+)/),
332
- safariVersion = version(isSafari, /version\/(\d+\.\d+)/),
333
- webKitVersion = version(isWebKit, /webkit\/(\d+\.\d+)/),
334
- isSecure = /^https/i.test(window.location.protocol),
335
- nullLog;
336
-
337
- // remove css image flicker
338
- try {
339
- document.execCommand("BackgroundImageCache", false, true);
340
- } catch(e) {}
341
-
342
-
343
- //<debug>
344
- var primitiveRe = /string|number|boolean/;
345
- function dumpObject (object) {
346
- var member, type, value, name,
347
- members = [];
348
-
349
- // Cannot use Ext.encode since it can recurse endlessly (if we're lucky)
350
- // ...and the data could be prettier!
351
- for (name in object) {
352
- if (object.hasOwnProperty(name)) {
353
- value = object[name];
354
-
355
- type = typeof value;
356
- if (type == "function") {
357
- continue;
358
- }
359
-
360
- if (type == 'undefined') {
361
- member = type;
362
- } else if (value === null || primitiveRe.test(type) || Ext.isDate(value)) {
363
- member = Ext.encode(value);
364
- } else if (Ext.isArray(value)) {
365
- member = '[ ]';
366
- } else if (Ext.isObject(value)) {
367
- member = '{ }';
368
- } else {
369
- member = type;
370
- }
371
- members.push(Ext.encode(name) + ': ' + member);
372
- }
373
- }
374
-
375
- if (members.length) {
376
- return ' \nData: {\n ' + members.join(',\n ') + '\n}';
377
- }
378
- return '';
379
- }
380
-
381
- function log (message) {
382
- var options, dump,
383
- con = Ext.global.console,
384
- level = 'log',
385
- indent = log.indent || 0,
386
- stack,
387
- out,
388
- max;
389
-
390
- log.indent = indent;
391
-
392
- if (typeof message != 'string') {
393
- options = message;
394
- message = options.msg || '';
395
- level = options.level || level;
396
- dump = options.dump;
397
- stack = options.stack;
398
-
399
- if (options.indent) {
400
- ++log.indent;
401
- } else if (options.outdent) {
402
- log.indent = indent = Math.max(indent - 1, 0);
403
- }
404
-
405
- if (dump && !(con && con.dir)) {
406
- message += dumpObject(dump);
407
- dump = null;
408
- }
409
- }
410
-
411
- if (arguments.length > 1) {
412
- message += Array.prototype.slice.call(arguments, 1).join('');
413
- }
414
-
415
- message = indent ? Ext.String.repeat(' ', log.indentSize * indent) + message : message;
416
- // w/o console, all messages are equal, so munge the level into the message:
417
- if (level != 'log') {
418
- message = '[' + level.charAt(0).toUpperCase() + '] ' + message;
419
- }
420
-
421
- // Not obvious, but 'console' comes and goes when Firebug is turned on/off, so
422
- // an early test may fail either direction if Firebug is toggled.
423
- //
424
- if (con) { // if (Firebug-like console)
425
- if (con[level]) {
426
- con[level](message);
427
- } else {
428
- con.log(message);
429
- }
430
-
431
- if (dump) {
432
- con.dir(dump);
433
- }
434
-
435
- if (stack && con.trace) {
436
- // Firebug's console.error() includes a trace already...
437
- if (!con.firebug || level != 'error') {
438
- con.trace();
439
- }
440
- }
441
- } else {
442
- if (Ext.isOpera) {
443
- opera.postError(message);
444
- } else {
445
- out = log.out;
446
- max = log.max;
447
-
448
- if (out.length >= max) {
449
- // this formula allows out.max to change (via debugger), where the
450
- // more obvious "max/4" would not quite be the same
451
- Ext.Array.erase(out, 0, out.length - 3 * Math.floor(max / 4)); // keep newest 75%
452
- }
453
-
454
- out.push(message);
455
- }
456
- }
457
-
458
- // Mostly informational, but the Ext.Error notifier uses them:
459
- ++log.count;
460
- ++log.counters[level];
461
- }
462
-
463
- function logx (level, args) {
464
- if (typeof args[0] == 'string') {
465
- args.unshift({});
466
- }
467
- args[0].level = level;
468
- log.apply(this, args);
469
- }
470
-
471
- log.error = function () {
472
- logx('error', Array.prototype.slice.call(arguments));
473
- };
474
- log.info = function () {
475
- logx('info', Array.prototype.slice.call(arguments));
476
- };
477
- log.warn = function () {
478
- logx('warn', Array.prototype.slice.call(arguments));
479
- };
480
-
481
- log.count = 0;
482
- log.counters = { error: 0, warn: 0, info: 0, log: 0 };
483
- log.indentSize = 2;
484
- log.out = [];
485
- log.max = 750;
486
- log.show = function () {
487
- window.open('','extlog').document.write([
488
- '<html><head><script type="text/javascript">',
489
- 'var lastCount = 0;',
490
- 'function update () {',
491
- 'var ext = window.opener.Ext,',
492
- 'extlog = ext && ext.log;',
493
- 'if (extlog && extlog.out && lastCount != extlog.count) {',
494
- 'lastCount = extlog.count;',
495
- 'var s = "<tt>" + extlog.out.join("~~~").replace(/[&]/g, "&amp;").replace(/[<]/g, "&lt;").replace(/[ ]/g, "&#160;").replace(/\\~\\~\\~/g, "<br/>") + "</tt>";',
496
- 'document.body.innerHTML = s;',
497
- '}',
498
- 'setTimeout(update, 1000);',
499
- '}',
500
- 'setTimeout(update, 1000);',
501
- '</script></head><body></body></html>'].join(''));
502
- };
503
- //</debug>
504
-
505
- nullLog = function () {};
506
- nullLog.info = nullLog.warn = nullLog.error = Ext.emptyFn;
507
-
508
- Ext.setVersion('extjs', '4.1.0');
509
- Ext.apply(Ext, {
510
- /**
511
- * @property {String} SSL_SECURE_URL
512
- * URL to a blank file used by Ext when in secure mode for iframe src and onReady src
513
- * to prevent the IE insecure content warning (`'about:blank'`, except for IE
514
- * in secure mode, which is `'javascript:""'`).
515
- */
516
- SSL_SECURE_URL : isSecure && isIE ? 'javascript:\'\'' : 'about:blank',
517
-
518
- /**
519
- * @property {Boolean} enableFx
520
- * True if the {@link Ext.fx.Anim} Class is available.
521
- */
522
-
523
- /**
524
- * @property {Boolean} scopeResetCSS
525
- * True to scope the reset CSS to be just applied to Ext components. Note that this
526
- * wraps root containers with an additional element. Also remember that when you turn
527
- * on this option, you have to use ext-all-scoped (unless you use the bootstrap.js to
528
- * load your javascript, in which case it will be handled for you).
529
- */
530
- scopeResetCSS : Ext.buildSettings.scopeResetCSS,
531
-
532
- /**
533
- * @property {String} resetCls
534
- * The css class used to wrap Ext components when the {@link #scopeResetCSS} option
535
- * is used.
536
- */
537
- resetCls: Ext.buildSettings.baseCSSPrefix + 'reset',
538
-
539
- /**
540
- * @property {Boolean} enableNestedListenerRemoval
541
- * **Experimental.** True to cascade listener removal to child elements when an element
542
- * is removed. Currently not optimized for performance.
543
- */
544
- enableNestedListenerRemoval : false,
545
-
546
- /**
547
- * @property {Boolean} USE_NATIVE_JSON
548
- * Indicates whether to use native browser parsing for JSON methods.
549
- * This option is ignored if the browser does not support native JSON methods.
550
- *
551
- * **Note:** Native JSON methods will not work with objects that have functions.
552
- * Also, property names must be quoted, otherwise the data will not parse.
553
- */
554
- USE_NATIVE_JSON : false,
555
-
556
- /**
557
- * Returns the dom node for the passed String (id), dom node, or Ext.Element.
558
- * Optional 'strict' flag is needed for IE since it can return 'name' and
559
- * 'id' elements by using getElementById.
560
- *
561
- * Here are some examples:
562
- *
563
- * // gets dom node based on id
564
- * var elDom = Ext.getDom('elId');
565
- * // gets dom node based on the dom node
566
- * var elDom1 = Ext.getDom(elDom);
567
- *
568
- * // If we don&#39;t know if we are working with an
569
- * // Ext.Element or a dom node use Ext.getDom
570
- * function(el){
571
- * var dom = Ext.getDom(el);
572
- * // do something with the dom node
573
- * }
574
- *
575
- * **Note:** the dom node to be found actually needs to exist (be rendered, etc)
576
- * when this method is called to be successful.
577
- *
578
- * @param {String/HTMLElement/Ext.Element} el
579
- * @return HTMLElement
580
- */
581
- getDom : function(el, strict) {
582
- if (!el || !document) {
583
- return null;
584
- }
585
- if (el.dom) {
586
- return el.dom;
587
- } else {
588
- if (typeof el == 'string') {
589
- var e = Ext.getElementById(el);
590
- // IE returns elements with the 'name' and 'id' attribute.
591
- // we do a strict check to return the element with only the id attribute
592
- if (e && isIE && strict) {
593
- if (el == e.getAttribute('id')) {
594
- return e;
595
- } else {
596
- return null;
597
- }
598
- }
599
- return e;
600
- } else {
601
- return el;
602
- }
603
- }
604
- },
605
-
606
- /**
607
- * Removes a DOM node from the document.
608
- *
609
- * Removes this element from the document, removes all DOM event listeners, and
610
- * deletes the cache reference. All DOM event listeners are removed from this element.
611
- * If {@link Ext#enableNestedListenerRemoval Ext.enableNestedListenerRemoval} is
612
- * `true`, then DOM event listeners are also removed from all child nodes.
613
- * The body node will be ignored if passed in.
614
- *
615
- * @param {HTMLElement} node The node to remove
616
- * @method
617
- */
618
- removeNode : isIE6 || isIE7 || isIE8
619
- ? (function() {
620
- var d;
621
- return function(n){
622
- if(n && n.tagName.toUpperCase() != 'BODY'){
623
- (Ext.enableNestedListenerRemoval) ? Ext.EventManager.purgeElement(n) : Ext.EventManager.removeAll(n);
624
-
625
- var cache = Ext.cache,
626
- id = n.id;
627
-
628
- if (cache[id]) {
629
- delete cache[id].dom;
630
- delete cache[id];
631
- }
632
-
633
- // removing an iframe this way can cause severe leaks
634
- // fixes leak issue with htmleditor in themes example
635
- if (n.tagName.toUpperCase() != 'IFRAME') {
636
- if (isIE8 && n.parentNode) {
637
- n.parentNode.removeChild(n);
638
- }
639
- d = d || document.createElement('div');
640
- d.appendChild(n);
641
- d.innerHTML = '';
642
- }
643
- }
644
- };
645
- }())
646
- : function(n) {
647
- if (n && n.parentNode && n.tagName.toUpperCase() != 'BODY') {
648
- (Ext.enableNestedListenerRemoval) ? Ext.EventManager.purgeElement(n) : Ext.EventManager.removeAll(n);
649
-
650
- var cache = Ext.cache,
651
- id = n.id;
652
-
653
- if (cache[id]) {
654
- delete cache[id].dom;
655
- delete cache[id];
656
- }
657
-
658
- n.parentNode.removeChild(n);
659
- }
660
- },
661
-
662
- isStrict: isStrict,
663
-
664
- isIEQuirks: isIE && !isStrict,
665
-
666
- /**
667
- * True if the detected browser is Opera.
668
- * @type Boolean
669
- */
670
- isOpera : isOpera,
671
-
672
- /**
673
- * True if the detected browser is Opera 10.5x.
674
- * @type Boolean
675
- */
676
- isOpera10_5 : isOpera10_5,
677
-
678
- /**
679
- * True if the detected browser uses WebKit.
680
- * @type Boolean
681
- */
682
- isWebKit : isWebKit,
683
-
684
- /**
685
- * True if the detected browser is Chrome.
686
- * @type Boolean
687
- */
688
- isChrome : isChrome,
689
-
690
- /**
691
- * True if the detected browser is Safari.
692
- * @type Boolean
693
- */
694
- isSafari : isSafari,
695
-
696
- /**
697
- * True if the detected browser is Safari 3.x.
698
- * @type Boolean
699
- */
700
- isSafari3 : isSafari3,
701
-
702
- /**
703
- * True if the detected browser is Safari 4.x.
704
- * @type Boolean
705
- */
706
- isSafari4 : isSafari4,
707
-
708
- /**
709
- * True if the detected browser is Safari 5.x.
710
- * @type Boolean
711
- */
712
- isSafari5 : isSafari5,
713
-
714
- /**
715
- * True if the detected browser is Safari 5.0.x.
716
- * @type Boolean
717
- */
718
- isSafari5_0 : isSafari5_0,
719
-
720
-
721
- /**
722
- * True if the detected browser is Safari 2.x.
723
- * @type Boolean
724
- */
725
- isSafari2 : isSafari2,
726
-
727
- /**
728
- * True if the detected browser is Internet Explorer.
729
- * @type Boolean
730
- */
731
- isIE : isIE,
732
-
733
- /**
734
- * True if the detected browser is Internet Explorer 6.x.
735
- * @type Boolean
736
- */
737
- isIE6 : isIE6,
738
-
739
- /**
740
- * True if the detected browser is Internet Explorer 7.x.
741
- * @type Boolean
742
- */
743
- isIE7 : isIE7,
744
-
745
- /**
746
- * True if the detected browser is Internet Explorer 8.x.
747
- * @type Boolean
748
- */
749
- isIE8 : isIE8,
750
-
751
- /**
752
- * True if the detected browser is Internet Explorer 9.x.
753
- * @type Boolean
754
- */
755
- isIE9 : isIE9,
756
-
757
- /**
758
- * True if the detected browser uses the Gecko layout engine (e.g. Mozilla, Firefox).
759
- * @type Boolean
760
- */
761
- isGecko : isGecko,
762
-
763
- /**
764
- * True if the detected browser uses a Gecko 1.9+ layout engine (e.g. Firefox 3.x).
765
- * @type Boolean
766
- */
767
- isGecko3 : isGecko3,
768
-
769
- /**
770
- * True if the detected browser uses a Gecko 2.0+ layout engine (e.g. Firefox 4.x).
771
- * @type Boolean
772
- */
773
- isGecko4 : isGecko4,
774
-
775
- /**
776
- * True if the detected browser uses a Gecko 5.0+ layout engine (e.g. Firefox 5.x).
777
- * @type Boolean
778
- */
779
- isGecko5 : isGecko5,
780
-
781
- /**
782
- * True if the detected browser uses a Gecko 5.0+ layout engine (e.g. Firefox 5.x).
783
- * @type Boolean
784
- */
785
- isGecko10 : isGecko10,
786
-
787
- /**
788
- * True if the detected browser uses FireFox 3.0
789
- * @type Boolean
790
- */
791
- isFF3_0 : isFF3_0,
792
-
793
- /**
794
- * True if the detected browser uses FireFox 3.5
795
- * @type Boolean
796
- */
797
- isFF3_5 : isFF3_5,
798
-
799
- /**
800
- * True if the detected browser uses FireFox 3.6
801
- * @type Boolean
802
- */
803
- isFF3_6 : isFF3_6,
804
-
805
- /**
806
- * True if the detected browser uses FireFox 4
807
- * @type Boolean
808
- */
809
- isFF4 : 4 <= firefoxVersion && firefoxVersion < 5,
810
-
811
- /**
812
- * True if the detected browser uses FireFox 5
813
- * @type Boolean
814
- */
815
- isFF5 : 5 <= firefoxVersion && firefoxVersion < 6,
816
-
817
- /**
818
- * True if the detected browser uses FireFox 10
819
- * @type Boolean
820
- */
821
- isFF10 : 10 <= firefoxVersion && firefoxVersion < 11,
822
-
823
- /**
824
- * True if the detected platform is Linux.
825
- * @type Boolean
826
- */
827
- isLinux : isLinux,
828
-
829
- /**
830
- * True if the detected platform is Windows.
831
- * @type Boolean
832
- */
833
- isWindows : isWindows,
834
-
835
- /**
836
- * True if the detected platform is Mac OS.
837
- * @type Boolean
838
- */
839
- isMac : isMac,
840
-
841
- /**
842
- * The current version of Chrome (0 if the browser is not Chrome).
843
- * @type Number
844
- */
845
- chromeVersion: chromeVersion,
846
-
847
- /**
848
- * The current version of Firefox (0 if the browser is not Firefox).
849
- * @type Number
850
- */
851
- firefoxVersion: firefoxVersion,
852
-
853
- /**
854
- * The current version of IE (0 if the browser is not IE). This does not account
855
- * for the documentMode of the current page, which is factored into {@link #isIE7},
856
- * {@link #isIE8} and {@link #isIE9}. Thus this is not always true:
857
- *
858
- * Ext.isIE8 == (Ext.ieVersion == 8)
859
- *
860
- * @type Number
861
- */
862
- ieVersion: ieVersion,
863
-
864
- /**
865
- * The current version of Opera (0 if the browser is not Opera).
866
- * @type Number
867
- */
868
- operaVersion: operaVersion,
869
-
870
- /**
871
- * The current version of Safari (0 if the browser is not Safari).
872
- * @type Number
873
- */
874
- safariVersion: safariVersion,
875
-
876
- /**
877
- * The current version of WebKit (0 if the browser does not use WebKit).
878
- * @type Number
879
- */
880
- webKitVersion: webKitVersion,
881
-
882
- /**
883
- * True if the page is running over SSL
884
- * @type Boolean
885
- */
886
- isSecure: isSecure,
887
-
888
- /**
889
- * URL to a 1x1 transparent gif image used by Ext to create inline icons with
890
- * CSS background images. In older versions of IE, this defaults to
891
- * "http://sencha.com/s.gif" and you should change this to a URL on your server.
892
- * For other browsers it uses an inline data URL.
893
- * @type String
894
- */
895
- BLANK_IMAGE_URL : (isIE6 || isIE7) ? '/' + '/www.sencha.com/s.gif' : 'data:image/gif;base64,R0lGODlhAQABAID/AMDAwAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==',
896
-
897
- /**
898
- * Utility method for returning a default value if the passed value is empty.
899
- *
900
- * The value is deemed to be empty if it is:
901
- *
902
- * - null
903
- * - undefined
904
- * - an empty array
905
- * - a zero length string (Unless the `allowBlank` parameter is `true`)
906
- *
907
- * @param {Object} value The value to test
908
- * @param {Object} defaultValue The value to return if the original value is empty
909
- * @param {Boolean} [allowBlank=false] true to allow zero length strings to qualify as non-empty.
910
- * @return {Object} value, if non-empty, else defaultValue
911
- * @deprecated 4.0.0 Use {@link Ext#valueFrom} instead
912
- */
913
- value : function(v, defaultValue, allowBlank){
914
- return Ext.isEmpty(v, allowBlank) ? defaultValue : v;
915
- },
916
-
917
- /**
918
- * Escapes the passed string for use in a regular expression.
919
- * @param {String} str
920
- * @return {String}
921
- * @deprecated 4.0.0 Use {@link Ext.String#escapeRegex} instead
922
- */
923
- escapeRe : function(s) {
924
- return s.replace(/([-.*+?\^${}()|\[\]\/\\])/g, "\\$1");
925
- },
926
-
927
- /**
928
- * Applies event listeners to elements by selectors when the document is ready.
929
- * The event name is specified with an `@` suffix.
930
- *
931
- * Ext.addBehaviors({
932
- * // add a listener for click on all anchors in element with id foo
933
- * '#foo a@click' : function(e, t){
934
- * // do something
935
- * },
936
- *
937
- * // add the same listener to multiple selectors (separated by comma BEFORE the @)
938
- * '#foo a, #bar span.some-class@mouseover' : function(){
939
- * // do something
940
- * }
941
- * });
942
- *
943
- * @param {Object} obj The list of behaviors to apply
944
- */
945
- addBehaviors : function(o){
946
- if(!Ext.isReady){
947
- Ext.onReady(function(){
948
- Ext.addBehaviors(o);
949
- });
950
- } else {
951
- var cache = {}, // simple cache for applying multiple behaviors to same selector does query multiple times
952
- parts,
953
- b,
954
- s;
955
- for (b in o) {
956
- if ((parts = b.split('@'))[1]) { // for Object prototype breakers
957
- s = parts[0];
958
- if(!cache[s]){
959
- cache[s] = Ext.select(s);
960
- }
961
- cache[s].on(parts[1], o[b]);
962
- }
963
- }
964
- cache = null;
965
- }
966
- },
967
-
968
- /**
969
- * Returns the size of the browser scrollbars. This can differ depending on
970
- * operating system settings, such as the theme or font size.
971
- * @param {Boolean} [force] true to force a recalculation of the value.
972
- * @return {Object} An object containing scrollbar sizes.
973
- * @return.width {Number} The width of the vertical scrollbar.
974
- * @return.height {Number} The height of the horizontal scrollbar.
975
- */
976
- getScrollbarSize: function (force) {
977
- if (!Ext.isReady) {
978
- return {};
979
- }
980
-
981
- if (force || !scrollbarSize) {
982
- var db = document.body,
983
- div = document.createElement('div');
984
-
985
- div.style.width = div.style.height = '100px';
986
- div.style.overflow = 'scroll';
987
- div.style.position = 'absolute';
988
-
989
- db.appendChild(div); // now we can measure the div...
990
-
991
- // at least in iE9 the div is not 100px - the scrollbar size is removed!
992
- scrollbarSize = {
993
- width: div.offsetWidth - div.clientWidth,
994
- height: div.offsetHeight - div.clientHeight
995
- };
996
-
997
- db.removeChild(div);
998
- }
999
-
1000
- return scrollbarSize;
1001
- },
1002
-
1003
- /**
1004
- * Utility method for getting the width of the browser's vertical scrollbar. This
1005
- * can differ depending on operating system settings, such as the theme or font size.
1006
- *
1007
- * This method is deprected in favor of {@link #getScrollbarSize}.
1008
- *
1009
- * @param {Boolean} [force] true to force a recalculation of the value.
1010
- * @return {Number} The width of a vertical scrollbar.
1011
- * @deprecated
1012
- */
1013
- getScrollBarWidth: function(force){
1014
- var size = Ext.getScrollbarSize(force);
1015
- return size.width + 2; // legacy fudge factor
1016
- },
1017
-
1018
- /**
1019
- * Copies a set of named properties fom the source object to the destination object.
1020
- *
1021
- * Example:
1022
- *
1023
- * ImageComponent = Ext.extend(Ext.Component, {
1024
- * initComponent: function() {
1025
- * this.autoEl = { tag: 'img' };
1026
- * MyComponent.superclass.initComponent.apply(this, arguments);
1027
- * this.initialBox = Ext.copyTo({}, this.initialConfig, 'x,y,width,height');
1028
- * }
1029
- * });
1030
- *
1031
- * Important note: To borrow class prototype methods, use {@link Ext.Base#borrow} instead.
1032
- *
1033
- * @param {Object} dest The destination object.
1034
- * @param {Object} source The source object.
1035
- * @param {String/String[]} names Either an Array of property names, or a comma-delimited list
1036
- * of property names to copy.
1037
- * @param {Boolean} [usePrototypeKeys] Defaults to false. Pass true to copy keys off of the
1038
- * prototype as well as the instance.
1039
- * @return {Object} The modified object.
1040
- */
1041
- copyTo : function(dest, source, names, usePrototypeKeys){
1042
- if(typeof names == 'string'){
1043
- names = names.split(/[,;\s]/);
1044
- }
1045
-
1046
- var n,
1047
- nLen = names.length,
1048
- name;
1049
-
1050
- for(n = 0; n < nLen; n++) {
1051
- name = names[n];
1052
-
1053
- if(usePrototypeKeys || source.hasOwnProperty(name)){
1054
- dest[name] = source[name];
1055
- }
1056
- }
1057
-
1058
- return dest;
1059
- },
1060
-
1061
- /**
1062
- * Attempts to destroy and then remove a set of named properties of the passed object.
1063
- * @param {Object} o The object (most likely a Component) who's properties you wish to destroy.
1064
- * @param {String...} args One or more names of the properties to destroy and remove from the object.
1065
- */
1066
- destroyMembers : function(o){
1067
- for (var i = 1, a = arguments, len = a.length; i < len; i++) {
1068
- Ext.destroy(o[a[i]]);
1069
- delete o[a[i]];
1070
- }
1071
- },
1072
-
1073
- /**
1074
- * Logs a message. If a console is present it will be used. On Opera, the method
1075
- * "opera.postError" is called. In other cases, the message is logged to an array
1076
- * "Ext.log.out". An attached debugger can watch this array and view the log. The
1077
- * log buffer is limited to a maximum of "Ext.log.max" entries (defaults to 250).
1078
- * The `Ext.log.out` array can also be written to a popup window by entering the
1079
- * following in the URL bar (a "bookmarklet"):
1080
- *
1081
- * javascript:void(Ext.log.show());
1082
- *
1083
- * If additional parameters are passed, they are joined and appended to the message.
1084
- * A technique for tracing entry and exit of a function is this:
1085
- *
1086
- * function foo () {
1087
- * Ext.log({ indent: 1 }, '>> foo');
1088
- *
1089
- * // log statements in here or methods called from here will be indented
1090
- * // by one step
1091
- *
1092
- * Ext.log({ outdent: 1 }, '<< foo');
1093
- * }
1094
- *
1095
- * This method does nothing in a release build.
1096
- *
1097
- * @param {String/Object} message The message to log or an options object with any
1098
- * of the following properties:
1099
- *
1100
- * - `msg`: The message to log (required).
1101
- * - `level`: One of: "error", "warn", "info" or "log" (the default is "log").
1102
- * - `dump`: An object to dump to the log as part of the message.
1103
- * - `stack`: True to include a stack trace in the log.
1104
- * - `indent`: Cause subsequent log statements to be indented one step.
1105
- * - `outdent`: Cause this and following statements to be one step less indented.
1106
- *
1107
- * @method
1108
- */
1109
- log :
1110
- //<debug>
1111
- log ||
1112
- //</debug>
1113
- nullLog,
1114
-
1115
- /**
1116
- * Partitions the set into two sets: a true set and a false set.
1117
- *
1118
- * Example 1:
1119
- *
1120
- * Ext.partition([true, false, true, true, false]);
1121
- * // returns [[true, true, true], [false, false]]
1122
- *
1123
- * Example 2:
1124
- *
1125
- * Ext.partition(
1126
- * Ext.query("p"),
1127
- * function(val){
1128
- * return val.className == "class1"
1129
- * }
1130
- * );
1131
- * // true are those paragraph elements with a className of "class1",
1132
- * // false set are those that do not have that className.
1133
- *
1134
- * @param {Array/NodeList} arr The array to partition
1135
- * @param {Function} truth (optional) a function to determine truth.
1136
- * If this is omitted the element itself must be able to be evaluated for its truthfulness.
1137
- * @return {Array} [array of truish values, array of falsy values]
1138
- * @deprecated 4.0.0 Will be removed in the next major version
1139
- */
1140
- partition : function(arr, truth){
1141
- var ret = [[],[]],
1142
- a, v,
1143
- aLen = arr.length;
1144
-
1145
- for (a = 0; a < aLen; a++) {
1146
- v = arr[a];
1147
- ret[ (truth && truth(v, a, arr)) || (!truth && v) ? 0 : 1].push(v);
1148
- }
1149
-
1150
- return ret;
1151
- },
1152
-
1153
- /**
1154
- * Invokes a method on each item in an Array.
1155
- *
1156
- * Example:
1157
- *
1158
- * Ext.invoke(Ext.query("p"), "getAttribute", "id");
1159
- * // [el1.getAttribute("id"), el2.getAttribute("id"), ..., elN.getAttribute("id")]
1160
- *
1161
- * @param {Array/NodeList} arr The Array of items to invoke the method on.
1162
- * @param {String} methodName The method name to invoke.
1163
- * @param {Object...} args Arguments to send into the method invocation.
1164
- * @return {Array} The results of invoking the method on each item in the array.
1165
- * @deprecated 4.0.0 Will be removed in the next major version
1166
- */
1167
- invoke : function(arr, methodName){
1168
- var ret = [],
1169
- args = Array.prototype.slice.call(arguments, 2),
1170
- a, v,
1171
- aLen = arr.length;
1172
-
1173
- for (a = 0; a < aLen; a++) {
1174
- v = arr[a];
1175
-
1176
- if (v && typeof v[methodName] == 'function') {
1177
- ret.push(v[methodName].apply(v, args));
1178
- } else {
1179
- ret.push(undefined);
1180
- }
1181
- }
1182
-
1183
- return ret;
1184
- },
1185
-
1186
- /**
1187
- * Zips N sets together.
1188
- *
1189
- * Example 1:
1190
- *
1191
- * Ext.zip([1,2,3],[4,5,6]); // [[1,4],[2,5],[3,6]]
1192
- *
1193
- * Example 2:
1194
- *
1195
- * Ext.zip(
1196
- * [ "+", "-", "+"],
1197
- * [ 12, 10, 22],
1198
- * [ 43, 15, 96],
1199
- * function(a, b, c){
1200
- * return "$" + a + "" + b + "." + c
1201
- * }
1202
- * ); // ["$+12.43", "$-10.15", "$+22.96"]
1203
- *
1204
- * @param {Array/NodeList...} arr This argument may be repeated. Array(s)
1205
- * to contribute values.
1206
- * @param {Function} zipper (optional) The last item in the argument list.
1207
- * This will drive how the items are zipped together.
1208
- * @return {Array} The zipped set.
1209
- * @deprecated 4.0.0 Will be removed in the next major version
1210
- */
1211
- zip : function(){
1212
- var parts = Ext.partition(arguments, function( val ){ return typeof val != 'function'; }),
1213
- arrs = parts[0],
1214
- fn = parts[1][0],
1215
- len = Ext.max(Ext.pluck(arrs, "length")),
1216
- ret = [],
1217
- i,
1218
- j,
1219
- aLen;
1220
-
1221
- for (i = 0; i < len; i++) {
1222
- ret[i] = [];
1223
- if(fn){
1224
- ret[i] = fn.apply(fn, Ext.pluck(arrs, i));
1225
- }else{
1226
- for (j = 0, aLen = arrs.length; j < aLen; j++){
1227
- ret[i].push( arrs[j][i] );
1228
- }
1229
- }
1230
- }
1231
- return ret;
1232
- },
1233
-
1234
- /**
1235
- * Turns an array into a sentence, joined by a specified connector - e.g.:
1236
- *
1237
- * Ext.toSentence(['Adama', 'Tigh', 'Roslin']); //'Adama, Tigh and Roslin'
1238
- * Ext.toSentence(['Adama', 'Tigh', 'Roslin'], 'or'); //'Adama, Tigh or Roslin'
1239
- *
1240
- * @param {String[]} items The array to create a sentence from
1241
- * @param {String} connector The string to use to connect the last two words.
1242
- * Usually 'and' or 'or' - defaults to 'and'.
1243
- * @return {String} The sentence string
1244
- * @deprecated 4.0.0 Will be removed in the next major version
1245
- */
1246
- toSentence: function(items, connector) {
1247
- var length = items.length,
1248
- head,
1249
- tail;
1250
-
1251
- if (length <= 1) {
1252
- return items[0];
1253
- } else {
1254
- head = items.slice(0, length - 1);
1255
- tail = items[length - 1];
1256
-
1257
- return Ext.util.Format.format("{0} {1} {2}", head.join(", "), connector || 'and', tail);
1258
- }
1259
- },
1260
-
1261
- /**
1262
- * @property {Boolean} useShims
1263
- * By default, Ext intelligently decides whether floating elements should be shimmed.
1264
- * If you are using flash, you may want to set this to true.
1265
- */
1266
- useShims: isIE6
1267
- });
1268
- }());
1269
-
1270
- /**
1271
- * Loads Ext.app.Application class and starts it up with given configuration after the page is ready.
1272
- *
1273
- * See Ext.app.Application for details.
1274
- *
1275
- * @param {Object} config
1276
- */
1277
- Ext.application = function(config) {
1278
- Ext.require('Ext.app.Application');
1279
-
1280
- Ext.onReady(function() {
1281
- new Ext.app.Application(config);
1282
- });
1283
- };