Closed
Bug 767843
Opened 11 years ago
Closed 11 years ago
stop using nsIDOMHTMLOptionElement in a11y
Categories
(Core :: Disability Access APIs, defect)
Core
Disability Access APIs
Tracking
()
RESOLVED
FIXED
mozilla18
People
(Reporter: tbsaunde, Assigned: tbsaunde)
References
(Blocks 2 open bugs)
Details
Attachments
(2 files)
4.92 KB,
patch
|
Details | Diff | Splinter Review | |
4.98 KB,
patch
|
surkov
:
review+
|
Details | Diff | Splinter Review |
No description provided.
Assignee | ||
Comment 1•11 years ago
|
||
Attachment #636203 -
Flags: review?(dbolter)
Comment 2•11 years ago
|
||
Comment on attachment 636203 [details] [diff] [review] patch Review of attachment 636203 [details] [diff] [review]: ----------------------------------------------------------------- ::: accessible/src/html/HTMLSelectAccessible.cpp @@ +234,5 @@ > > // Are we selected? > + bool selected = false; > + nsHTMLOptionElement* option = nsHTMLOptionElement::FromContent(mContent); > + if (option && option->Selected()) { I'd do bool selected = option && option->Selected(); note, below you don't have a null check option element, perhaps you can do bool selected = nsHTMLOptionElement::FromContent(mContent)->Selected();
Assignee | ||
Comment 3•11 years ago
|
||
(In reply to alexander :surkov from comment #2) > Comment on attachment 636203 [details] [diff] [review] > patch > > Review of attachment 636203 [details] [diff] [review]: > ----------------------------------------------------------------- > > ::: accessible/src/html/HTMLSelectAccessible.cpp > @@ +234,5 @@ > > > > // Are we selected? > > + bool selected = false; > > + nsHTMLOptionElement* option = nsHTMLOptionElement::FromContent(mContent); > > + if (option && option->Selected()) { > > I'd do > bool selected = option && option->Selected(); I guess you could do that, though I think you still need the if to change the state. > note, below you don't have a null check option element, perhaps you can do > bool selected = nsHTMLOptionElement::FromContent(mContent)->Selected(); actually, I'm pretty sure that code is, and has been busted for optgroups for a while. So I should probably add a null check htere.
Comment 4•11 years ago
|
||
Comment on attachment 636203 [details] [diff] [review] patch It makes sense to switch reviewer to Alexander.
Attachment #636203 -
Flags: review?(dbolter)
Comment 5•11 years ago
|
||
(In reply to Trevor Saunders (:tbsaunde) from comment #3) > (In reply to alexander :surkov from comment #2) > > Comment on attachment 636203 [details] [diff] [review] > > patch > > > > Review of attachment 636203 [details] [diff] [review]: > > ----------------------------------------------------------------- > > > > ::: accessible/src/html/HTMLSelectAccessible.cpp > > @@ +234,5 @@ > > > > > > // Are we selected? > > > + bool selected = false; > > > + nsHTMLOptionElement* option = nsHTMLOptionElement::FromContent(mContent); > > > + if (option && option->Selected()) { > > > > I'd do > > bool selected = option && option->Selected(); > > I guess you could do that, though I think you still need the if to change > the state. sure bool selected = bla; if (selected) {} :) > actually, I'm pretty sure that code is, and has been busted for optgroups > for a while. So I should probably add a null check htere. ok, I see
Assignee | ||
Comment 6•11 years ago
|
||
Attachment #637553 -
Flags: review?(surkov.alexander)
Updated•11 years ago
|
Attachment #637553 -
Flags: review?(surkov.alexander) → review+
Assignee | ||
Comment 7•11 years ago
|
||
https://tbpl.mozilla.org/?tree=Try&rev=7135192653ea
Assignee | ||
Comment 8•11 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/b3ad8edbd748
Comment 9•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/b3ad8edbd748
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla18
You need to log in
before you can comment on or make changes to this bug.
Description
•