Permalink
Browse files

In plus dev example use OL "MouseWheel.js" development code as patch.

  • Loading branch information...
1 parent b1f0ef7 commit 34ab5720c9b6ca8e5a2fe982ae7148afcb396ac2 @jorix committed Dec 16, 2012
Showing with 56 additions and 1 deletion.
  1. +54 −0 examples/feature-popups-plus-dev.html
  2. +2 −1 examples/feature-popups-plus.js
@@ -0,0 +1,54 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+ <meta name="lang" content="en" />
+ <meta name="author" content="Jorix" />
+ <meta name="description" content="Usage example of FeaturePopups control for OpenLayers that wraps the management of popups and SelectFeature control" />
+ <meta name="keywords" content="OpenLayers, SelectFearure, popup, BBOX, cluster, clustering, strategy, template, safe selection, keep selection, FeaturePopups" />
+
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
+ <meta name="apple-mobile-web-app-capable" content="yes">
+ <link rel="stylesheet" href="../github-pages/forkme_banner.css" type="text/css">
+
+ <title>Example advanced use of FeaturePopups for OpenLayers</title>
+ <script src="http://jorix.github.com/OL-Ragbag/dev/releaseEnvirontment.js"></script>
+ <script>
+ var release = new releaseEnvironment({
+ defaults: {patch: true},
+ patches: [
+ "../lib/patches_OL-popup-autosize.js",
+ "http://www.openlayers.org/dev/lib/OpenLayers/Handler/MouseWheel.js"
+ ]
+ });
+ release.writeScripts();
+ </script>
+ <link rel="stylesheet" href="http://www.openlayers.org/dev/theme/default/style.css" type="text/css">
+ <link rel="stylesheet" href="http://www.openlayers.org/dev/examples/style.css" type="text/css">
+ <style>
+ .olControlFeaturePopups_list{font-size: 80%;}
+ .olControlFeaturePopups_list ul{margin-bottom: 0}
+ </style>
+ <script src="../lib/FeaturePopups.js"></script>
+
+ </head>
+ <body>
+ <h1 id="title">??</h1>
+ <div id="environmentForm"></div>
+ <script>
+ release.writeSelectionForm("environmentForm", "title");
+ </script>
+ <a id="forkme_banner" href="https://github.com/jorix/OL-FeaturePopups">View on GitHub</a>
+ <div id="tags">popups, vector layers, templates, advanced</div>
+ <div id="map" style="width: 600px; height: 500px;" class="smallmap"></div>
+ <div id="docs">
+ <p>
+ View the <a href="feature-popups-plus.js" target="_blank">feature-popups-plus.js</a>
+ source to see how this is done.
+ (see also <a href="feature-popups-common.js" target="_blank">feature-popups-common.js</a>)
+ </p>
+ </div>
+ <script src="feature-popups-common.js"></script>
+ <script src="feature-popups-plus.js"></script>
+ </body>
+</html>
@@ -16,8 +16,9 @@ var fpControl = new OpenLayers.Control.FeaturePopups({
~OpenLayers.Control.FeaturePopups.CLOSE_BOX,
// ** Allow to zoom with the scroll wheel when the mouse is in the single popup active area, but like all drugs can have side effects ;-) **
popupSingleOptions: {popupClass: framedCloudScrolable},
+ popupListItemOptions: {popupClass: framedCloudScrolable},
// ** Overwrites html of the list popups adding a vacuum <li> before each item **
- popupListOptions: {eventListeners: {
+ popupListOptions: {popupClass: framedCloudScrolable, eventListeners: {
"beforepopupdisplayed": function(e){
var html = [],
feature0 = null,

0 comments on commit 34ab572

Please sign in to comment.