Bug 1362847 - Allow headless on other Gtk platforms. r?bdahl
MozReview-Commit-ID: 9NRiPQA73ov
--- a/toolkit/xre/nsAppRunner.cpp
+++ b/toolkit/xre/nsAppRunner.cpp
@@ -3131,17 +3131,17 @@ XREMain::XRE_mainInit(bool* aExitFlag)
ChaosMode::SetChaosFeature(feature);
}
if (ChaosMode::isActive(ChaosFeature::Any)) {
printf_stderr("*** You are running in chaos test mode. See ChaosMode.h. ***\n");
}
if (gfxPlatform::IsHeadless()) {
-#ifdef XP_LINUX
+#ifdef MOZ_WIDGET_GTK
Output(false, "*** You are running in headless mode.\n");
#else
Output(true, "Error: headless mode is not currently supported on this platform.\n");
return 1;
#endif
}
nsresult rv;
--- a/widget/headless/tests/xpcshell.ini
+++ b/widget/headless/tests/xpcshell.ini
@@ -1,9 +1,9 @@
[DEFAULT]
-skip-if = os != "linux"
+skip-if = toolkit != "gtk2" && toolkit != "gtk3"
headless = true
[test_headless_clipboard.js]
[test_headless.js]
support-files =
headless.html
headless_button.html