Opened 10 years ago
Closed 10 years ago
#14028 closed bug (notabug)
delegate event
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | undecided | Milestone: | None |
Component: | unfiled | Version: | 1.10.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
considering DOM such as A
and code: element.delegate(":not(C *)","click",dosomething); if click inside C, this statement will trigger click event but that is not we want. read source code I found in "Find delegate handlers" will bubble from inside C until A, so when trying until B it will be matched and apply dosomething hanler. is it a bug?
Change History (4)
comment:1 Changed 10 years ago by
comment:2 Changed 10 years ago by
additionally, if C has many ancestors until B, dosomething will be triggered as many times
comment:3 Changed 10 years ago by
why handlers function iterate ancestor nodes of event target? I assume only test selector on event target is enough.
comment:4 Changed 10 years ago by
Resolution: | → notabug |
---|---|
Status: | new → closed |
Please ask for help on a forum.
Note: See
TracTickets for help on using
tickets.
sorry for bad format. A/B/C means: A is parent of B, B is parent of C, C has chlildren