[GTK] Add MediaStream feature to avoid MediaStream test failure
[WebKit-https.git] / Source / WebKit / gtk / webkit / webkitwebview.cpp
index 253e7d9f7b75fd5fc9e35e2e47d41acf75523192..586f6776b55208c88668f578f9b62e25b39b4a42 100644 (file)
 #include "DeviceOrientationClientGtk.h"
 #endif
 
+#if ENABLE(MEDIA_STREAM)
+#include "UserMediaClientGtk.h"
+#endif
+
 /**
  * SECTION:webkitwebview
  * @short_description: The central class of the WebKitGTK+ API
@@ -3520,6 +3524,10 @@ static void webkit_web_view_init(WebKitWebView* webView)
     WebCore::provideDeviceOrientationTo(priv->corePage, new DeviceOrientationClientGtk);
 #endif
 
+#if ENABLE(MEDIA_STREAM)
+    WebCore::provideUserMediaTo(priv->corePage, new UserMediaClientGtk);
+#endif
+
     if (DumpRenderTreeSupportGtk::dumpRenderTreeModeEnabled()) {
         static_cast<GeolocationClientMock*>(pageClients.geolocationClient)->setController(priv->corePage->geolocationController());
         // Set some testing-specific settings