[OpenLayers-Dev] Wanted: a generic control wrapper

Ludwig Max Brinckmann ludwigbrinckmann at gmail.com
Thu Nov 9 09:54:20 EST 2006


One step at a time. For the moment I just wanted to factor out the code the
operates the generics of a control. But once this is done then OpenLayers
would have the base to build some sort of dashboard for controls.

Ludwig

On 11/8/06, Cameron Shorter <cameron.shorter at gmail.com> wrote:
>
> Sounds like you are asking for a ToolBar or ControlBar.
> A ToolBar shows an array of Tool Icons. When you select a tool, you get
> a Control popup, or you change the way a Control works.
>
> The entire Toolbar should be able to be hidden or expanded.
>
> There should be a distinction between the different types of buttons.
> They can be:
> * 2 State - on/off, multiple tools can be selected at once
> * Radio buttons - on/off, pressing one button deselects other radio
> buttons
> * One Shot
>
> (I'm also interested in this sort of functionality)
>
> Ludwig Max Brinckmann wrote:
> > I find that there is a little too much combination of 'business-logic'
> > and presentation in the way the LayerSwitcher is implemented. One aspect
> > of it is the actual layer control, but the other is just having a
> > control that can be opened and closed.
> >
> > I do not know if you have considered separating the two, so that there
> > would be a generic control, which would set up the open/close
> > functionality and have some ways of positioning it on the page plus a
> > control over the size when opened.
> > A second bit of functionality would be e.g. the layerswitcher, which
> > would simply fill a div in the generic control and to which the generic
> > control would delegate when redrawing the contents.
> > This would make it easier to develop custom controls that one could fill
> > with additional functionality, with a shared behaviour/appearance on the
> > screen.
> >
> > I hacked out some simple stuff that I just need for a demo here, but you
> > can see the base idea at
> > http://iceds.ge.ucl.ac.uk/OL/control.html
> >
> > On the right hand side are three controls, the top a variation of the
> > layerswitcher, the bottom two browsers that will allow adding a layer to
> > OpenLayers by clicking on a WMS Layer. All three controls just use the
> > same dummy control to handle the opening and there are ways to set the
> > size and position....
> >
> > (The green sliders in the layerswitcher are supposed to enable a user to
> > adjust the opacity of a layer, but somehow the sliders do not get the
> > mouse focus, as the map dragging monopolises it. The layers are also
> > supposed to be restackable using scriptaculous sortable, but in this
> > version it does not work for the same reason).
> >
> > I have only tested this on firefox (it does not work at all on IE) and
> > there a quite a few bugs in it, but I thought submitting the idea to get
> > some more input on how this could be done in the most generic fashion.
> >
> > Ludwig
> >
> >
> >
> > ------------------------------------------------------------------------
> >
> > _______________________________________________
> > Dev mailing list
> > Dev at openlayers.org
> > http://openlayers.org/mailman/listinfo/dev
>
>
> --
> Cameron Shorter
> http://cameron.shorter.net
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-dev/attachments/20061109/3af45c5e/attachment.html


More information about the Dev mailing list