h...@chromium.org
unread,Oct 9, 2015, 9:02:28 AM10/9/15Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Sign in to report message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to to...@chromium.org, gui...@chromium.org, pe...@chromium.org, blink-...@chromium.org, tommyw+w...@chromium.org, gui...@chromium.org, to...@chromium.org
I think it's OK now... WebVector is a very limited vector type.
On 2015/10/08 09:50:25, Peter Beverloo wrote:
> nit: Why don't use add them to |mandatory| immediately rather than
first writing
> them to a temporary vector, then copying the contents to it? There are
no
> failure clauses after this loop, so that should be safe to do.
It seems that mandatory is a WebVector, and I can't find any append
operation in WebVector.h. Seems that WebVectors can only be modified by
assign().
On 2015/10/08 09:50:25, Peter Beverloo wrote:
> Would it make sense to check for the return value here, as you do for
the
> function above (using |ok|)?
Done.
On 2015/10/08 09:50:25, Peter Beverloo wrote:
> I'm still not a huge fan of the overloading, but it matches the style
of this
> file.
> If you, or anybody, would touch this file in the future, a good thing
to
> consider would be to refactor the interface in a way that would allow
you to
> write unit tests for it. The functions you extracted would actually be
perfect
> for that already.
I thought Blink only believed in JS-level tests... now I see that
there's actually a gunit user here too. Will definitely consider writing
gunit tests in the future!
A next step in the refactoring is to make the other caller of create()
use MediaTrackConstraintSet instead of Dictionary; this will delete the
overload. I overloaded these functions becaue I think the names of the
functions are good, and did not want to make them harder to read; I
agree about it generally being a confusing thing.
On 2015/10/08 09:50:25, Peter Beverloo wrote:
> const T&, otherwise you're making a copy.
Done.
On 2015/10/08 09:50:25, Peter Beverloo wrote:
> https:// please
Done.
On 2015/10/08 09:50:25, Peter Beverloo wrote:
> consistency micro nit: We usually use the following syntax in IDL
files:
> =====
> // copyright
> // https://...
> [] idl statements
> =====
> (note the blank lines, absence of Specification: line.)
Thanks - these are the kind of style issues that are hard to gather from
the documentation!
On 2015/10/08 09:50:25, Peter Beverloo wrote:
> micro nit: optional -> _optional
Done.
https://codereview.chromium.org/1318393002/