Diffstat (limited to 'noncore/apps/opie-console/mainwindow.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/opie-console/mainwindow.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/noncore/apps/opie-console/mainwindow.h b/noncore/apps/opie-console/mainwindow.h index 19d3a3d..3b16f0a 100644 --- a/noncore/apps/opie-console/mainwindow.h +++ b/noncore/apps/opie-console/mainwindow.h | |||
@@ -1,129 +1,132 @@ | |||
1 | #ifndef OPIE_MAIN_WINDOW_H | 1 | #ifndef OPIE_MAIN_WINDOW_H |
2 | #define OPIE_MAIN_WINDOW_H | 2 | #define OPIE_MAIN_WINDOW_H |
3 | 3 | ||
4 | #include <qmainwindow.h> | 4 | #include <qmainwindow.h> |
5 | #include <qlist.h> | 5 | #include <qlist.h> |
6 | 6 | ||
7 | #include "session.h" | 7 | #include "session.h" |
8 | 8 | ||
9 | /** | 9 | /** |
10 | * this is the MainWindow of the new opie console | 10 | * this is the MainWindow of the new opie console |
11 | * it's also the dispatcher between the different | 11 | * it's also the dispatcher between the different |
12 | * actions supported by the gui | 12 | * actions supported by the gui |
13 | */ | 13 | */ |
14 | class QToolBar; | 14 | class QToolBar; |
15 | class QToolButton; | 15 | class QToolButton; |
16 | class QMenuBar; | 16 | class QMenuBar; |
17 | class QAction; | 17 | class QAction; |
18 | class MetaFactory; | 18 | class MetaFactory; |
19 | class TabWidget; | 19 | class TabWidget; |
20 | class ProfileManager; | 20 | class ProfileManager; |
21 | class Profile; | 21 | class Profile; |
22 | class FunctionKeyboard; | 22 | class FunctionKeyboard; |
23 | class FKey; | 23 | class FKey; |
24 | 24 | class DocLnk; | |
25 | 25 | ||
26 | class MainWindow : public QMainWindow { | 26 | class MainWindow : public QMainWindow { |
27 | Q_OBJECT | 27 | Q_OBJECT |
28 | public: | 28 | public: |
29 | MainWindow( QWidget *parent = 0, const char *name = 0, WFlags fl = 0 ); | 29 | MainWindow( QWidget *parent = 0, const char *name = 0, WFlags fl = 0 ); |
30 | ~MainWindow(); | 30 | ~MainWindow(); |
31 | 31 | ||
32 | /** | 32 | /** |
33 | * our factory to generate IOLayer and so on | 33 | * our factory to generate IOLayer and so on |
34 | * | 34 | * |
35 | */ | 35 | */ |
36 | MetaFactory* factory(); | 36 | MetaFactory* factory(); |
37 | 37 | ||
38 | /** | 38 | /** |
39 | * A session contains a QWidget*, | 39 | * A session contains a QWidget*, |
40 | * an IOLayer* and some infos for us | 40 | * an IOLayer* and some infos for us |
41 | */ | 41 | */ |
42 | Session* currentSession(); | 42 | Session* currentSession(); |
43 | 43 | ||
44 | /** | 44 | /** |
45 | * the session list | 45 | * the session list |
46 | */ | 46 | */ |
47 | QList<Session> sessions(); | 47 | QList<Session> sessions(); |
48 | 48 | ||
49 | /** | 49 | /** |
50 | * | 50 | * |
51 | */ | 51 | */ |
52 | ProfileManager* manager(); | 52 | ProfileManager* manager(); |
53 | TabWidget* tabWidget(); | 53 | TabWidget* tabWidget(); |
54 | 54 | ||
55 | private slots: | 55 | private slots: |
56 | void slotNew(); | 56 | void slotNew(); |
57 | void slotConnect(); | 57 | void slotConnect(); |
58 | void slotDisconnect(); | 58 | void slotDisconnect(); |
59 | void slotTerminate(); | 59 | void slotTerminate(); |
60 | void slotConfigure(); | 60 | void slotConfigure(); |
61 | void slotClose(); | 61 | void slotClose(); |
62 | void slotProfile(int); | 62 | void slotProfile(int); |
63 | void slotTransfer(); | 63 | void slotTransfer(); |
64 | void slotOpenKeb(bool); | 64 | void slotOpenKeb(bool); |
65 | void slotOpenButtons(bool); | 65 | void slotOpenButtons(bool); |
66 | void slotRecordScript(); | 66 | void slotRecordScript(); |
67 | void slotSaveScript(); | 67 | void slotSaveScript(); |
68 | void slotRunScript(); | 68 | void slotRunScript(int); |
69 | void slotFullscreen(); | 69 | void slotFullscreen(); |
70 | void slotSessionChanged( Session* ); | 70 | void slotSessionChanged( Session* ); |
71 | void slotKeyReceived(FKey, ushort, ushort, bool); | 71 | void slotKeyReceived(FKey, ushort, ushort, bool); |
72 | 72 | ||
73 | /* what could these both slot do? */ | 73 | /* what could these both slot do? */ |
74 | void slotCopy(); | 74 | void slotCopy(); |
75 | void slotPaste(); | 75 | void slotPaste(); |
76 | 76 | ||
77 | /* save the currentSession() to Profiles */ | 77 | /* save the currentSession() to Profiles */ |
78 | void slotSaveSession(); | 78 | void slotSaveSession(); |
79 | 79 | ||
80 | private: | 80 | private: |
81 | void initUI(); | 81 | void initUI(); |
82 | void populateProfiles(); | 82 | void populateProfiles(); |
83 | void populateScripts(); | ||
83 | void create( const Profile& ); | 84 | void create( const Profile& ); |
84 | /** | 85 | /** |
85 | * the current session | 86 | * the current session |
86 | */ | 87 | */ |
87 | Session* m_curSession; | 88 | Session* m_curSession; |
88 | 89 | ||
89 | /** | 90 | /** |
90 | * the session list | 91 | * the session list |
91 | */ | 92 | */ |
92 | QList<Session> m_sessions; | 93 | QList<Session> m_sessions; |
94 | QList<DocLnk> m_scriptsData; | ||
93 | 95 | ||
94 | /** | 96 | /** |
95 | * the metafactory | 97 | * the metafactory |
96 | */ | 98 | */ |
97 | MetaFactory* m_factory; | 99 | MetaFactory* m_factory; |
98 | ProfileManager* m_manager; | 100 | ProfileManager* m_manager; |
99 | 101 | ||
100 | TabWidget* m_consoleWindow; | 102 | TabWidget* m_consoleWindow; |
101 | QToolBar* m_tool; | 103 | QToolBar* m_tool; |
102 | QToolBar* m_icons; | 104 | QToolBar* m_icons; |
103 | QToolBar* m_keyBar; | 105 | QToolBar* m_keyBar; |
104 | QToolBar* m_buttonBar; | 106 | QToolBar* m_buttonBar; |
105 | QMenuBar* m_bar; | 107 | QMenuBar* m_bar; |
106 | QPopupMenu* m_console; | 108 | QPopupMenu* m_console; |
107 | QPopupMenu* m_sessionsPop; | 109 | QPopupMenu* m_sessionsPop; |
110 | QPopupMenu* m_scriptsPop; | ||
108 | QPopupMenu* m_scripts; | 111 | QPopupMenu* m_scripts; |
109 | QAction* m_connect; | 112 | QAction* m_connect; |
110 | QAction* m_disconnect; | 113 | QAction* m_disconnect; |
111 | QAction* m_terminate; | 114 | QAction* m_terminate; |
112 | QAction* m_transfer; | 115 | QAction* m_transfer; |
113 | QAction* m_setProfiles; | 116 | QAction* m_setProfiles; |
114 | QAction* m_openKeys; | 117 | QAction* m_openKeys; |
115 | QAction* m_openButtons; | 118 | QAction* m_openButtons; |
116 | QAction* m_recordScript; | 119 | QAction* m_recordScript; |
117 | QAction* m_saveScript; | 120 | QAction* m_saveScript; |
118 | QAction* m_runScript; | ||
119 | QAction* m_fullscreen; | 121 | QAction* m_fullscreen; |
120 | QAction* m_closewindow; | 122 | QAction* m_closewindow; |
121 | 123 | ||
122 | FunctionKeyboard *m_kb; | 124 | FunctionKeyboard *m_kb; |
125 | int m_runScript_id; | ||
123 | bool m_isFullscreen; | 126 | bool m_isFullscreen; |
124 | 127 | ||
125 | QWidget* savedParentFullscreen; | 128 | QWidget* savedParentFullscreen; |
126 | }; | 129 | }; |
127 | 130 | ||
128 | 131 | ||
129 | #endif | 132 | #endif |