Bug 37802

Summary: Spatial Navigation: at @updateFocusCandidateIfCloser make an assignment shortcut when FocusCandidate is null
Product: WebKit Reporter: Antonio Gomes <tonikitoo>
Component: AccessibilityAssignee: Antonio Gomes <tonikitoo>
Status: CLOSED FIXED    
Severity: Normal CC: abarth, eric, hausmann, simon.fraser, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: All   
Bug Depends on: 18662    
Bug Blocks: 35784, 36463    
Description Flags
patch v1 none

Description Antonio Gomes 2010-04-19 08:25:10 PDT
In updateFocusCandidateIfCloser  method (see WebCore/page/FocusController.cpp), we do all bail out checks in the begining of the method body. If after those bail out checks, no "best FocusCandidate" has been taken yet (i.e. focusCandidate.isNull() == true) , we can safely take the current candidate, and exit earlier.

no behavior change, it is just a safe assignment shortcut.

patch coming ...
Comment 1 Antonio Gomes 2010-04-19 08:29:06 PDT
Created attachment 53680 [details]
patch v1
Comment 2 Antonio Gomes 2010-04-20 14:36:12 PDT
Comment on attachment 53680 [details]
patch v1

Clearing flags on attachment: 53680

Committed r57921: <http://trac.webkit.org/changeset/57921>
Comment 3 Antonio Gomes 2010-04-20 14:36:48 PDT
Thank you Simon Fraser!
Comment 4 WebKit Review Bot 2010-04-20 15:17:12 PDT
http://trac.webkit.org/changeset/57921 might have broken Leopard Intel Release (Tests)
The following changes are on the blame list:
Comment 5 Simon Hausmann 2010-04-26 03:26:04 PDT
Revision r57921 cherry-picked into qtwebkit-2.0 with commit 2be19c2e5f8f6902fb11932cc51a0a309eebd2d1