summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJorrit Schippers2009-09-09 19:40:01 (GMT)
committer Jorrit Schippers2009-09-09 19:40:01 (GMT)
commit6d33d05b993466f70910dc0d0b9b4a3f0d0fe15d (patch)
tree8a6502739583639bb6b7c0b54e14b09de3ab14fd
parent574d00bfdf910a566f3ece4d332bbd3933c5ff15 (diff)
Make sure the grippie has the right width, even when fckeditor.utils.js is loaded before teaser.js or textarea.js
-rw-r--r--fckeditor.utils.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/fckeditor.utils.js b/fckeditor.utils.js
index 6aca7ed..e3192fc 100644
--- a/fckeditor.utils.js
+++ b/fckeditor.utils.js
@@ -9,6 +9,13 @@ var fckTeaser = { lookup : {}, lookupSetup : false, cache : {} };
* Drupal behavior that adds FCKeditors to textareas
*/
Drupal.behaviors.fckeditor = function(context) {
+ // make sure the textarea behavior is run first, to get a correctly sized grippie
+ // the textarea behavior requires the teaser behavior, so load that one as well
+ if (Drupal.behaviors.teaser && Drupal.behaviors.textarea) {
+ Drupal.behaviors.teaser(context);
+ Drupal.behaviors.textarea(context);
+ }
+
$('textarea.fckeditor:not(.fckeditor-processed)', context).each(function() {
var textarea = $(this).addClass('fckeditor-processed');