Bug 29672 - fix accessibility webkit-style-check errors
Summary: fix accessibility webkit-style-check errors
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Accessibility (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC OS X 10.5
: P2 Normal
Assignee: chris fleizach
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-09-23 00:30 PDT by chris fleizach
Modified: 2009-11-02 23:01 PST (History)
0 users

See Also:


Attachments
patch (61.11 KB, patch)
2009-11-02 20:51 PST, chris fleizach
levin: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description chris fleizach 2009-09-23 00:30:30 PDT
looks like there's probably quite a few
Comment 1 chris fleizach 2009-11-02 20:51:11 PST
Created attachment 42358 [details]
patch

Just fixing webkit-style errors
Comment 2 David Levin 2009-11-02 22:13:42 PST
Comment on attachment 42358 [details]
patch

I know there are mixed feelings about style clean up, but I think it is nice to have a consistent style in the code, so I'll review it.

It would be nice to fix up a few nits before check-in.

> Index: WebCore/accessibility/AXObjectCache.h

> +struct TextMarkerData  {

Might as well fix the two spaces before the {. (Make it one space.)

> +    bool nodeIsAriaType(Node* node, String role);

No need for the param name "node" here.

> Index: WebCore/accessibility/AccessibilityObject.cpp
>      for (parent = parentObject(); parent && parent->accessibilityIsIgnored(); parent = parent->parentObject())
> +    { }

The preferred style would be to have the open { right after the ) of the for statement. I would think the close brace would go on the next line.


> Index: WebCore/accessibility/AccessibilityRenderObject.cpp

> @@ -296,10 +296,10 @@ bool AccessibilityRenderObject::isSlider
>  bool AccessibilityRenderObject::isMenuRelated() const
>  {
>      AccessibilityRole role = roleValue();
> -    return  role == MenuRole ||
> -            role == MenuBarRole ||
> -            role == MenuButtonRole ||
> -            role == MenuItemRole;
> +    return  role == MenuRole 
> +            || role == MenuBarRole
> +            || role == MenuButtonRole
> +            || role == MenuItemRole;

There are two spaces after the return. Also, if you only indent the subsequent lines by 4 spaces, things line up nicely (much like before):

return role == MenuRole 
    || role == MenuBarRole
    || role == MenuButtonRole
    || role == MenuItemRole;
Comment 3 chris fleizach 2009-11-02 23:01:39 PST
http://trac.webkit.org/changeset/50444