diff options
author | kintel <kintel@b57f626f-c46c-0410-a088-ec61d464b74c> | 2009-12-13 20:24:15 (GMT) |
---|---|---|
committer | kintel <kintel@b57f626f-c46c-0410-a088-ec61d464b74c> | 2009-12-13 20:24:15 (GMT) |
commit | e63ca44aca045492fedae85b19b17d1e4d184950 (patch) | |
tree | e337608dee3787b407ea5dd94b5c59f2df4ef563 /MainWindow.h | |
parent | 697052f93acfdf0ad6854de2cb4ee1cd20651ef4 (diff) |
Added Open Recent menu
git-svn-id: http://svn.clifford.at/openscad/trunk@170 b57f626f-c46c-0410-a088-ec61d464b74c
Diffstat (limited to 'MainWindow.h')
-rw-r--r-- | MainWindow.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/MainWindow.h b/MainWindow.h index c08e369..bf499b7 100644 --- a/MainWindow.h +++ b/MainWindow.h @@ -13,7 +13,7 @@ public: static QPointer<MainWindow> current_win; static void requestOpenFile(const QString &filename); - QString filename; + QString fileName; class Highlighter *highlighter; QTimer *animate_timer; @@ -39,23 +39,29 @@ public: QString last_compiled_doc; bool enableOpenCSG; + static const int maxRecentFiles = 10; + QAction *actionRecentFile[maxRecentFiles]; + MainWindow(const char *filename = 0); ~MainWindow(); private slots: void updatedFps(); void updateTVal(); + void setFileName(const QString &filename); private: void openFile(const QString &filename); void load(); - void maybe_change_dir(); void find_root_tag(AbstractNode *n); void compile(bool procevents); private slots: void actionNew(); void actionOpen(); + void actionOpenRecent(); + void clearRecentFiles(); + void updateRecentFileActions(); void actionSave(); void actionSaveAs(); void actionReload(); |