[OpenLayers-Trac] [OpenLayers] #1073: Allow specification of per-entry icons for RSS feeds
OpenLayers
trac at openlayers.org
Sat Nov 3 18:27:28 EDT 2007
#1073: Allow specification of per-entry icons for RSS feeds
---------------------------+------------------------------------------------
Reporter: ianmayo | Owner: crschmidt
Type: feature | Status: new
Priority: minor | Milestone: 2.6 Release
Component: Layer.GeoRSS | Version: 2.5 RC5
Resolution: | Keywords: review
---------------------------+------------------------------------------------
Changes (by ahocevar):
* keywords: => review
Comment:
Ok, I kept thinking about the usefulness of the style and rule framework,
and here I am finally with a patch, incremental to
http://trac.openlayers.org/ticket/533. It makes minor changes to three
classes:
* OpenLayers.Layer.GeoRSS: new style property which will be passed to the
marker, if set. Also parses the "category" tag in RSS 2
* OpenLayers.Marker: new feature and style properties. Both will be
destroyed in the destroy method, to avoid memory leaks by the circular
reference between feature and marker. Also, if the style property is set,
it will be parsed and the marker icon will be set to the externalGraphic
property of the style.
* OpenLayers.Feature: adds a reference to itself in the createMarker
method. So now the marker knows about its feature, like geometries already
do.
I also modified the georss.html example to show the new feature, by using
the newly added georss-category.xml example feed.
--
Ticket URL: <http://trac.openlayers.org/ticket/1073#comment:3>
OpenLayers <http://openlayers.org/>
A free AJAX map viewer
More information about the Trac
mailing list