Bug 144392 - [Mac] Use new device picker menu API
Summary: [Mac] Use new device picker menu API
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Eric Carlson
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2015-04-29 09:35 PDT by Eric Carlson
Modified: 2015-05-04 11:12 PDT (History)
2 users (show)

See Also:


Attachments
Proposed patch. (10.79 KB, patch)
2015-04-29 10:55 PDT, Eric Carlson
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Carlson 2015-04-29 09:35:50 PDT
Use the new API.
Comment 1 Eric Carlson 2015-04-29 09:36:24 PDT
<rdar://problem/20718389>
Comment 2 Eric Carlson 2015-04-29 10:55:00 PDT
Created attachment 251967 [details]
Proposed patch.
Comment 3 WebKit Commit Bot 2015-04-29 10:56:41 PDT
Attachment 251967 [details] did not pass style-queue:


ERROR: Source/WebCore/platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.mm:53:  Should have a space between // and comment  [whitespace/comments] [4]
Total errors found: 1 in 6 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 4 Jer Noble 2015-04-29 11:02:44 PDT
Comment on attachment 251967 [details]
Proposed patch.

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

r=me, with nits

> Source/WebCore/platform/graphics/MediaPlaybackTargetPicker.h:53
> -    virtual void showPlaybackTargetPicker(const FloatRect&, bool);
> +    virtual void showPlaybackTargetPicker(const FloatRect&, bool /*checkActiveRoute*/);

nit: We should either not add a comment, or add the parameter name without a comment.

> Source/WebCore/platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.h:47
> -    virtual void showPlaybackTargetPicker(const FloatRect&, bool) override;
> +    virtual void showPlaybackTargetPicker(const FloatRect&, bool /*checkActiveRoute*/) override;

Ditto.

> Source/WebCore/platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.h:60
> +        OutputeDeviceAvailabilityChanged = 1 << 0,

Nit: Outpute

> Source/WebCore/platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.mm:150
> +    m_pendingActionTimer.stop();
> +    m_pendingActionTimer.startOneShot(0);

The .stop() isn't necessary. startOneShot() will stop the timer before re-targetting.
Comment 5 Eric Carlson 2015-04-29 11:10:00 PDT
Comment on attachment 251967 [details]
Proposed patch.

Committed r183560: https://trac.webkit.org/r183560