From 7963fb6a7f46a2d0d745b2dc86d1d7dcd91fa294 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Junod?= Date: Thu, 31 Mar 2011 11:28:11 +0000 Subject: [PATCH] add modify feature control to mobile drawing example git-svn-id: http://svn.openlayers.org/trunk/openlayers@11833 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf --- build/mobile.cfg | 1 + examples/mobile-drawing.html | 6 ++++++ examples/mobile-drawing.js | 4 ++++ 3 files changed, 11 insertions(+) diff --git a/build/mobile.cfg b/build/mobile.cfg index b1305ecc10..bea6f52ed7 100644 --- a/build/mobile.cfg +++ b/build/mobile.cfg @@ -15,6 +15,7 @@ OpenLayers/Control/ZoomPanel.js OpenLayers/Control/Attribution.js OpenLayers/Control/SelectFeature.js OpenLayers/Control/DrawFeature.js +OpenLayers/Control/ModifyFeature.js OpenLayers/Control/Panel.js OpenLayers/Handler/Point.js OpenLayers/Handler/Path.js diff --git a/examples/mobile-drawing.html b/examples/mobile-drawing.html index 42f91cf2f6..cdcdafbb45 100644 --- a/examples/mobile-drawing.html +++ b/examples/mobile-drawing.html @@ -55,6 +55,12 @@ div.olControlZoomPanel .olControlZoomToMaxExtentItemInactive { display: none; } + .olControlEditingToolbar .olControlModifyFeatureItemInactive { + background-position: -1px -1px; + } + .olControlEditingToolbar .olControlModifyFeatureItemActive { + background-position: -1px -24px; + } #title, #tags, #shortdesc { display: none; } diff --git a/examples/mobile-drawing.js b/examples/mobile-drawing.js index c5f23e5cf5..c4083e8a7b 100644 --- a/examples/mobile-drawing.js +++ b/examples/mobile-drawing.js @@ -20,6 +20,10 @@ function init() { new OpenLayers.Control({ displayClass: 'olControlNavigation' }), + new OpenLayers.Control.ModifyFeature(vector, { + vertexRenderIntent: 'temporary', + displayClass: 'olControlModifyFeature' + }), new OpenLayers.Control.DrawFeature(vector, OpenLayers.Handler.Point, { displayClass: 'olControlDrawFeaturePoint' }),