Commit b8affb94 authored by zork@chromium.org's avatar zork@chromium.org

Re-add workaround that allowed keyboard navigation of options sub-pages to work.

BUG=chromium-os:15629
TEST=Manual


Review URL: http://codereview.chromium.org/7061007

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86395 0039d316-1c4b-4281-b951-d872f2087c98
parent edc80952
...@@ -687,6 +687,15 @@ cr.define('options', function() { ...@@ -687,6 +687,15 @@ cr.define('options', function() {
if (!topPage || topPage.isOverlay || !topPage.parentPage) if (!topPage || topPage.isOverlay || !topPage.parentPage)
return; return;
// Do nothing if the client coordinates are not within the source element.
// This occurs if the user toggles a checkbox by pressing spacebar.
// This is a workaround to prevent keyboard events from closing the window.
// See: crosbug.com/15678
if (event.clientX == -document.body.scrollLeft &&
event.clientY == -document.body.scrollTop) {
return;
}
// Don't interfere with navbar clicks. // Don't interfere with navbar clicks.
if ($('navbar').contains(event.target)) if ($('navbar').contains(event.target))
return; return;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment