Bug 1654775 [Wayland] Don't flood console with 'Getting screen in wayland, primary display will be returned', r=jhorak

Differential Revision: https://phabricator.services.mozilla.com/D85257
This commit is contained in:
Martin Stransky 2020-08-05 07:43:54 +00:00
parent 1e6ec7ec86
commit 93e6b04071

View File

@ -108,12 +108,12 @@ void ScreenManager::CopyScreensToAllRemotesIfIsParent() {
NS_IMETHODIMP
ScreenManager::ScreenForRect(int32_t aX, int32_t aY, int32_t aWidth,
int32_t aHeight, nsIScreen** aOutScreen) {
#ifdef MOZ_WAYLAND
#if defined(MOZ_WAYLAND) && defined(MOZ_LOGGING)
static bool inWayland = gdk_display_get_default() &&
!GDK_IS_X11_DISPLAY(gdk_display_get_default());
if (inWayland) {
NS_WARNING("Getting screen in wayland, primary display will be returned.");
MOZ_LOG(sScreenLog, LogLevel::Warning,
("Getting screen in wayland, primary display will be returned."));
}
#endif