Mercurial > hg > octave-nkf
comparison libgui/src/files-dock-widget.h @ 16506:8a4960f2c7c3
gui: allow running files from the file browser
* files-dock-widget.cc(constructor): connect run_file_signal
(contextmenu_requested): add menu to run the selected file
(contextmenu_run): new slot for running the selected file
(run_file_signal): new signal
* files-dock-widget.h: new function contextmenu_run, new signal run_file_signal
author | Torsten <ttl@justmail.de> |
---|---|
date | Fri, 12 Apr 2013 22:20:39 +0200 |
parents | 49b059bf27c7 |
children | 14045b872a3d |
comparison
equal
deleted
inserted
replaced
16505:ff061068a66c | 16506:8a4960f2c7c3 |
---|---|
83 /** context menu wanted */ | 83 /** context menu wanted */ |
84 void contextmenu_requested (const QPoint& pos); | 84 void contextmenu_requested (const QPoint& pos); |
85 | 85 |
86 /* context menu actions */ | 86 /* context menu actions */ |
87 void contextmenu_open (bool); | 87 void contextmenu_open (bool); |
88 void contextmenu_run (bool); | |
88 void contextmenu_load (bool); | 89 void contextmenu_load (bool); |
89 void contextmenu_rename (bool); | 90 void contextmenu_rename (bool); |
90 void contextmenu_delete (bool); | 91 void contextmenu_delete (bool); |
91 void contextmenu_newfile (bool); | 92 void contextmenu_newfile (bool); |
92 void contextmenu_newdir (bool); | 93 void contextmenu_newdir (bool); |
99 /** Emitted, whenever the currently displayed directory changed. */ | 100 /** Emitted, whenever the currently displayed directory changed. */ |
100 void displayed_directory_changed (const QString& dir); | 101 void displayed_directory_changed (const QString& dir); |
101 | 102 |
102 /** Emitted, whenever the user requested to load a file. */ | 103 /** Emitted, whenever the user requested to load a file. */ |
103 void load_file_signal (const QString& fileName); | 104 void load_file_signal (const QString& fileName); |
105 | |
106 /** Emitted, whenever the user requested to run a file. */ | |
107 void run_file_signal (const QString& fileName); | |
104 | 108 |
105 private: | 109 private: |
106 | 110 |
107 // TODO: Add toolbar with buttons for navigating the path, creating dirs, etc | 111 // TODO: Add toolbar with buttons for navigating the path, creating dirs, etc |
108 | 112 |