imperavi-rails 0.0.8.beta → 0.0.9.beta

Sign up to get free protection for your applications and to get access to all the features.
Files changed (381) hide show
  1. data/README.md +1 -1
  2. data/app/assets/javascripts/imperavi-rails/imperavi/redactor.js +14 -8
  3. data/app/controllers/imperavi_rails/imperavi_controller.rb +2 -2
  4. data/app/helpers/imperavi_rails/imperavi_helper.rb +12 -5
  5. data/app/views/imperavi_rails/languages/en.js +62 -0
  6. data/app/views/imperavi_rails/languages/fr.js +61 -0
  7. data/app/views/imperavi_rails/languages/pl.js +62 -0
  8. data/app/views/imperavi_rails/languages/pt_br.js +68 -0
  9. data/app/views/imperavi_rails/languages/ru.js +62 -0
  10. data/app/views/imperavi_rails/languages/ua.js +62 -0
  11. data/app/views/imperavi_rails/toolbars/air.js +33 -0
  12. data/app/views/imperavi_rails/toolbars/main.js +70 -0
  13. data/app/views/imperavi_rails/toolbars/mini.js +65 -0
  14. data/config/routes.rb +10 -10
  15. data/lib/imperavi-rails/version.rb +1 -1
  16. metadata +124 -845
  17. data/spec/dummy/db/development.sqlite3 +0 -0
  18. data/spec/dummy/log/development.log +0 -24866
  19. data/spec/dummy/public/system/dragonfly/development/2012/02/03/10_10_05_126_6.jpg +0 -0
  20. data/spec/dummy/public/system/dragonfly/development/2012/02/03/10_10_05_126_6.jpg.meta +0 -4
  21. data/spec/dummy/public/system/dragonfly/development/2012/02/03/14_44_32_721_6.jpg +0 -0
  22. data/spec/dummy/public/system/dragonfly/development/2012/02/03/14_44_32_721_6.jpg.meta +0 -4
  23. data/spec/dummy/public/system/dragonfly/development/2012/02/03/14_45_23_25_5.jpg +0 -0
  24. data/spec/dummy/public/system/dragonfly/development/2012/02/03/14_45_23_25_5.jpg.meta +0 -4
  25. data/spec/dummy/public/system/dragonfly/development/2012/02/03/14_45_49_374_15744.jpg +0 -0
  26. data/spec/dummy/public/system/dragonfly/development/2012/02/03/14_45_49_374_15744.jpg.meta +0 -3
  27. data/spec/dummy/public/system/dragonfly/development/2012/02/03/14_50_20_902_4.jpg +0 -0
  28. data/spec/dummy/public/system/dragonfly/development/2012/02/03/14_50_20_902_4.jpg.meta +0 -4
  29. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_22_15_373_5.jpg +0 -0
  30. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_22_15_373_5.jpg.meta +0 -4
  31. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_22_40_820_5.jpg +0 -0
  32. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_22_40_820_5.jpg.meta +0 -4
  33. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_23_30_325_3.jpg +0 -0
  34. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_23_30_325_3.jpg.meta +0 -4
  35. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_23_57_376_4.jpg +0 -0
  36. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_23_57_376_4.jpg.meta +0 -4
  37. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_26_27_220_5.jpg +0 -0
  38. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_26_27_220_5.jpg.meta +0 -4
  39. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_26_57_55_6.jpg +0 -0
  40. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_26_57_55_6.jpg.meta +0 -4
  41. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_27_58_370_5.jpg +0 -0
  42. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_27_58_370_5.jpg.meta +0 -4
  43. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_29_07_700_5.jpg +0 -0
  44. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_29_07_700_5.jpg.meta +0 -4
  45. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_29_19_327_4.jpg +0 -0
  46. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_29_19_327_4.jpg.meta +0 -4
  47. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_29_53_813_4.jpg +0 -0
  48. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_29_53_813_4.jpg.meta +0 -4
  49. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_30_13_242_5.jpg +0 -0
  50. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_30_13_242_5.jpg.meta +0 -4
  51. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_30_19_927_6.jpg +0 -0
  52. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_30_19_927_6.jpg.meta +0 -4
  53. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_14_355_5.jpg +0 -0
  54. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_14_355_5.jpg.meta +0 -4
  55. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_19_371_1.jpg +0 -0
  56. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_19_371_1.jpg.meta +0 -4
  57. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_28_432_15750.jpg +0 -0
  58. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_28_432_15750.jpg.meta +0 -3
  59. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_39_821_15720.jpg +0 -0
  60. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_39_821_15720.jpg.meta +0 -3
  61. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_47_624_4.jpg +0 -0
  62. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_31_47_624_4.jpg.meta +0 -4
  63. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_33_26_155_5.jpg +0 -0
  64. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_33_26_155_5.jpg.meta +0 -4
  65. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_34_29_787_2_small.jpg +0 -0
  66. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_34_29_787_2_small.jpg.meta +0 -3
  67. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_34_35_450_6.jpg +0 -0
  68. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_34_35_450_6.jpg.meta +0 -4
  69. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_34_41_340_15744.jpg +0 -0
  70. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_34_41_340_15744.jpg.meta +0 -3
  71. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_38_14_325_5.jpg +0 -0
  72. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_38_14_325_5.jpg.meta +0 -4
  73. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_45_06_883_6.jpg +0 -0
  74. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_45_06_883_6.jpg.meta +0 -4
  75. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_45_18_915_6.jpg +0 -0
  76. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_45_18_915_6.jpg.meta +0 -4
  77. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_45_46_86_15744.jpg +0 -0
  78. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_45_46_86_15744.jpg.meta +0 -3
  79. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_47_24_195_3.jpg +0 -0
  80. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_47_24_195_3.jpg.meta +0 -4
  81. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_47_46_83_5.jpg +0 -0
  82. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_47_46_83_5.jpg.meta +0 -4
  83. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_51_18_603_15720.jpg +0 -0
  84. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_51_18_603_15720.jpg.meta +0 -3
  85. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_51_57_666_6.jpg +0 -0
  86. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_51_57_666_6.jpg.meta +0 -4
  87. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_53_25_938_6.jpg +0 -0
  88. data/spec/dummy/public/system/dragonfly/development/2012/02/17/19_53_25_938_6.jpg.meta +0 -4
  89. data/spec/dummy/tmp/cache/assets/C41/5B0/sprockets%2F095415e1141a435237aa9464752d21fd +0 -242
  90. data/spec/dummy/tmp/cache/assets/CA9/BC0/sprockets%2F85d8b987b980454101a1236fdec2c220 +0 -0
  91. data/spec/dummy/tmp/cache/assets/CBE/FC0/sprockets%2Ff5431a64e341b062b7530132a5c1ea5a +0 -2365
  92. data/spec/dummy/tmp/cache/assets/CC0/310/sprockets%2Fb372e5f868e8a8801e126262f66c9c08 +0 -16
  93. data/spec/dummy/tmp/cache/assets/CC5/C10/sprockets%2F7c81f5c40dc9b87819488e127f487a04 +0 -591
  94. data/spec/dummy/tmp/cache/assets/CD5/530/sprockets%2F8d4c18bd4851f107c450a2c782301f8b +0 -53
  95. data/spec/dummy/tmp/cache/assets/CD7/EF0/sprockets%2Fc22597dc7c74137ba100f08542fec580 +0 -76
  96. data/spec/dummy/tmp/cache/assets/CE5/650/sprockets%2F8ab512c9b33ac90e699b73469d71f061 +0 -269
  97. data/spec/dummy/tmp/cache/assets/CF0/1D0/sprockets%2F6fc757c2c8329244ca95d6909865bbc2 +0 -81
  98. data/spec/dummy/tmp/cache/assets/D02/F90/sprockets%2Ff029f33d65d53d13d3c0fd29e0c08133 +0 -10
  99. data/spec/dummy/tmp/cache/assets/D06/850/sprockets%2F9027c767fa3c09c1a605eae10b43d549 +0 -9272
  100. data/spec/dummy/tmp/cache/assets/D09/DB0/sprockets%2F5ad1bbd0a458985447fac962fb121264 +0 -188
  101. data/spec/dummy/tmp/cache/assets/D0C/0C0/sprockets%2F106b7f622fb804e4248c862abe73a4c8 +0 -16
  102. data/spec/dummy/tmp/cache/assets/D11/D20/sprockets%2Fcac21eac42152981882bf9e489316af4 +0 -61
  103. data/spec/dummy/tmp/cache/assets/D1A/AB0/sprockets%2F05ea78f209b93ef03f29e933625b7fa5 +0 -306
  104. data/spec/dummy/tmp/cache/assets/D24/8E0/sprockets%2F47f976dc55ebc7889e349067c9ba01b2 +0 -16
  105. data/spec/dummy/tmp/cache/assets/D2A/450/sprockets%2F58e369b37e5157ea746a485eea17e9f7 +0 -28
  106. data/spec/dummy/tmp/cache/assets/D33/480/sprockets%2Fec072121b559132efe7d07cac0e991a5 +0 -106
  107. data/spec/dummy/tmp/cache/assets/D34/D90/sprockets%2Fac3fb880b6bb140d16d5b4a6916e5067 +0 -52
  108. data/spec/dummy/tmp/cache/assets/D38/5D0/sprockets%2F7913f60d743aeb957af7a0ca5a20059d +0 -0
  109. data/spec/dummy/tmp/cache/assets/D38/C80/sprockets%2Fb7152c93aa41253e9ed17d71a5c0eb88 +0 -16
  110. data/spec/dummy/tmp/cache/assets/D43/830/sprockets%2Fe09848481135db1a4a5c783a7dc94fbd +0 -50
  111. data/spec/dummy/tmp/cache/assets/D58/6D0/sprockets%2Fd2a3ab2b5401861dcd2e343ca6e4923e +0 -37
  112. data/spec/dummy/tmp/cache/assets/D59/260/sprockets%2Fd513a46ce8d83f003a733cb306dfe01a +0 -1509
  113. data/spec/dummy/tmp/cache/assets/D64/190/sprockets%2Ffdfa1bbf71247a2b9ef0b97732603e02 +0 -0
  114. data/spec/dummy/tmp/cache/assets/D66/200/sprockets%2Fb343cda49d5d41a82c10a8f06d986bd2 +0 -45
  115. data/spec/dummy/tmp/cache/assets/D6B/980/sprockets%2F56c37f49f60073a401fcbd529dcaa74e +0 -222
  116. data/spec/dummy/tmp/cache/assets/D6D/7C0/sprockets%2Fa4b9caa51f636e2b2db868c480e2a487 +0 -8
  117. data/spec/dummy/tmp/cache/assets/D6D/AF0/sprockets%2F5a1aa4e3f7d7008e775019dfef3282cc +1 -96
  118. data/spec/dummy/tmp/cache/assets/D73/170/sprockets%2Ffe70d93b5d3398dd8d0c6a3d701290ef +0 -123
  119. data/spec/dummy/tmp/cache/assets/D76/560/sprockets%2Fe0c5141697a090ffb74c9412e6dd7fef +0 -50
  120. data/spec/dummy/tmp/cache/assets/D76/B30/sprockets%2Fce979145545abbfd4ca50fea3489554c +0 -395
  121. data/spec/dummy/tmp/cache/assets/D84/210/sprockets%2Fabd0103ccec2b428ac62c94e4c40b384 +0 -9655
  122. data/spec/dummy/tmp/cache/assets/D95/E80/sprockets%2F844edf25b78967cbe9cf3e969c37c6c7 +0 -0
  123. data/spec/dummy/tmp/cache/assets/D96/230/sprockets%2F63e1b63e2b03d0bd6aaebd27c9973e91 +0 -249
  124. data/spec/dummy/tmp/cache/assets/D9B/E30/sprockets%2Fd87c8ca46743542cace533cfe91ae1d0 +0 -567
  125. data/spec/dummy/tmp/cache/assets/D9B/FF0/sprockets%2Fd8bbace39747d4af921e0534736baea3 +0 -125
  126. data/spec/dummy/tmp/cache/assets/DA2/970/sprockets%2F0d4ef1d42ee3e36fedcd979b3506525b +0 -882
  127. data/spec/dummy/tmp/cache/assets/DA2/EA0/sprockets%2F9e95d2e1a4da7fafb60b9b782a53b753 +0 -378
  128. data/spec/dummy/tmp/cache/assets/DA8/F60/sprockets%2Fbb2cd57d63160c94d622ef9d91ccef68 +0 -16
  129. data/spec/dummy/tmp/cache/assets/DAC/140/sprockets%2F7a814a5598eaaaccf7ab7895f5663ad5 +0 -89
  130. data/spec/dummy/tmp/cache/assets/DAC/DC0/sprockets%2Fe8cdb03f780ff87851dd459dc844ad1b +0 -246
  131. data/spec/dummy/tmp/cache/assets/DB7/F90/sprockets%2Faf8cc6b28a790c7e3bd686e8ab9973c8 +0 -0
  132. data/spec/dummy/tmp/cache/assets/DBB/960/sprockets%2Fe20156d5decfaaea9d1e09f14a100f19 +0 -16
  133. data/spec/dummy/tmp/cache/assets/E04/890/sprockets%2F2f5173deea6c795b8fdde723bb4b63af +0 -61
  134. data/spec/dummy/tmp/cache/assets/E05/F10/sprockets%2Fb3d9b0e88cdded276ebdce333e338a85 +0 -30
  135. data/spec/dummy/tmp/cache/assets/E22/CE0/sprockets%2F6fe70d27fda81ea53c8bdaeb1b112dd7 +0 -9289
  136. data/spec/dummy/tmp/cache/assets/E26/210/sprockets%2Fbb3accabff7037e93dc9a3373f4a5b7a +0 -1580
  137. data/spec/dummy/tmp/cache/assets/E66/AE0/sprockets%2Ffcb98ed9ac3e15f6d9e59fd00cbb2d3d +0 -16
  138. data/spec/dummy/tmp/cache/sass/9bd7199bacdbfc23c47b913698aa7195d1e0f382/application.css.scssc +0 -0
  139. data/spec/dummy/tmp/cache/sass/bc54e898614d486bf9338d646e8cd056915d4779/imperavi-base.css.scssc +0 -0
  140. data/spec/dummy/tmp/cache/sass/bc54e898614d486bf9338d646e8cd056915d4779/redactor.css.scssc +0 -0
  141. data/spec/dummy/tmp/cache/sass/bc54e898614d486bf9338d646e8cd056915d4779/wym.css.scssc +0 -0
  142. data/spec/dummy/tmp/dragonfly/cache/body/00/4aecc0c59254723e83737f8928702ffd7bb98b +0 -373
  143. data/spec/dummy/tmp/dragonfly/cache/body/01/8b80e42551d33aed663f5757b3e4d3789383e6 +0 -2359
  144. data/spec/dummy/tmp/dragonfly/cache/body/02/3133eaaddaa68515039bc51e11b3bca2ad3f23 +0 -986
  145. data/spec/dummy/tmp/dragonfly/cache/body/03/13c061439229cdbd19215cbd1cf0e26441fac2 +0 -713
  146. data/spec/dummy/tmp/dragonfly/cache/body/05/024188cd40feb026eb8ccd15985d890ba9c84e +0 -643
  147. data/spec/dummy/tmp/dragonfly/cache/body/06/e22ab9a18784ce1f20e09401ee38b9672860d9 +0 -697
  148. data/spec/dummy/tmp/dragonfly/cache/body/07/f49938e6a88e40d2d6fd9fc613578396148e1d +0 -1014
  149. data/spec/dummy/tmp/dragonfly/cache/body/08/8e8a8fc07862b6f7f1bb3d065c44a796a1b959 +0 -489
  150. data/spec/dummy/tmp/dragonfly/cache/body/09/7fc6a9593ea7b3a9992dd166cdc87cf0e06afc +0 -2341
  151. data/spec/dummy/tmp/dragonfly/cache/body/09/c8b9529699d7f44fc6e314c992ea222ecf891a +0 -926
  152. data/spec/dummy/tmp/dragonfly/cache/body/0a/eae45805608cdebd81ace3ac272d43ef8c581a +0 -517
  153. data/spec/dummy/tmp/dragonfly/cache/body/0f/33cebc2562a1ba143494c74b572a7f569c398e +0 -0
  154. data/spec/dummy/tmp/dragonfly/cache/body/12/f3e9f5435e64b368b805b0f6e2e5b04763e0e9 +0 -713
  155. data/spec/dummy/tmp/dragonfly/cache/body/13/02bfc481015a6a0abeb3bd17a166b761ba8a47 +0 -626
  156. data/spec/dummy/tmp/dragonfly/cache/body/14/132bf3af2f923b66a62826ebe1dd001f0ba183 +0 -0
  157. data/spec/dummy/tmp/dragonfly/cache/body/16/3001f75355d109f24b59f690f7ba71c2616261 +0 -2343
  158. data/spec/dummy/tmp/dragonfly/cache/body/16/7a17ea4c64e37f9f0aa5e773501ee5131bb2af +0 -552
  159. data/spec/dummy/tmp/dragonfly/cache/body/16/c5ea89574eb557096b3fefd758954e84a34381 +0 -0
  160. data/spec/dummy/tmp/dragonfly/cache/body/18/1ddbad5715e03f6bcaeb409ca55a8f1f1c2b76 +0 -1000
  161. data/spec/dummy/tmp/dragonfly/cache/body/18/dc1d281e1b27f8e29a5d3ea3192ee5ab92c8fe +0 -1721
  162. data/spec/dummy/tmp/dragonfly/cache/body/19/244efbcbf0ed096cc80addb39d1139782691e4 +0 -701
  163. data/spec/dummy/tmp/dragonfly/cache/body/1b/09d865c098ccb9e1bb1783281f8f18ab22f49c +0 -1016
  164. data/spec/dummy/tmp/dragonfly/cache/body/1b/5baeb3d8b21ebdd6d60357437ea9b4ddefa49a +0 -537
  165. data/spec/dummy/tmp/dragonfly/cache/body/1b/f3995977d56cd70d334227ffae3858fdb3e1d4 +0 -1011
  166. data/spec/dummy/tmp/dragonfly/cache/body/1c/8c49d20e2ca7ccea3c7124923f2d6ff715400c +0 -538
  167. data/spec/dummy/tmp/dragonfly/cache/body/1e/3ce5b58c37f23053d85f581ff49d15ad1a498a +0 -674
  168. data/spec/dummy/tmp/dragonfly/cache/body/1f/de9c96ae1b545cb125a43f6c81fe6f15851ac7 +0 -546
  169. data/spec/dummy/tmp/dragonfly/cache/body/20/5d43e6adae0bf766e830109660e59dfd97a776 +0 -646
  170. data/spec/dummy/tmp/dragonfly/cache/body/20/9dd05484ee6eca030ee50cf71b912a67089c79 +0 -2339
  171. data/spec/dummy/tmp/dragonfly/cache/body/21/199c9bdb6c7f65200a15ca0934612bcae4204c +0 -242
  172. data/spec/dummy/tmp/dragonfly/cache/body/21/bdc0c588b6d2ddbbcc9b76fe749c38f0ef2f41 +0 -872
  173. data/spec/dummy/tmp/dragonfly/cache/body/22/f0e133e63c81c43643026aa5cbb3712bfa929e +0 -708
  174. data/spec/dummy/tmp/dragonfly/cache/body/24/f7da13054199d224537d7530367474f292c85a +0 -2359
  175. data/spec/dummy/tmp/dragonfly/cache/body/27/0ac007b4441579233e425f3e7a36887eb4298e +0 -986
  176. data/spec/dummy/tmp/dragonfly/cache/body/28/c775213c7f72c870045887887893831bbb9083 +0 -1006
  177. data/spec/dummy/tmp/dragonfly/cache/body/2a/602d5bf47ce3c3e1fbd540f3659acdf8488b84 +0 -2341
  178. data/spec/dummy/tmp/dragonfly/cache/body/2c/79dceb2787a90f7da9a43673db8d1f1922a379 +0 -641
  179. data/spec/dummy/tmp/dragonfly/cache/body/2d/016dc3e8be00f46455041e5187159762a1a72b +0 -535
  180. data/spec/dummy/tmp/dragonfly/cache/body/2d/40a96b71b5c4be6ea5de082c5c468b923df113 +0 -626
  181. data/spec/dummy/tmp/dragonfly/cache/body/2f/2077afd991927df732811e002d532f34a62c86 +0 -0
  182. data/spec/dummy/tmp/dragonfly/cache/body/30/7cdb90b26de71fedb1774d7b7fe630e77cf34f +0 -1011
  183. data/spec/dummy/tmp/dragonfly/cache/body/33/43ee3681542a52fec318884c34cdc6233aec90 +0 -2359
  184. data/spec/dummy/tmp/dragonfly/cache/body/34/d994dfa8a8a2cf1dddcfcb9d7d43839f798a66 +0 -1007
  185. data/spec/dummy/tmp/dragonfly/cache/body/36/1acb61b84bbb2e3b1fe7cb28e1ca0bb2ebc147 +0 -1721
  186. data/spec/dummy/tmp/dragonfly/cache/body/37/0de185ac6803197940a4aca2ee4cb6cd97aa25 +0 -700
  187. data/spec/dummy/tmp/dragonfly/cache/body/39/36d756ac37cbfd7995a8413c5b813623f8c1d6 +0 -496
  188. data/spec/dummy/tmp/dragonfly/cache/body/39/c79f94952d16de5de0ec59089d381ace6e386e +0 -1029
  189. data/spec/dummy/tmp/dragonfly/cache/body/3f/457b87cdc17162db48461cf72c87457ebe753b +0 -1011
  190. data/spec/dummy/tmp/dragonfly/cache/body/40/d745dd4044031ccd76b4f5a8ad46e3c16ea8c0 +0 -915
  191. data/spec/dummy/tmp/dragonfly/cache/body/42/bb515c02767a37104eca97f75df3b4a49e1759 +0 -242
  192. data/spec/dummy/tmp/dragonfly/cache/body/43/1a5a2dc62c3b453378dad049c48fcf36928f53 +0 -2342
  193. data/spec/dummy/tmp/dragonfly/cache/body/43/abfe6e68d8603f92084533b5f94fb717bc2b02 +0 -700
  194. data/spec/dummy/tmp/dragonfly/cache/body/44/65e89dffc7531e6479a00711d7bf430c56754f +0 -2359
  195. data/spec/dummy/tmp/dragonfly/cache/body/47/1092abd16e44c60537ac674b871481ca6d108e +0 -489
  196. data/spec/dummy/tmp/dragonfly/cache/body/47/befec7e863f30488d1c9a72619411e3c311eea +0 -552
  197. data/spec/dummy/tmp/dragonfly/cache/body/48/4af0743c55ececa9e2b3477a666492914d5a25 +0 -700
  198. data/spec/dummy/tmp/dragonfly/cache/body/48/5935b1ceed38545d44989a5464049018f63ecd +0 -926
  199. data/spec/dummy/tmp/dragonfly/cache/body/48/cf4eb3ec838cdab2af24f4603e7954ab5012ee +0 -0
  200. data/spec/dummy/tmp/dragonfly/cache/body/4a/72b5c050f6e3702f880e19fcf37793c135cd3d +0 -0
  201. data/spec/dummy/tmp/dragonfly/cache/body/4a/db06a6fda9b3fbe12beb6816390a4fd61e4491 +0 -667
  202. data/spec/dummy/tmp/dragonfly/cache/body/4b/088deec20739cb75b3d8e2ca591171b342026d +0 -862
  203. data/spec/dummy/tmp/dragonfly/cache/body/4b/ea67064045b150fdd661d9b25fe1c447df7570 +0 -703
  204. data/spec/dummy/tmp/dragonfly/cache/body/50/8888bca37caef9e8ecf9434f304d1ab2cc820a +0 -538
  205. data/spec/dummy/tmp/dragonfly/cache/body/54/862500a3c1ce6a605de340ded6051d9d6c96dc +0 -880
  206. data/spec/dummy/tmp/dragonfly/cache/body/55/a3a5731c805bf0c5deda35500598030e91caf7 +0 -2358
  207. data/spec/dummy/tmp/dragonfly/cache/body/56/50f6edaa5e2fe07797333404d13fe63360f72c +0 -0
  208. data/spec/dummy/tmp/dragonfly/cache/body/56/dfa139236a6fcecf0fdd13308a17d03666d223 +0 -2361
  209. data/spec/dummy/tmp/dragonfly/cache/body/58/d135dda5118408bf76a2b381ac0d482276ee97 +0 -546
  210. data/spec/dummy/tmp/dragonfly/cache/body/59/0b00b9579bdc8d199e42d68cc83ee72ba6036a +0 -712
  211. data/spec/dummy/tmp/dragonfly/cache/body/59/c6cdda1534cfeb69aed8a295fa36aa0b34d9ac +0 -882
  212. data/spec/dummy/tmp/dragonfly/cache/body/5c/c982746925609ae2ddd24d20e9f96247006dc3 +0 -883
  213. data/spec/dummy/tmp/dragonfly/cache/body/5f/033e3fda7f0149729cdeba2807ccad0ce6ea32 +0 -1016
  214. data/spec/dummy/tmp/dragonfly/cache/body/5f/95bdb3eb07339f50a73c3e2c38d619b2321902 +0 -2361
  215. data/spec/dummy/tmp/dragonfly/cache/body/60/92cdccc969bab02d35b702148409d59276ec8e +0 -703
  216. data/spec/dummy/tmp/dragonfly/cache/body/61/e9711fd55eccdf62882cb8d127b22664f7023f +0 -3
  217. data/spec/dummy/tmp/dragonfly/cache/body/62/d3974c45b38586ded0f6adefcefeb4e25aea08 +0 -2357
  218. data/spec/dummy/tmp/dragonfly/cache/body/63/9cff6d42d49aaded2e3201d0b311fb0c4d5af5 +0 -872
  219. data/spec/dummy/tmp/dragonfly/cache/body/65/b3251b1348841946320cd8ac140a7a10a07de5 +0 -894
  220. data/spec/dummy/tmp/dragonfly/cache/body/66/59b5c1535bed3649f05f378f9a935a9369a14f +0 -2341
  221. data/spec/dummy/tmp/dragonfly/cache/body/67/8611d272ec29fc5cb7a63a709a12f47da63fbd +0 -538
  222. data/spec/dummy/tmp/dragonfly/cache/body/68/9bc64959e48ba446c2a48a48952d4e6e422bee +0 -2334
  223. data/spec/dummy/tmp/dragonfly/cache/body/6a/0be367e94b672cef188ef8c3261ed63fa59e6d +0 -701
  224. data/spec/dummy/tmp/dragonfly/cache/body/6a/1642bac93ee93e5ca10af933c39f6db9e15508 +0 -0
  225. data/spec/dummy/tmp/dragonfly/cache/body/6a/4558d01c325e63bfe9abe3df6b1255e51a20e6 +0 -703
  226. data/spec/dummy/tmp/dragonfly/cache/body/6b/8df0f17fd3ce7a7e551e91f30909a847a2abee +0 -734
  227. data/spec/dummy/tmp/dragonfly/cache/body/6b/90cf2c21e1934876d420d2524fe5216c5e7bf1 +0 -551
  228. data/spec/dummy/tmp/dragonfly/cache/body/6d/d8a547a0125a1da2df83e6b2f4c36631a1bd2f +0 -538
  229. data/spec/dummy/tmp/dragonfly/cache/body/6e/a8d288ea6931b9277121b209ac32959b717029 +0 -882
  230. data/spec/dummy/tmp/dragonfly/cache/body/6f/b27a907116ff2fa7a668b30d49b65885a09022 +0 -1016
  231. data/spec/dummy/tmp/dragonfly/cache/body/71/01bff740c639a7b8383a5e247ece9552656acb +0 -708
  232. data/spec/dummy/tmp/dragonfly/cache/body/73/7752ee519e2ee8c13b4c9165fb98c19a874843 +0 -882
  233. data/spec/dummy/tmp/dragonfly/cache/body/74/98c8a3bb6ee03af2b6952e797e632938d84649 +0 -237
  234. data/spec/dummy/tmp/dragonfly/cache/body/74/c9b1fca6f96048f555aed33ddb5c5240839f62 +0 -793
  235. data/spec/dummy/tmp/dragonfly/cache/body/75/01f0f946848c6b910634bed2a58e748dd0a4d2 +0 -986
  236. data/spec/dummy/tmp/dragonfly/cache/body/75/15881fe428cd4b04438de4e03ba3acc7cd789e +0 -642
  237. data/spec/dummy/tmp/dragonfly/cache/body/77/02b8ae247e83a86e819b150375bd2971911635 +0 -882
  238. data/spec/dummy/tmp/dragonfly/cache/body/77/78d2df49ed1274a18f2c479b5747a91417458f +0 -490
  239. data/spec/dummy/tmp/dragonfly/cache/body/79/0ba4208b6b095e78b15c6f2c4ef04b9e568fdf +0 -976
  240. data/spec/dummy/tmp/dragonfly/cache/body/7a/40b3b7e48d2fb4f8dc6b9ce3b2c6414cd3db4b +0 -638
  241. data/spec/dummy/tmp/dragonfly/cache/body/7a/44fbc7caa954feca99ae14cdd31700f3bc01ca +0 -0
  242. data/spec/dummy/tmp/dragonfly/cache/body/81/1412d99f15c17d9a52618013667ddc6acbb5e7 +0 -560
  243. data/spec/dummy/tmp/dragonfly/cache/body/82/bb0ce1f6b156348edb5d054b09681adbb1541c +0 -638
  244. data/spec/dummy/tmp/dragonfly/cache/body/82/f4aef50c7d0580ce3de59af781988f8c027e31 +0 -0
  245. data/spec/dummy/tmp/dragonfly/cache/body/84/3bafbd4a01aaae5795b68c2a21561fd78e8bfb +0 -0
  246. data/spec/dummy/tmp/dragonfly/cache/body/84/61cb5340e22fb0e266e5276613f5b218b793c0 +0 -774
  247. data/spec/dummy/tmp/dragonfly/cache/body/87/452e47dc8c565d70543b6a8b3aeeeafef5ede6 +0 -1008
  248. data/spec/dummy/tmp/dragonfly/cache/body/8e/46450213e0599dab4f0033c16b21731ca5e19c +0 -242
  249. data/spec/dummy/tmp/dragonfly/cache/body/8e/6921af9cd9a9aa0cb4a521be98d497ff7fdeaf +0 -700
  250. data/spec/dummy/tmp/dragonfly/cache/body/8e/d1fec3f23b9477057019f581847f7f8b2051c3 +0 -0
  251. data/spec/dummy/tmp/dragonfly/cache/body/8f/e7d4976bf7e183cf4f6ab9409f8503351dad3c +0 -709
  252. data/spec/dummy/tmp/dragonfly/cache/body/90/1abfe79ed8fa57b0f367b8d6cc284742d74bd9 +0 -703
  253. data/spec/dummy/tmp/dragonfly/cache/body/93/fe1fa30d5fe0cb493dd11ea6eaee9201b50cd8 +0 -712
  254. data/spec/dummy/tmp/dragonfly/cache/body/94/7a175f9de08b84499763ba6cc25f6911ef315e +0 -913
  255. data/spec/dummy/tmp/dragonfly/cache/body/98/2828d5b0867095317a017415955ef31a50dbc5 +0 -1014
  256. data/spec/dummy/tmp/dragonfly/cache/body/98/f06faf5cfff9a92b4d99d400523e1f1551742e +0 -1007
  257. data/spec/dummy/tmp/dragonfly/cache/body/99/2dab09135d5fcbaa2c2b833a8284cb56be5c26 +0 -1014
  258. data/spec/dummy/tmp/dragonfly/cache/body/99/b545fe8ab3b930d8997fd75bb08feea0c9754d +0 -915
  259. data/spec/dummy/tmp/dragonfly/cache/body/9a/ff030c94bb0fbe5d9fbb8cf6865236cb7d74b2 +0 -217
  260. data/spec/dummy/tmp/dragonfly/cache/body/9f/8083640216ee29b9e8b4f10990f33d94aa352c +0 -2360
  261. data/spec/dummy/tmp/dragonfly/cache/body/9f/f4d177f296f259ff4ef3ddb38583daaf7c4dad +0 -1011
  262. data/spec/dummy/tmp/dragonfly/cache/body/a0/13144afc0d13219dad65508b046b9e0693a22b +0 -926
  263. data/spec/dummy/tmp/dragonfly/cache/body/a1/44a32dab1df021f54bf212d2a401b7fc69a2d8 +0 -882
  264. data/spec/dummy/tmp/dragonfly/cache/body/a2/7996e882d74e2e2c590fbfee8a8842b43f5c5e +0 -1014
  265. data/spec/dummy/tmp/dragonfly/cache/body/a2/e9ac7eba6c9ac611ec0cb7f26cbe0711b4b59c +0 -694
  266. data/spec/dummy/tmp/dragonfly/cache/body/a3/cd2fc5aabd1c551bba7f290844b8d89c94ab1e +0 -523
  267. data/spec/dummy/tmp/dragonfly/cache/body/a4/1a483a32348565e7afc810f49f55c1a9cbcd5d +0 -707
  268. data/spec/dummy/tmp/dragonfly/cache/body/a4/2e62d48de5370a8402707dd02fcf64039923b4 +0 -0
  269. data/spec/dummy/tmp/dragonfly/cache/body/a5/ddf1a8e968d20390ab06c94b19eb69a1e81ad7 +0 -908
  270. data/spec/dummy/tmp/dragonfly/cache/body/a6/f516919f720c81c119adadf1693ea44e5b90fe +0 -490
  271. data/spec/dummy/tmp/dragonfly/cache/body/a8/5137398b4d62aacbb0921f50eb9f62e7ec8de4 +0 -0
  272. data/spec/dummy/tmp/dragonfly/cache/body/a8/85ba08a1465f458ec2e999aecc73ba6b885520 +0 -1575
  273. data/spec/dummy/tmp/dragonfly/cache/body/a8/fb555a7e2420a17ce30758861ac3de784677eb +0 -1011
  274. data/spec/dummy/tmp/dragonfly/cache/body/ab/c30526420462e4081de3dcbc7598a7930bbc51 +0 -0
  275. data/spec/dummy/tmp/dragonfly/cache/body/b0/9703b98c965449cfbff801b8482e5c2c9b1b50 +0 -954
  276. data/spec/dummy/tmp/dragonfly/cache/body/b1/4c0f9e41101026eff8ebdc3fc9eae61c25372b +0 -700
  277. data/spec/dummy/tmp/dragonfly/cache/body/b2/f1d81a83ca37d428780d1d9deb87cf0312cb62 +0 -0
  278. data/spec/dummy/tmp/dragonfly/cache/body/b3/d870794114f8ce678eeeddb0616abbea93ec7b +0 -562
  279. data/spec/dummy/tmp/dragonfly/cache/body/b4/1d331b6f64144bdee2ab598fd7f5ed2bcb6c3c +0 -0
  280. data/spec/dummy/tmp/dragonfly/cache/body/b4/84edbbb2dae5a5fc1cbfc8c8d3517bd1466a1b +0 -2359
  281. data/spec/dummy/tmp/dragonfly/cache/body/b5/52eaf4b5bac5fcf8667e5fb74f4b1c61984b0e +0 -537
  282. data/spec/dummy/tmp/dragonfly/cache/body/b6/9ec86cf5018fe63297e409da6638450c5041d2 +0 -0
  283. data/spec/dummy/tmp/dragonfly/cache/body/b7/31c759f6bf5b6adc13874d8ccf325a1715bf33 +0 -882
  284. data/spec/dummy/tmp/dragonfly/cache/body/b8/84c73fced17e1cb4f2efc18ed4f81789e5a622 +0 -0
  285. data/spec/dummy/tmp/dragonfly/cache/body/b9/43df43ad225c99d420cdb7e5d7714c2876273f +0 -1007
  286. data/spec/dummy/tmp/dragonfly/cache/body/b9/b4cb4d1647df4ec458ef3cc18782261a46bef2 +0 -641
  287. data/spec/dummy/tmp/dragonfly/cache/body/ba/1c57461ee48afadc870fca415b0e2aeaec3f4a +0 -882
  288. data/spec/dummy/tmp/dragonfly/cache/body/bb/cf048304dee182fc21ba43f408d8623c2f65b1 +0 -1721
  289. data/spec/dummy/tmp/dragonfly/cache/body/be/d14e3b72d93bfc0cace752edf21f5cc2af8949 +0 -2358
  290. data/spec/dummy/tmp/dragonfly/cache/body/c1/0767685a05c93f5e79a81ec5016820d7068afd +0 -281
  291. data/spec/dummy/tmp/dragonfly/cache/body/c2/d1fe276d6e527c155855e99dc19d239b6d71f3 +0 -7
  292. data/spec/dummy/tmp/dragonfly/cache/body/c3/5f95670b5171f06b0c450331c20ce59d44d5bd +0 -537
  293. data/spec/dummy/tmp/dragonfly/cache/body/c3/c76755904506b55cc288baed5e8f3ae767e1f9 +0 -908
  294. data/spec/dummy/tmp/dragonfly/cache/body/c7/48859071d0c1e701557a2b59181ae9d40b4c1c +0 -1029
  295. data/spec/dummy/tmp/dragonfly/cache/body/cc/e21614b70000b7a45bf382a696dfdf2e78811f +0 -1029
  296. data/spec/dummy/tmp/dragonfly/cache/body/cd/daa343d969732d44b9018e9e8403d758c1075b +0 -2334
  297. data/spec/dummy/tmp/dragonfly/cache/body/cd/dbba7b01cfb5eabf3c3b557d3cc1c7eeac9157 +0 -523
  298. data/spec/dummy/tmp/dragonfly/cache/body/d0/654133544a02cf512cdbe78256f913d684ee32 +0 -894
  299. data/spec/dummy/tmp/dragonfly/cache/body/d4/42ed09f48e3e24cd3cd958c9e0865df054419b +0 -1029
  300. data/spec/dummy/tmp/dragonfly/cache/body/d6/1d64e39570cd647cee3d3a62efa17ab2290d1e +0 -0
  301. data/spec/dummy/tmp/dragonfly/cache/body/d6/1eefad56108f5a8e1fa7aa72ff9b9f9cd633fc +0 -538
  302. data/spec/dummy/tmp/dragonfly/cache/body/d6/d1ac8848c469cd9094fa75b7528e0f5b6b632e +0 -496
  303. data/spec/dummy/tmp/dragonfly/cache/body/d7/899077450ebef4fdc0e9bb929825299f54457f +0 -697
  304. data/spec/dummy/tmp/dragonfly/cache/body/d9/f0d58e806b8697218740130d2ca12b3b86d6ef +0 -1007
  305. data/spec/dummy/tmp/dragonfly/cache/body/da/378953b0532aa6da1fa92abeeae89199ef8227 +0 -1006
  306. data/spec/dummy/tmp/dragonfly/cache/body/da/7c689c2f3a69f6770b63b71a8e71b6a1a28b37 +0 -967
  307. data/spec/dummy/tmp/dragonfly/cache/body/da/e26a3a67f1a9ea2332232ea28c90082c0e3bad +0 -963
  308. data/spec/dummy/tmp/dragonfly/cache/body/dc/abdd743fd3e9d7bd5647abeb86e66a3e6f9597 +0 -0
  309. data/spec/dummy/tmp/dragonfly/cache/body/e0/85f72a9f92bfadac77ceb40b9dcce7f1d0c0b4 +0 -712
  310. data/spec/dummy/tmp/dragonfly/cache/body/e1/f71dadeca1e7e8044d7ffe33168a41cf4b915e +0 -712
  311. data/spec/dummy/tmp/dragonfly/cache/body/e3/5e3eeacd0fa04028277861a7e20aca055126bf +0 -705
  312. data/spec/dummy/tmp/dragonfly/cache/body/e7/71af29ca1fb912746c2a8c252ce2dbda293797 +0 -0
  313. data/spec/dummy/tmp/dragonfly/cache/body/eb/d3df10f28dd5eb3361f2dea07bce8f31883cb4 +0 -562
  314. data/spec/dummy/tmp/dragonfly/cache/body/ef/f130cc312268f0864d651bb53d4f83189b925a +0 -9267
  315. data/spec/dummy/tmp/dragonfly/cache/body/f2/0000c07c049d6b02b83c134a47f79d25c8f884 +0 -1006
  316. data/spec/dummy/tmp/dragonfly/cache/body/f3/81eaa388ae0115314da5ef3dff86dde481f6ea +0 -1011
  317. data/spec/dummy/tmp/dragonfly/cache/body/f4/f597679294dfce3758a1e23f8739ddadb7a07a +0 -905
  318. data/spec/dummy/tmp/dragonfly/cache/body/f6/5638ff81bbc2e264c25be9224311d5b88e199e +0 -696
  319. data/spec/dummy/tmp/dragonfly/cache/body/f8/4c49b7e7f1df8b9bf194c8e4f238965275a470 +0 -638
  320. data/spec/dummy/tmp/dragonfly/cache/body/f8/bce7bef222715dce37713e4b658bb432746046 +0 -642
  321. data/spec/dummy/tmp/dragonfly/cache/body/fb/4bbd9bd1b55ea5c5f029a98429cbe84fecbd56 +0 -1029
  322. data/spec/dummy/tmp/dragonfly/cache/body/fb/54a1604f6c72b35d8b9c3da9f3899d77db70dd +0 -1834
  323. data/spec/dummy/tmp/dragonfly/cache/body/fe/83a325403c35319d9539703bf8b707c48cbb81 +0 -700
  324. data/spec/dummy/tmp/dragonfly/cache/meta/0b/a9c9bfcc4c3c931157c0740283f9879ffbc80e +0 -0
  325. data/spec/dummy/tmp/dragonfly/cache/meta/16/82dfe14b1caadf556cccc78e6742ecba3c8f50 +0 -0
  326. data/spec/dummy/tmp/dragonfly/cache/meta/18/2807a34d96c2dc102f1c7f2c2fe2a3dea0152a +0 -0
  327. data/spec/dummy/tmp/dragonfly/cache/meta/1b/df42876b5661f82d4041d818e787e2f58949e7 +0 -0
  328. data/spec/dummy/tmp/dragonfly/cache/meta/1d/f723c27427056dd58a506f1e4f15020442098e +0 -0
  329. data/spec/dummy/tmp/dragonfly/cache/meta/22/66939b783406813e2f0a76f3a2f29473675994 +0 -0
  330. data/spec/dummy/tmp/dragonfly/cache/meta/23/4f7740cb6118c7c530ce379339a99828a75ef3 +0 -0
  331. data/spec/dummy/tmp/dragonfly/cache/meta/26/25fc31c2b02071c5c60621d36793dc55fdb33c +0 -0
  332. data/spec/dummy/tmp/dragonfly/cache/meta/29/717968cc2fa016a4911e7161b6423235f36c87 +0 -0
  333. data/spec/dummy/tmp/dragonfly/cache/meta/2d/83e1c5e84c02b8fee05b62d483999bfaba7be0 +0 -0
  334. data/spec/dummy/tmp/dragonfly/cache/meta/2d/b7fe2b8774fa388daa3c8370f34052119b4222 +0 -0
  335. data/spec/dummy/tmp/dragonfly/cache/meta/2d/fe381b58b48b16278672bd61db736e4e920955 +0 -0
  336. data/spec/dummy/tmp/dragonfly/cache/meta/32/e0d3566d2be50daabce5a94c515f772050829b +0 -0
  337. data/spec/dummy/tmp/dragonfly/cache/meta/38/5bb4a3ceace256ca114fc14a3c5ae12ec83fb0 +0 -0
  338. data/spec/dummy/tmp/dragonfly/cache/meta/39/b52b68255f54efe8cb853fd153088f94a7661a +0 -0
  339. data/spec/dummy/tmp/dragonfly/cache/meta/3e/0173e72157b702c4926d190389540028b0ae1d +0 -0
  340. data/spec/dummy/tmp/dragonfly/cache/meta/52/a111bad2ef8c87af7f55baf0ffc5cdefc446e4 +0 -0
  341. data/spec/dummy/tmp/dragonfly/cache/meta/55/32c60f25996b8e8a9fdf7125956c5204fa8792 +0 -0
  342. data/spec/dummy/tmp/dragonfly/cache/meta/64/61f1782e6f9ec4e6416c0aec429529ea70a1a1 +0 -0
  343. data/spec/dummy/tmp/dragonfly/cache/meta/66/b6e26427e56a9f9ade00d4cf5d615679f0f7a7 +0 -0
  344. data/spec/dummy/tmp/dragonfly/cache/meta/66/f44aba1428593600ff0e47ea6aa54362e39a59 +0 -0
  345. data/spec/dummy/tmp/dragonfly/cache/meta/6d/f4ba8735866613f9b640f6a0cc8e4583eba1f9 +0 -0
  346. data/spec/dummy/tmp/dragonfly/cache/meta/78/d74c0cd05a77c0c06acb622761d30c9ea00bb3 +0 -0
  347. data/spec/dummy/tmp/dragonfly/cache/meta/7a/6033b3a3f17fbddc765d138d39de24f94f0965 +0 -0
  348. data/spec/dummy/tmp/dragonfly/cache/meta/7a/d6666861b23fcf6c7ea45d61810fdb1c14d9d0 +0 -0
  349. data/spec/dummy/tmp/dragonfly/cache/meta/80/5841ac20acdd8dd41460c8346294abc5c4dd8f +0 -0
  350. data/spec/dummy/tmp/dragonfly/cache/meta/83/5df7873207b08f78fd9d690e5a0b759242b937 +0 -0
  351. data/spec/dummy/tmp/dragonfly/cache/meta/83/696c30e03b7215b60e076bc528c8829ddcc516 +0 -0
  352. data/spec/dummy/tmp/dragonfly/cache/meta/83/b01df8c183f9586aff3f30bd22f4c24793c52b +0 -0
  353. data/spec/dummy/tmp/dragonfly/cache/meta/85/289eb541e97e28d96dacfd07c314be3beb566a +0 -0
  354. data/spec/dummy/tmp/dragonfly/cache/meta/8c/1a23bf2dd650d0327255a5fe948c325d350107 +0 -0
  355. data/spec/dummy/tmp/dragonfly/cache/meta/8f/5281faf3f227ef4bbbd3b644cc9eafc86ff9b1 +0 -0
  356. data/spec/dummy/tmp/dragonfly/cache/meta/91/0922a2bd8308a75961dac5733d4907df678f65 +0 -0
  357. data/spec/dummy/tmp/dragonfly/cache/meta/92/8e4f3f982b856114506c590c291dea7f0c29d7 +0 -0
  358. data/spec/dummy/tmp/dragonfly/cache/meta/92/99ecbc80a7e8abcc02a36d9c3365b23b1a5b1a +0 -0
  359. data/spec/dummy/tmp/dragonfly/cache/meta/98/00e4dc8c2a89849e9d3cb8dd37f8c45d744dd3 +0 -0
  360. data/spec/dummy/tmp/dragonfly/cache/meta/9d/4531b3a9ffdee2c2b2b485675e8b055a2de25f +0 -0
  361. data/spec/dummy/tmp/dragonfly/cache/meta/a2/5920380e48276ad6f8bc26fb9a4a527db839c8 +0 -0
  362. data/spec/dummy/tmp/dragonfly/cache/meta/b7/407b5584752ca5298158a78be896bf810dd4e0 +0 -0
  363. data/spec/dummy/tmp/dragonfly/cache/meta/b7/ae83f0c4d7b4849a78af8830c31ffe4b166b52 +0 -0
  364. data/spec/dummy/tmp/dragonfly/cache/meta/d2/458b4acc8a67ee57346f1f4ebfa0f0e4bb4ea3 +0 -0
  365. data/spec/dummy/tmp/dragonfly/cache/meta/d5/341018026448c1d4f56801bd7ddb8380e1a73c +0 -0
  366. data/spec/dummy/tmp/dragonfly/cache/meta/e7/6d1dc2d45d19440e781f6c5d00f39d8aeb4da1 +0 -0
  367. data/spec/dummy/tmp/dragonfly/cache/meta/ee/fe74949a8c2a0bbc077385a12944d9f98a12e0 +0 -0
  368. data/spec/dummy/tmp/dragonfly/cache/meta/ef/d71b44567b90c7f85e9bd0576e4b7e55bd3565 +0 -0
  369. data/spec/dummy/tmp/dragonfly/cache/meta/f4/2f71b4755920b57e574c91123765511a8f0b25 +0 -0
  370. data/spec/dummy/tmp/dragonfly/cache/meta/f5/b1288f6769945a2de532e359e061896e1197df +0 -0
  371. data/spec/dummy/tmp/dragonfly/cache/meta/f9/67ac04386c59253bd80f4034d18af166cc5691 +0 -0
  372. data/spec/dummy/tmp/sass-cache/6e61637ec8d1d247724328e8c4a6704fe36b468e/_hacks.scssc +0 -0
  373. data/spec/dummy/tmp/sass-cache/77824dc1336af71703311a2e58b21a32c1511e63/_border-radius.scssc +0 -0
  374. data/spec/dummy/tmp/sass-cache/77824dc1336af71703311a2e58b21a32c1511e63/_box-shadow.scssc +0 -0
  375. data/spec/dummy/tmp/sass-cache/77824dc1336af71703311a2e58b21a32c1511e63/_gradient.scssc +0 -0
  376. data/spec/dummy/tmp/sass-cache/77824dc1336af71703311a2e58b21a32c1511e63/_images.scssc +0 -0
  377. data/spec/dummy/tmp/sass-cache/77824dc1336af71703311a2e58b21a32c1511e63/_inline-block.scssc +0 -0
  378. data/spec/dummy/tmp/sass-cache/77824dc1336af71703311a2e58b21a32c1511e63/_shared.scssc +0 -0
  379. data/spec/dummy/tmp/sass-cache/bc54e898614d486bf9338d646e8cd056915d4779/buttons.css.scssc +0 -0
  380. data/spec/dummy/tmp/sass-cache/bc54e898614d486bf9338d646e8cd056915d4779/redactor.css.scssc +0 -0
  381. data/spec/dummy/tmp/sass-cache/d1a1c9c63df53223abb80676ef7dcc16c1375c54/_support.scssc +0 -0
@@ -1,1575 +0,0 @@
1
- /*
2
- Redactor v7.2.0
3
- Updated 20.11.2011
4
-
5
- In English http://imperavi.com/
6
- In Russian http://imperavi.ru/
7
-
8
- Copyright (c) 2009-2012, Imperavi Ltd.
9
- Dual licensed under the MIT or GPL Version 2 licenses.
10
-
11
- Usage: $('#content').redactor();
12
- */
13
-
14
-
15
- var isCtrl = false;
16
- var redactorActive = false;
17
-
18
- var $table = false;
19
- var $tbody = false;
20
- var $thead = false;
21
- var $current_tr = false;
22
- var $current_td = false;
23
-
24
- var deviceAndroid = "android";
25
- var uagent = navigator.userAgent.toLowerCase();
26
-
27
- // detect iOS and Android
28
- function isiOS() {
29
- return ((navigator.platform.indexOf("iPhone") != -1) || (navigator.platform.indexOf("iPod") != -1) || (navigator.platform.indexOf("iPad") != -1));
30
- }
31
-
32
- function detectAndroid() {
33
- return uagent.search(deviceAndroid) > -1
34
- }
35
-
36
- function detectAndroidWebKit() {
37
- if (detectAndroid()) {
38
- return uagent.search('webkit') > -1
39
- }
40
-
41
- return false;
42
- }
43
-
44
- // redactor
45
- (function($){
46
- // Initialization
47
- $.fn.redactor = function(options) {
48
- if (isiOS() || detectAndroid() || detectAndroidWebKit()) return false;
49
- var obj = new Construct(this, options);
50
- obj.init();
51
- return obj;
52
- };
53
-
54
- // Options and variables
55
- function Construct(el, options) {
56
- this.opts = $.extend({
57
- air : false,
58
- autosave : false, // false or url
59
- interval : 20, // seconds
60
- resize : true,
61
- visual : true,
62
- focus : false,
63
- autoclear : true,
64
- removeClasses : false,
65
- removeStyles : true,
66
- convertLinks : true,
67
- autoformat : true,
68
- clearOnInit : false,
69
- overlay : true, // modal overlay
70
- fileUploadCallback : false, // callback function
71
- imageUploadCallback : false, // callback function
72
-
73
- // Paths to various handlers
74
- paths : {
75
- // Editor css
76
- stylesheets : ['/assets/imperavi-rails/imperavi/wym.css'],
77
-
78
- // Toolbar
79
- toolbar : '/imperavi/toolbar.js',
80
-
81
- // Interface translations
82
- language : '/imperavi/language.js',
83
-
84
- // Typograf
85
- typograf : '/imperavi/typograf',
86
-
87
- // Dialogs
88
- // TODO Add dialogs sizes
89
- dialogs : {
90
- file : '/imperavi/file?r',
91
- fileEdit : '/imperavi/file_edit',
92
- image : '/imperavi/image?r',
93
- imageEdit : '/imperavi/image_edit',
94
- link : '/imperavi/link',
95
- table : '/imperavi/table',
96
- video : '/imperavi/video'
97
- },
98
-
99
- // Images
100
- images : {
101
- upload : '/imperavi/images',
102
- download : '/imperavi/images/777',
103
- list : '/imperavi/images.json'
104
- },
105
-
106
- // Files
107
- files : {
108
- upload : '/imperavi/files',
109
- download : '/imperavi/files/777', // /tests/file_download.php?file=
110
- remove : '/imperavi/files/777' // /tests/file_delete.php?delete=
111
- }
112
- }
113
- }, options);
114
-
115
- this.$el = $(el);
116
- };
117
-
118
- // Functionality
119
- Construct.prototype = {
120
- init: function() {
121
- if (this.opts.air) this.opts.toolbar = 'air';
122
-
123
- // include lang and toolbar
124
- this.include();
125
-
126
- // sizes and id
127
- this.frameID = this.$el.attr('id');
128
- this.width = this.$el.css('width');
129
- this.height = this.$el.css('height');
130
-
131
- // modal overlay
132
- if ($('#redactor_imp_modal_overlay').size() == 0) {
133
- this.overlay = $('<div id="redactor_imp_modal_overlay" style="display: none;"></div>');
134
- $('body').prepend(this.overlay);
135
- }
136
-
137
- // create container
138
- this.box = $('<div id="imp_redactor_box_' + this.frameID + '" style="width: ' + this.width + ';" class="imp_redactor_box imp_redactor_box"></div>');
139
-
140
- // air box
141
- if (this.opts.air) {
142
- this.air = $('<div id="imp_redactor_air_' + this.frameID + '" class="redactor_air" style="display: none;"></div>');
143
- }
144
-
145
- // create iframe
146
- this.frame = $('<iframe frameborder="0" marginheight="0" marginwidth="0" vspace="0" hspace="0" scrolling="auto" id="imp_redactor_frame_' + this.frameID + '" style="height: ' + this.height + ';" class="imp_redactor_frame"></iframe>');
147
-
148
- this.$el.hide();
149
-
150
- // append box and frame
151
- $(this.box).insertAfter(this.$el).append(this.frame).append(this.$el);
152
-
153
- // toolbar
154
- if (this.opts.toolbar !== false) this.buildToolbar();
155
-
156
- // resizer
157
- if (this.opts.resize) {
158
- this.resizer = $('<div id="imp_redactor_resize' + this.frameID + '" class="imp_redactor_resize"><div></div></div>');
159
- $(this.box).append(this.resizer);
160
-
161
- $(this.resizer).mousedown(function(e) { this.initResize(e) }.bind2(this));
162
- }
163
-
164
- // enable
165
- this.enable(this.$el.val());
166
-
167
- $(this.doc).click(function() { this.hideAllDropDown() }.bind2(this));
168
-
169
- if (this.opts.autoclear) {
170
- $(this.doc).bind('paste', function(e) {
171
- setTimeout(function () { this.clean(); }.bind2(this), 200);
172
- }.bind2(this));
173
- }
174
-
175
- // air enable
176
- this.enableAir();
177
-
178
- // doc events
179
- $(this.doc).keydown(function(e) {
180
- if (e.ctrlKey || e.metaKey) isCtrl = true;
181
- if (e.keyCode == 9) { this.execCommand('indent', false); return false; }
182
- if (e.keyCode == 66 && isCtrl) { this.execCommand('bold', 'bold'); return false; }
183
- if (e.keyCode == 73 && isCtrl) { this.execCommand('italic', 'italic'); return false; }
184
-
185
- }.bind2(this)).keyup(function(e) {
186
- isCtrl = false;
187
-
188
- if (e.keyCode == 13) {
189
- $(this.doc).linkify();
190
- return true;
191
- }
192
-
193
- this.syncCode();
194
- }.bind2(this));
195
-
196
- // autosave
197
- if (this.opts.autosave) {
198
- setInterval(function() {
199
- var html = this.getHtml();
200
- $.post(this.opts.autosave, { data: html });
201
- }.bind2(this), this.opts.interval*1000);
202
- }
203
-
204
- this.formSets();
205
-
206
- // focus
207
- if (this.opts.focus) this.focus();
208
- },
209
-
210
- /*
211
- API
212
- */
213
- setHtml: function(html) {
214
- this.doc.body.innerHTML = html;
215
- this.docObserve();
216
- },
217
-
218
- getHtml: function() {
219
- return this.doc.body.innerHTML;
220
- },
221
-
222
- getCode: function(clear) {
223
- return this.$el.val();
224
- },
225
-
226
- focus: function() {
227
- if ($.browser.msie) $(this.frame).load(function() { $(this).get(0).contentWindow.focus(); });
228
- else this.frame.get(0).contentWindow.focus();
229
- },
230
-
231
- typo: function() {
232
- var html = this.getHtml();
233
-
234
- $.ajax({
235
- url : this.opts.paths.typograf,
236
- type : 'post',
237
- data : 'redactor=' + escape(encodeURIComponent(html)),
238
- success: function(data) {
239
- this.setHtml(data);
240
- }.bind2(this)
241
- });
242
- },
243
-
244
- syncCode: function() {
245
- var html = this.getHtml();
246
-
247
- html = this.tidyUp(html);
248
- html = html.replace(/\%7B/gi, '{');
249
- html = html.replace(/\%7D/gi, '}');
250
- html = html.replace(/<hr class="redactor_cut">/gi, '<!--more-->');
251
- html = html.replace(/<hr class=redactor_cut>/gi, '<!--more-->');
252
- this.$el.val(html);
253
- },
254
-
255
- destroy: function() {
256
- var html = this.getCode();
257
- $(this.box).after(this.$el)
258
- this.box.remove();
259
- this.$el.val(html).show();
260
- },
261
-
262
- // Include
263
- include: function() {
264
- // lang
265
- $('head').append(
266
- $('<script src="' + this.opts.paths.language + '"></script>')
267
- );
268
-
269
- // toolbar
270
- // @tanraya
271
- if (this.opts.toolbar !== false) {
272
- $('head').append($('<script src="' + this.opts.paths.toolbar + '"></script>'));
273
- }
274
- },
275
-
276
- // Enable
277
- enable: function(html) {
278
- this.doc = this.contentDocumentFrame(this.frame);
279
-
280
- // flash replace
281
- html = html.replace(/\<object([\w\W]*?)\<\/object\>/gi, '<p class="redactor_video_box"><object$1</object></p>');
282
-
283
- if (html == '') {
284
- if (this.opts.autoformat === true) {
285
- html = $.browser.msie ? "<p></p>" : "<p>&nbsp;</p>";
286
- }
287
- }
288
-
289
- this.redactorWrite(this.getRedactorDoc(html));
290
- if (this.opts.clearOnInit) this.clean();
291
- this.designMode();
292
- },
293
-
294
- enableAir: function() {
295
- if (this.opts.air) {
296
- $('#imp_redactor_air_' + this.frameID).hide();
297
-
298
- $(this.doc).bind('textselect', this.frameID, function(e) {
299
- var width = $('#imp_redactor_air_' + this.frameID).width();
300
- var width_area = $(this.frame).width();
301
- var diff = width_area - e.clientX;
302
-
303
- if (diff < width) e.clientX = e.clientX - width;
304
-
305
- $('#imp_redactor_air_' + this.frameID).css({ left: e.clientX + 'px', top: (e.clientY + 8) + 'px' }).show();
306
-
307
- }.bind2(this));
308
-
309
- $(this.doc).bind('textunselect', this.frameID, function() {
310
- $('#imp_redactor_air_' + this.frameID).hide();
311
- }.bind2(this));
312
- }
313
- },
314
-
315
- redactorWrite: function(html) {
316
- this.doc.open();
317
- this.doc.write(html);
318
- this.doc.close();
319
- },
320
-
321
- getRedactorDoc: function(html) {
322
- css = '';
323
-
324
- for (stylesheet in this.opts.paths.stylesheets) {
325
- css += '<link media="all" href="' + this.opts.paths.stylesheets[stylesheet] + '" rel="stylesheet">';
326
- }
327
-
328
- var frameHtml = '<!DOCTYPE html>\n';
329
- frameHtml += '<html><head>' + css + '</head><body>';
330
- frameHtml += html;
331
- frameHtml += '</body></html>';
332
-
333
- return frameHtml;
334
- },
335
-
336
- contentDocumentFrame: function(frame) {
337
- frame = frame.get(0);
338
-
339
- if (frame.contentDocument) return frame.contentDocument;
340
- else if (frame.contentWindow && frame.contentWindow.document) return frame.contentWindow.document;
341
- else if (frame.document) return frame.document;
342
- else return null;
343
- },
344
-
345
- designMode: function() {
346
- if (this.doc) {
347
- this.doc.designMode = 'on';
348
- this.frame.load(function() {
349
- this.enableObjects();
350
- this.docObserve();
351
- this.doc.designMode = 'on';
352
- }.bind2(this));
353
- }
354
- },
355
-
356
- enableObjects: function() {
357
- if ($.browser.mozilla) {
358
- this.doc.execCommand("enableObjectResizing", false, "false");
359
- this.doc.execCommand("enableInlineTableEditing", false, "false");
360
- }
361
- },
362
-
363
-
364
- // Observers
365
- docObserve: function() {
366
- var body = $(this.doc).find('body');
367
-
368
- body.find('img').click(function(e) { this.imageEdit(e); }.bind2(this));
369
- body.find('table').click(function(e) { this.tableObserver(e); }.bind2(this));
370
- body.find('.redactor_file_link').click(function(e) { this.fileEdit(e); }.bind2(this));
371
-
372
- },
373
-
374
- // Format on submit form
375
- formSets: function() {
376
- var oldOnsubmit = null;
377
- var theForm = $(this.box).parents('form');
378
-
379
- if (theForm.length == 0) return false;
380
-
381
- oldOnsubmit = theForm.get(0).onsubmit;
382
-
383
- if (typeof theForm.get(0).onsubmit != "function") {
384
- theForm.get(0).onsubmit = function() {
385
- if (this.opts.visual) {
386
- this.syncCode();
387
- return true;
388
- }
389
- }.bind2(this)
390
- } else {
391
- theForm.get(0).onsubmit = function() {
392
- if (this.opts.visual) {
393
- this.syncCode();
394
- return oldOnsubmit();
395
- }
396
- }.bind2(this)
397
- }
398
-
399
- return true;
400
- },
401
-
402
- // Exec
403
- execCommand: function(cmd, param) {
404
- if (this.opts.visual && this.doc) {
405
- try {
406
- this.frame.get(0).contentWindow.focus();
407
-
408
- if (cmd == 'inserthtml' && $.browser.msie) {
409
- this.doc.selection.createRange().pasteHTML(param);
410
- } else {
411
- this.doc.execCommand(cmd, false, param);
412
-
413
- if (param == "blockquote" || param == 'pre')
414
- this.doc.body.appendChild(this.doc.createElement("BR"));
415
- }
416
- } catch (e) { }
417
-
418
- this.syncCode();
419
- if (this.opts.air) $('#imp_redactor_air_' + this.frameID).hide();
420
- }
421
- },
422
-
423
- // Format and clean
424
- clean: function() {
425
- var html = this.getHtml();
426
-
427
- if ($.browser.mozilla) html = this.convertSpan(html);
428
-
429
- // strip tags
430
- html = html.replace(/<(?!\s*\/?(a|br|p|b|i|strong|em|table|tr|td|th|tbody|thead|tfoot|h2|h3|h4)\b)[^>]+>/ig,"");
431
-
432
- if (this.opts.removeStyles) html = html.replace(/ style=".*?"/g, '');
433
- if (this.opts.removeClasses) html = html.replace(/ class=".*?"/g, '');
434
-
435
- html = this.tidyUp(html);
436
-
437
- this.setHtml(html);
438
- this.paragraphise();
439
-
440
- return html;
441
- },
442
-
443
- tidyUp: function (html) {
444
- // lowercase
445
- if ($.browser.msie)
446
- {
447
- html = html.replace(/< *(\/ *)?(\w+)/g,function(w){return w.toLowerCase()});
448
- html = html.replace(/ jQuery(.*?)=\"(.*?)\"/gi, '');
449
- }
450
-
451
- if (this.opts.convertLinks) html = this.convertLinks(html);
452
-
453
- html = html.replace(/[\t]*/g, '');
454
- html = html.replace(/[\r\n]*/g, '');
455
- html = html.replace(/\n\s*\n/g, "\n");
456
- html = html.replace(/^[\s\n]*/, '');
457
- html = html.replace(/[\s\n]*$/, '');
458
-
459
- var lb = '\r\n';
460
- var btags = ["<html","</html>","</head>","<title","</title>","<meta","<link","<style","</style>","</body>","<body","<head","<div","<p","<form","<fieldset","<label","</label>","<legend","</legend>","<object","</object>","<embed","</embed>","<select","</select>","<option","<option","<input","<textarea","</textarea>","</form>","</fieldset>","<br>","<br />","<hr","<pre","</pre>","<blockquote","</blockquote>","<ul","</ul>","<ol","</ol>","<li","<dl","</dl>","<dt","</dt>","<dd","</dd>","<\!--","<table","</table>","</thead>","<tbody","</tbody>","<caption","</caption>","<th","</th>","<tr","</tr>","<td","<script","</script>","<noscript","</noscript>"];
461
- for (i = 0; i < btags.length; ++i)
462
- {
463
- var bbb = btags[i];
464
- html = html.replace(new RegExp(bbb,'gi'),lb+bbb);
465
- }
466
-
467
- // indenting
468
- html = html.replace(/<li/g, "\t<li");
469
- html = html.replace(/<tr/g, "\t<tr");
470
- html = html.replace(/<td/g, "\t\t<td");
471
- html = html.replace(/<\/tr>/g, "\t</tr>");
472
-
473
- // empty tags
474
- var btags = ["<pre></pre>","<blockquote></blockquote>","<ul></ul>","<ol></ol>","<li></li>","<table></table>","<tr></tr>","<span><span>", "<p>&nbsp;</p>", "<p></p>", "<p><br></p>", "<div></div>"];
475
- for (i = 0; i < btags.length; ++i)
476
- {
477
- var bbb = btags[i];
478
- html = html.replace(new RegExp(bbb,'gi'), "");
479
- }
480
-
481
- return html;
482
- },
483
-
484
- convertLinks: function(html)
485
- {
486
- html = html.replace(/\<a(.*?)href="http:\/\/(.*?)"(.*?)>([\w\W]*?)\<\/a\>/gi, "<a$1href=\"rttp://$2\"$3>$4</a>");
487
- html = html.replace(/\<a(.*?)href="rttp:\/\/(.*?)"(.*?)>http:\/\/([\w\W]*?)\<\/a\>/gi, "<a$1href=\"rttp://$2\"$3>rttp:\/\/$4</a>");
488
-
489
- //var url1 = /(^|>|\s)(www\..+?\..+?)(\s|<|$)/g;
490
- var url2 = /(^|>|\s)(((https?|ftp):\/\/|mailto:).+?)(\s|<|$)/g;
491
-
492
- //html = html.replace(url1, '$1<a href="http://$2">$2</a>$3')
493
- html = html.replace(url2, '$1<a href="$2">$2</a>$5');
494
-
495
- html = html.replace(/\<a(.*?)href="rttp:\/\/(.*?)"(.*?)>([\w\W]*?)\<\/a\>/gi, "<a$1href=\"http://$2\"$3>$4</a>");
496
- html = html.replace(/\<a(.*?)href="http:\/\/(.*?)"(.*?)>rttp:\/\/([\w\W]*?)\<\/a\>/gi, "<a$1href=\"http://$2\"$3>http://$4</a>");
497
-
498
- return html;
499
- },
500
-
501
- convertSpan: function(html)
502
- {
503
- html = html.replace(/\<span(.*?)style="font-weight: bold;"\>([\w\W]*?)\<\/span\>/gi, "<strong>$2</strong>");
504
- html = html.replace(/\<span(.*?)style="font-style: italic;"\>([\w\W]*?)\<\/span\>/gi, "<em>$2</em>");
505
- html = html.replace(/\<span(.*?)style="font-weight: bold; font-style: italic;"\>([\w\W]*?)\<\/span\>/gi, "<em><strong>$2</strong></em>");
506
- html = html.replace(/\<span(.*?)style="font-style: italic; font-weight: bold;"\>([\w\W]*?)\<\/span\>/gi, "<strong><em>$2</em></strong>");
507
-
508
- return html;
509
- },
510
-
511
- /*
512
- Paragraphise
513
- */
514
- paragraphise: function()
515
- {
516
-
517
- if (this.opts.autoformat === false) return true;
518
- if (this.opts.visual)
519
- {
520
- var theBody = this.doc.body;
521
-
522
- /* Remove all text nodes containing just whitespace */
523
- for (var i = 0; i < theBody.childNodes.length; i++)
524
- {
525
- if (theBody.childNodes[i].nodeName.toLowerCase() == "#text" && theBody.childNodes[i].data.search(/^\s*$/) != -1)
526
- {
527
- theBody.removeChild(theBody.childNodes[i]);
528
- i--;
529
- }
530
- }
531
-
532
- var removedElements = new Array();
533
- for (var i = 0; i < theBody.childNodes.length; i++)
534
- {
535
- if (theBody.childNodes[i].nodeName.isInlineName())
536
- {
537
- removedElements.push(theBody.childNodes[i].cloneNode(true));
538
- theBody.removeChild(theBody.childNodes[i]);
539
- i--;
540
- }
541
- else if (theBody.childNodes[i].nodeName.toLowerCase() == "br")
542
- {
543
- if (i + 1 < theBody.childNodes.length)
544
- {
545
- if (theBody.childNodes[i + 1].nodeName.toLowerCase() == "br")
546
- {
547
- while (i < theBody.childNodes.length && theBody.childNodes[i].nodeName.toLowerCase() == "br")
548
- {
549
- theBody.removeChild(theBody.childNodes[i]);
550
- }
551
-
552
- if (removedElements.length > 0)
553
- {
554
- this.insertNewParagraph(removedElements, theBody.childNodes[i]);
555
- removedElements = new Array();
556
- }
557
- }
558
- else if (!theBody.childNodes[i + 1].nodeName.isInlineName()) theBody.removeChild(theBody.childNodes[i]);
559
- else if (removedElements.length > 0)
560
- {
561
- removedElements.push(theBody.childNodes[i].cloneNode(true));
562
- theBody.removeChild(theBody.childNodes[i]);
563
- }
564
- else theBody.removeChild(theBody.childNodes[i]);
565
- i--;
566
- }
567
- else theBody.removeChild(theBody.childNodes[i]);
568
- }
569
- else if (removedElements.length > 0)
570
- {
571
- this.insertNewParagraph(removedElements, theBody.childNodes[i]);
572
- removedElements = new Array();
573
- }
574
- }
575
-
576
- if (removedElements.length > 0) this.insertNewParagraph(removedElements);
577
- }
578
-
579
- return true;
580
- },
581
- insertNewParagraph: function(elementArray, succeedingElement)
582
- {
583
- var theBody = this.doc.getElementsByTagName("body")[0];
584
- var theParagraph = this.doc.createElement("p");
585
-
586
- for (var i = 0; i < elementArray.length; i++) theParagraph.appendChild(elementArray[i]);
587
-
588
- if (typeof(succeedingElement) != "undefined") theBody.insertBefore(theParagraph, succeedingElement);
589
- else theBody.appendChild(theParagraph);
590
-
591
- return true;
592
- },
593
-
594
- /*
595
- Selection
596
- */
597
- get_selection: function ()
598
- {
599
- if (this.frame.get(0).contentWindow.getSelection) return this.frame.get(0).contentWindow.getSelection();
600
- else if (this.frame.get(0).contentWindow.document.selection) return this.frame.contentWindow.get(0).document.selection.createRange();
601
- },
602
-
603
- setCut: function()
604
- {
605
- this.execCommand('inserthtml', '<hr class="redactor_cut" />');
606
- },
607
-
608
- /*
609
- Toggle
610
- */
611
- toggle: function()
612
- {
613
- if (this.opts.visual)
614
- {
615
- this.addSelButton('html');
616
-
617
- var html = this.getHtml();
618
-
619
- html = this.tidyUp(html);
620
-
621
- html = html.replace(/\%7B/gi, '{');
622
- html = html.replace(/\%7D/gi, '}');
623
-
624
- // flash replace
625
- html = html.replace(/<p(.*?)class="redactor_video_box"(.*?)>([\w\W]*?)\<\/p>/gi, "$3");
626
-
627
- // files replace
628
- html = html.replace(/<a(.*?)rel="(.*?)"(.*?)class="redactor_file_link(.*?)"(.*?)>([\w\W]*?)\<\/a>/gi, "<a href=\"" + this.opts.paths.files.download + "$2\" rel=\"$2\" class=\"redactor_file_link$4\">$6</a>");
629
-
630
- // cut replace
631
- html = html.replace(/<hr class="redactor_cut"\/>/gi, '<!--more-->');
632
- html = html.replace(/<hr class=redactor_cut>/gi, '<!--more-->');
633
-
634
-
635
- this.frame.hide();
636
- this.$el.val(html);
637
- this.$el.show().focus();
638
-
639
- var height = this.$el.height();
640
-
641
- this.opts.visual = false;
642
- }
643
- else
644
- {
645
- this.removeSelButton('html');
646
- this.$el.hide();
647
-
648
- var html = this.$el.val();
649
-
650
- // cut replace
651
- html = html.replace(/<!--more-->/gi, '<hr class="redactor_cut"/>');
652
-
653
- // flash replace
654
- html = html.replace(/\<object([\w\W]*?)\<\/object\>/gi, '<p class="redactor_video_box"><object$1</object></p>');
655
-
656
- // files replace
657
- html = html.replace(/<a(.*?)href="(.*?)"(.*?)rel="(.*?)"(.*?)class="redactor_file_link(.*?)">(.*?)<\/a>/gi, "<a href=\"javascript:void(null);\" rel=\"$4\" class=\"redactor_file_link$6\">$7</a>");
658
-
659
-
660
- this.opts.visual = true;
661
-
662
- this.setHtml(html);
663
-
664
- this.frame.show();
665
- this.focus();
666
- }
667
- },
668
-
669
-
670
- /*
671
- Video
672
- */
673
- showVideo: function()
674
- {
675
- redactorActive = this;
676
- this.modalInit(RLANG.video, this.opts.paths.dialogs.video, 600, 360, function()
677
- {
678
- $('#redactor_insert_video_area').focus();
679
- });
680
- },
681
- insertVideo: function()
682
- {
683
- var data = $('#redactor_insert_video_area').val();
684
- if (redactorActive.opts.visual)
685
- {
686
- // iframe video
687
- if (data.search('iframe')) {}
688
- // flash
689
- else data = '<p class="redactor_video_box">' + data + '</p>';
690
- }
691
-
692
- redactorActive.execCommand('inserthtml', data);
693
- this.modalClose();
694
-
695
- },
696
-
697
-
698
-
699
- /*
700
- File
701
- */
702
- showFile: function()
703
- {
704
- redactorActive = this;
705
-
706
- var handler = function()
707
- {
708
- // upload params
709
- var params = '';
710
- if (this.opts.fileUploadCallback) params = this.opts.fileUploadCallback();
711
-
712
- $('#redactor_file').dragupload(
713
- {
714
- url: this.opts.paths.files.upload + params,
715
- success: function(data)
716
- {
717
- this.fileUploadCallback(data);
718
-
719
- }.bind2(this)
720
- });
721
-
722
- this.uploadInit('redactor_file', { auto: true, url: this.opts.paths.files.upload + params, success: function(data) {
723
-
724
- this.fileUploadCallback(data);
725
-
726
- }.bind2(this) });
727
-
728
-
729
- }.bind2(this);
730
-
731
-
732
- redactorActive = this;
733
- this.modalInit(RLANG.file, this.opts.paths.dialogs.file, 500, 400, handler);
734
- },
735
- fileUploadCallback: function(data)
736
- {
737
- redactorActive.frame.get(0).contentWindow.focus();
738
- redactorActive.execCommand('inserthtml', data);
739
- this.modalClose();
740
- this.docObserve();
741
- },
742
- fileEdit: function(e)
743
- {
744
- var el = e.target;
745
- var file_id = $(el).attr('rel');
746
-
747
- var handler = function()
748
- {
749
- $('#file').val($(el).text());
750
- $('#redactorFileDeleteBtn').click(function()
751
- {
752
- this.fileDelete(el, file_id);
753
- }.bind2(this));
754
-
755
- $('#redactorFileDownloadBtn').click(function()
756
- {
757
- this.fileDownload(el, file_id);
758
- }.bind2(this));
759
-
760
- }.bind2(this);
761
-
762
- redactorActive = this;
763
- this.modalInit(RLANG.file, this.opts.paths.dialogs.fileEdit, 400, 200, handler);
764
- },
765
- fileDelete: function(el, file_id)
766
- {
767
- $(el).remove();
768
- $.get(this.opts.paths.files.remove + file_id);
769
- redactorActive.frame.get(0).contentWindow.focus();
770
- this.modalClose();
771
- },
772
- fileDownload: function(el, file_id)
773
- {
774
- top.location.href = this.opts.paths.files.download + file_id;
775
- },
776
-
777
- /*
778
- Table
779
- */
780
- showTable: function()
781
- {
782
- redactorActive = this;
783
- this.modalInit(RLANG.table, this.opts.paths.dialogs.table, 360, 200);
784
- },
785
- insertTable: function()
786
- {
787
- var rows = $('#redactor_table_rows').val();
788
- var columns = $('#redactor_table_columns').val();
789
-
790
- var table_box = $('<div></div>');
791
-
792
- var tableid = Math.floor(Math.random() * 99999);
793
- var table = $('<table id="table' + tableid + '"><tbody></tbody></table>');
794
-
795
- for (i = 0; i < rows; i++)
796
- {
797
- var row = $('<tr></tr>')
798
- for (z = 0; z < columns; z++)
799
- {
800
- var column = $('<td>&nbsp;</td>');
801
- $(row).append(column);
802
- }
803
- $(table).append(row);
804
- }
805
-
806
- $(table_box).append(table);
807
- var html = $(table_box).html();
808
- if ($.browser.msie) html += '<p></p>';
809
- else html += '<p>&nbsp;</p>';
810
-
811
- redactorActive.execCommand('inserthtml', html);
812
- this.enableObjects();
813
- this.docObserve();
814
- this.modalClose();
815
-
816
- $table = $(this.doc).find('body').find('#table' + tableid);
817
-
818
-
819
- },
820
- tableObserver: function(e)
821
- {
822
- $table = $(e.target).parents('table');
823
-
824
- $tbody = $(e.target).parents('tbody');
825
- $thead = $($table).find('thead');
826
-
827
- $current_td = $(e.target);
828
- $current_tr = $(e.target).parents('tr');
829
- },
830
- deleteTable: function()
831
- {
832
- $($table).remove();
833
- $table = false;
834
- },
835
- deleteRow: function()
836
- {
837
- $($current_tr).remove();
838
- },
839
- deleteColumn: function()
840
- {
841
- var index = $($current_td).attr('cellIndex');
842
-
843
- $($table).find('tr').each(function()
844
- {
845
- $(this).find('td').eq(index).remove();
846
- });
847
- },
848
- addHead: function()
849
- {
850
- if ($($table).find('thead').size() != 0) this.deleteHead();
851
- else
852
- {
853
- var tr = $($table).find('tr').first().clone();
854
- tr.find('td').html('&nbsp;');
855
- $thead = $('<thead></thead>');
856
- $thead.append(tr);
857
- $($table).prepend($thead);
858
- }
859
- },
860
- deleteHead: function()
861
- {
862
- $($thead).remove();
863
- $thead = false;
864
- },
865
- insertRowAbove: function()
866
- {
867
- this.insertRow('before');
868
- },
869
- insertRowBelow: function()
870
- {
871
- this.insertRow('after');
872
- },
873
- insertColumnLeft: function()
874
- {
875
- this.insertColumn('before');
876
- },
877
- insertColumnRight: function()
878
- {
879
- this.insertColumn('after');
880
- },
881
- insertRow: function(type)
882
- {
883
- var new_tr = $($current_tr).clone();
884
- new_tr.find('td').html('&nbsp;');
885
- if (type == 'after') $($current_tr).after(new_tr);
886
- else $($current_tr).before(new_tr);
887
- },
888
- insertColumn: function(type)
889
- {
890
- var index = $($current_td).attr('cellIndex');
891
-
892
- $($table).find('tr').each(function(i,s)
893
- {
894
- var current = $(s).find('td').eq(index);
895
- var td = current.clone();
896
- td.html('&nbsp;');
897
- if (type == 'after') $(current).after(td);
898
- else $(current).before(td);
899
- });
900
- },
901
-
902
- /*
903
- Image
904
- */
905
- imageEdit: function(e)
906
- {
907
- var handler = function()
908
- {
909
- var $el = $(e.target);
910
- var src = $el.attr('src');
911
- $('#redactor_image_edit_src').attr('href', src);
912
- $('#redactor_image_edit_delete').click(function() { this.deleteImage(e.target); }.bind2(this));
913
- $('#redactorSaveBtn').click(function() { this.imageSave(e.target); }.bind2(this));
914
-
915
- $('#redactor_file_alt').val($el.attr('alt'));
916
-
917
- var float = $el.css('float');
918
- if (float == 'none') float = 0;
919
-
920
- $('#redactor_form_image_align').val(float);
921
-
922
- }.bind2(this);
923
-
924
- redactorActive = this;
925
- this.modalInit(RLANG.image, this.opts.paths.dialogs.imageEdit, 380, 290, handler);
926
- },
927
- imageSave: function(el)
928
- {
929
- $(el).attr('alt', $('#redactor_file_alt').val());
930
-
931
- var style = '';
932
- if ($('#redactor_form_image_align') != 0)
933
- {
934
- var float = $('#redactor_form_image_align').val();
935
-
936
- // @tanraya AddedClasses
937
- $(el).removeClass('img_left').removeClass('img_right')
938
-
939
- if (float == 'left')
940
- $(el).addClass('img_left');
941
- else if (float == 'right')
942
- $(el).addClass('img_right')
943
- }
944
- else $(el).css({ float: 'none', margin: '0' });
945
-
946
- this.modalClose();
947
- },
948
- deleteImage: function(el)
949
- {
950
- $(el).remove();
951
- this.modalClose();
952
- },
953
- showImage: function()
954
- {
955
- this.spanid = Math.floor(Math.random() * 99999);
956
- if (jQuery.browser.msie)
957
- {
958
- this.execCommand('inserthtml', '<span id="span' + this.spanid + '"></span>');
959
- }
960
-
961
- var handler = function() {
962
- if (this.opts.paths.images.list !== false) {
963
- $.getJSON(this.opts.paths.images.list, function(data) {
964
- $.each(data, function(key, val) {
965
- var img = $('<img src="' + val.thumb + '" rel="' + val.image + '">');
966
- img.click(function() { redactorActive.imageSetThumb($(this).attr('rel')); });
967
- $('#redactor_image_box').append(img);
968
- });
969
- });
970
- } else {
971
- $('#redactor_tabs li').eq(0).remove();
972
- $('#redactor_tabs a').eq(1).addClass('redactor_tabs_act');
973
- $('#redactor_tabs1').hide();
974
- $('#redactor_tabs2').show();
975
- }
976
-
977
- // upload params
978
- var params = '';
979
- if (this.opts.imageUploadCallback) var params = this.opts.imageUploadCallback();
980
-
981
- $('#redactor_file').dragupload({
982
- url : this.opts.paths.images.upload + params,
983
- success : function(data) {
984
- this.imageUploadCallback(data);
985
- }.bind2(this)
986
- });
987
-
988
- this.uploadInit('redactor_file', {
989
- auto : true,
990
- url : this.opts.paths.images.upload + params,
991
- trigger : 'redactorUploadBtn',
992
- success : function(data) {
993
- this.imageUploadCallback(data);
994
- }.bind2(this)});
995
- }.bind2(this);
996
-
997
- redactorActive = this;
998
- this.modalInit(RLANG.image, this.opts.paths.dialogs.image, 570, 450, handler);
999
-
1000
- },
1001
- imageSetThumb: function(data)
1002
- {
1003
- this._imageSet('<img alt="" src="' + data + '" />');
1004
- },
1005
- imageUploadCallback: function(data)
1006
- {
1007
- if ($('#redactor_file_link').val() != '') data = $('#redactor_file_link').val();
1008
-
1009
- this._imageSet(data);
1010
-
1011
- },
1012
- _imageSet: function(html)
1013
- {
1014
- redactorActive.frame.get(0).contentWindow.focus();
1015
-
1016
- if ($.browser.msie)
1017
- {
1018
- $(redactorActive.doc.getElementById('span' + redactorActive.spanid)).after(html);
1019
- $(redactorActive.doc.getElementById('span' + redactorActive.spanid)).remove();
1020
- }
1021
- else
1022
- {
1023
- redactorActive.execCommand('inserthtml', html);
1024
- }
1025
-
1026
- this.modalClose();
1027
- this.docObserve();
1028
- },
1029
-
1030
-
1031
- /*
1032
- Link
1033
- */
1034
- showLink: function()
1035
- {
1036
- redactorActive = this;
1037
-
1038
- var handler = function()
1039
- {
1040
- var sel = this.get_selection();
1041
- if ($.browser.msie)
1042
- {
1043
- var temp = sel.htmlText.match(/href="(.*?)"/gi);
1044
- if (temp != null)
1045
- {
1046
- temp = new String(temp);
1047
- temp = temp.replace(/href="(.*?)"/gi, '$1');
1048
- }
1049
-
1050
- var text = sel.text;
1051
- if (temp != null) var url = temp;
1052
- else var url = '';
1053
- var title = '';
1054
- }
1055
- else
1056
- {
1057
- if (sel.anchorNode.parentNode.tagName == 'A')
1058
- {
1059
- var url = sel.anchorNode.parentNode.href;
1060
- var text = sel.anchorNode.parentNode.text;
1061
- var title = sel.anchorNode.parentNode.title;
1062
- if (sel.toString() == '') this.insert_link_node = sel.anchorNode.parentNode
1063
-
1064
- }
1065
- else
1066
- {
1067
- var text = sel.toString();
1068
- var url = '';
1069
- var title = '';
1070
- }
1071
- }
1072
-
1073
- $('#redactor_link_url').val(url).focus();
1074
- $('#redactor_link_text').val(text);
1075
- $('#redactor_link_title').val(title);
1076
-
1077
- }.bind2(this);
1078
-
1079
- this.modalInit(RLANG.link, this.opts.paths.dialogs.link, 400, 300, handler);
1080
-
1081
- },
1082
- insertLink: function()
1083
- {
1084
- var value = $('#redactor_link_text').val();
1085
- if (value == '') return true;
1086
-
1087
- var title = $('#redactor_link_title').val();
1088
- if (title != '') title = ' title="' + $('#redactor_link_title').val() + '"';
1089
-
1090
- if ($('#redactor_link_id_url').get(0).checked) var mailto = '';
1091
- else var mailto = 'mailto:';
1092
-
1093
- var a = '<a href="' + mailto + $('#redactor_link_url').val() + '"' + title +'>' + value + '</a> ';
1094
-
1095
- if (a)
1096
- {
1097
- if (this.insert_link_node)
1098
- {
1099
- $(this.insert_link_node).text(value);
1100
- $(this.insert_link_node).attr('href', $('#redactor_link_url').val());
1101
-
1102
- var title = $('#redactor_link_title').val();
1103
- if (title != '') $(this.insert_link_node).attr('title', title);
1104
-
1105
- this.modalClose();
1106
- }
1107
- else
1108
- {
1109
- redactorActive.frame.get(0).contentWindow.focus();
1110
- redactorActive.execCommand('inserthtml', a);
1111
- }
1112
- }
1113
-
1114
- this.modalClose();
1115
- },
1116
-
1117
-
1118
- /*
1119
- Modal
1120
- */
1121
- modalInit: function(title, url, width, height, handler, scroll)
1122
- {
1123
- if (this.opts.overlay)
1124
- {
1125
- $('#redactor_imp_modal_overlay').show();
1126
- $('#redactor_imp_modal_overlay').click(function() { this.modalClose(); }.bind2(this));
1127
- }
1128
-
1129
- if ($('#redactor_imp_modal').size() == 0)
1130
- {
1131
- this.modal = $('<div id="redactor_imp_modal" style="display: none;"><div id="redactor_imp_modal_close"></div><div id="redactor_imp_modal_header"></div><div id="redactor_imp_modal_inner"></div></div>');
1132
- $('body').append(this.modal);
1133
- }
1134
-
1135
- $('#redactor_imp_modal_close').click(function() { this.modalClose(); }.bind2(this));
1136
- $(document).keyup(function(e) { if( e.keyCode == 27) this.modalClose(); }.bind2(this));
1137
- $(this.doc).keyup(function(e) { if( e.keyCode == 27) this.modalClose(); }.bind2(this));
1138
-
1139
- $.ajax({
1140
- url: url,
1141
- success: function(data)
1142
- {
1143
- // parse lang
1144
- $.each(RLANG, function(i,s)
1145
- {
1146
- var re = new RegExp("%RLANG\." + i + "%","gi");
1147
- data = data.replace(re, s);
1148
- });
1149
-
1150
- $('#redactor_imp_modal_inner').html(data);
1151
- $('#redactor_imp_modal_header').html(title);
1152
-
1153
- if (height === false) theight = 'auto';
1154
- else theight = height + 'px';
1155
-
1156
- $('#redactor_imp_modal').css({ width: width + 'px', height: theight, marginTop: '-' + height/2 + 'px', marginLeft: '-' + width/2 + 'px' }).fadeIn('fast');
1157
-
1158
- if (scroll === true)
1159
- {
1160
- $('#imp_redactor_table_box').height(height-$('#redactor_imp_modal_header').outerHeight()-130).css('overflow', 'auto');
1161
- }
1162
-
1163
- if (typeof(handler) == 'function') handler();
1164
-
1165
-
1166
- }.bind2(this)
1167
- });
1168
- },
1169
- modalClose: function()
1170
- {
1171
-
1172
- $('#redactor_imp_modal_close').unbind('click', function() { this.modalClose(); }.bind2(this));
1173
- $('#redactor_imp_modal').fadeOut('fast', function()
1174
- {
1175
- $('#redactor_imp_modal_inner').html('');
1176
-
1177
- if (this.opts.overlay)
1178
- {
1179
- $('#redactor_imp_modal_overlay').hide();
1180
- $('#redactor_imp_modal_overlay').unbind('click', function() { this.modalClose(); }.bind2(this));
1181
- }
1182
-
1183
- $(document).unbind('keyup', function(e) { if( e.keyCode == 27) this.modalClose(); }.bind2(this));
1184
- $(this.doc).unbind('keyup', function(e) { if( e.keyCode == 27) this.modalClose(); }.bind2(this));
1185
-
1186
- }.bind2(this));
1187
-
1188
- },
1189
-
1190
- /*
1191
- Upload
1192
- */
1193
- uploadInit: function(element, options)
1194
- {
1195
- /*
1196
- Options
1197
- */
1198
- this.uploadOptions = {
1199
- url: false,
1200
- success: false,
1201
- start: false,
1202
- trigger: false,
1203
- auto: false,
1204
- input: false
1205
- };
1206
-
1207
- $.extend(this.uploadOptions, options);
1208
-
1209
-
1210
- // Test input or form
1211
- if ($('#' + element).get(0).tagName == 'INPUT')
1212
- {
1213
- this.uploadOptions.input = $('#' + element);
1214
- this.element = $($('#' + element).get(0).form);
1215
- }
1216
- else
1217
- {
1218
- this.element = $('#' + element);
1219
- }
1220
-
1221
-
1222
- this.element_action = this.element.attr('action');
1223
-
1224
- // Auto or trigger
1225
- if (this.uploadOptions.auto)
1226
- {
1227
- $(this.uploadOptions.input).change(function()
1228
- {
1229
- this.element.submit(function(e) { return false; });
1230
- this.uploadSubmit();
1231
- }.bind2(this));
1232
-
1233
- }
1234
- else if (this.uploadOptions.trigger)
1235
- {
1236
- $('#' + this.uploadOptions.trigger).click(function() { this.uploadSubmit(); }.bind2(this));
1237
- }
1238
- },
1239
- uploadSubmit : function()
1240
- {
1241
- this.uploadForm(this.element, this.uploadFrame());
1242
- },
1243
- uploadFrame : function()
1244
- {
1245
- this.id = 'f' + Math.floor(Math.random() * 99999);
1246
-
1247
- var d = document.createElement('div');
1248
- var iframe = '<iframe style="display:none" src="about:blank" id="'+this.id+'" name="'+this.id+'"></iframe>';
1249
- d.innerHTML = iframe;
1250
- document.body.appendChild(d);
1251
-
1252
- // Start
1253
- if (this.uploadOptions.start) this.uploadOptions.start();
1254
-
1255
- $('#' + this.id).load(function () { this.uploadLoaded() }.bind2(this));
1256
-
1257
- return this.id;
1258
- },
1259
- uploadForm : function(f, name)
1260
- {
1261
- if (this.uploadOptions.input)
1262
- {
1263
- var formId = 'redactorUploadForm' + this.id;
1264
- var fileId = 'redactorUploadFile' + this.id;
1265
- this.form = $('<form action="' + this.uploadOptions.url + '" method="POST" target="' + name + '" name="' + formId + '" id="' + formId + '" enctype="multipart/form-data"></form>');
1266
-
1267
- var oldElement = this.uploadOptions.input;
1268
- var newElement = $(oldElement).clone();
1269
- $(oldElement).attr('id', fileId);
1270
- $(oldElement).before(newElement);
1271
- $(oldElement).appendTo(this.form);
1272
- $(this.form).css('position', 'absolute');
1273
- $(this.form).css('top', '-2000px');
1274
- $(this.form).css('left', '-2000px');
1275
- $(this.form).appendTo('body');
1276
-
1277
- this.form.submit();
1278
- }
1279
- else
1280
- {
1281
- f.attr('target', name);
1282
- f.attr('method', 'POST');
1283
- f.attr('enctype', 'multipart/form-data');
1284
- f.attr('action', this.uploadOptions.url);
1285
-
1286
- this.element.submit();
1287
- }
1288
-
1289
- },
1290
- uploadLoaded : function()
1291
- {
1292
- var i = $('#' + this.id);
1293
-
1294
- if (i.contentDocument) var d = i.contentDocument;
1295
- else if (i.contentWindow) var d = i.contentWindow.document;
1296
- else var d = window.frames[this.id].document;
1297
-
1298
- if (d.location.href == "about:blank") return true;
1299
-
1300
- // Success
1301
- if (this.uploadOptions.success) this.uploadOptions.success(d.body.innerHTML);
1302
-
1303
- this.element.attr('action', this.element_action);
1304
- this.element.attr('target', '');
1305
- //this.element.unbind('submit');
1306
- //if (this.uploadOptions.input) $(this.form).remove();
1307
- },
1308
-
1309
- /*
1310
- Toolbar
1311
- */
1312
- buildToolbar: function()
1313
- {
1314
- this.toolbar = $('<ul id="imp_redactor_toolbar_' + this.frameID + '" class="imp_redactor_toolbar"></ul>');
1315
-
1316
- if (this.opts.air)
1317
- {
1318
- $(this.air).append(this.toolbar);
1319
- this.box.prepend(this.air);
1320
- }
1321
- else $(this.box).prepend(this.toolbar);
1322
-
1323
-
1324
- $.each(RTOOLBAR,
1325
- function (i, s)
1326
- {
1327
- if (s.name == 'separator')
1328
- {
1329
- var li = $('<li class="separator"></li>');
1330
- $(this.toolbar).append(li);
1331
- }
1332
- else
1333
- {
1334
-
1335
- var a = $('<a href="javascript:void(null);" class="imp_btn imp_btn_' + s.name + '" title="' + s.title + '"></a>');
1336
-
1337
- if (typeof(s.func) == 'undefined') a.click(function() { this.execCommand(s.exec, s.name); }.bind2(this));
1338
- else if (s.func != 'show') a.click(function(e) { this[s.func](e); }.bind2(this));
1339
-
1340
- var li = $('<li class="imp_li_btn imp_li_btn_' + s.name + '"></li>');
1341
- $(li).append(a);
1342
- $(this.toolbar).append(li);
1343
-
1344
- // build dropdown box
1345
- if (s.name == 'backcolor' || s.name == 'fontcolor' || typeof(s.dropdown) != 'undefined')
1346
- {
1347
- var ul = $('<ul class="imp_redactor_drop_down imp_redactor_drop_down' + this.frameID + '" id="imp_redactor_drop_down' + this.frameID + '_' + s.name + '" style="display: none;"></ul>');
1348
- if ($.browser.msie) ul.css({ borderLeft: '1px solid #ddd', borderRight: '1px solid #ddd', borderBottom: '1px solid #ddd' });
1349
- }
1350
-
1351
- // build dropdown
1352
- if (typeof(s.dropdown) != 'undefined')
1353
- {
1354
-
1355
- $.each(s.dropdown,
1356
- function (x, d)
1357
- {
1358
- if (typeof(d.style) == 'undefined') d.style = '';
1359
-
1360
- if (d.name == 'separator')
1361
- {
1362
- var ul_li = $('<li class="separator_drop"></li>');
1363
- $(ul).append(ul_li);
1364
- }
1365
- else
1366
- {
1367
-
1368
- var ul_li = $('<li></li>');
1369
- var ul_li_a = $('<a href="javascript:void(null);" style="' + d.style + '">' + d.title + '</a>');
1370
- $(ul_li).append(ul_li_a);
1371
- $(ul).append(ul_li);
1372
-
1373
- if (typeof(d.func) == 'undefined') $(ul_li_a).click(function() { this.execCommand(d.exec, d.name); }.bind2(this));
1374
- else $(ul_li_a).click(function(e) { this[d.func](e); }.bind2(this));
1375
- }
1376
-
1377
-
1378
-
1379
- }.bind2(this)
1380
- );
1381
- }
1382
- else a.mouseover(function() { this.hideAllDropDown() }.bind2(this));
1383
-
1384
- // observing dropdown
1385
- if (s.name == 'backcolor' || s.name == 'fontcolor' || typeof(s.dropdown) != 'undefined')
1386
- {
1387
- $('#imp_redactor_toolbar_' + this.frameID).after(ul);
1388
-
1389
- this.hdlHideDropDown = function(e) { this.hideDropDown(e, ul, s.name) }.bind2(this);
1390
- this.hdlShowDropDown = function(e) { this.showDropDown(e, ul, s.name) }.bind2(this);
1391
- this.hdlShowerDropDown = function(e) { this.showerDropDown(e, ul, s.name) }.bind2(this);
1392
-
1393
- a.click(this.hdlShowDropDown).mouseover(this.hdlShowerDropDown);
1394
-
1395
- $(document).click(this.hdlHideDropDown);
1396
- }
1397
-
1398
-
1399
- }
1400
- }.bind2(this)
1401
- );
1402
- },
1403
-
1404
- /*
1405
- DropDown
1406
- */
1407
- showedDropDown: false,
1408
- showDropDown: function(e, ul, name)
1409
- {
1410
-
1411
- if (this.showedDropDown) this.hideAllDropDown();
1412
- else
1413
- {
1414
- this.showedDropDown = true;
1415
- this.showingDropDown(e, ul, name);
1416
- }
1417
-
1418
- },
1419
- showingDropDown: function(e, ul, name)
1420
- {
1421
- this.hideAllDropDown();
1422
- this.addSelButton(name);
1423
-
1424
- var left = $('#imp_redactor_toolbar_' + this.frameID + ' li.imp_li_btn_' + name).position().left;
1425
- $(ul).css('left', left + 'px').show();
1426
- },
1427
- showerDropDown: function(e, ul, name)
1428
- {
1429
- if (this.showedDropDown) this.showingDropDown(e, ul, name);
1430
- },
1431
- hideAllDropDown: function()
1432
- {
1433
- $('#imp_redactor_toolbar_' + this.frameID + ' li.imp_li_btn').removeClass('act');
1434
- $('ul.imp_redactor_drop_down' + this.frameID).hide();
1435
- },
1436
- hideDropDown: function(e, ul, name)
1437
- {
1438
- if (!$(e.target).parent().hasClass('act'))
1439
- {
1440
- this.showedDropDown = false;
1441
- this.hideAllDropDown();
1442
- }
1443
-
1444
- $(document).unbind('click', this.hdlHideDropDown);
1445
- $(this.doc).unbind('click', this.hdlHideDropDown);
1446
-
1447
- },
1448
- addSelButton: function(name)
1449
- {
1450
- var element = $('#imp_redactor_toolbar_' + this.frameID + ' li.imp_li_btn_' + name);
1451
- element.addClass('act');
1452
- },
1453
- removeSelButton: function(name)
1454
- {
1455
- var element = $('#imp_redactor_toolbar_' + this.frameID + ' li.imp_li_btn_' + name);
1456
- element.removeClass('act');
1457
- },
1458
- toggleSelButton: function(name)
1459
- {
1460
- $('#imp_redactor_toolbar_' + this.frameID + ' li.imp_li_btn_' + name).toggleClass('act');
1461
- },
1462
-
1463
-
1464
- /*
1465
- Resizer
1466
- */
1467
- initResize: function(e)
1468
- {
1469
- if (e.preventDefault) e.preventDefault();
1470
- else e.returnValue = false;
1471
-
1472
- this.splitter = e.target;
1473
-
1474
- if (this.opts.visual)
1475
- {
1476
- this.element_resize = this.frame;
1477
- this.element_resize.get(0).style.visibility = 'hidden';
1478
- this.element_resize_parent = this.$el;
1479
- }
1480
- else
1481
- {
1482
- this.element_resize = this.$el;
1483
- this.element_resize_parent = this.frame;
1484
- }
1485
-
1486
- this.stopResizeHdl = function (e) { this.stopResize(e) }.bind2(this);
1487
- this.startResizeHdl = function (e) { this.startResize(e) }.bind2(this);
1488
- this.resizeHdl = function (e) { this.resize(e) }.bind2(this);
1489
-
1490
- $(document).mousedown(this.startResizeHdl);
1491
- $(document).mouseup(this.stopResizeHdl);
1492
- $(this.splitter).mouseup(this.stopResizeHdl);
1493
-
1494
- this.null_point = false;
1495
- this.h_new = false;
1496
- this.h = this.element_resize.height();
1497
- },
1498
- startResize: function()
1499
- {
1500
- $(document).mousemove(this.resizeHdl);
1501
- },
1502
- resize: function(e)
1503
- {
1504
- if (e.preventDefault) e.preventDefault();
1505
- else e.returnValue = false;
1506
-
1507
- var y = e.pageY;
1508
- if (this.null_point == false) this.null_point = y;
1509
- if (this.h_new == false) this.h_new = this.element_resize.height();
1510
-
1511
- var s_new = (this.h_new + y - this.null_point) - 10;
1512
-
1513
- if (s_new <= 30) return true;
1514
-
1515
- if (s_new >= 0)
1516
- {
1517
- this.element_resize.get(0).style.height = s_new + 'px';
1518
- this.element_resize_parent.get(0).style.height = s_new + 'px';
1519
- }
1520
- },
1521
- stopResize: function(e)
1522
- {
1523
- $(document).unbind('mousemove', this.resizeHdl);
1524
- $(document).unbind('mousedown', this.startResizeHdl);
1525
- $(document).unbind('mouseup', this.stopResizeHdl);
1526
- $(this.splitter).unbind('mouseup', this.stopResizeHdl);
1527
-
1528
- this.element_resize.get(0).style.visibility = 'visible';
1529
- }
1530
-
1531
- };
1532
-
1533
-
1534
- String.prototype.isInlineName = function()
1535
- {
1536
- var inlineList = new Array("#text", "a", "em", "font", "span", "strong", "u");
1537
- var theName = this.toLowerCase();
1538
-
1539
- for (var i = 0; i < inlineList.length; i++)
1540
- {
1541
- if (theName == inlineList[i])
1542
- {
1543
- return true;
1544
- }
1545
- }
1546
-
1547
- return false;
1548
- };
1549
-
1550
-
1551
- // bind2
1552
- Function.prototype.bind2 = function(object)
1553
- {
1554
- var method = this; var oldArguments = $.makeArray(arguments).slice(1);
1555
- return function (argument)
1556
- {
1557
- if (argument == new Object) { method = null; oldArguments = null; }
1558
- else if (method == null) throw "Attempt to invoke destructed method reference.";
1559
- else { var newArguments = $.makeArray(arguments); return method.apply(object, oldArguments.concat(newArguments)); }
1560
- };
1561
- };
1562
-
1563
-
1564
- })(jQuery);
1565
-
1566
- // redactor_tabs
1567
- function showRedactorTabs(el, index)
1568
- {
1569
- $('#redactor_tabs a').removeClass('redactor_tabs_act');
1570
- $(el).addClass('redactor_tabs_act');
1571
-
1572
- $('.redactor_tabs').hide();
1573
- $('#redactor_tabs' + index).show();
1574
- }
1575
- ;