Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

browser(firefox): Win build fix (#2822)

Yury Semikhatsky605257b1a03c
diff --git a/browser_patches/firefox/BUILD_NUMBER b/browser_patches/firefox/BUILD_NUMBER
index 487285274c..b1e1a0c008 100644
--- a/browser_patches/firefox/BUILD_NUMBER
+++ b/browser_patches/firefox/BUILD_NUMBER
@@ -1 +1 @@
-1119
+1120
diff --git a/browser_patches/firefox/juggler/screencast/nsScreencastService.cpp b/browser_patches/firefox/juggler/screencast/nsScreencastService.cpp
index 25d342b37f..e0a47cac04 100644
--- a/browser_patches/firefox/juggler/screencast/nsScreencastService.cpp
+++ b/browser_patches/firefox/juggler/screencast/nsScreencastService.cpp
@@ -112,14 +112,13 @@ nsresult nsScreencastService::StartVideoRecording(nsIDocShell* aDocShell, const
mozilla::widget::CompositorWidgetInitData initData;
widget->GetCompositorWidgetInitData(&initData);
const mozilla::widget::GtkCompositorWidgetInitData& gtkInitData = initData.get_GtkCompositorWidgetInitData();
-# ifdef MOZ_X11
nsCString windowId;
+# ifdef MOZ_X11
windowId.AppendPrintf("%lu", gtkInitData.XWindow());
# else
// TODO: support in wayland
return NS_ERROR_NOT_IMPLEMENTED;
# endif
-#endif
*sessionId = ++mLastSessionId;
nsCString error;
RefPtr<ScreencastEncoder> encoder = ScreencastEncoder::create(error, PromiseFlatCString(aFileName), 1280, 960, Nothing());
@@ -134,6 +133,10 @@ nsresult nsScreencastService::StartVideoRecording(nsIDocShell* aDocShell, const
mIdToSession.emplace(*sessionId, std::move(session));
return NS_OK;
+#else
+ // TODO: support Windows and Mac.
+ return NS_ERROR_NOT_IMPLEMENTED;
+#endif
}
nsresult nsScreencastService::StopVideoRecording(int32_t sessionId) {