Index: misc/ahah.js
===================================================================
RCS file: /cvs/drupal/drupal/misc/ahah.js,v
retrieving revision 1.15
diff -u -r1.15 ahah.js
--- misc/ahah.js	27 Apr 2009 20:19:35 -0000	1.15
+++ misc/ahah.js	13 Jul 2009 20:16:55 -0000
@@ -197,7 +197,9 @@
   // Attach all javascript behaviors to the new content, if it was successfully
   // added to the page, this if statement allows #ahah[wrapper] to be optional.
   if (new_content.parents('html').length > 0) {
-    Drupal.attachBehaviors(new_content);
+    // Apply any settings from the returned JSON if available.
+    var settings = response.settings || Drupal.settings;
+    Drupal.attachBehaviors(new_content, settings);
   }
 
   Drupal.unfreezeHeight();
