Bug 106714

Summary: Clean up WebVTTNodeType code
Product: WebKit Reporter: Elliott Sprehn <esprehn>
Component: New BugsAssignee: Elliott Sprehn <esprehn>
Status: RESOLVED FIXED    
Severity: Normal CC: allan.jensen, cmarcelo, dgorbik, macpherson, menard, mjs, ojan.autocc, rniwa, tony, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 106679    
Attachments:
Description Flags
Patch
none
Patch none

Description Elliott Sprehn 2013-01-11 15:45:49 PST
Clean up WebVTTNodeType code
Comment 1 Elliott Sprehn 2013-01-11 15:53:40 PST
Created attachment 182439 [details]
Patch
Comment 2 Tony Chang 2013-01-11 16:15:14 PST
Comment on attachment 182439 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=182439&action=review

> Source/WebCore/css/StyleResolver.cpp:657
> +    if (m_element->webVTTNodeType())

Nit: I would probably explicitly say != WebVTTNodeTypeNone or when declaring the enum, set WebVTTNodeTypeNone = 0.

> Source/WebCore/dom/Element.cpp:2318
> +    return ensureElementRareData()->setWebVTTNodeType(type);

Nit: return not needed.

> Source/WebCore/dom/NodeRareData.h:401
> +    unsigned m_webVTTNodeType : 2;

Nit: In RenderStyle, we normally add an end-of-line comment with the enum name so it's easier to verify that we've allocated enough space.
Comment 3 Elliott Sprehn 2013-01-11 17:39:59 PST
Created attachment 182453 [details]
Patch
Comment 4 Ryosuke Niwa 2013-01-11 23:32:23 PST
Thanks for the refactoring!
Comment 5 WebKit Review Bot 2013-01-14 12:19:25 PST
Comment on attachment 182453 [details]
Patch

Clearing flags on attachment: 182453

Committed r139639: <http://trac.webkit.org/changeset/139639>
Comment 6 WebKit Review Bot 2013-01-14 12:19:29 PST
All reviewed patches have been landed.  Closing bug.