You are here

function getlocations_gps_defaults in Get Locations 7

Same name and namespace in other branches
  1. 7.2 modules/getlocations_gps/getlocations_gps.module \getlocations_gps_defaults()

Set up default settings.

Return value

array $newdefaults

3 calls to getlocations_gps_defaults()
getlocations_gps_map_display_options_form in modules/getlocations_gps/getlocations_gps.module
getlocations_gps_settings_form in modules/getlocations_gps/getlocations_gps.module
Function to display the getlocations_gps admin settings form
getlocations_js_settings_do in ./getlocations.module
Function sets up javascript settings
1 string reference to 'getlocations_gps_defaults'
getlocations_gps_uninstall in modules/getlocations_gps/getlocations_gps.install
Implements hook_uninstall().

File

modules/getlocations_gps/getlocations_gps.module, line 69
getlocations_gps.module @author Bob Hutchinson http://drupal.org/user/52366 @copyright GNU GPL

Code

function getlocations_gps_defaults($settings = '') {
  $getlocations_gps_defaults = array(
    'gps_button' => 0,
    // checkbox
    'gps_button_label' => t('Show current position'),
    // tf
    'gps_marker' => 'drupal',
    'gps_marker_title' => t('Your current position'),
    'gps_bubble' => 0,
    // checkbox
    'gps_geocode' => 0,
    // checkbox
    'gps_center' => 0,
    // checkbox
    'gps_type' => 0,
    'gps_zoom' => -1,
    'gps_latlon_path' => url('getlocations_gps/latlon'),
  );
  if ($settings) {
    $getlocations_gps_defaults = getlocations_adjust_vars($getlocations_gps_defaults, $settings);
  }
  else {
    $getlocations_gps_defaults = variable_get('getlocations_gps_defaults', $getlocations_gps_defaults);
  }
  return $getlocations_gps_defaults;
}