Closed
Bug 484158
Opened 15 years ago
Closed 14 years ago
Using the addEventListener moves focus from clicked objects
Categories
(Firefox :: General, defect)
Tracking
()
RESOLVED
INCOMPLETE
People
(Reporter: chico4, Unassigned)
Details
(Whiteboard: [CLOSEME 2010-11-01])
Attachments
(1 file)
4.68 KB,
text/html
|
Details |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.7) Gecko/2009021910 Firefox/3.0.7 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.7) Gecko/2009021910 Firefox/3.0.7 Hi, Consider this HTML (is also attached): <html> <head> <script> function myclick(){alert('click');return false;} </script> </head> <body> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#">aaaa</a></div> <div><a href="#" id="check">aaaa</a></div> <script> document.getElementById('check').addEventListener("click", myclick, false); </script> </body></html> Now load it in a small window in firfox, so you'll see a vertical scrollbar. Scroll down a little bit, then click on the last text. you'll see that the item has a focus rectangle, but the scrollbar jumps up. Is this a browser bug? how can I make the scrollbar not to jump and stay in the same location clicked? Thanks, Tal. Reproducible: Always Steps to Reproduce: 1.Load the attached HTML, scroll down until the last item and click on it. 2. 3. Actual Results: The scrollbar jumps up to the start instead of staying near the clicked item. Expected Results: Scrollbar doesnt move when clicking on the item.
That is not a bug, but a feature. # is a anchor, if you paste this at the end of your page: <a name="thefooter"></a> and you go to #thefooter, then you'll be scrolled down. Instead of using # to 'do nothing', use javascript:void(0);
Comment 3•14 years ago
|
||
This is a mass search for Firefox General bugs filed against version 3.0 that are UNCO and have not been changed for 200 days. Reporter, please update to Firefox 3.6.10 or alter. Firefox 3.0 is no longer supported and is no longer receiving updates. After you update, please create a fresh profile, http://support.mozilla.com/kb/managing+profiles, and test to see if your bug still exists. If you still the bug, then please post a comment with the version you tested against, and the problem. If the issue is no longer there, please set the RESOLUTION to RESOLVED, WORKSFORME.
Whiteboard: [CLOSEME 2010-11-01]
Comment 4•14 years ago
|
||
No reply from reporter, INCOMPLETE. Please retest with Firefox 3.6.12 or later and a new profile (http://support.mozilla.com/kb/Managing+profiles). If you continue to see this issue with the newest firefox and a new profile, then please comment on this bug.
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → INCOMPLETE
You need to log in
before you can comment on or make changes to this bug.
Description
•