Bug 121213 - [CSS Shapes] Remove unnecessarily complex template from ShapeInfo classes
Summary: [CSS Shapes] Remove unnecessarily complex template from ShapeInfo classes
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Bem Jones-Bey
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-09-11 22:57 PDT by Bem Jones-Bey
Modified: 2013-09-12 10:08 PDT (History)
5 users (show)

See Also:


Attachments
Patch (11.36 KB, patch)
2013-09-11 22:58 PDT, Bem Jones-Bey
no flags Details | Formatted Diff | Diff
Patch (11.34 KB, patch)
2013-09-12 09:12 PDT, Bem Jones-Bey
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Bem Jones-Bey 2013-09-11 22:57:08 PDT
[CSS Shapes] Remove unnecessarily complex template from ShapeInfo classes
Comment 1 Bem Jones-Bey 2013-09-11 22:58:45 PDT
Created attachment 211400 [details]
Patch

purge horrid template mess
Comment 2 Darin Adler 2013-09-12 07:58:26 PDT
Comment on attachment 211400 [details]
Patch

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

> Source/WebCore/rendering/shapes/ShapeInfo.h:113
> +    virtual ShapeValue* getShapeValue() const = 0;

In WebKit coding style, functions like this one are supposed to be named just "shapeValue()" without the get prefix.

> Source/WebCore/rendering/shapes/ShapeInsideInfo.h:65
> +class ShapeInsideInfo : public ShapeInfo<RenderBlock> {

Can this class be marked FINAL?

> Source/WebCore/rendering/shapes/ShapeOutsideInfo.h:42
> +class ShapeOutsideInfo : public ShapeInfo<RenderBox>, public MappedInfo<RenderBox, ShapeOutsideInfo> {

Can this class be marked FINAL?
Comment 3 Bem Jones-Bey 2013-09-12 09:12:53 PDT
Created attachment 211434 [details]
Patch

Fix style and add FINAL per review comments.
Comment 4 WebKit Commit Bot 2013-09-12 09:49:39 PDT
Comment on attachment 211434 [details]
Patch

Clearing flags on attachment: 211434

Committed r155627: <http://trac.webkit.org/changeset/155627>
Comment 5 WebKit Commit Bot 2013-09-12 09:49:41 PDT
All reviewed patches have been landed.  Closing bug.
Comment 6 Darin Adler 2013-09-12 10:08:39 PDT
If you liked the compile time aspect of the old solution and wanted to solve this without virtual function call overhead, the appropriate technique probably would be traits.