Mercurial > octave
changeset 29822:0923ae48a4f7
avoid possible crash on return to command line after closing main window
* octave-qobject.h, octave-qobject.cc
(base_qobject::variable_editor_widget): Connect qt_interpreter_events
refresh_variable_editor_signal directly to variable_editor refresh
slot instead of to base_qobject refresh_variable_editor slot.
(base_qobject::refresh_variable_editor): Delete unused slot function.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Fri, 25 Jun 2021 15:39:48 -0400 |
parents | 589d2ae0b04e |
children | 7917b91a3c58 |
files | libgui/src/octave-qobject.cc libgui/src/octave-qobject.h |
diffstat | 2 files changed, 1 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/libgui/src/octave-qobject.cc Fri Jun 25 09:09:01 2021 -0400 +++ b/libgui/src/octave-qobject.cc Fri Jun 25 15:39:48 2021 -0400 @@ -699,7 +699,7 @@ connect (qt_link (), &qt_interpreter_events::refresh_variable_editor_signal, - this, &base_qobject::refresh_variable_editor); + m_variable_editor_widget, &variable_editor::refresh); connect_interpreter_events<variable_editor> (m_variable_editor_widget); } @@ -855,11 +855,6 @@ }); } - void base_qobject::refresh_variable_editor (void) - { - m_variable_editor_widget->refresh (); - } - void base_qobject::execute_command (const QString& command) { emit interpreter_event
--- a/libgui/src/octave-qobject.h Fri Jun 25 09:09:01 2021 -0400 +++ b/libgui/src/octave-qobject.h Fri Jun 25 15:39:48 2021 -0400 @@ -223,8 +223,6 @@ void handle_variable_editor_update (void); - void refresh_variable_editor (void); - void interpreter_ready (void); void interpreter_event (const fcn_callback& fcn);