Mercurial > octave
comparison libgui/src/main-window.cc @ 27409:a0d49e55acae
rename change_directory to directory_changed in event manager
Attempt to be clearer that this action is a notification about a
directory change that has happened, not a request to change the
directory.
* event-manager.h (interpreter_events::directory_changed,
event_manager::directory_changed): Rename from change_directory.
Change all uses.
* qt-interpreter-events.h, qt-interpreter-events.cc
(qt_interpreter_events::directory_changed,
qt_interpreter_events::directory_changed_signal): Rename from
change_directory and change_directory_signal. Change all uses.
* main-window.cc (main_window::update_octave_directory): Rename from
change_directory. Change all uses.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Fri, 13 Sep 2019 16:40:08 -0400 |
parents | 9b19eec60931 |
children | da1f59fe04b3 |
comparison
equal
deleted
inserted
replaced
27408:9b19eec60931 | 27409:a0d49e55acae |
---|---|
941 set_window_layout (nullptr); // do not use the settings file | 941 set_window_layout (nullptr); // do not use the settings file |
942 showNormal (); // make sure main window is not minimized | 942 showNormal (); // make sure main window is not minimized |
943 focus_command_window (); | 943 focus_command_window (); |
944 } | 944 } |
945 | 945 |
946 void main_window::change_directory (const QString& dir) | 946 void main_window::update_octave_directory (const QString& dir) |
947 { | 947 { |
948 // Remove existing entry, if any, then add new directory at top and | 948 // Remove existing entry, if any, then add new directory at top and |
949 // mark it as the current directory. Finally, update the file list | 949 // mark it as the current directory. Finally, update the file list |
950 // widget. | 950 // widget. |
951 | 951 |
2121 SLOT (set_workspace (bool, bool, const symbol_info_list&))); | 2121 SLOT (set_workspace (bool, bool, const symbol_info_list&))); |
2122 | 2122 |
2123 connect (qt_link, SIGNAL (clear_workspace_signal (void)), | 2123 connect (qt_link, SIGNAL (clear_workspace_signal (void)), |
2124 m_workspace_model, SLOT (clear_workspace (void))); | 2124 m_workspace_model, SLOT (clear_workspace (void))); |
2125 | 2125 |
2126 connect (qt_link, SIGNAL (change_directory_signal (QString)), | 2126 connect (qt_link, SIGNAL (directory_changed_signal (QString)), |
2127 this, SLOT (change_directory (QString))); | 2127 this, SLOT (update_octave_directory (QString))); |
2128 | 2128 |
2129 connect (qt_link, SIGNAL (change_directory_signal (QString)), | 2129 connect (qt_link, SIGNAL (directory_changed_signal (QString)), |
2130 m_file_browser_window, SLOT (update_octave_directory (QString))); | 2130 m_file_browser_window, SLOT (update_octave_directory (QString))); |
2131 | 2131 |
2132 connect (qt_link, SIGNAL (change_directory_signal (QString)), | 2132 connect (qt_link, SIGNAL (directory_changed_signal (QString)), |
2133 m_editor_window, SLOT (update_octave_directory (QString))); | 2133 m_editor_window, SLOT (update_octave_directory (QString))); |
2134 | 2134 |
2135 connect (qt_link, | 2135 connect (qt_link, |
2136 SIGNAL (execute_command_in_terminal_signal (QString)), | 2136 SIGNAL (execute_command_in_terminal_signal (QString)), |
2137 this, SLOT (execute_command_in_terminal (QString))); | 2137 this, SLOT (execute_command_in_terminal (QString))); |