From 890030f185624c4289e719434b46f9c149c6ebe0 Mon Sep 17 00:00:00 2001 From: Thomas Debesse Date: Tue, 22 Dec 2020 20:08:31 +0100 Subject: [PATCH] macos: disable drawing xorrectangle (rectangle selection feedback) disable drawing xorrectangle (rectangle selection feedback) to workaround crash, selection still works --- libs/gtkutil/xorrectangle.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libs/gtkutil/xorrectangle.cpp b/libs/gtkutil/xorrectangle.cpp index ab15ac88..56ae908a 100644 --- a/libs/gtkutil/xorrectangle.cpp +++ b/libs/gtkutil/xorrectangle.cpp @@ -16,6 +16,7 @@ void XORRectangle::lazy_init() void XORRectangle::draw() const { +#ifndef WORKAROUND_MACOS_GTK2_DESTROY const int x = float_to_integer(m_rectangle.x); const int y = float_to_integer(m_rectangle.y); const int w = float_to_integer(m_rectangle.w); @@ -26,6 +27,7 @@ void XORRectangle::draw() const cairo_set_source_rgb(cr, 1, 1, 1); cairo_set_operator(cr, CAIRO_OPERATOR_DIFFERENCE); cairo_stroke(cr); +#endif } XORRectangle::XORRectangle(ui::GLArea widget) : m_widget(widget), cr(0) -- 2.39.2