Permalink
Browse files

Allow pan or zoom the map when the mouse is in popup active area.

  • Loading branch information...
1 parent 413ca11 commit 77727548c9e066397d52d7315efa8b33408d0976 @jorix committed Dec 30, 2012
Showing with 6 additions and 2 deletions.
  1. +6 −2 examples/feature-popups-plus.js
@@ -3,7 +3,10 @@
// ** advanced use **
var framedCloudScrollable = OpenLayers.Class(OpenLayers.Popup.FramedCloud, {
- displayClass: "olScrollable olPopup"
+ displayClass: "olScrollable olPopup",
+ registerEvents:function() {
+ this.events = new OpenLayers.Events(this);
+ }
});
var singleEventListeners = {
"beforepopupdisplayed": function(e) {
@@ -25,7 +28,8 @@ var fpControl = new OpenLayers.Control.FeaturePopups({
// ** Don't use close box on popups
mode: OpenLayers.Control.FeaturePopups.DEFAULT &
~OpenLayers.Control.FeaturePopups.CLOSE_BOX,
- // ** Allow to zoom with the scroll wheel when the mouse is in the single popup active area (see `framedCloudScrollable`)
+ // ** Allow pan or zoom the map and to zoom with the scroll wheel when the
+ // mouse is in popup active area (see `framedCloudScrollable`)
// ** Alert instead of popup on `poisLayer` (see `singleEventListeners`)
popupSingleOptions: {
popupClass: framedCloudScrollable,

0 comments on commit 7772754

Please sign in to comment.