impr: Discard wayland platform errors
This commit is contained in:
parent
62978e5d34
commit
0cba735eb3
@ -388,6 +388,13 @@ namespace hex::init {
|
|||||||
|
|
||||||
void WindowSplash::initGLFW() {
|
void WindowSplash::initGLFW() {
|
||||||
glfwSetErrorCallback([](int errorCode, const char *desc) {
|
glfwSetErrorCallback([](int errorCode, const char *desc) {
|
||||||
|
if (errorCode == GLFW_PLATFORM_ERROR) {
|
||||||
|
// Ignore error spam caused by Wayland not supporting moving or resizing
|
||||||
|
// windows or querying their position and size.
|
||||||
|
if (std::string_view(desc).contains("Wayland"))
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
lastGlfwError.errorCode = errorCode;
|
lastGlfwError.errorCode = errorCode;
|
||||||
lastGlfwError.desc = std::string(desc);
|
lastGlfwError.desc = std::string(desc);
|
||||||
log::error("GLFW Error [{}] : {}", errorCode, desc);
|
log::error("GLFW Error [{}] : {}", errorCode, desc);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user