View source
<?php
function gm3_region_menu() {
return array(
'gm3_region/callback/%' => array(
'title' => 'GM3 Region callback',
'page callback' => 'gm3_region_get_points',
'page arguments' => array(
2,
),
'file' => 'gm3_region.callback.inc',
'access arguments' => array(
'access content',
),
'type' => MENU_CALLBACK,
),
'gm3_region/callback2/%/%/%' => array(
'title' => 'GM3 Region callback',
'page callback' => 'gm3_region_get_region_id_from_latlng',
'page arguments' => array(
2,
3,
4,
),
'file' => 'gm3_region.callback.inc',
'access arguments' => array(
'access content',
),
'type' => MENU_CALLBACK,
),
);
}
function gm3_region_library() {
return array(
'region' => array(
'title' => t('Google Maps Javascript API V3: Region selection'),
'website' => 'http://code.google.com/apis/maps/',
'version' => '3',
'js' => array(
array(
'data' => drupal_get_path('module', 'gm3_region') . "/js/gm3_region.region.js",
),
array(
'data' => array(
'gm3_region' => array(
'callback' => url('gm3_region/callback'),
'callback2' => url('gm3_region/callback2'),
),
),
'type' => 'setting',
),
),
'dependencies' => array(
array(
'gm3',
'gm3.polygon',
),
),
),
);
}
function gm3_region_theme() {
return array(
'gm3_region_button' => array(
'variables' => array(
'id' => 'gm3-map',
),
'file' => 'gm3_region.theme.inc',
),
'gm3_region_region_text' => array(
'variables' => array(
'data' => array(),
),
'file' => 'gm3_region.theme.inc',
),
);
}