Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Disabling Map Scrolling in "The Events Calendar" 2.0.11
--- /the-events-calendar/admin-views/event-map.php Tue Apr 2 21:47:46 2013
+++ /the-events-calendar/admin-views/event-map.php Tue Apr 2 21:41:11 2013
@@ -14,6 +14,7 @@
function initialize() {
var myOptions = {
+ scrollwheel: <?php echo tribe_get_option( 'embedGoogleMapsEnableScrollWheel', true ) ? 'true' : 'false' ; ?>,
zoom: <?php echo tribe_get_option( 'embedGoogleMapsZoom', '10' ); ?>,
center: event_address,
mapTypeId: google.maps.MapTypeId.ROADMAP
--- /the-events-calendar/admin-views/tribe-options-general.php Tue Apr 2 21:47:46 2013
+++ /the-events-calendar/admin-views/tribe-options-general.php Tue Apr 2 21:38:27 2013
@@ -157,6 +157,15 @@
'class' => 'google-embed-field',
'validation_type' => 'number_or_percent',
),
+ 'embedGoogleMapsEnableScrollWheel' => array(
+ 'type' => 'checkbox_bool',
+ 'label' => __( 'Google Maps Enable Scrollwheel', 'tribe-events-calendar' ),
+ 'tooltip' => __( 'Turn off to disable scrollwheel zooming on the map', 'tribe_events_calendar' ),
+ 'size' => 'small',
+ 'default' => true,
+ 'class' => 'google-embed-field',
+ 'validation_type' => 'boolean',
+ ),
'sendPressTrendsData' => array(
'type' => 'checkbox_bool',
'label' => __( 'Send PressTrends Data', 'tribe-events-calendar' ),
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment