Bug 134350 - [iOS] no need to deactivate audio session
Summary: [iOS] no need to deactivate audio session
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Eric Carlson
Keywords: InRadar
Depends on:
Reported: 2014-06-26 10:37 PDT by Eric Carlson
Modified: 2014-06-26 11:31 PDT (History)
9 users (show)

See Also:

Proposed patch. (1.24 KB, patch)
2014-06-26 11:00 PDT, Eric Carlson
jer.noble: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Carlson 2014-06-26 10:37:46 PDT
There is no need to call setActive:NO on the audio session, WebCore's session will automatically be deactivated if another application begins playing audio.
Comment 1 Eric Carlson 2014-06-26 10:38:36 PDT
Comment 2 Eric Carlson 2014-06-26 11:00:41 PDT
Created attachment 233916 [details]
Proposed patch.
Comment 3 Jer Noble 2014-06-26 11:02:32 PDT
Comment on attachment 233916 [details]
Proposed patch.

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


> Source/WebCore/ChangeLog:9
> +        [iOS] no need to deactivate audio session
> +        https://bugs.webkit.org/show_bug.cgi?id=134350
> +
> +        Reviewed by NOBODY (OOPS!).
> +
> +        * platform/audio/mac/MediaSessionManagerMac.cpp:
> +        (MediaSessionManager::updateSessionState): Never call setActive:false.

nit: Why not?

(Maybe: "Embedding WebView apps may want to enable the audio session outside of the WebView, and since the AudioSession is global to the app, disabling the audio session can interrupt that audio."
Comment 4 Eric Carlson 2014-06-26 11:31:29 PDT
Committed r170485: https://trac.webkit.org/r170485