[OpenLayers-Dev] iPhone Support

Stephen Woodbridge woodbri at swoodbridge.com
Thu Feb 11 14:20:53 EST 2010

Evan James Bowling wrote:
> Hey Steve,
>   Forgive my ignorance, but what does FF have to do with the iPhone? I 
> didn't think there was a Firefox App for the iPhone, but maybe you were 
> just talking about additional work you have done on OpenLayers in general.

Well, in general, I would like to build applications that work on any 
browser. It seems silly to me that we build an application for the 
iPhone and don't make it compatible with a desktop browser. I'm not 
opposed to changing the UI and other things so we are not dumping huge 
amounts of code to the mobile browsers for an optimized application, but 
given all the work that has gone into OpenLayers to make it cross 
browser enabled, it bothers me that people are making mobile browser 
libraries and apps that don't work in other browsers. Obvious you have 
to map touches and gestures to appropriate events and some interactions 
may be lost.

>   I have worked with OpenLayers for nearly a year now, but I haven't 
> contributed any patches or bug reports. Compatibility with mobile 
> browsers is important to me, and I was wondering if I could give you a 
> hand in any way. I'll start to root around with the above mentioned links.

That is great! I'm sure anything you might want to contribute to OL 
would be more than welcome. If you haven't filed a CLA yet read this:


At the moment I don't have any specific issues I need help with. I do 
need to figure our how to create a minified OpenLayers file with just 
the parts of OL that the application needs so it loads faster.

The next big feature I want to add to this demo is the ability to add 
persistent markers to the map where the user adds the marker at the 
current location of a selected location and then fills out a form and 
mabe adds a photo to it and that is all sent back to the server. Eitehr 
via my own Ajax code or maybe using something like featureserver. Then 
the app requests markers in the current view and draws them. Clicking on 
a marker opens up form window with the attributes and a picture thumbnail.

Some much to do and so little time :)

-Steve W

> -Evan
> On Thu, Feb 11, 2010 at 11:10 AM, Stephen Woodbridge 
> <woodbri at swoodbridge.com <mailto:woodbri at swoodbridge.com>> wrote:
>     Hi Bruno,
>     Thank you for putting up the sandbox. I was able to use that and make
>     some changes that you might be interested in. If you are interested in
>     adding them to the sandbox, I can make a patch against a clean version
>     of the sandbox.
>     I added mouse events to the buttons so they work also in FF.
>     I modified the button creation code so you can pass {text: "string"} and
>     string will be drawn as the button label
>     Here is a link [1] to what I got working. Be patience it takes a long
>     time to load over my DSL line and none of the JS is packaged up. You can
>     also load it in FF and the buttons and pan works with the mouse. Ignore
>     the Search functionality, I have not hooked that up yet.
>     [1] http://imaptools.com:8080/iphone/index2.html
>     Regards,
>       -Steve
>     Bruno Binet wrote:
>      > Hi,
>      >
>      > Sorry for the late response.
>      > I recently worked on the Camptocamp mobile sandbox to provide a
>     mobile
>      > interface with simple search functionnality for one of our customers.
>      > This sandbox is based on patched versions of IOL and iUI libraries.
>      > - IOL [1] is the OpenLayers mobile library initiated by OpenGeo which
>      > is able to handle touch events for example. Given Tim response on
>      > previous OL mobile thread, IOL is not targetted to be pushed in
>      > OpenLayers, but OL browser event handling stuff should rather be
>      > revisited so that OL could work transparently on mobile devices. So I
>      > think that future efforts on mobile should put directly in
>     OpenLayers.
>      > - iUI [2] is a ui library which mimics the iphone interface.
>      >
>      > The sandbox has been tested with webkit mobile devices only
>     (iphone OS
>      > and android). It was designed to work only on mobile devices, so that
>      > we could drop many dependencies and reduce the size of the js build.
>      > So you're right, we haven't tried to make it work transparently on
>      > desktop browser like firefox.
>      >
>      > Hope this clarifies the situation.
>      > Cheers,
>      >
>      > Bruno
>      >
>      > [1] http://projects.opengeo.org/mobile
>      > [2] http://code.google.com/p/iui/
>      >
>      > On 5 February 2010 22:38, Stephen Woodbridge
>     <woodbri at swoodbridge.com <mailto:woodbri at swoodbridge.com>> wrote:
>      >> Hi Devs,
>      >>
>      >> I have been looking into iPhone support for OpenLayers and have
>     found:
>      >>
>      >> 1) sandbox/camptocamp/mobile/ which looks promising and got it
>     working
>      >> 2) http://trac.openlayers.org/ticket/1994 (the demo is gone)
>      >> 3) are there other OL specific resources, examples?
>      >>
>      >> I was wondering if this is actively being worked on by someone? who?
>      >> Is there a list of mobile browser that are targeted for support?
>      >> My Acer NetBook has touch gestures but I haven't look into how
>     these are
>      >> presented as JS events.
>      >>
>      >> One thing I noticed with the camptocamp sandbox is that the page
>     does
>      >> not work in FireFox from my desktop. I am assuming that there is no
>      >> browser detection and code to handle mouse events in place of
>     touch events.
>      >>
>      >> In general I'm interested in where this is going and would be
>     interested
>      >> in testing things as they get added to trunk or sandboxes.
>      >>
>      >> Thanks,
>      >>   -Steve
>      >> _______________________________________________
>      >> Dev mailing list
>      >> Dev at openlayers.org <mailto:Dev at openlayers.org>
>      >> http://openlayers.org/mailman/listinfo/dev
>      >>
>      >
>      >
>      >
>     _______________________________________________
>     Dev mailing list
>     Dev at openlayers.org <mailto:Dev at openlayers.org>
>     http://openlayers.org/mailman/listinfo/dev

More information about the Dev mailing list