RESOLVED FIXED 124032
[AX] Clean up static_cast<> to cast from AccessibilityObject
https://bugs.webkit.org/show_bug.cgi?id=124032
Summary [AX] Clean up static_cast<> to cast from AccessibilityObject
Gyuyoung Kim
Reported 2013-11-07 22:51:06 PST
ACCESSIBILITY_OBJECT_TYPE_CASTS can support more helpful casting functions. So, we need to use them as much as possible. This patch cleans up all static_cast<> in accessibility. This patch generates toAccessibilityFoo() in order to replace static_cast<> with it. - Generate toAccessibilityARIAGridRow() - Generate toAccessibilityImageMapLink() - Generate toAccessibilityListBox() - Generate toAccessibilityListBoxOption() - Generate toAccessibilityMenuListOption() - Generate toAccessibilityMenuListPopup() - Generate toAccessibilityScrollbar() - Generate toAccessibilitySlider()
Attachments
Patch (25.77 KB, patch)
2013-11-07 22:55 PST, Gyuyoung Kim
no flags
Patch (25.79 KB, patch)
2013-11-10 08:05 PST, Gyuyoung Kim
no flags
Radar WebKit Bug Importer
Comment 1 2013-11-07 22:51:28 PST
Gyuyoung Kim
Comment 2 2013-11-07 22:55:11 PST
Gyuyoung Kim
Comment 3 2013-11-07 23:48:38 PST
Mario, how do you think ?
Mario Sanchez Prada
Comment 4 2013-11-08 02:07:33 PST
Comment on attachment 216361 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=216361&action=review (In reply to comment #3) > Mario, how do you think ? I think it's a good cleanup. Setting the r+ now, but please fix those small things pointed out below before landing. Thanks! > Source/WebCore/accessibility/AccessibilityListBoxOption.h:65 > - bool isListBoxOption() const { return true; } > + bool isListBoxOption() const OVERRIDE { return true; } You should declare it as virtual and use the FINAL modifier here too if you are declaring this in upper classes as a virtual method (as you are) > Source/WebCore/accessibility/AccessibilitySlider.h:75 > + virtual bool isSliderThumb() const OVERRIDE { return true; } FINAL missing
Gyuyoung Kim
Comment 5 2013-11-10 08:05:14 PST
Gyuyoung Kim
Comment 6 2013-11-10 08:15:10 PST
(In reply to comment #4) > (From update of attachment 216361 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=216361&action=review > > (In reply to comment #3) > > Mario, how do you think ? > > I think it's a good cleanup. Setting the r+ now, but please fix those small things pointed out below before landing. Thanks! > > > Source/WebCore/accessibility/AccessibilityListBoxOption.h:65 > > - bool isListBoxOption() const { return true; } > > + bool isListBoxOption() const OVERRIDE { return true; } > > You should declare it as virtual and use the FINAL modifier here too if you are declaring this in upper classes as a virtual method (as you are) > > > Source/WebCore/accessibility/AccessibilitySlider.h:75 > > + virtual bool isSliderThumb() const OVERRIDE { return true; } > > FINAL missing Yes, right. Fixed them.
WebKit Commit Bot
Comment 7 2013-11-10 08:57:52 PST
Comment on attachment 216526 [details] Patch Clearing flags on attachment: 216526 Committed r159026: <http://trac.webkit.org/changeset/159026>
WebKit Commit Bot
Comment 8 2013-11-10 08:57:55 PST
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.