[Bf-blender-cvs] [702d8c26527] wl_default: GHOST/wayland: try Wayland only when 'BLENDER_WAYLAND' is set
Christian Rauch
noreply at git.blender.org
Sat Jul 3 14:29:26 CEST 2021
Commit: 702d8c26527ca381218e63378a71e17807cd4617
Author: Christian Rauch
Date: Thu Jun 3 21:12:09 2021 +0100
Branches: wl_default
https://developer.blender.org/rB702d8c26527ca381218e63378a71e17807cd4617
GHOST/wayland: try Wayland only when 'BLENDER_WAYLAND' is set
===================================================================
M intern/ghost/intern/GHOST_ISystem.cpp
===================================================================
diff --git a/intern/ghost/intern/GHOST_ISystem.cpp b/intern/ghost/intern/GHOST_ISystem.cpp
index 7c12bfe0306..5ef942efb59 100644
--- a/intern/ghost/intern/GHOST_ISystem.cpp
+++ b/intern/ghost/intern/GHOST_ISystem.cpp
@@ -55,11 +55,13 @@ GHOST_TSuccess GHOST_ISystem::createSystem()
m_system = new GHOST_SystemNULL();
#elif defined(WITH_GHOST_X11) && defined(WITH_GHOST_WAYLAND)
/* Special case, try Wayland, fall back to X11. */
- try {
- m_system = new GHOST_SystemWayland();
- }
- catch (const std::runtime_error &) {
- /* fallback to X11. */
+ if (std::getenv("BLENDER_WAYLAND")) {
+ try {
+ m_system = new GHOST_SystemWayland();
+ }
+ catch (const std::runtime_error &) {
+ /* fallback to X11. */
+ }
}
if (!m_system) {
m_system = new GHOST_SystemX11();
More information about the Bf-blender-cvs
mailing list