diff --git a/core/modules/views/views_ui/lib/Drupal/views_ui/Form/Ajax/Rearrange.php b/core/modules/views/views_ui/lib/Drupal/views_ui/Form/Ajax/Rearrange.php
index de01217..eb54ab0 100644
--- a/core/modules/views/views_ui/lib/Drupal/views_ui/Form/Ajax/Rearrange.php
+++ b/core/modules/views/views_ui/lib/Drupal/views_ui/Form/Ajax/Rearrange.php
@@ -85,12 +85,23 @@ public function buildForm(array $form, array &$form_state) {
       }
     }
 
+    $form['fields'] = array(
+      '#type' => 'table',
+      '#header' => array('', t('Weight'), t('Remove')),
+      '#empty' => t('No fields available.'),
+      '#tabledrag' => array(
+        array('order', 'sibling', 'weight'),
+      ),
+      '#tree' => TRUE,
+      '#prefix' => '<div class="scroll">',
+      '#suffix' => '</div>',
+    );
+
     foreach ($display->getOption($types[$type]['plural']) as $id => $field) {
-      $form['fields'][$id] = array('#tree' => TRUE);
-      $form['fields'][$id]['weight'] = array(
-        '#type' => 'textfield',
-        '#default_value' => ++$count,
-      );
+      $form['fields'][$id] = array();
+
+      $form['fields'][$id]['#attributes'] = array('class' => array('draggable'), 'id' => 'views-row-' . $id);
+
       $handler = $display->getHandler($type, $id);
       if ($handler) {
         $name = $handler->adminLabel() . ' ' . $handler->adminSummary();
@@ -105,30 +116,29 @@ public function buildForm(array $form, array &$form_state) {
       else {
         $form['fields'][$id]['name'] = array('#markup' => t('Broken field @id', array('@id' => $id)));
       }
+
+      $form['fields'][$id]['weight'] = array(
+        '#type' => 'textfield',
+        '#default_value' => ++$count,
+        '#attributes' => array('class' => array('weight')),
+      );
+
       $form['fields'][$id]['removed'] = array(
         '#type' => 'checkbox',
         '#id' => 'views-removed-' . $id,
         '#attributes' => array('class' => array('views-remove-checkbox')),
         '#default_value' => 0,
+        '#suffix' => l('<span>' . t('Remove') . '</span>', 'javascript:void()', array('attributes' => array('id' => 'views-remove-link-' . $id, 'class' => array('views-hidden', 'views-button-remove', 'views-remove-link'), 'alt' => t('Remove this item'), 'title' => t('Remove this item')), 'html' => TRUE)),
       );
     }
 
-    // Add javascript settings that will be added via $.extend for tabledragging
-    $form['#js']['tableDrag']['arrange']['weight'][0] = array(
-      'target' => 'weight',
-      'source' => NULL,
-      'relationship' => 'sibling',
-      'action' => 'order',
-      'hidden' => TRUE,
-      'limit' => 0,
-    );
-
     $name = NULL;
     if (isset($form_state['update_name'])) {
       $name = $form_state['update_name'];
     }
 
     $view->getStandardButtons($form, $form_state, 'views_ui_rearrange_form');
+
     return $form;
   }
 
diff --git a/core/modules/views/views_ui/views_ui.theme.inc b/core/modules/views/views_ui/views_ui.theme.inc
index cb5396b..b353345 100644
--- a/core/modules/views/views_ui/views_ui.theme.inc
+++ b/core/modules/views/views_ui/views_ui.theme.inc
@@ -245,38 +245,6 @@ function theme_views_ui_reorder_displays_form($vars) {
 /**
  * Turn the rearrange form into a proper table
  */
-function theme_views_ui_rearrange_form($variables) {
-  $form = $variables['form'];
-
-  $rows = array();
-  foreach (element_children($form['fields']) as $id) {
-    if (isset($form['fields'][$id]['name'])) {
-      $row = array();
-      $row[] = drupal_render($form['fields'][$id]['name']);
-      $form['fields'][$id]['weight']['#attributes']['class'] = array('weight');
-      $row[] = drupal_render($form['fields'][$id]['weight']);
-      $row[] = drupal_render($form['fields'][$id]['removed']) . l('<span>' . t('Remove') . '</span>', 'javascript:void()', array('attributes' => array('id' => 'views-remove-link-' . $id, 'class' => array('views-hidden', 'views-button-remove', 'views-remove-link'), 'alt' => t('Remove this item'), 'title' => t('Remove this item')), 'html' => TRUE));
-      $rows[] = array('data' => $row, 'class' => array('draggable'), 'id' => 'views-row-' . $id);
-    }
-  }
-  if (empty($rows)) {
-    $rows[] = array(array('data' => t('No fields available.'), 'colspan' => '2'));
-  }
-
-  $header = array('', t('Weight'), t('Remove'));
-  $output = drupal_render($form['override']);
-  $output .= '<div class="scroll">';
-  $output .= theme('table', array('header' => $header, 'rows' => $rows, 'attributes' => array('id' => 'arrange')));
-  $output .= '</div>';
-  $output .= drupal_render_children($form);
-  drupal_add_tabledrag('arrange', 'order', 'sibling', 'weight');
-
-  return $output;
-}
-
-/**
- * Turn the rearrange form into a proper table
- */
 function theme_views_ui_rearrange_filter_form(&$vars) {
   $form = $vars['form'];
   $rows = $ungroupable_rows = array();
