Closed
Bug 156137
Opened 19 years ago
Closed 18 years ago
onClick on a link doesn't fire on middle click
Categories
(Core :: DOM: UI Events & Focus Handling, defect)
Core
DOM: UI Events & Focus Handling
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: bugzilla, Assigned: joki)
References
Details
(Whiteboard: WONTFIX?)
Attachments
(1 file)
223 bytes,
text/html
|
Details |
Originally reopened bug 63950, this bug is being refiled per jruderman@hmc.edu. Note that it is almost the opposite of bug 151142 and is dependent on bug 70501. onClick doesn't fire when a middle click is issued to open a tab in a new window. This behavior was noted on both Linux and Windows release versions of Mozilla 1.0.
Reporter | ||
Comment 1•19 years ago
|
||
![]() |
||
Comment 2•19 years ago
|
||
Sorry, this is done on purpose -- a lot of sites assume that "onclick" is only fired for the left button (since that is what IE and NS4 do). See bug 71705 I feel that this must (regretfully) be wontfixed -- it would break a large number of sites and make browsing suck a lot more if we implemented this...
Whiteboard: WONTFIX?
Comment 3•19 years ago
|
||
Middle-clicking on the body element fires onclick, but middle-clicking on a link has a special meaning and so it does not fire onclick. Btw, what are you trying to do in the onclick handler for the link?
Summary: onClick doesn't fire on middle click → onClick on a link doesn't fire on middle click
Reporter | ||
Comment 4•19 years ago
|
||
Testcase HTML is what I'm trying to do. I have a list of items that get generated out of an application that need to be looked at and/or fixed. I am one of three people that run this, and the other two aren't exactly techno-savvy. They use IE6 for this app while I use Mozilla. The app generates this list, which can be up to 1500 items long. When one clicks on a link, the check box gets checked and a new window pops up so that the item can be looked at or fixed, then the window closed so the list doesn't have to be constantly re-generated. The check box holds the place in the list so that if I have to do something else, I don't get list. Now, I am a fervent believer in tabbed browsing, because I hate having 10 open windows. So when I want to open the link, I middle-click to open the tab. I expect that the checkbox would check. But it doesn't, and I have to manually do that. I would also accept as resolution to this bug: 1) a way to open a link in a new tab via HTML 2) a way to open a link in a new tab as a Javascript action 3) a preference that "_blank" opens a new tab (see bug 103843, bug 104204, bug 105409) Sites don't necessarily know what middle-click is. They know left is primary and right is context menu (if possible.) On a mac, right click is accomplished by command-click. So control-click or middle button doesn't have a worldwide assigned feature (but sometimes it does, as in bug 151142). Sometimes it has odd effects (big 70498). Sometimes it doesn't Do What You Expect (bug 98984, bug 107147). Sometimes people even get confused if bugs are features (bug 57317, which in turn changed behaviour between platforms!). I particularly like the argument given in bug 71705 comment 28 where the point is made that sometimes people need to do what they want to do, not what you expect them to want. I also like the argument that sometimes what the user wants is more important than what the developer wants (many bugs listed here have this argument throughout). I feel everyone needs to discuss what middle mouse button is really, really supposed to do - there doesn't seem to be any design document explaining what it's supposed to do when.
Reporter | ||
Comment 5•19 years ago
|
||
Is there a meta bug for middle-click? Or are all these middle-click issues (including this one) going to sit in an undefined state until someone gives up and Does It Their Way?
Comment 6•19 years ago
|
||
I vote for Wontfix as well. We should get this of the UNCONF radar, atleast. Boris ?
![]() |
||
Comment 7•19 years ago
|
||
It's up to the module owner, imo.
Comment 8•19 years ago
|
||
*** Bug 159711 has been marked as a duplicate of this bug. ***
*** Bug 164042 has been marked as a duplicate of this bug. ***
Updated•18 years ago
|
QA Contact: rakeshmishra → trix
Reporter | ||
Comment 10•18 years ago
|
||
This may have been fixed without further comment; a middle-click on the link in the attachment is now checking the box, and thus it looks like onClick is firing on middle-click; at least in 1.3 alpha (BID:2002121222) Someone else care to confirm and/or mark CLOSED/FIXED?
![]() |
||
Comment 11•18 years ago
|
||
That was a regression in 1.3a. In 1.3b it will not work again. I'm resolving this wontfix. We got a large number of reports of _user_ (not developer) problems reported with 1.3a because of the regression in it...
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago
Resolution: --- → WONTFIX
Reporter | ||
Comment 12•18 years ago
|
||
I have to admit I'm disappointed with this decision. Still, a discussion about what middle-click is supposed to do when would be nice. Or maybe the target="_blank" to new tab pref (bug 103843 comment 43 or perhaps bug 105547) would help...?
![]() |
||
Comment 13•18 years ago
|
||
Sure. But this is a bug on DOM events. We can't usefully fire onclick on non-left-click in the current state of the web.... UI suggestions for Mozilla should live in bugs in the UI component. ;)
Comment 14•16 years ago
|
||
*** Bug 290231 has been marked as a duplicate of this bug. ***
Comment 15•16 years ago
|
||
*** Bug 309771 has been marked as a duplicate of this bug. ***
Updated•2 years ago
|
Component: Event Handling → User events and focus handling
You need to log in
before you can comment on or make changes to this bug.
Description
•