Ticket #984 (closed feature: wontfix)
Attribution control does not allow external element to be used
| Reported by: | openlayers | Owned by: | |
|---|---|---|---|
| Priority: | minor | Milestone: | |
| Component: | Control | Version: | SVN |
| Keywords: | attribution control | Cc: | grand.edgemaster@… |
| State: |
Description
It would be nice if the Attribution control would allow an external div to be used, like the mouseposition control currently does.
For the short term in my personal code, I've created a wrapper class to implement it:
OpenLayers.Control.CAttribution = OpenLayers.Class(OpenLayers.Control.Attribution, {
element: null,
draw: function() {
OpenLayers.Control.Attribution.prototype.draw.apply(this, arguments);
if(this.element) this.div.style.display = "none";
},
updateAttribution: function() {
OpenLayers.Control.Attribution.prototype.updateAttribution.apply(this, arguments);
if(this.element) this.element.innerHTML = this.div.innerHTML;
},
CLASS_NAME: "OpenLayers.Control.CAttribution"
});
Change History
Note: See
TracTickets for help on using
tickets.
