Bug 11678

Summary: [S60] tabbing navigation skips over text content
Product: WebKit Reporter: Shaun Keller <shaun.keller>
Component: Layout and RenderingAssignee: Nobody <webkit-unassigned>
Status: CLOSED FIXED    
Severity: Normal CC: zalan
Priority: P2    
Version: 412   
Hardware: S60 Emulator   
OS: S60 3rd edition   
Attachments:
Description Flags
tabbing navigation fix
zalan: review-
apply corrections based on Zalan's comments
zalan: review+
retry at usable diff/patch zalan: review+

Description Shaun Keller 2006-11-22 07:35:05 PST
TSW# TMCN-6TLQ58
Comment 1 Shaun Keller 2006-11-22 07:41:13 PST
Created attachment 11608 [details]
tabbing navigation fix
Comment 2 zalan 2006-11-26 13:41:48 PST
Comment on attachment 11608 [details]
tabbing navigation fix

in getNewTabbedCursorPosition, you use the same variable name (as the parameter of this function) to call the subframe's getNewTabbedCursorPosition. is it intentional? as with this setup your nodeIndex remains -1 even if it is set to something else in the subframe call. 

int nodeIndex = -1;
bool foundInFrame = foundFrame->getNewTabbedCursorPosition(lr,tb,nodeIndex);


in tabbedNavigation, it looks to me that nodeIndex can be easily -1 and that crashes on the following line
QRect foundRect = (*_focusableNodeList)[nodeIndex];

and please remove the FIXME comment
Comment 3 Shaun Keller 2006-11-27 08:30:44 PST
Created attachment 11642 [details]
apply corrections based on Zalan's comments

Thanks for catching the nodeIndex errors.  The delta is: removed the creation of shadowing variables; added a test for return nodeIndex value of -1 which now skips over changing the cursor position based on a found node; corrected comments and indenting.  I rebuilt, tested and reviewed the changes with Sriram.
Comment 4 Shaun Keller 2006-11-27 09:30:55 PST
Created attachment 11643 [details]
retry at usable diff/patch
Comment 5 zalan 2006-11-28 18:27:33 PST
Comment on attachment 11642 [details]
apply corrections based on Zalan's comments

r=me
Comment 6 zalan 2006-11-28 18:28:01 PST
Comment on attachment 11643 [details]
retry at usable diff/patch

r=me
Comment 7 zalan 2006-11-28 18:41:14 PST
3.2 17914
3.1m 17915
Comment 8 Krishna 2006-11-30 13:54:56 PST
Verified and Closed.