Index: location.views.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/location/location.views.inc,v
retrieving revision 1.16.2.4
diff -u -p -r1.16.2.4 location.views.inc
--- location.views.inc	29 Sep 2010 12:41:28 -0000	1.16.2.4
+++ location.views.inc	10 Feb 2011 08:33:38 -0000
@@ -504,6 +504,21 @@ function location_views_proximity_get_re
         }
       }
       break;
+    case 'address':
+    case 'address_default':
+      // Force default for country.
+      if ($options['origin'] == 'address_default') {
+        $options['country'] = variable_get('location_default_country', 'us');
+      }
+      // Address lookup.
+      if (!empty($options['address_string']) && !empty($options['country'])) {
+	 //geocoding
+        $location = array(
+          'street' => $options['address_string'],
+          'country' => $options['country'],
+        );
+        $coords = google_geocode_location($location);
+        if ($coords) {
+          $coordinates['latitude'] = (float) $coords['lat'];
+          $coordinates['longitude'] = (float) $coords['lon'];
+        }
+      }
+      break;
     case 'php':
       ob_start();
       $result = eval($options['php_code']);
Index: handlers/location_views_handler_filter_proximity.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/location/handlers/location_views_handler_filter_proximity.inc,v
retrieving revision 1.3.2.5
diff -u -p -r1.3.2.5 location_views_handler_filter_proximity.inc
--- handlers/location_views_handler_filter_proximity.inc	29 Sep 2010 14:04:55 -0000	1.3.2.5
+++ handlers/location_views_handler_filter_proximity.inc	10 Feb 2011 08:33:39 -0000
@@ -22,6 +22,7 @@ class location_views_handler_filter_prox
         'latitude' => '',
         'longitude' => '',
         'postal_code' => '',
+        'address_string' => '',
         'country' => '',
         'php_code' => '',
         'nid_arg' => '',
@@ -78,6 +79,8 @@ class location_views_handler_filter_prox
         'static' => t('Static  Latitude / Longitude'),
         'postal' => t('Postal Code / Country'),
         'postal_default' => t('Postal Code (assume default country)'),
+        'address' => t('Address / Country'),
+        'address_default' => t('Address (assume default country)'),
         'php' => t('Use PHP code to determine latitude/longitude'),
         'nid_arg' => t("Node's Latitude / Longitude from views nid argument"),
         'uid_arg' => t("User's Latitude / Longitude from views uid argument"),
@@ -137,13 +140,21 @@ class location_views_handler_filter_prox
       '#dependency' => array('edit-options-origin' => array('postal', 'postal_default')),
       '#weight' => 3,
     );
+    $form['value']['address_string'] = array(
+      '#type' => 'textfield',
+      '#title' => t('Address'),
+      '#default_value' => $this->value['address_string'],
+      '#process' => array('views_process_dependency'),
+      '#dependency' => array('edit-options-origin' => array('address', 'address_default')),
+      '#weight' => 3,
+    );
     $form['value']['country'] = array(
       '#type' => 'select',
       '#title' => t('Country'),
       '#options' => array('' => '') + location_get_iso3166_list(),
       '#default_value' => $this->value['country'],
       '#process' => array('views_process_dependency'),
-      '#dependency' => array('edit-options-origin' => array('postal')),
+      '#dependency' => array('edit-options-origin' => array('postal', 'address')),
       '#weight' => 4,
     );
 
@@ -263,7 +274,10 @@ class location_views_handler_filter_prox
     if ($origin != 'postal' && $origin != 'postal_default') {
       unset($form[$key]['postal_code']);
     }
-    if ($origin != 'postal') {
+    if ($origin != 'address' && $origin != 'address_default') {
+      unset($form[$key]['address_string']);
+    }
+    if ($origin != 'postal' && $origin != 'address') {
       unset($form[$key]['country']);
     }
 
