Index: views.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/views.module,v
retrieving revision 1.338
diff -u -p -r1.338 views.module
--- views.module	3 Jun 2009 00:01:00 -0000	1.338
+++ views.module	10 Jul 2009 20:16:01 -0000
@@ -979,7 +979,7 @@ function views_exposed_form(&$form_state
 //  $form['#attributes']['class'] = array('views-exposed-form');
 
   // If using AJAX, we need the form plugin.
-  if ($view->use_ajax) {
+  if ($view->use_ajax['use_ajax']) {
     drupal_add_js('misc/jquery.form.js');
   }
   views_add_js('dependent');
Index: css/views.css
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/css/views.css,v
retrieving revision 1.11
diff -u -p -r1.11 views.css
--- css/views.css	6 Jun 2008 23:08:00 -0000	1.11
+++ css/views.css	10 Jul 2009 20:16:01 -0000
@@ -94,3 +94,8 @@ div.view:hover div.views-hide {
   border-top: none;
 }
 
+/* Prevent animation jumps when using ajax calls on View tables */
+.view-content table {
+  display: block;
+  margin: 0;
+}
Index: includes/view.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/includes/view.inc,v
retrieving revision 1.159
diff -u -p -r1.159 view.inc
--- includes/view.inc	4 Jun 2009 18:40:45 -0000	1.159
+++ includes/view.inc	10 Jul 2009 20:16:02 -0000
@@ -109,7 +109,7 @@ class view extends views_db_object {
   }
 
   /**
-   * The pager element id to use if use_apger is on
+   * The pager element id to use if use_pager is on
    */
   function set_pager_element($pager_element) {
     $this->pager['element'] = $pager_element;
@@ -129,7 +129,7 @@ class view extends views_db_object {
    * rather than a page refresh.
    */
   function set_use_ajax($use_ajax) {
-    $this->use_ajax = $use_ajax;
+    $this->use_ajax['use_ajax'] = $use_ajax;
   }
 
   /**
@@ -399,7 +399,7 @@ class view extends views_db_object {
       unset($form_state['rerender']);
     }
 
-    if (!empty($this->ajax)) {
+    if (!empty($this->use_ajax)) {
       $form_state['ajax'] = TRUE;
     }
 
Index: js/ajax_view.js
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/js/ajax_view.js,v
retrieving revision 1.18
diff -u -p -r1.18 ajax_view.js
--- js/ajax_view.js	2 Jun 2009 19:30:44 -0000	1.18
+++ js/ajax_view.js	10 Jul 2009 20:16:02 -0000
@@ -28,6 +28,7 @@ Drupal.Views.Ajax.ajaxViewResponse = fun
     $view.replaceWith($newView);
     $view = $newView;
     Drupal.attachBehaviors($view.parent());
+    $view.find('.view-content').hide();
   }
  
   if (response.messages) {
@@ -37,6 +38,61 @@ Drupal.Views.Ajax.ajaxViewResponse = fun
 };
 
 /**
+ * jQuery effect for Views.
+ */
+Drupal.Views.Ajax.jQueryEffectHide = function(target, effect) {
+  var $view_content = $(target + ' .view-content');
+  var $view = $view_content.children();
+  var height = $view_content.height();
+  $view_content.height($view_content.height());
+
+  switch(effect) {
+    case 'hideshow':
+      $view.hide('slow');
+      break;
+    case 'slide':
+      $view.slideUp('slow');
+      break;
+    case 'fade':
+      $view.fadeOut('slow');
+      break;
+  }
+  return height;
+};
+
+/**
+ * jQuery effect for Views.
+ */
+Drupal.Views.Ajax.jQueryEffectShow = function(target, effect, height) {
+  var $view_content = $(target + ' .view-content');
+  var $view = $view_content.children();
+  $view_content.show();
+  $view.show();
+  var height_new = $view_content.height();
+
+  $view.hide();
+  $view_content.height(height).animate({height: height_new}, 'slow', 'swing', function(){
+    switch(effect) {
+      case 'hideshow':
+        $view.show('slow', function(){
+          $view_content.height('');
+        });
+        break;
+      case 'slide':
+        $view.slideDown('slow', function(){
+          $view_content.height('');
+        });
+        break;
+      case 'fade':
+        $view.fadeIn('slow', function(){
+          $view_content.height('');
+        });
+        break;
+    }
+  });
+};
+
+/**
  * Ajax behavior for views. 
  */
 Drupal.behaviors.ViewsAjaxView = function() {
@@ -75,6 +131,7 @@ Drupal.behaviors.ViewsAjaxView = functio
       .submit(function () {
         $('input[type=submit]', this).after('<span class="views-throbbing">&nbsp</span>');
         var object = this;
+        var height = Drupal.Views.Ajax.jQueryEffectHide(view, settings.view_use_ajax);
         $(this).ajaxSubmit({
           url: ajax_path,
           type: 'GET',
@@ -84,10 +141,15 @@ Drupal.behaviors.ViewsAjaxView = functio
               $.each(response.__callbacks, function(i, callback) {
                 eval(callback)(view, response);
               });
+              Drupal.Views.Ajax.jQueryEffectShow(view, settings.view_use_ajax, height);
               $('.views-throbbing', object).remove();
             }
           },
-          error: function() { alert(Drupal.t("An error occurred at @path.", {'@path': ajax_path})); $('.views-throbbing', object).remove(); },
+          error: function() {
+            $('.views-throbbing', object).remove();
+            alert(Drupal.t("An error occurred at @path.", {'@path': ajax_path}));
+            Drupal.Views.Ajax.jQueryEffectShow(view, settings.view_use_ajax, height);
+          },
           dataType: 'json'
         });
 
@@ -122,6 +184,8 @@ Drupal.behaviors.ViewsAjaxView = functio
               );
               $(this).click(function () {
                 $(this).addClass('views-throbbing');
+                var height = Drupal.Views.Ajax.jQueryEffectHide(view, settings.view_use_ajax);
+
                 $.ajax({
                   url: ajax_path,
                   type: 'GET',
@@ -142,10 +206,16 @@ Drupal.behaviors.ViewsAjaxView = functio
                         eval(callback)(target, response);
                       });
                     }
+                    Drupal.Views.Ajax.jQueryEffectShow(view, settings.view_use_ajax, height);
+                  },
+                  error: function() {
+                    $(this).removeClass('views-throbbing');
+                    alert(Drupal.t("An error occurred at @path.", {'@path': ajax_path}));
+                    Drupal.Views.Ajax.jQueryEffectShow(view, settings.view_use_ajax, height);
                   },
-                  error: function() { $(this).removeClass('views-throbbing'); alert(Drupal.t("An error occurred at @path.", {'@path': ajax_path})); },
                   dataType: 'json'
                 });
+                
 
                 return false;
               });
Index: plugins/views_plugin_display.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/plugins/views_plugin_display.inc,v
retrieving revision 1.24
diff -u -p -r1.24 views_plugin_display.inc
--- plugins/views_plugin_display.inc	10 Jun 2009 22:01:31 -0000	1.24
+++ plugins/views_plugin_display.inc	10 Jul 2009 20:16:03 -0000
@@ -106,7 +106,7 @@ class views_plugin_display extends views
     if (!empty($this->definition['use ajax'])) {
       return $this->get_option('use_ajax');
     }
-    return FALSE;
+    return 'no';
   }
 
   /**
@@ -320,7 +320,7 @@ class views_plugin_display extends views
         'default' => FILTER_FORMAT_DEFAULT,
       ),
       'use_ajax' => array(
-        'default' => FALSE,
+        'default' => 'no',
       ),
       'items_per_page' => array(
         'default' => 10,
@@ -668,7 +668,7 @@ class views_plugin_display extends views
       $options['use_ajax'] = array(
         'category' => 'basic',
         'title' => t('Use AJAX'),
-        'value' => $this->get_option('use_ajax') ? t('Yes') : t('No'),
+        'value' => $this->get_option('use_ajax') != 'no' ? t('Yes') : t('No'),
         'desc' => t('Change whether or not this display will use AJAX.'),
       );
     }
@@ -857,8 +857,9 @@ class views_plugin_display extends views
         );
         $form['use_ajax'] = array(
           '#type' => 'radios',
-          '#options' => array(1 => t('Yes'), 0 => t('No')),
-          '#default_value' => $this->get_option('use_ajax') ? 1 : 0,
+          '#options' => array('hideshow' => t('Hide/show'), 'slide' => t('Slide up/down'), 'fade' => t('Fade in/out'), 'no' => t('None')),
+          '#description' => t("If AJAX is being used, you can select a jQuery effect to transition between changing content."),
+          '#default_value' => $this->get_option('use_ajax'),
         );
         break;
       case 'use_pager':
@@ -1478,7 +1479,7 @@ class views_plugin_display extends views
         $this->set_option($section, $form_state['values'][$section]);
         break;
       case 'use_ajax':
-        $this->set_option($section, (bool)$form_state['values'][$section]);
+        $this->set_option($section, $form_state['values'][$section]);
         break;
       case 'use_pager':
         $this->set_option($section, $form_state['values'][$section]);
Index: theme/theme.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/theme/theme.inc,v
retrieving revision 1.76
diff -u -p -r1.76 theme.inc
--- theme/theme.inc	2 Jun 2009 20:28:52 -0000	1.76
+++ theme/theme.inc	10 Jul 2009 20:16:03 -0000
@@ -129,7 +129,7 @@ function template_preprocess_views_view(
   $vars['dom_id'] = !empty($view->dom_id) ? $view->dom_id : $dom_id++;
 
   // If using AJAX, send identifying data about this view.
-  if ($view->use_ajax) {
+  if ($view->use_ajax['use_ajax'] != 'no') {
     $settings = array(
       'views' => array(
         'ajax_path' => url('views/ajax'),
@@ -139,6 +139,8 @@ function template_preprocess_views_view(
             'view_display_id' => $view->current_display,
             'view_args' => implode('/', $view->args),
             'view_path' => $_GET['q'],
+            // jQuery effect for AJAX transitions
+            'view_use_ajax' => $view->use_ajax['use_ajax'],
             // Pass through URL to ensure we get e.g. language prefixes.
 //            'view_base_path' => isset($view->display['page']) ? substr(url($view->display['page']->display_options['path']), strlen($base_path)) : '',
             'view_base_path' => $view->get_path(),
