Remove HasMediaCaptureDevice
authorjonlee@apple.com <jonlee@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 15 Nov 2016 18:19:19 +0000 (18:19 +0000)
committerjonlee@apple.com <jonlee@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 15 Nov 2016 18:19:19 +0000 (18:19 +0000)
https://bugs.webkit.org/show_bug.cgi?id=164767
<rdar://problem/29263696>

Reviewed by Eric Carlson.

Source/WebCore:

* Modules/mediastream/MediaStream.cpp:
(WebCore::MediaStream::mediaState): Remove HasMediaCaptureDevice in state.
* page/MediaProducer.h:
* testing/Internals.cpp:
(WebCore::Internals::pageMediaState): Remove it in the media string.

Source/WebKit2:

* UIProcess/API/C/WKPage.cpp: Remove kWKMediaHasCaptureDevice.
(WKPageGetMediaState):
* UIProcess/API/C/WKPagePrivate.h:

LayoutTests:

* fast/mediastream/MediaStream-page-muted-expected.txt: Remove check for HasMediaCaptureDevice.
* fast/mediastream/MediaStream-page-muted.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@208735 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/fast/mediastream/MediaStream-page-muted-expected.txt
LayoutTests/fast/mediastream/MediaStream-page-muted.html
Source/WebCore/ChangeLog
Source/WebCore/Modules/mediastream/MediaStream.cpp
Source/WebCore/page/MediaProducer.h
Source/WebCore/testing/Internals.cpp
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/C/WKPage.cpp
Source/WebKit2/UIProcess/API/C/WKPagePrivate.h

index b67ce7d..a7f1e5d 100644 (file)
@@ -1,3 +1,14 @@
+2016-11-15  Jon Lee  <jonlee@apple.com>
+
+        Remove HasMediaCaptureDevice
+        https://bugs.webkit.org/show_bug.cgi?id=164767
+        <rdar://problem/29263696>
+
+        Reviewed by Eric Carlson.
+
+        * fast/mediastream/MediaStream-page-muted-expected.txt: Remove check for HasMediaCaptureDevice.
+        * fast/mediastream/MediaStream-page-muted.html:
+
 2016-11-14  Dave Hyatt  <hyatt@apple.com>
 
         [CSS Parser] Fix font-synthesis and text-decoration-skip parsing
index 7fd0a89..05b3d16 100644 (file)
@@ -12,20 +12,16 @@ PASS window.internals.pageMediaState().includes('HasActiveMediaCaptureDevice') b
 *** Muting capture devices
 EVENT: mute
 PASS muteChangedEvent.target.muted is true
-PASS window.internals.pageMediaState().includes('HasMediaCaptureDevice') is true
 EVENT: mute
 PASS muteChangedEvent.target.muted is true
-PASS window.internals.pageMediaState().includes('HasMediaCaptureDevice') is true
 
 PASS window.internals.pageMediaState().includes('HasActiveMediaCaptureDevice') became false
 
 *** Unmuting capture devices
 EVENT: unmute
 PASS muteChangedEvent.target.muted is false
-PASS window.internals.pageMediaState().includes('HasMediaCaptureDevice') is true
 EVENT: unmute
 PASS muteChangedEvent.target.muted is false
-PASS window.internals.pageMediaState().includes('HasMediaCaptureDevice') is true
 
 PASS window.internals.pageMediaState().includes('HasActiveMediaCaptureDevice') became true
 PASS successfullyParsed is true
index e16775e..3fa487d 100644 (file)
@@ -24,7 +24,6 @@
                 muteChangedEvent = ev;
                 debug(`EVENT: ${muteChangedEvent.type}`);
                 shouldBe('muteChangedEvent.target.muted', (muteChangedEvent.type == "mute").toString());
-                shouldBe("window.internals.pageMediaState().includes('HasMediaCaptureDevice')", "true");
 
                 if (++eventCount == 2) {
                     debug("");
index 8cd976b..04c62ba 100644 (file)
@@ -1,3 +1,17 @@
+2016-11-15  Jon Lee  <jonlee@apple.com>
+
+        Remove HasMediaCaptureDevice
+        https://bugs.webkit.org/show_bug.cgi?id=164767
+        <rdar://problem/29263696>
+
+        Reviewed by Eric Carlson.
+
+        * Modules/mediastream/MediaStream.cpp:
+        (WebCore::MediaStream::mediaState): Remove HasMediaCaptureDevice in state.
+        * page/MediaProducer.h:
+        * testing/Internals.cpp:
+        (WebCore::Internals::pageMediaState): Remove it in the media string.
+
 2016-11-14  Dave Hyatt  <hyatt@apple.com>
 
         [CSS Parser] Fix font-synthesis and text-decoration-skip parsing
index 14d1b5c..e28e7b0 100644 (file)
@@ -312,7 +312,6 @@ MediaProducer::MediaStateFlags MediaStream::mediaState() const
     if (!m_isActive)
         return state;
 
-    state |= HasMediaCaptureDevice;
     if (m_private->isProducingData())
         state |= HasActiveMediaCaptureDevice;
 
index 1c0f0ea..15e9928 100644 (file)
@@ -43,7 +43,6 @@ public:
         HasPlaybackTargetAvailabilityListener = 1 << 9,
         HasAudioOrVideo = 1 << 10,
         HasActiveMediaCaptureDevice = 1 << 11,
-        HasMediaCaptureDevice = 1 << 12,
     };
     typedef unsigned MediaStateFlags;
 
index b814785..04ee454 100644 (file)
@@ -3012,8 +3012,6 @@ String Internals::pageMediaState()
         string.append("HasAudioOrVideo,");
     if (state & MediaProducer::HasActiveMediaCaptureDevice)
         string.append("HasActiveMediaCaptureDevice,");
-    if (state & MediaProducer::HasMediaCaptureDevice)
-        string.append("HasMediaCaptureDevice,");
 
     if (string.isEmpty())
         string.append("IsNotPlaying");
index f3f6500..fb1180d 100644 (file)
@@ -1,3 +1,15 @@
+2016-11-15  Jon Lee  <jonlee@apple.com>
+
+        Remove HasMediaCaptureDevice
+        https://bugs.webkit.org/show_bug.cgi?id=164767
+        <rdar://problem/29263696>
+
+        Reviewed by Eric Carlson.
+
+        * UIProcess/API/C/WKPage.cpp: Remove kWKMediaHasCaptureDevice.
+        (WKPageGetMediaState):
+        * UIProcess/API/C/WKPagePrivate.h:
+
 2016-11-15  Daniel Bates  <dabates@apple.com>
 
         Disallow loads using HTTP 0.9 at the ResourceHandle/NetworkDataTask level
index cea6049..bb60d3d 100644 (file)
@@ -2748,8 +2748,6 @@ WKMediaState WKPageGetMediaState(WKPageRef page)
         state |= kWKMediaIsPlayingAudio;
     if (coreState & WebCore::MediaProducer::IsPlayingVideo)
         state |= kWKMediaIsPlayingVideo;
-    if (coreState & WebCore::MediaProducer::HasMediaCaptureDevice)
-        state |= kWKMediaHasCaptureDevice;
     if (coreState & WebCore::MediaProducer::HasActiveMediaCaptureDevice)
         state |= kWKMediaHasActiveCaptureDevice;
 
index dae51fa..e4c2f11 100644 (file)
@@ -134,7 +134,6 @@ enum {
     kWKMediaIsPlayingAudio = 1 << 0,
     kWKMediaIsPlayingVideo = 1 << 1,
     kWKMediaHasActiveCaptureDevice = 1 << 2,
-    kWKMediaHasCaptureDevice = 1 << 3,
 };
 typedef uint32_t WKMediaState;