You are here

function legacy_gmap_defaults in GMap Module 7.2

Get the defaults for a gmap.

1 call to legacy_gmap_defaults()
legacy__gmap_parse_macro in tests/inc/gmap_parse_macro.inc

File

tests/inc/gmap_defaults.inc, line 12
Contains gmap_defaults.inc

Namespace

tests\inc

Code

function legacy_gmap_defaults() {
  $defaults = array(
    'width' => '300px',
    'height' => '200px',
    'zoom' => 3,
    'maxzoom' => 14,
    'controltype' => 'Small',
    'pancontrol' => 1,
    'streetviewcontrol' => 0,
    'align' => 'None',
    'latlong' => '40,0',
    'maptype' => 'Map',
    'mtc' => 'standard',
    'baselayers' => array(
      'Map',
      'Satellite',
      'Hybrid',
    ),
    'styles' => array(
      'line_default' => array(
        '0000ff',
        5,
        45,
        '',
        0,
        0,
      ),
      'poly_default' => array(
        '000000',
        3,
        25,
        'ff0000',
        45,
      ),
      'highlight_color' => 'ff0000',
    ),
    'line_colors' => array(
      '#00cc00',
      '#ff0000',
      '#0000ff',
    ),
  );
  $defaults['behavior'] = array();
  $m = array();
  $behaviors = legacy_gmap_module_invoke('behaviors', $m);
  foreach ($behaviors as $k => $v) {
    $defaults['behavior'][$k] = $v['default'];
  }
  $defaults = array_merge($defaults, variable_get('gmap_default', array()));
  return $defaults;
}