nohref was initially implemented in bug 7304 but has since broken again. It should be an easy fix but I'm not sure where the appropriate place to insert a check for this attribute would be. I'd like to remove all href/target/etc-aware code out of the imagemap code since it just begs for bugs to keep it duplicated in there. Anyone got any suggestions?
see also bug 234615
> It should be an easy fix but I'm not sure where the appropriate place to insert > a check for this attribute would be. Probably nsHTMLAreaElement::HandleDOMEvent. It should just call nsGenericHTMLElement::HandleDOMEvent if nohref is set. > I'd like to remove all href/target/etc-aware code out of the imagemap code Where is this in imagemap code, really? You mean the stuff in bug 234615? Yeah, that's gotta go.
Yeah, the stuff in bug 234615 as well as the small remainder in terms of the implementation and callers of Area::GetHREF. I think we need it in more then just nsHTMLAreaElement::HandleDOMEvent (well, actually nsGenericHTMLElement::HandleDOMEventForAnchors, right?) since we want to: A) Not follow the link when clicked on B) Not change the cursor when hovering the link
Ah, you are indeed right, nohref is an <area> thing only so the code for it should not live in nsGenericHTMLElement::HandleDOMEventForAnchors
What needs to be done here?
WORKSFORME per https://bugzilla.mozilla.org/attachment.cgi?id=1042.
Status: NEW → RESOLVED
Last Resolved: 3 months ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.