openlayers_behavior_dragpan

DragPan Behavior

Hierarchy

Functions & methods

NameDescription
openlayers_behavior::__construct
openlayers_behavior_dragpan::js_dependency Overrides openlayers_behavior::js_dependency
openlayers_behavior_dragpan::options_form Overrides openlayers_behavior::options_form
openlayers_behavior_dragpan::options_initProvide initial values for options. Overrides openlayers_behavior::options_init
openlayers_behavior_dragpan::renderRender. Overrides openlayers_behavior::render

includes/behaviors/openlayers_behavior_dragpan.inc, line 12

View code
<?php
class openlayers_behavior_dragpan extends openlayers_behavior {
  /**
   * Provide initial values for options.
   */
  function options_init() {
    return array(
      'navigation' => '',
    );
  }

  function js_dependency() {
    return array('OpenLayers.Control.DragPan');
  }

  function options_form($defaults) {
    return array();
  }

  /**
   * Render.
   */
  function render(&$map) {
    drupal_add_js(drupal_get_path('module', 'openlayers') . 
      '/includes/behaviors/js/openlayers_behavior_dragpan.js');
    return $this->options;
  }
}
?>