[Geomoose-users] use esc key to deactivate tools

Jim Klassen klassen.js at gmail.com
Mon Mar 25 21:21:04 PDT 2013


Given the nature of this extension requiring OpenLayers to be updated, I am reluctant to put it in trunk until the OL dependency is met.  While it works for me, but please consider this experimental and understand you will need a good working knowledge of GeoMoose and its build system to effectively use it.  Also, recognize that there has been little to no testing of GeoMoose against OpenLayers 2.12 so you are on your own.  Also, please do not use this as an example of how to write a proper extension.  That said, for the adventurous and those who don't care (or know how to fix it if it breaks with the next GeoMoose release), enjoy.

http://www.geomoose.org/wiki/index.php/Keyboard_Control

On Mar 25, 2013, at 3:48 PM, Matej Mailing wrote:

> Jim, that sounds great. It would be a very useful addon.
> 
> Matej
> 
> 
> 2013/3/25 Jim Klassen <klassen.js at gmail.com>
> I've got an extension that enables the OpenLayers Keyboard Controls to pan/zoom the map.  I haven't released it yet because it required a few changes to GeoMoose core that I haven't had time to package up.
> 
> The trickiest part is getting the control to NOT respond when you don't want it to.  (Such as arrow keys in an input field).  This requires OpenLayers 2.12 and a few other minor changes.  If there is interest I can work on packing it up.  My strategy was to activate the keyboard control when one of the pan/zoom in/zoom out tools is active.  The tool deactivates when the user changes tools or moves focus outside of the map.
> 
> 
> On Mar 25, 2013, at 1:45 PM, Matej Mailing wrote:
> 
>> Hi,
>> 
>> one interesting addon to your idea would also be to have left/right/up/down arrows with the functionalities. I am not so much into ajax part of the code, but would welcome any progress on that.
>> 
>> Regards,
>> Matej
>> 
>> 
>> 2013/3/24 Boris <franticpianist at yahoo.co.uk>
>> Hi there,
>> I just installed the latest geomoose and ms4w.
>> And i was wondering if anyone could help me write an extension to use the esc key to deactivate any active tool, or if this had already been done before, or if it is too big a task to be an easy fix?
>> 
>> Thank you
>> Boris
>> _______________________________________________
>> Geomoose-users mailing list
>> Geomoose-users at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/geomoose-users
>> 
>> _______________________________________________
>> Geomoose-users mailing list
>> Geomoose-users at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/geomoose-users
> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geomoose-users/attachments/20130326/cb727e87/attachment-0001.html>


More information about the Geomoose-users mailing list