Closed
Bug 566551
Opened 14 years ago
Closed 14 years ago
ARIA grid and accessible selectable methods shouldn't use GetNextSibling
Categories
(Core :: Disability Access APIs, defect)
Core
Disability Access APIs
Tracking
()
RESOLVED
FIXED
People
(Reporter: surkov, Assigned: surkov)
References
(Blocks 1 open bug)
Details
(Keywords: access)
Attachments
(1 file, 1 obsolete file)
(deleted),
patch
|
MarcoZ
:
review+
|
Details | Diff | Splinter Review |
No description provided.
Assignee | ||
Comment 1•14 years ago
|
||
Attachment #445924 -
Flags: superreview?(neil)
Attachment #445924 -
Flags: review?(marco.zehe)
Attachment #445924 -
Flags: review?(bolterbugz)
Comment 2•14 years ago
|
||
Comment on attachment 445924 [details] [diff] [review]
patch
Nit:
>+ var acc = getAccessible(aIdentifier, [nsIAccessibleSelectable]);
>+ var len = aSelectedChildren.length;
Please bail if acc is null.
Attachment #445924 -
Flags: review?(marco.zehe) → review+
Assignee | ||
Comment 3•14 years ago
|
||
(In reply to comment #2)
> (From update of attachment 445924 [details] [diff] [review])
> Nit:
> >+ var acc = getAccessible(aIdentifier, [nsIAccessibleSelectable]);
> >+ var len = aSelectedChildren.length;
>
> Please bail if acc is null.
ok
Comment 4•14 years ago
|
||
Comment on attachment 445924 [details] [diff] [review]
patch
>+nsAccessible*
>+nsAccIterator::GetNext()
>+{
>+ if (!mState)
>+ return nsnull;
>+
>+ nsAccessible *child = mState->mParent->GetChildAt(mState->mIndex++);
>+ if (!child) {
>+ IteratorState *tmp = mState;
>+ mState = mState->mParentState;
>+ delete tmp;
>+
>+ return GetNext();
>+ }
>+
>+ PRBool isComplying = mFilterFunc(child);
>+ if (isComplying)
>+ return child;
>+
>+ if (mIsDeep) {
>+ IteratorState *childState = new IteratorState(child, mState);
>+ mState = childState;
>+ }
>+
>+ return GetNext();
>+}
It might look nice but I'm scared by this "loop" ;-) Would you mind using a while (mState) loop instead?
Attachment #445924 -
Flags: superreview?(neil) → superreview+
Assignee | ||
Comment 5•14 years ago
|
||
Neil's comment is addressed
Attachment #445924 -
Attachment is obsolete: true
Attachment #445942 -
Flags: review?(bolterbugz)
Attachment #445924 -
Flags: review?(bolterbugz)
Assignee | ||
Comment 6•14 years ago
|
||
Neil, is the patch ok?
Comment 7•14 years ago
|
||
Yeah, that looks OK now thanks!
Comment 8•14 years ago
|
||
Comment on attachment 445942 [details] [diff] [review]
patch2
After discussing on IRC, -Alex and I agreed that I do the code review in David's absence.
r=me with nits/requests:
>+ /**
>+ * Return next accessible complying with filter function.
>+ */
Please add a sentence saying that when calling for the first time, returns the first item (so that it is clear there is no extra method for getting the first item).
>+ // The index out of range.
The index *is* out of range.
>+ ++ (*aSelectionCount);
Remove space before ( please.
Attachment #445942 -
Flags: review?(bolterbugz) → review+
Assignee | ||
Comment 9•14 years ago
|
||
landed on 1.9.3 with addressed Marco's comments - http://hg.mozilla.org/mozilla-central/rev/f646d72f612d
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Assignee | ||
Updated•14 years ago
|
Flags: in-testsuite+
You need to log in
before you can comment on or make changes to this bug.
Description
•