Bug 144876

Summary: Move TransformOperation-based classes off of PassRefPtr
Product: WebKit Reporter: Zan Dobersek <zan>
Component: New BugsAssignee: Zan Dobersek <zan>
Status: RESOLVED FIXED    
Severity: Normal CC: darin
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 144797    
Attachments:
Description Flags
Patch
none
Patch for landing none

Description Zan Dobersek 2015-05-11 11:15:24 PDT
Move TransformOperation-based classes off of PassRefPtr
Comment 1 Zan Dobersek 2015-05-11 11:21:16 PDT
Created attachment 252871 [details]
Patch
Comment 2 Darin Adler 2015-05-11 17:20:40 PDT
Comment on attachment 252871 [details]
Patch

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

> Source/WebCore/platform/graphics/transforms/TransformOperation.h:30
> +#include <wtf/Ref.h>

I think Forward.h would have sufficed here. I don’t think we need to include Ref.h just to declare functions with Ref<X> as a return type.

> Source/WebCore/platform/graphics/transforms/TransformOperations.cpp:85
> +        RefPtr<TransformOperation> blendedOperation = toOperation ? toOperation->blend(fromOperation.get(), progress) : (fromOperation ? RefPtr<TransformOperation>(fromOperation->blend(nullptr, progress, true)) : nullptr);

A real shame that we have to cast to RefPtr here. At some point we should probably add something that turns a Ref into a RefPtr without having to repeat the name of the type involved.
Comment 3 Zan Dobersek 2015-05-12 00:58:53 PDT
Comment on attachment 252871 [details]
Patch

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

>> Source/WebCore/platform/graphics/transforms/TransformOperation.h:30
>> +#include <wtf/Ref.h>
> 
> I think Forward.h would have sufficed here. I don’t think we need to include Ref.h just to declare functions with Ref<X> as a return type.

That entails including Ref.h in all the header files declaring the deriving interfaces, but I'm OK with that.
Comment 4 Zan Dobersek 2015-05-12 01:05:56 PDT
Created attachment 252949 [details]
Patch for landing
Comment 5 Zan Dobersek 2015-05-12 02:54:52 PDT
Comment on attachment 252949 [details]
Patch for landing

Clearing flags on attachment: 252949

Committed r184193: <http://trac.webkit.org/changeset/184193>
Comment 6 Zan Dobersek 2015-05-12 02:54:59 PDT
All reviewed patches have been landed.  Closing bug.