This is a separated patch form bug 61410, containing only a refactoring part.
Created attachment 95558 [details] move focus related functions from Document to FocusController
Comment on attachment 95558 [details] move focus related functions from Document to FocusController View in context: https://bugs.webkit.org/attachment.cgi?id=95558&action=review > Source/WebCore/page/FocusController.cpp:312 > + for (Node* n = start; n; n = n->traverseNextNode()) nit: Should avoid 1-letter variable name. > Source/WebCore/page/FocusController.cpp:332 > + int winningTabIndex = SHRT_MAX + 1; nit: Because this is C++, we had better use numeric_limits<short> instead of SHRT_MAX. > Source/WebCore/page/FocusController.h:79 > + /** nit: We usually use '//' for comments.
Thank you for the review. I'll land this patch after addressing the review comments. (In reply to comment #2) > (From update of attachment 95558 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=95558&action=review > > > Source/WebCore/page/FocusController.cpp:312 > > + for (Node* n = start; n; n = n->traverseNextNode()) > > nit: Should avoid 1-letter variable name. > > > Source/WebCore/page/FocusController.cpp:332 > > + int winningTabIndex = SHRT_MAX + 1; > > nit: Because this is C++, we had better use numeric_limits<short> instead of SHRT_MAX. > > > Source/WebCore/page/FocusController.h:79 > > + /** > > nit: We usually use '//' for comments.
Committed r87874: <http://trac.webkit.org/changeset/87874>