changeset 28556:26fd670f776a stable

Stop error when deleting uicontrol "frame" objects (bug #58544). * qt-graphics-toolkit.cc (initialize): Check for uicontrol object with "frame" style and don't create a graphics object for this type which is unimplemented.
author Pantxo Diribarne <pantxo.diribarne@gmail.com>
date Sun, 14 Jun 2020 19:57:06 -0700
parents 7a17dfa7716d
children 3fe9e1009399 c9f7d1d7a6e7
files libgui/graphics/qt-graphics-toolkit.cc
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/libgui/graphics/qt-graphics-toolkit.cc	Fri Jul 10 08:34:33 2020 +0200
+++ b/libgui/graphics/qt-graphics-toolkit.cc	Sun Jun 14 19:57:06 2020 -0700
@@ -121,7 +121,7 @@
   qt_graphics_toolkit::initialize (const graphics_object& go)
   {
     if (go.isa ("figure")
-        || go.isa ("uicontrol")
+        || (go.isa ("uicontrol") && go.get ("style").string_value () != "frame")
         || go.isa ("uipanel")
         || go.isa ("uibuttongroup")
         || go.isa ("uimenu")
@@ -131,7 +131,7 @@
         || go.isa ("uipushtool")
         || go.isa ("uitoggletool"))
       {
-        // FIXME: We need to unlock the mutex here but we have no way to know if
+        // FIXME: We need to unlock the mutex here but we have no way to know
         // if it was previously locked by this thread, and thus if we should
         // re-lock it.