From 2d95c198153a8145e16adce7b84dabe777d1fe81 Mon Sep 17 00:00:00 2001
From: Peter Philipp <peter.philipp@cando-image.com>
Date: Thu, 28 Oct 2010 15:37:11 +0200
Subject: [PATCH] Tab indent fix

---
 .../cart/includes/commerce_cart.checkout_pane.inc  |   10 +-
 .../includes/commerce_checkout.checkout_pane.inc   |   16 ++--
 .../includes/commerce_customer.checkout_pane.inc   |  104 ++++++++++----------
 3 files changed, 65 insertions(+), 65 deletions(-)

diff --git a/modules/cart/includes/commerce_cart.checkout_pane.inc b/modules/cart/includes/commerce_cart.checkout_pane.inc
index 73d2698..13d156e 100644
--- a/modules/cart/includes/commerce_cart.checkout_pane.inc
+++ b/modules/cart/includes/commerce_cart.checkout_pane.inc
@@ -16,15 +16,15 @@ function commerce_cart_contents_pane_settings_form($checkout_pane) {
   // Build an options array of Views available for the cart contents pane.
   $options = array();
 
- 	// Generate an option list from all user defined and module defined views.
- 	foreach (views_get_all_views() as $view_id => $view_value) {
+   // Generate an option list from all user defined and module defined views.
+   foreach (views_get_all_views() as $view_id => $view_value) {
     // Only include line item Views.
     if ($view_value->base_table == 'commerce_order') {
-     	foreach ($view_value->display as $display_id => $display_value) {
+       foreach ($view_value->display as $display_id => $display_value) {
         $options[check_plain($view_id)][$view_id .'|'. $display_id] = check_plain($display_value->display_title);
       }
-   	}
- 	}
+     }
+   }
 
   $form['commerce_cart_contents_pane_view'] = array(
     '#type' => 'select',
diff --git a/modules/checkout/includes/commerce_checkout.checkout_pane.inc b/modules/checkout/includes/commerce_checkout.checkout_pane.inc
index a2b4930..19cda0a 100644
--- a/modules/checkout/includes/commerce_checkout.checkout_pane.inc
+++ b/modules/checkout/includes/commerce_checkout.checkout_pane.inc
@@ -18,21 +18,21 @@ function commerce_checkout_review_pane_checkout_form($form, &$form_state, $check
   $pane_form['review'] = array(
     '#theme' => 'commerce_checkout_review',
     '#data' => array(),
-	);
+  );
 
   // Load all the checkout panes enabled for the review page.
   $checkout_panes = commerce_checkout_panes(array('enabled' => TRUE, 'review' => TRUE));
 
   // Loop through all the pages before the review page...
   foreach (commerce_checkout_pages() as $page_id => $checkout_page) {
-		// Exit the loop once the review page is reached.
-		if ($page_id == 'review') {
-			break;
-		}
+    // Exit the loop once the review page is reached.
+    if ($page_id == 'review') {
+      break;
+    }
 
     // Then loop through all the panes...
     foreach (commerce_checkout_panes(array('page' => $page_id)) as $pane_id => $checkout_pane_local) {
-		  // If the pane is on the review callback...
+      // If the pane is on the review callback...
       if ($callback = commerce_checkout_pane_callback($checkout_pane_local, 'review')) {
         // Add a row for it in the review data.
         $pane_form['review']['#data'][$pane_id] = array(
@@ -43,9 +43,9 @@ function commerce_checkout_review_pane_checkout_form($form, &$form_state, $check
         $pane_form['review']['#data'][$pane_id]['data'] = $callback($form, $form_state, $checkout_pane_local, $order);
       }
     }
-	}
+  }
 
-	return $pane_form;
+  return $pane_form;
 }
 
 /**
diff --git a/modules/customer/includes/commerce_customer.checkout_pane.inc b/modules/customer/includes/commerce_customer.checkout_pane.inc
index ac01c9e..92cba03 100644
--- a/modules/customer/includes/commerce_customer.checkout_pane.inc
+++ b/modules/customer/includes/commerce_customer.checkout_pane.inc
@@ -14,18 +14,18 @@ function commerce_customer_profile_pane_settings_form($checkout_pane) {
   $form = array();
 
   // Extract the type of profile represented by this pane from its ID.
-	$type = substr($checkout_pane->pane_id, 17);
+  $type = substr($checkout_pane->pane_id, 17);
 
   // Build an options array of customer profile reference fields available for
-	// the data from this customer profile pane.
+  // the data from this customer profile pane.
   $options = array('' => t('- None -'));
 
   foreach (commerce_info_fields('commerce_customer_profile_reference', 'commerce_order') as $name => $field) {
-		if ($type == $field['settings']['profile_type']) {
-			$instance = field_info_instance('commerce_order', $name, 'commerce_order');
-			$options[$name] = check_plain($instance['label']);
-		}
-	}
+    if ($type == $field['settings']['profile_type']) {
+      $instance = field_info_instance('commerce_order', $name, 'commerce_order');
+      $options[$name] = check_plain($instance['label']);
+    }
+  }
 
   $form['commerce_' . $checkout_pane->pane_id . '_field'] = array(
     '#type' => 'select',
@@ -45,35 +45,35 @@ function commerce_customer_profile_pane_checkout_form($form, &$form_state, $chec
   $pane_form = array();
 
   // Extract the type of profile represented by this pane from its ID.
-	$type = substr($checkout_pane->pane_id, 17);
-
-	// Find the referenced profile ID using the related reference field...
-	$profile_id = 0;
-
-	if ($field_name = variable_get('commerce_' . $checkout_pane->pane_id . '_field', '')) {
-		if (!empty($order->{$field_name}[LANGUAGE_NONE][0]['profile_id'])) {
-			$profile_id = $order->{$field_name}[LANGUAGE_NONE][0]['profile_id'];
-		}
-	}
-	else {
-		// Or try the association stored in the order's data array if no field is set.
-		if (!empty($order->data['profiles'][$checkout_pane->pane_id])) {
-			$profile_id = $order->data['profiles'][$checkout_pane->pane_id];
-		}
-	}
+  $type = substr($checkout_pane->pane_id, 17);
+
+  // Find the referenced profile ID using the related reference field...
+  $profile_id = 0;
+
+  if ($field_name = variable_get('commerce_' . $checkout_pane->pane_id . '_field', '')) {
+    if (!empty($order->{$field_name}[LANGUAGE_NONE][0]['profile_id'])) {
+      $profile_id = $order->{$field_name}[LANGUAGE_NONE][0]['profile_id'];
+    }
+  }
+  else {
+    // Or try the association stored in the order's data array if no field is set.
+    if (!empty($order->data['profiles'][$checkout_pane->pane_id])) {
+      $profile_id = $order->data['profiles'][$checkout_pane->pane_id];
+    }
+  }
 
   // Create a new profile of the specified type if it hasn't already been made.
-	if (!empty($profile_id)) {
-		$profile = commerce_customer_profile_load($profile_id);
-	}
-	else {
-		$profile = commerce_customer_profile_new($type, $order->uid);
-	}
-
-	$pane_form['customer_profile'] = array(
-	  '#type' => 'value',
-		'#value' => $profile,
-	);
+  if (!empty($profile_id)) {
+    $profile = commerce_customer_profile_load($profile_id);
+  }
+  else {
+    $profile = commerce_customer_profile_new($type, $order->uid);
+  }
+
+  $pane_form['customer_profile'] = array(
+    '#type' => 'value',
+    '#value' => $profile,
+  );
 
   // Add the field widgets for the profile.
   field_attach_form('commerce_customer_profile', $profile, $pane_form, $form_state);
@@ -131,14 +131,14 @@ function commerce_customer_profile_pane_checkout_form_submit($form, &$form_state
   // Save the profile.
   commerce_customer_profile_save($profile);
 
-	// Store the profile ID for the related field as specified on the settings form.
-	if ($field_name = variable_get('commerce_' . $checkout_pane->pane_id . '_field', '')) {
-		$order->{$field_name}[LANGUAGE_NONE][0]['profile_id'] = $profile->profile_id;
-	}
-	else {
-		// Or make the association in the order's data array if no field was found.
-		$order->data['profiles'][$checkout_pane->pane_id] = $profile->profile_id;
-	}
+  // Store the profile ID for the related field as specified on the settings form.
+  if ($field_name = variable_get('commerce_' . $checkout_pane->pane_id . '_field', '')) {
+    $order->{$field_name}[LANGUAGE_NONE][0]['profile_id'] = $profile->profile_id;
+  }
+  else {
+    // Or make the association in the order's data array if no field was found.
+    $order->data['profiles'][$checkout_pane->pane_id] = $profile->profile_id;
+  }
 }
 
 /**
@@ -146,14 +146,14 @@ function commerce_customer_profile_pane_checkout_form_submit($form, &$form_state
  *   Review checkout pane.
  */
 function commerce_customer_profile_pane_review($form, $form_state, $checkout_pane, $order) {
-	// Load the profile based on the related customer profile reference field...
-	if ($field_name = variable_get('commerce_' . $checkout_pane->pane_id . '_field', '')) {
-		$profile = commerce_customer_profile_load($order->{$field_name}[LANGUAGE_NONE][0]['profile_id']);
-	}
-	else {
-		// Or use the association stored in the order's data array if no field is set.
-		$profile = commerce_customer_profile_load($order->data['profiles'][$checkout_pane->pane_id]);
-	}
-
-	return drupal_render(commerce_customer_profile_build_content($profile, 'customer'));
+  // Load the profile based on the related customer profile reference field...
+  if ($field_name = variable_get('commerce_' . $checkout_pane->pane_id . '_field', '')) {
+    $profile = commerce_customer_profile_load($order->{$field_name}[LANGUAGE_NONE][0]['profile_id']);
+  }
+  else {
+    // Or use the association stored in the order's data array if no field is set.
+    $profile = commerce_customer_profile_load($order->data['profiles'][$checkout_pane->pane_id]);
+  }
+
+  return drupal_render(commerce_customer_profile_build_content($profile, 'customer'));
 }
-- 
1.7.0.2.msysgit.0

