On Mon, Jan 19, 2009 at 3:30 PM, Alexandre Dube <[email protected]> wrote: > Hi Eric, > > I took a look at the SelectFeature control. Now I understand what you > meant and it makes sense. Also, it's also making sense to have this control > have the possibility to highlight on hover or on click. > > "beforefeaturehighlighted" and "featurehighlighted" events make sense, but > a "featureunhighlighted" (or some other term meaning that the feature was > highlighted and is now no more) would also be useful.
Alexandre, The more I think about this highlight feature control the more I think there's no room for both a select feature and a highlight feature controls. What causes people trouble is that they can't use two select feature controls, one in hover mode and the other in click mode. This is because once a feature is hovered it is selected, and cannot be selected again when it is clicked. Maybe we could modify the select feature control so that (1) it optionally uses its own selectedFeatures array, as opposed to relying on the layer's, and (b) defines its own "beforefeatureselected", "featureselected" and "featureunselected" event types. In this way, one should be able to use two select feature controls, and get "featureselected" events, from the first control when features are hovered and from the second control when features are clicked. Tell me what you think, -- Eric _______________________________________________ Users mailing list [email protected] http://openlayers.org/mailman/listinfo/users
