From 642318d4796b5178a3e17b6396ceda95249ff7f0 Mon Sep 17 00:00:00 2001 From: "ojan@chromium.org" Date: Mon, 21 Feb 2011 06:41:43 +0000 Subject: [PATCH] 2011-02-20 Ojan Vafai Reviewed by Adam Barth. [codereviewtool] don't let lines/diffblocks be mouse focusable https://bugs.webkit.org/show_bug.cgi?id=54851 Unfortunately, this will only work once https://bugs.webkit.org/show_bug.cgi?id=54727 is committed. In the interim, it won't break anything. * code-review.js: git-svn-id: https://svn.webkit.org/repository/webkit/trunk@79185 268f45cc-cd09-0410-ab3c-d52691b4dbfc --- Websites/bugs.webkit.org/ChangeLog | 12 ++++++++++++ Websites/bugs.webkit.org/code-review.js | 2 ++ 2 files changed, 14 insertions(+) diff --git a/Websites/bugs.webkit.org/ChangeLog b/Websites/bugs.webkit.org/ChangeLog index e5a7075dfbc5..433cbfe9026e 100644 --- a/Websites/bugs.webkit.org/ChangeLog +++ b/Websites/bugs.webkit.org/ChangeLog @@ -1,3 +1,15 @@ +2011-02-20 Ojan Vafai + + Reviewed by Adam Barth. + + [codereviewtool] don't let lines/diffblocks be mouse focusable + https://bugs.webkit.org/show_bug.cgi?id=54851 + + Unfortunately, this will only work once https://bugs.webkit.org/show_bug.cgi?id=54727 + is committed. In the interim, it won't break anything. + + * code-review.js: + 2011-02-20 Ojan Vafai Reviewed by Adam Barth. diff --git a/Websites/bugs.webkit.org/code-review.js b/Websites/bugs.webkit.org/code-review.js index 843ab75790dd..c3fb45c70cdb 100644 --- a/Websites/bugs.webkit.org/code-review.js +++ b/Websites/bugs.webkit.org/code-review.js @@ -1358,6 +1358,8 @@ var CODE_REVIEW_UNITTEST; // -1 makes the element focusable without actually putting in in the tab order. node.attr('tabindex', -1); node.focus(); + // Remove the tabindex on blur to avoid having the node be mouse-focusable. + node.bind('blur', function() { node.removeAttr('tabindex'); }); $(document).scrollTop(node.position().top - window.innerHeight / 2); } -- 2.36.0