Answering my own question - you would use displayClass to override the image as documented at: http://dev.openlayers.org/releases/OpenLayers-2.8/doc/apidocs/files/OpenLayers/Control/Button-js.html
Happy holidays! Rich On Thu, Dec 24, 2009 at 9:44 AM, Richard Greenwood <[email protected]> wrote: > I have two OpenLayers.Control.DrawFeature controls in my panel. One > draws a Polygon, the other a regular polygon. So I want to have > different button background-images for the two buttons, but they both > are getting the background-image defined by the > .olControlDrawFeatureItemInactive class. > > I (think) I have assigned a unique id to the two controls: > > new OpenLayers.Control.DrawFeature(lyrVectors, > OpenLayers.Handler.RegularPolygon, > {handlerOptions: {sides: 24}, title: 'Draw a circle.', id: > 'drawEllipse'}), > new OpenLayers.Control.DrawFeature(lyrVectors, > OpenLayers.Handler.Polygon, > {title: 'Draw a polygon. Double click when done.', id: > 'drawPoly'}), > > and in my .css I am attempting to use the id to assign a unique > background-image: > > div#drawPoly { > background-image: url("../graphics/polygon.gif"); > } > > I may be going about this in completely the wrong way. Any help is > appreciated. > > Thanks, > Rich > > -- > Richard Greenwood > [email protected] > www.greenwoodmap.com > -- Richard Greenwood [email protected] www.greenwoodmap.com _______________________________________________ Users mailing list [email protected] http://openlayers.org/mailman/listinfo/users
