Mercurial > octave
diff libgui/src/m-editor/file-editor.h @ 24731:a01472d4a170
use tab navigation from tab_bar in file editor
* file-editor.cc (active_tab_changed): give focus to current tab widget;
(switch_left_tab, switch_right_tab, move_tab_left, move_tab_right,
switch_tab): remove slots, now contained in tab_bar;
(construct): use new method for adding an action allowing a different
receiver for the action signal
(add_action): added argument for different receiver for action signal;
* file-editor.h: remove switch_left_tab, switch_right_tab, move_tab_left,
move_tab_right, switch_tab;
add_action with new receiver argument;
author | Torsten <mttl@mailbox.org> |
---|---|
date | Sun, 11 Feb 2018 10:57:46 +0100 |
parents | 63b5ac6a5ee7 |
children | 6652d3823428 |
line wrap: on
line diff
--- a/libgui/src/m-editor/file-editor.h Sun Feb 11 10:16:53 2018 +0100 +++ b/libgui/src/m-editor/file-editor.h Sun Feb 11 10:57:46 2018 +0100 @@ -300,11 +300,6 @@ void zoom_out (bool); void zoom_normal (bool); - void switch_left_tab (void); - void switch_right_tab (void); - void move_tab_left (void); - void move_tab_right (void); - void create_context_menu (QMenu *); void edit_status_update (bool, bool); @@ -324,16 +319,15 @@ void toggle_preference (const QString& preference, bool def); - void switch_tab (int direction, bool movetab = false); - void handle_dir_remove (const QString& old_name, const QString& new_name); bool editor_tab_has_focus (void); QWidget * find_tab_widget (const QString& openFileName); - QAction * add_action (QMenu *menu, const QString& text, const char *member); + QAction * add_action (QMenu *menu, const QString& text, + const char *member, QWidget *receiver = nullptr); QAction * add_action (QMenu *menu, const QIcon& icon, const QString& text, - const char *member); + const char *member, QWidget *receiver = nullptr); QMenu * add_menu (QMenuBar *p, QString text);