diff libgui/src/main-window.h @ 15626:1cc10ce368ea

enable entering a new directory in the current directory combobox * main_window.cc: construct (): use QLineEdit for the line edit in _current_directory_combo_box, connect its signal returnedPressed () to new slot current_working_directory_entered (), use const int instead of hard coded constants for combobox parameters; set_current_working_directory (): Check whether directory exists; new slot current_wirking_directory_entered (): set current directory to the entered one if it exists * main_window.h: new slot current_working_directory_entered (), define constants for combobox parameters, QLineEdit _current_directory_line_edit to be used in combobox
author Torsten <ttl@justmail.de>
date Sun, 25 Nov 2012 15:16:07 +0100
parents c9c79d4a0a00
children 7d300b85ee25
line wrap: on
line diff
--- a/libgui/src/main-window.h	Fri Nov 23 15:29:13 2012 -0500
+++ b/libgui/src/main-window.h	Sun Nov 25 15:16:07 2012 +0100
@@ -98,6 +98,7 @@
   void change_current_working_directory ();
   void set_current_working_directory (const QString& directory);
   void current_working_directory_up ();
+  void current_working_directory_entered ();
 
   void focus_command_window ();
   void focus_command_history ();
@@ -166,6 +167,10 @@
   // Toolbars.
   QStatusBar *              _status_bar;
   QComboBox *               _current_directory_combo_box;
+  static const int        current_directory_width       = 300;
+  static const int        current_directory_max_visible = 16;
+  static const int        current_directory_max_count   = 16;
+  QLineEdit *               _current_directory_line_edit;
 
   octave_qt_event_listener *_octave_qt_event_listener;