WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
105977
Implement WebIDL-style string constants in WebAudio (part 2)
https://bugs.webkit.org/show_bug.cgi?id=105977
Summary
Implement WebIDL-style string constants in WebAudio (part 2)
Chris Rogers
Reported
2013-01-02 17:28:39 PST
Implement WebIDL-style string constants in WebAudio (part 2)
Attachments
Patch
(62.75 KB, patch)
2013-01-02 17:49 PST
,
Chris Rogers
no flags
Details
Formatted Diff
Diff
Patch
(62.60 KB, patch)
2013-01-02 18:21 PST
,
Chris Rogers
haraken
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Chris Rogers
Comment 1
2013-01-02 17:49:59 PST
Created
attachment 181123
[details]
Patch
Adam Barth
Comment 2
2013-01-02 17:58:56 PST
Comment on
attachment 181123
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=181123&action=review
> Source/WebCore/Modules/webaudio/BiquadFilterNode.cpp:47 > + return "lowpass";
You can wrap these constants in ASCIILiteral if you want to make things slightly faster.
WebKit Review Bot
Comment 3
2013-01-02 18:12:10 PST
Comment on
attachment 181123
[details]
Patch
Attachment 181123
[details]
did not pass chromium-ews (chromium-xvfb): Output:
http://queues.webkit.org/results/15656259
Chris Rogers
Comment 4
2013-01-02 18:21:56 PST
Created
attachment 181126
[details]
Patch
Chris Rogers
Comment 5
2013-01-03 11:58:50 PST
Comment on
attachment 181123
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=181123&action=review
>> Source/WebCore/Modules/webaudio/BiquadFilterNode.cpp:47 >> + return "lowpass"; > > You can wrap these constants in ASCIILiteral if you want to make things slightly faster.
I'm not super worried about efficiency on the getters and it seems like it might be a little less readable this way. Do you have a strong preference?
Chris Rogers
Comment 6
2013-01-03 12:00:52 PST
Kentaro, would you mind having a look. This one is very similar to the "part 1" patch:
https://bugs.webkit.org/show_bug.cgi?id=105058
Thanks!
Adam Barth
Comment 7
2013-01-03 13:44:02 PST
> Do you have a strong preference?
Nope!
Kentaro Hara
Comment 8
2013-01-04 07:07:17 PST
Comment on
attachment 181126
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=181126&action=review
LGTM
> Source/WebCore/bindings/v8/custom/V8BiquadFilterNodeCustom.cpp:40 > + v8::Handle<v8::Object> holder = info.Holder(); > + BiquadFilterNode* imp = V8BiquadFilterNode::toNative(holder);
Nit: You can just write 'info.Holder()' instead of putting it into 'holder'.
> Source/WebCore/bindings/v8/custom/V8BiquadFilterNodeCustom.cpp:46 > + if (!ok || !imp->setType(type))
This should be 'ASSERT(ok)'. Since you are checking IsNumber() above, toUInt32() should not fail.
> Source/WebCore/bindings/v8/custom/V8PannerNodeCustom.cpp:40 > + v8::Handle<v8::Object> holder = info.Holder(); > + PannerNode* imp = V8PannerNode::toNative(holder);
Ditto. You can write 'info.Holder()'.
> Source/WebCore/bindings/v8/custom/V8PannerNodeCustom.cpp:46 > + if (!ok || !imp->setPanningModel(model))
Ditto. 'ASSERT(ok)'.
> Source/WebCore/bindings/v8/custom/V8PannerNodeCustom.cpp:66 > + v8::Handle<v8::Object> holder = info.Holder(); > + PannerNode* imp = V8PannerNode::toNative(holder);
Ditto.
> Source/WebCore/bindings/v8/custom/V8PannerNodeCustom.cpp:72 > + if (!ok || !imp->setDistanceModel(model))
Ditto.
Kentaro Hara
Comment 9
2013-01-04 07:09:15 PST
nbarth: Once you implement 'enum' in WebKit IDLs, you might want to clean up the custom bindings of this patch.
Chris Rogers
Comment 10
2013-01-04 13:34:48 PST
Committed
r138849
: <
http://trac.webkit.org/changeset/138849
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug