spiderfw 0.5.19 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (255) hide show
  1. data/CHANGELOG +7 -0
  2. data/VERSION +1 -1
  3. data/apps/core/auth/lib/rbac.rb +7 -2
  4. data/apps/core/auth/models/mixins/rbac_provider.rb +66 -4
  5. data/apps/core/components/assets.rb +63 -33
  6. data/apps/core/components/public/js/jquery/{jquery-1.4.3.js → jquery-1.5.2.js} +2617 -1126
  7. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/overlay/overlay.apple.js +155 -0
  8. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/overlay/overlay.js +293 -0
  9. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/scrollable/scrollable.js +335 -0
  10. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/tabs/tabs.css +59 -0
  11. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/tabs/tabs.js +283 -0
  12. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/toolbox/toolbox.expose.js +224 -0
  13. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/tooltip/tooltip.dynamic.js +150 -0
  14. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/tooltip/tooltip.js +343 -0
  15. data/apps/core/components/public/js/jquery/jquery-tools-1.2.5/tooltip/tooltip.slide.js +78 -0
  16. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/button_bg.png +0 -0
  17. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/datepicker.gif +0 -0
  18. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/icon_sprite.png +0 -0
  19. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/progress_bar.gif +0 -0
  20. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/slider_h_bg.gif +0 -0
  21. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/slider_handles.png +0 -0
  22. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/slider_v_bg.gif +0 -0
  23. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/tab_bg.gif +0 -0
  24. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/the_gradient.gif +0 -0
  25. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-anim_basic_16x16.gif +0 -0
  26. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_diagonals-thick_18_b81900_40x40.png +0 -0
  27. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_diagonals-thick_20_666666_40x40.png +0 -0
  28. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_flat_10_000000_40x100.png +0 -0
  29. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_glass_100_f6f6f6_1x400.png +0 -0
  30. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_glass_100_fdf5ce_1x400.png +0 -0
  31. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  32. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_gloss-wave_35_f6a828_500x100.png +0 -0
  33. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_highlight-soft_100_eeeeee_1x100.png +0 -0
  34. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-bg_highlight-soft_75_ffe45c_1x100.png +0 -0
  35. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-icons_222222_256x240.png +0 -0
  36. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-icons_228ef1_256x240.png +0 -0
  37. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-icons_ef8c08_256x240.png +0 -0
  38. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-icons_ffd27a_256x240.png +0 -0
  39. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/images/ui-icons_ffffff_256x240.png +0 -0
  40. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4 → jquery-ui-1.8.11}/css/Aristo/jquery-ui.custom.css +0 -0
  41. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-af.js +0 -0
  42. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-ar-DZ.js +23 -0
  43. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-ar.js +7 -8
  44. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-az.js +0 -0
  45. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-bg.js +0 -0
  46. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-bs.js +0 -0
  47. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-ca.js +0 -0
  48. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-cs.js +0 -0
  49. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-da.js +0 -0
  50. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-de.js +0 -0
  51. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-el.js +0 -0
  52. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-en-AU.js +23 -0
  53. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-en-GB.js +0 -0
  54. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-en-NZ.js +23 -0
  55. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-eo.js +0 -0
  56. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-es.js +0 -0
  57. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-et.js +0 -0
  58. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-eu.js +0 -0
  59. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-fa.js +0 -0
  60. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-fi.js +0 -0
  61. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-fo.js +0 -0
  62. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-fr-CH.js +0 -0
  63. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-fr.js +12 -10
  64. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-gl.js +23 -0
  65. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-he.js +0 -0
  66. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-hr.js +0 -0
  67. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-hu.js +1 -1
  68. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-hy.js +0 -0
  69. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-id.js +0 -0
  70. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-is.js +0 -0
  71. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-it.js +0 -0
  72. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-ja.js +0 -0
  73. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-ko.js +0 -0
  74. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-kz.js +23 -0
  75. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-lt.js +0 -0
  76. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-lv.js +0 -0
  77. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-ml.js +23 -0
  78. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-ms.js +0 -0
  79. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-nl.js +0 -0
  80. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-no.js +23 -0
  81. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-pl.js +0 -0
  82. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-pt-BR.js +0 -0
  83. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-pt.js +22 -0
  84. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-rm.js +21 -0
  85. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-ro.js +0 -0
  86. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-ru.js +1 -1
  87. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-sk.js +0 -0
  88. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-sl.js +0 -0
  89. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-sq.js +0 -0
  90. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-sr-SR.js +0 -0
  91. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-sr.js +0 -0
  92. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-sv.js +0 -0
  93. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-ta.js +0 -0
  94. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-th.js +1 -1
  95. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/i18n/jquery.ui.datepicker-tj.js +23 -0
  96. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-tr.js +0 -0
  97. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-uk.js +0 -0
  98. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-vi.js +0 -0
  99. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-zh-CN.js +0 -0
  100. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-zh-HK.js +0 -0
  101. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/i18n/jquery.ui.datepicker-zh-TW.js +0 -0
  102. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.blind.js +3 -3
  103. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.bounce.js +3 -3
  104. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.clip.js +3 -3
  105. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.core.js +48 -15
  106. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.drop.js +3 -3
  107. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.explode.js +2 -2
  108. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/jquery.effects.fade.js +32 -0
  109. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.fold.js +3 -3
  110. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.highlight.js +2 -2
  111. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.pulsate.js +2 -2
  112. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.scale.js +4 -4
  113. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.shake.js +3 -3
  114. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.slide.js +4 -4
  115. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.effects.transfer.js +2 -2
  116. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.accordion.js +33 -20
  117. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.autocomplete.js +104 -42
  118. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.button.js +35 -13
  119. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.core.js +111 -84
  120. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.datepicker.js +87 -46
  121. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.dialog.js +105 -75
  122. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.draggable.js +17 -15
  123. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.droppable.js +5 -5
  124. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.mouse.js +16 -11
  125. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.position.js +51 -32
  126. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.progressbar.js +24 -10
  127. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.resizable.js +7 -7
  128. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.selectable.js +3 -3
  129. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.slider.js +9 -7
  130. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.sortable.js +22 -20
  131. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.tabs.js +15 -14
  132. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → jquery-ui-1.8.11}/ui/jquery.ui.widget.js +50 -25
  133. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → plugins/bsmselect}/GPL-LICENSE.txt +1 -1
  134. data/apps/core/components/public/js/jquery/{jquery-ui-1.8.4/development-bundle → plugins/bsmselect}/MIT-LICENSE.txt +3 -7
  135. data/apps/core/components/public/js/jquery/plugins/bsmselect/README.md +185 -0
  136. data/apps/core/components/public/js/jquery/plugins/bsmselect/css/jquery.bsmselect.css +64 -0
  137. data/apps/core/components/public/js/jquery/plugins/bsmselect/js/jquery.bsmselect.compatibility.js +60 -0
  138. data/apps/core/components/public/js/jquery/plugins/bsmselect/js/jquery.bsmselect.js +381 -0
  139. data/apps/core/components/public/js/jquery/plugins/bsmselect/js/jquery.bsmselect.sortable.js +49 -0
  140. data/apps/core/components/public/js/plugins/sortable.js +16 -7
  141. data/apps/core/components/public/js/spider.js +60 -41
  142. data/apps/core/components/widgets/admin/admin.shtml +1 -1
  143. data/apps/core/components/widgets/list/list.shtml +2 -2
  144. data/apps/core/components/widgets/month_calendar/month_calendar.shtml +23 -20
  145. data/apps/core/components/widgets/switcher/switcher.rb +77 -21
  146. data/apps/core/components/widgets/switcher/templates/default.shtml +8 -0
  147. data/apps/core/components/widgets/switcher/templates/table.shtml +15 -0
  148. data/apps/core/components/widgets/table/table.rb +4 -1
  149. data/apps/core/components/widgets/table/table.shtml +10 -8
  150. data/apps/core/forms/public/css/form.css +9 -1
  151. data/apps/core/forms/public/date_time.js +14 -2
  152. data/apps/core/forms/public/input.js +1 -1
  153. data/apps/core/forms/public/select.js +4 -3
  154. data/apps/core/forms/tags/element_row.erb +11 -2
  155. data/apps/core/forms/widgets/inputs/date_time/date_time.rb +9 -0
  156. data/apps/core/forms/widgets/inputs/date_time/date_time.shtml +1 -1
  157. data/apps/core/forms/widgets/inputs/html_area/html_area.shtml +2 -2
  158. data/apps/core/forms/widgets/inputs/input/input.rb +0 -3
  159. data/apps/core/forms/widgets/inputs/select/select.shtml +2 -2
  160. data/apps/messenger/backends/email/sendmail.rb +20 -0
  161. data/apps/messenger/backends/email/smtp.rb +12 -14
  162. data/apps/messenger/backends/email/test.rb +20 -0
  163. data/apps/messenger/config/options.rb +9 -9
  164. data/apps/messenger/config/test.config.yml +2 -0
  165. data/apps/messenger/controllers/mixins/messenger_helper.rb +41 -15
  166. data/apps/messenger/lib/email_backend.rb +10 -0
  167. data/apps/messenger/messenger.rb +45 -26
  168. data/apps/messenger/test/features/attachments.feature +26 -0
  169. data/apps/messenger/test/features/messenger_helper.feature +31 -0
  170. data/apps/messenger/test/features/sending_email.feature +10 -0
  171. data/apps/messenger/test/features/step_definitions/common_steps.rb +11 -0
  172. data/apps/messenger/test/features/step_definitions/email_steps.rb +98 -0
  173. data/apps/messenger/test/features/support/env.rb +11 -0
  174. data/apps/messenger/test/files/test_file1.txt +1 -0
  175. data/apps/messenger/test/lib/controllers/mail_test_controller.rb +34 -0
  176. data/apps/messenger/test/templates/email/multipart.html.erb +1 -0
  177. data/apps/messenger/test/templates/email/multipart.txt.erb +1 -0
  178. data/apps/messenger/test/templates/email/simple.erb +1 -0
  179. data/apps/messenger/test/templates/email/vars.erb +1 -0
  180. data/lib/spiderfw/cmd/cmd.rb +4 -0
  181. data/lib/spiderfw/cmd/commands/webserver.rb +12 -59
  182. data/lib/spiderfw/config/configuration.rb +4 -0
  183. data/lib/spiderfw/config/options/spider.rb +25 -8
  184. data/lib/spiderfw/controller/controller.rb +10 -4
  185. data/lib/spiderfw/controller/first_responder.rb +6 -20
  186. data/lib/spiderfw/controller/http_controller.rb +2 -1
  187. data/lib/spiderfw/controller/mixins/http_mixin.rb +12 -1
  188. data/lib/spiderfw/controller/mixins/visual.rb +3 -16
  189. data/lib/spiderfw/env.rb +1 -1
  190. data/lib/spiderfw/http/server.rb +178 -2
  191. data/lib/spiderfw/model/base_model.rb +142 -111
  192. data/lib/spiderfw/model/data_type.rb +15 -0
  193. data/lib/spiderfw/model/datatypes/decimal.rb +8 -0
  194. data/lib/spiderfw/model/datatypes/pk.rb +29 -0
  195. data/lib/spiderfw/model/datatypes.rb +1 -0
  196. data/lib/spiderfw/model/element.rb +5 -1
  197. data/lib/spiderfw/model/extended_models/managed.rb +1 -1
  198. data/lib/spiderfw/model/junction.rb +23 -0
  199. data/lib/spiderfw/model/mappers/db_mapper.rb +96 -80
  200. data/lib/spiderfw/model/mappers/document_mapper.rb +315 -0
  201. data/lib/spiderfw/model/mappers/mapper.rb +164 -75
  202. data/lib/spiderfw/model/mixins/list.rb +1 -0
  203. data/lib/spiderfw/model/mixins/versioned.rb +63 -27
  204. data/lib/spiderfw/model/model.rb +36 -9
  205. data/lib/spiderfw/model/query_funcs.rb +3 -0
  206. data/lib/spiderfw/model/query_set.rb +21 -1
  207. data/lib/spiderfw/model/storage/base_storage.rb +259 -6
  208. data/lib/spiderfw/model/storage/{db/db_connection_pool.rb → connection_pool.rb} +25 -21
  209. data/lib/spiderfw/model/storage/db/adapters/mysql.rb +25 -5
  210. data/lib/spiderfw/model/storage/db/adapters/oracle.rb +1 -1
  211. data/lib/spiderfw/model/storage/db/connectors/jdbc_oracle.rb +2 -2
  212. data/lib/spiderfw/model/storage/db/connectors/oci8.rb +3 -4
  213. data/lib/spiderfw/model/storage/db/db_storage.rb +18 -219
  214. data/lib/spiderfw/model/storage/document/adapters/mongodb.rb +307 -0
  215. data/lib/spiderfw/model/storage/document/document.rb +7 -0
  216. data/lib/spiderfw/model/storage/document/document_storage.rb +34 -0
  217. data/lib/spiderfw/model/storage.rb +23 -11
  218. data/lib/spiderfw/model/unit_of_work.rb +45 -22
  219. data/lib/spiderfw/spider.rb +660 -0
  220. data/lib/spiderfw/templates/blocks/html.rb +4 -2
  221. data/lib/spiderfw/templates/blocks/run.rb +1 -1
  222. data/lib/spiderfw/templates/blocks/tag_if.rb +1 -1
  223. data/lib/spiderfw/templates/blocks/widget.rb +1 -1
  224. data/lib/spiderfw/templates/layout.rb +29 -5
  225. data/lib/spiderfw/templates/template.rb +72 -7
  226. data/lib/spiderfw/templates/template_blocks.rb +1 -1
  227. data/lib/spiderfw/test/capybara.rb +7 -0
  228. data/lib/spiderfw/test/cucumber.rb +12 -0
  229. data/lib/spiderfw/test/page_object.rb +29 -0
  230. data/lib/spiderfw/test/spec.rb +20 -0
  231. data/lib/spiderfw/test/stubs/mapper_stub.rb +18 -0
  232. data/lib/spiderfw/test/stubs/storage_stub.rb +23 -0
  233. data/lib/spiderfw/test/unit.rb +23 -0
  234. data/lib/spiderfw/test.rb +89 -0
  235. data/lib/spiderfw/utils/json.rb +6 -0
  236. data/lib/spiderfw/utils/logger.rb +17 -4
  237. data/lib/spiderfw/utils/loggers/apache_commons_logger.rb +61 -0
  238. data/lib/spiderfw/utils/monkey/date_time.rb +2 -2
  239. data/lib/spiderfw/utils/monkey/module.rb +3 -1
  240. data/lib/spiderfw/utils/profiling.rb +2 -2
  241. data/lib/spiderfw/widget/widget.rb +31 -13
  242. data/lib/spiderfw.rb +1 -597
  243. data/spider.gemspec +9 -10
  244. metadata +193 -132
  245. data/apps/admin/_init.rb +0 -9
  246. data/apps/admin/controllers/admin_controller.rb +0 -12
  247. data/apps/admin/widgets/dashboard_widget/dashboard_widget.rb +0 -8
  248. data/apps/core/components/public/js/jquery/jquery-ui-1.8.4/development-bundle/AUTHORS.txt +0 -30
  249. data/apps/core/components/public/js/jquery/jquery-ui-1.8.4/development-bundle/ui/i18n/jquery-ui-i18n.js +0 -1176
  250. data/apps/core/components/public/js/jquery/jquery-ui-1.8.4/development-bundle/ui/i18n/jquery.ui.datepicker-no.js +0 -23
  251. data/apps/core/components/public/js/jquery/jquery-ui-1.8.4/development-bundle/version.txt +0 -1
  252. data/apps/core/components/public/js/jquery/plugins/asmselect/jquery.asmselect.css +0 -64
  253. data/apps/core/components/public/js/jquery/plugins/asmselect/jquery.asmselect.js +0 -407
  254. data/apps/core/components/widgets/switcher/switcher.shtml +0 -17
  255. data/apps/master/po/master.pot +0 -400
@@ -1,7 +1,7 @@
1
1
  /*
2
- * jQuery UI Autocomplete 1.8.4
2
+ * jQuery UI Autocomplete @VERSION
3
3
  *
4
- * Copyright 2010, AUTHORS.txt (http://jqueryui.com/about)
4
+ * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
5
5
  * Dual licensed under the MIT or GPL Version 2 licenses.
6
6
  * http://jquery.org/license
7
7
  *
@@ -14,9 +14,13 @@
14
14
  */
15
15
  (function( $, undefined ) {
16
16
 
17
+ // used to prevent race conditions with remote data sources
18
+ var requestIndex = 0;
19
+
17
20
  $.widget( "ui.autocomplete", {
18
21
  options: {
19
22
  appendTo: "body",
23
+ autoFocus: false,
20
24
  delay: 300,
21
25
  minLength: 1,
22
26
  position: {
@@ -26,9 +30,14 @@ $.widget( "ui.autocomplete", {
26
30
  },
27
31
  source: null
28
32
  },
33
+
34
+ pending: 0,
35
+
29
36
  _create: function() {
30
37
  var self = this,
31
- doc = this.element[ 0 ].ownerDocument;
38
+ doc = this.element[ 0 ].ownerDocument,
39
+ suppressKeyPress;
40
+
32
41
  this.element
33
42
  .addClass( "ui-autocomplete-input" )
34
43
  .attr( "autocomplete", "off" )
@@ -39,10 +48,11 @@ $.widget( "ui.autocomplete", {
39
48
  "aria-haspopup": "true"
40
49
  })
41
50
  .bind( "keydown.autocomplete", function( event ) {
42
- if ( self.options.disabled ) {
51
+ if ( self.options.disabled || self.element.attr( "readonly" ) ) {
43
52
  return;
44
53
  }
45
54
 
55
+ suppressKeyPress = false;
46
56
  var keyCode = $.ui.keyCode;
47
57
  switch( event.keyCode ) {
48
58
  case keyCode.PAGE_UP:
@@ -63,20 +73,17 @@ $.widget( "ui.autocomplete", {
63
73
  break;
64
74
  case keyCode.ENTER:
65
75
  case keyCode.NUMPAD_ENTER:
66
- // when menu is open or has focus
67
- if ( self.menu.element.is( ":visible" ) ) {
76
+ // when menu is open and has focus
77
+ if ( self.menu.active ) {
78
+ // #6055 - Opera still allows the keypress to occur
79
+ // which causes forms to submit
80
+ suppressKeyPress = true;
68
81
  event.preventDefault();
69
82
  }
70
83
  //passthrough - ENTER and TAB both select the current element
71
84
  case keyCode.TAB:
72
85
  if ( !self.menu.active ) {
73
- if (!self.menu.element.is( ":visible" )) return;
74
- var firstItem = self.menu.element.children().eq(0);
75
- if (firstItem){
76
- self.menu.activate(event, firstItem);
77
- return false;
78
- }
79
- else return;
86
+ return;
80
87
  }
81
88
  self.menu.select( event );
82
89
  break;
@@ -97,6 +104,12 @@ $.widget( "ui.autocomplete", {
97
104
  break;
98
105
  }
99
106
  })
107
+ .bind( "keypress.autocomplete", function( event ) {
108
+ if ( suppressKeyPress ) {
109
+ suppressKeyPress = false;
110
+ event.preventDefault();
111
+ }
112
+ })
100
113
  .bind( "focus.autocomplete", function() {
101
114
  if ( self.options.disabled ) {
102
115
  return;
@@ -131,7 +144,7 @@ $.widget( "ui.autocomplete", {
131
144
  // so we have to track the next mousedown and close the menu if
132
145
  // the user clicks somewhere outside of the autocomplete
133
146
  var menuElement = self.menu.element[ 0 ];
134
- if ( event.target === menuElement ) {
147
+ if ( !$( event.target ).closest( ".ui-menu-item" ).length ) {
135
148
  setTimeout(function() {
136
149
  $( document ).one( 'mousedown', function( event ) {
137
150
  if ( event.target !== self.element[ 0 ] &&
@@ -151,7 +164,7 @@ $.widget( "ui.autocomplete", {
151
164
  .menu({
152
165
  focus: function( event, ui ) {
153
166
  var item = ui.item.data( "item.autocomplete" );
154
- if ( false !== self._trigger( "focus", null, { item: item } ) ) {
167
+ if ( false !== self._trigger( "focus", event, { item: item } ) ) {
155
168
  // use value to match what will end up in the input, if it was a key event
156
169
  if ( /^key/.test(event.originalEvent.type) ) {
157
170
  self.element.val( item.value );
@@ -166,11 +179,21 @@ $.widget( "ui.autocomplete", {
166
179
  if ( self.element[0] !== doc.activeElement ) {
167
180
  self.element.focus();
168
181
  self.previous = previous;
182
+ // #6109 - IE triggers two focus events and the second
183
+ // is asynchronous, so we need to reset the previous
184
+ // term synchronously and asynchronously :-(
185
+ setTimeout(function() {
186
+ self.previous = previous;
187
+ self.selectedItem = item;
188
+ }, 1);
169
189
  }
170
190
 
171
191
  if ( false !== self._trigger( "select", event, { item: item } ) ) {
172
192
  self.element.val( item.value );
173
193
  }
194
+ // reset the term after the select event
195
+ // this allows custom select handling to work properly
196
+ self.term = self.element.val();
174
197
 
175
198
  self.close( event );
176
199
  self.selectedItem = item;
@@ -213,10 +236,14 @@ $.widget( "ui.autocomplete", {
213
236
  if ( key === "appendTo" ) {
214
237
  this.menu.element.appendTo( $( value || "body", this.element[0].ownerDocument )[0] )
215
238
  }
239
+ if ( key === "disabled" && value && this.xhr ) {
240
+ this.xhr.abort();
241
+ }
216
242
  },
217
243
 
218
244
  _initSource: function() {
219
- var array,
245
+ var self = this,
246
+ array,
220
247
  url;
221
248
  if ( $.isArray(this.options.source) ) {
222
249
  array = this.options.source;
@@ -226,7 +253,25 @@ $.widget( "ui.autocomplete", {
226
253
  } else if ( typeof this.options.source === "string" ) {
227
254
  url = this.options.source;
228
255
  this.source = function( request, response ) {
229
- $.getJSON( url, request, response );
256
+ if ( self.xhr ) {
257
+ self.xhr.abort();
258
+ }
259
+ self.xhr = $.ajax({
260
+ url: url,
261
+ data: request,
262
+ dataType: "json",
263
+ autocompleteRequest: ++requestIndex,
264
+ success: function( data, status ) {
265
+ if ( this.autocompleteRequest === requestIndex ) {
266
+ response( data );
267
+ }
268
+ },
269
+ error: function() {
270
+ if ( this.autocompleteRequest === requestIndex ) {
271
+ response( [] );
272
+ }
273
+ }
274
+ });
230
275
  };
231
276
  } else {
232
277
  this.source = this.options.source;
@@ -235,12 +280,16 @@ $.widget( "ui.autocomplete", {
235
280
 
236
281
  search: function( value, event ) {
237
282
  value = value != null ? value : this.element.val();
283
+
284
+ // always save the actual value, not the one passed as an argument
285
+ this.term = this.element.val();
286
+
238
287
  if ( value.length < this.options.minLength ) {
239
288
  return this.close( event );
240
289
  }
241
290
 
242
291
  clearTimeout( this.closing );
243
- if ( this._trigger("search") === false ) {
292
+ if ( this._trigger( "search", event ) === false ) {
244
293
  return;
245
294
  }
246
295
 
@@ -248,31 +297,32 @@ $.widget( "ui.autocomplete", {
248
297
  },
249
298
 
250
299
  _search: function( value ) {
251
- this.term = this.element
252
- .addClass( "ui-autocomplete-loading" )
253
- // always save the actual value, not the one passed as an argument
254
- .val();
300
+ this.pending++;
301
+ this.element.addClass( "ui-autocomplete-loading" );
255
302
 
256
303
  this.source( { term: value }, this.response );
257
304
  },
258
305
 
259
306
  _response: function( content ) {
260
- if ( content.length ) {
307
+ if ( !this.options.disabled && content && content.length ) {
261
308
  content = this._normalize( content );
262
309
  this._suggest( content );
263
310
  this._trigger( "open" );
264
311
  } else {
265
312
  this.close();
266
313
  }
267
- this.element.removeClass( "ui-autocomplete-loading" );
314
+ this.pending--;
315
+ if ( !this.pending ) {
316
+ this.element.removeClass( "ui-autocomplete-loading" );
317
+ }
268
318
  },
269
319
 
270
320
  close: function( event ) {
271
321
  clearTimeout( this.closing );
272
322
  if ( this.menu.element.is(":visible") ) {
273
- this._trigger( "close", event );
274
323
  this.menu.element.hide();
275
324
  this.menu.deactivate();
325
+ this._trigger( "close", event );
276
326
  }
277
327
  },
278
328
 
@@ -303,21 +353,31 @@ $.widget( "ui.autocomplete", {
303
353
 
304
354
  _suggest: function( items ) {
305
355
  var ul = this.menu.element
306
- .empty()
307
- .zIndex( this.element.zIndex() + 1 ),
308
- menuWidth,
309
- textWidth;
356
+ .empty()
357
+ .zIndex( this.element.zIndex() + 1 );
310
358
  this._renderMenu( ul, items );
311
359
  // TODO refresh should check if the active item is still in the dom, removing the need for a manual deactivate
312
360
  this.menu.deactivate();
313
361
  this.menu.refresh();
314
- this.menu.element.show().position( $.extend({
362
+
363
+ // size and position menu
364
+ ul.show();
365
+ this._resizeMenu();
366
+ ul.position( $.extend({
315
367
  of: this.element
316
368
  }, this.options.position ));
317
369
 
318
- menuWidth = ul.width( "" ).outerWidth();
319
- textWidth = this.element.outerWidth();
320
- ul.outerWidth( Math.max( menuWidth, textWidth ) );
370
+ if ( this.options.autoFocus ) {
371
+ this.menu.next( new $.Event("mouseover") );
372
+ }
373
+ },
374
+
375
+ _resizeMenu: function() {
376
+ var ul = this.menu.element;
377
+ ul.outerWidth( Math.max(
378
+ ul.width( "" ).outerWidth(),
379
+ this.element.outerWidth()
380
+ ) );
321
381
  },
322
382
 
323
383
  _renderMenu: function( ul, items ) {
@@ -434,7 +494,7 @@ $.widget("ui.menu", {
434
494
  elementHeight = this.element.height();
435
495
  if (offset < 0) {
436
496
  this.element.attr("scrollTop", scroll + offset);
437
- } else if (offset > elementHeight) {
497
+ } else if (offset >= elementHeight) {
438
498
  this.element.attr("scrollTop", scroll + offset - elementHeight + item.height());
439
499
  }
440
500
  }
@@ -490,12 +550,12 @@ $.widget("ui.menu", {
490
550
  if (this.hasScroll()) {
491
551
  // TODO merge with no-scroll-else
492
552
  if (!this.active || this.last()) {
493
- this.activate(event, this.element.children(":first"));
553
+ this.activate(event, this.element.children(".ui-menu-item:first"));
494
554
  return;
495
555
  }
496
556
  var base = this.active.offset().top,
497
557
  height = this.element.height(),
498
- result = this.element.children("li").filter(function() {
558
+ result = this.element.children(".ui-menu-item").filter(function() {
499
559
  var close = $(this).offset().top - base - height + $(this).height();
500
560
  // TODO improve approximation
501
561
  return close < 10 && close > -10;
@@ -503,11 +563,12 @@ $.widget("ui.menu", {
503
563
 
504
564
  // TODO try to catch this earlier when scrollTop indicates the last page anyway
505
565
  if (!result.length) {
506
- result = this.element.children(":last");
566
+ result = this.element.children(".ui-menu-item:last");
507
567
  }
508
568
  this.activate(event, result);
509
569
  } else {
510
- this.activate(event, this.element.children(!this.active || this.last() ? ":first" : ":last"));
570
+ this.activate(event, this.element.children(".ui-menu-item")
571
+ .filter(!this.active || this.last() ? ":first" : ":last"));
511
572
  }
512
573
  },
513
574
 
@@ -516,13 +577,13 @@ $.widget("ui.menu", {
516
577
  if (this.hasScroll()) {
517
578
  // TODO merge with no-scroll-else
518
579
  if (!this.active || this.first()) {
519
- this.activate(event, this.element.children(":last"));
580
+ this.activate(event, this.element.children(".ui-menu-item:last"));
520
581
  return;
521
582
  }
522
583
 
523
584
  var base = this.active.offset().top,
524
585
  height = this.element.height();
525
- result = this.element.children("li").filter(function() {
586
+ result = this.element.children(".ui-menu-item").filter(function() {
526
587
  var close = $(this).offset().top - base + height - $(this).height();
527
588
  // TODO improve approximation
528
589
  return close < 10 && close > -10;
@@ -530,11 +591,12 @@ $.widget("ui.menu", {
530
591
 
531
592
  // TODO try to catch this earlier when scrollTop indicates the last page anyway
532
593
  if (!result.length) {
533
- result = this.element.children(":first");
594
+ result = this.element.children(".ui-menu-item:first");
534
595
  }
535
596
  this.activate(event, result);
536
597
  } else {
537
- this.activate(event, this.element.children(!this.active || this.first() ? ":last" : ":first"));
598
+ this.activate(event, this.element.children(".ui-menu-item")
599
+ .filter(!this.active || this.first() ? ":last" : ":first"));
538
600
  }
539
601
  },
540
602
 
@@ -1,7 +1,7 @@
1
1
  /*
2
- * jQuery UI Button 1.8.4
2
+ * jQuery UI Button @VERSION
3
3
  *
4
- * Copyright 2010, AUTHORS.txt (http://jqueryui.com/about)
4
+ * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
5
5
  * Dual licensed under the MIT or GPL Version 2 licenses.
6
6
  * http://jquery.org/license
7
7
  *
@@ -44,6 +44,7 @@ var lastActive,
44
44
 
45
45
  $.widget( "ui.button", {
46
46
  options: {
47
+ disabled: null,
47
48
  text: true,
48
49
  label: null,
49
50
  icons: {
@@ -56,6 +57,10 @@ $.widget( "ui.button", {
56
57
  .unbind( "reset.button" )
57
58
  .bind( "reset.button", formResetHandler );
58
59
 
60
+ if ( typeof this.options.disabled !== "boolean" ) {
61
+ this.options.disabled = this.element.attr( "disabled" );
62
+ }
63
+
59
64
  this._determineButtonType();
60
65
  this.hasTitle = !!this.buttonElement.attr( "title" );
61
66
 
@@ -195,8 +200,16 @@ $.widget( "ui.button", {
195
200
  if ( this.type === "checkbox" || this.type === "radio" ) {
196
201
  // we don't search against the document in case the element
197
202
  // is disconnected from the DOM
198
- this.buttonElement = this.element.parents().last()
199
- .find( "label[for=" + this.element.attr("id") + "]" );
203
+ var ancestor = this.element.parents().filter(":last"),
204
+ labelSelector = "label[for=" + this.element.attr("id") + "]";
205
+ this.buttonElement = ancestor.find( labelSelector );
206
+ if ( !this.buttonElement.length ) {
207
+ ancestor = ancestor.length ? ancestor.siblings() : this.element.siblings();
208
+ this.buttonElement = ancestor.filter( labelSelector );
209
+ if ( !this.buttonElement.length ) {
210
+ this.buttonElement = ancestor.find( labelSelector );
211
+ }
212
+ }
200
213
  this.element.addClass( "ui-helper-hidden-accessible" );
201
214
 
202
215
  var checked = this.element.is( ":checked" );
@@ -285,34 +298,43 @@ $.widget( "ui.button", {
285
298
  .appendTo( buttonElement.empty() )
286
299
  .text(),
287
300
  icons = this.options.icons,
288
- multipleIcons = icons.primary && icons.secondary;
301
+ multipleIcons = icons.primary && icons.secondary,
302
+ buttonClasses = [];
303
+
289
304
  if ( icons.primary || icons.secondary ) {
290
- buttonElement.addClass( "ui-button-text-icon" +
291
- ( multipleIcons ? "s" : ( icons.primary ? "-primary" : "-secondary" ) ) );
305
+ if ( this.options.text ) {
306
+ buttonClasses.push( "ui-button-text-icon" + ( multipleIcons ? "s" : ( icons.primary ? "-primary" : "-secondary" ) ) );
307
+ }
308
+
292
309
  if ( icons.primary ) {
293
310
  buttonElement.prepend( "<span class='ui-button-icon-primary ui-icon " + icons.primary + "'></span>" );
294
311
  }
312
+
295
313
  if ( icons.secondary ) {
296
314
  buttonElement.append( "<span class='ui-button-icon-secondary ui-icon " + icons.secondary + "'></span>" );
297
315
  }
316
+
298
317
  if ( !this.options.text ) {
299
- buttonElement
300
- .addClass( multipleIcons ? "ui-button-icons-only" : "ui-button-icon-only" )
301
- .removeClass( "ui-button-text-icons ui-button-text-icon-primary ui-button-text-icon-secondary" );
318
+ buttonClasses.push( multipleIcons ? "ui-button-icons-only" : "ui-button-icon-only" );
319
+
302
320
  if ( !this.hasTitle ) {
303
321
  buttonElement.attr( "title", buttonText );
304
322
  }
305
323
  }
306
324
  } else {
307
- buttonElement.addClass( "ui-button-text-only" );
325
+ buttonClasses.push( "ui-button-text-only" );
308
326
  }
327
+ buttonElement.addClass( buttonClasses.join( " " ) );
309
328
  }
310
329
  });
311
330
 
312
331
  $.widget( "ui.buttonset", {
332
+ options: {
333
+ items: ":button, :submit, :reset, :checkbox, :radio, a, :data(button)"
334
+ },
335
+
313
336
  _create: function() {
314
337
  this.element.addClass( "ui-buttonset" );
315
- this._init();
316
338
  },
317
339
 
318
340
  _init: function() {
@@ -328,7 +350,7 @@ $.widget( "ui.buttonset", {
328
350
  },
329
351
 
330
352
  refresh: function() {
331
- this.buttons = this.element.find( ":button, :submit, :reset, :checkbox, :radio, a, :data(button)" )
353
+ this.buttons = this.element.find( this.options.items )
332
354
  .filter( ":ui-button" )
333
355
  .button( "refresh" )
334
356
  .end()
@@ -1,7 +1,7 @@
1
1
  /*!
2
- * jQuery UI 1.8.4
2
+ * jQuery UI @VERSION
3
3
  *
4
- * Copyright 2010, AUTHORS.txt (http://jqueryui.com/about)
4
+ * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
5
5
  * Dual licensed under the MIT or GPL Version 2 licenses.
6
6
  * http://jquery.org/license
7
7
  *
@@ -17,71 +17,8 @@ if ( $.ui.version ) {
17
17
  return;
18
18
  }
19
19
 
20
- //Helper functions and ui object
21
20
  $.extend( $.ui, {
22
- version: "1.8.4",
23
-
24
- // $.ui.plugin is deprecated. Use the proxy pattern instead.
25
- plugin: {
26
- add: function( module, option, set ) {
27
- var proto = $.ui[ module ].prototype;
28
- for ( var i in set ) {
29
- proto.plugins[ i ] = proto.plugins[ i ] || [];
30
- proto.plugins[ i ].push( [ option, set[ i ] ] );
31
- }
32
- },
33
- call: function( instance, name, args ) {
34
- var set = instance.plugins[ name ];
35
- if ( !set || !instance.element[ 0 ].parentNode ) {
36
- return;
37
- }
38
-
39
- for ( var i = 0; i < set.length; i++ ) {
40
- if ( instance.options[ set[ i ][ 0 ] ] ) {
41
- set[ i ][ 1 ].apply( instance.element, args );
42
- }
43
- }
44
- }
45
- },
46
-
47
- contains: function( a, b ) {
48
- return document.compareDocumentPosition ?
49
- a.compareDocumentPosition( b ) & 16 :
50
- a !== b && a.contains( b );
51
- },
52
-
53
- hasScroll: function( el, a ) {
54
-
55
- //If overflow is hidden, the element might have extra content, but the user wants to hide it
56
- if ( $( el ).css( "overflow" ) === "hidden") {
57
- return false;
58
- }
59
-
60
- var scroll = ( a && a === "left" ) ? "scrollLeft" : "scrollTop",
61
- has = false;
62
-
63
- if ( el[ scroll ] > 0 ) {
64
- return true;
65
- }
66
-
67
- // TODO: determine which cases actually cause this to happen
68
- // if the element doesn't have the scroll set, see if it's possible to
69
- // set the scroll
70
- el[ scroll ] = 1;
71
- has = ( el[ scroll ] > 0 );
72
- el[ scroll ] = 0;
73
- return has;
74
- },
75
-
76
- isOverAxis: function( x, reference, size ) {
77
- //Determines when x coordinate is over "b" element axis
78
- return ( x > reference ) && ( x < ( reference + size ) );
79
- },
80
-
81
- isOver: function( y, x, top, left, height, width ) {
82
- //Determines when x, y coordinates is over "b" element
83
- return $.ui.isOverAxis( y, top, height ) && $.ui.isOverAxis( x, left, width );
84
- },
21
+ version: "@VERSION",
85
22
 
86
23
  keyCode: {
87
24
  ALT: 18,
@@ -119,7 +56,7 @@ $.extend( $.ui, {
119
56
  }
120
57
  });
121
58
 
122
- //jQuery plugins
59
+ // plugins
123
60
  $.fn.extend({
124
61
  _focus: $.fn.focus,
125
62
  focus: function( delay, fn ) {
@@ -136,18 +73,6 @@ $.fn.extend({
136
73
  this._focus.apply( this, arguments );
137
74
  },
138
75
 
139
- enableSelection: function() {
140
- return this
141
- .attr( "unselectable", "off" )
142
- .css( "MozUserSelect", "" );
143
- },
144
-
145
- disableSelection: function() {
146
- return this
147
- .attr( "unselectable", "on" )
148
- .css( "MozUserSelect", "none" );
149
- },
150
-
151
76
  scrollParent: function() {
152
77
  var scrollParent;
153
78
  if (($.browser.msie && (/(static|relative)/).test(this.css('position'))) || (/absolute/).test(this.css('position'))) {
@@ -180,8 +105,8 @@ $.fn.extend({
180
105
  // other browsers return a string
181
106
  // we ignore the case of nested elements with an explicit value of 0
182
107
  // <div style="z-index: -10;"><div style="z-index: 0;"></div></div>
183
- value = parseInt( elem.css( "zIndex" ) );
184
- if ( !isNaN( value ) && value != 0 ) {
108
+ value = parseInt( elem.css( "zIndex" ), 10 );
109
+ if ( !isNaN( value ) && value !== 0 ) {
185
110
  return value;
186
111
  }
187
112
  }
@@ -190,6 +115,17 @@ $.fn.extend({
190
115
  }
191
116
 
192
117
  return 0;
118
+ },
119
+
120
+ disableSelection: function() {
121
+ return this.bind( ( $.support.selectstart ? "selectstart" : "mousedown" ) +
122
+ ".ui-disableSelection", function( event ) {
123
+ event.preventDefault();
124
+ });
125
+ },
126
+
127
+ enableSelection: function() {
128
+ return this.unbind( ".ui-disableSelection" );
193
129
  }
194
130
  });
195
131
 
@@ -222,7 +158,7 @@ $.each( [ "Width", "Height" ], function( i, name ) {
222
158
  }
223
159
 
224
160
  return this.each(function() {
225
- $.style( this, type, reduce( this, size ) + "px" );
161
+ $( this ).css( type, reduce( this, size ) + "px" );
226
162
  });
227
163
  };
228
164
 
@@ -232,12 +168,12 @@ $.each( [ "Width", "Height" ], function( i, name ) {
232
168
  }
233
169
 
234
170
  return this.each(function() {
235
- $.style( this, type, reduce( this, size, true, margin ) + "px" );
171
+ $( this).css( type, reduce( this, size, true, margin ) + "px" );
236
172
  });
237
173
  };
238
174
  });
239
175
 
240
- //Additional selectors
176
+ // selectors
241
177
  function visible( element ) {
242
178
  return !$( element ).parents().andSelf().filter(function() {
243
179
  return $.curCSS( this, "visibility" ) === "hidden" ||
@@ -278,4 +214,95 @@ $.extend( $.expr[ ":" ], {
278
214
  }
279
215
  });
280
216
 
217
+ // support
218
+ $(function() {
219
+ var body = document.body,
220
+ div = body.appendChild( div = document.createElement( "div" ) );
221
+
222
+ $.extend( div.style, {
223
+ minHeight: "100px",
224
+ height: "auto",
225
+ padding: 0,
226
+ borderWidth: 0
227
+ });
228
+
229
+ $.support.minHeight = div.offsetHeight === 100;
230
+ $.support.selectstart = "onselectstart" in div;
231
+
232
+ // set display to none to avoid a layout bug in IE
233
+ // http://dev.jquery.com/ticket/4014
234
+ body.removeChild( div ).style.display = "none";
235
+ });
236
+
237
+
238
+
239
+
240
+
241
+ // deprecated
242
+ $.extend( $.ui, {
243
+ // $.ui.plugin is deprecated. Use the proxy pattern instead.
244
+ plugin: {
245
+ add: function( module, option, set ) {
246
+ var proto = $.ui[ module ].prototype;
247
+ for ( var i in set ) {
248
+ proto.plugins[ i ] = proto.plugins[ i ] || [];
249
+ proto.plugins[ i ].push( [ option, set[ i ] ] );
250
+ }
251
+ },
252
+ call: function( instance, name, args ) {
253
+ var set = instance.plugins[ name ];
254
+ if ( !set || !instance.element[ 0 ].parentNode ) {
255
+ return;
256
+ }
257
+
258
+ for ( var i = 0; i < set.length; i++ ) {
259
+ if ( instance.options[ set[ i ][ 0 ] ] ) {
260
+ set[ i ][ 1 ].apply( instance.element, args );
261
+ }
262
+ }
263
+ }
264
+ },
265
+
266
+ // will be deprecated when we switch to jQuery 1.4 - use jQuery.contains()
267
+ contains: function( a, b ) {
268
+ return document.compareDocumentPosition ?
269
+ a.compareDocumentPosition( b ) & 16 :
270
+ a !== b && a.contains( b );
271
+ },
272
+
273
+ // only used by resizable
274
+ hasScroll: function( el, a ) {
275
+
276
+ //If overflow is hidden, the element might have extra content, but the user wants to hide it
277
+ if ( $( el ).css( "overflow" ) === "hidden") {
278
+ return false;
279
+ }
280
+
281
+ var scroll = ( a && a === "left" ) ? "scrollLeft" : "scrollTop",
282
+ has = false;
283
+
284
+ if ( el[ scroll ] > 0 ) {
285
+ return true;
286
+ }
287
+
288
+ // TODO: determine which cases actually cause this to happen
289
+ // if the element doesn't have the scroll set, see if it's possible to
290
+ // set the scroll
291
+ el[ scroll ] = 1;
292
+ has = ( el[ scroll ] > 0 );
293
+ el[ scroll ] = 0;
294
+ return has;
295
+ },
296
+
297
+ // these are odd functions, fix the API or move into individual plugins
298
+ isOverAxis: function( x, reference, size ) {
299
+ //Determines when x coordinate is over "b" element axis
300
+ return ( x > reference ) && ( x < ( reference + size ) );
301
+ },
302
+ isOver: function( y, x, top, left, height, width ) {
303
+ //Determines when x, y coordinates is over "b" element
304
+ return $.ui.isOverAxis( y, top, height ) && $.ui.isOverAxis( x, left, width );
305
+ }
306
+ });
307
+
281
308
  })( jQuery );