summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-console/session.h
Unidiff
Diffstat (limited to 'noncore/apps/opie-console/session.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-console/session.h38
1 files changed, 32 insertions, 6 deletions
diff --git a/noncore/apps/opie-console/session.h b/noncore/apps/opie-console/session.h
index 44b5fc8..c3673fc 100644
--- a/noncore/apps/opie-console/session.h
+++ b/noncore/apps/opie-console/session.h
@@ -1,12 +1,14 @@
1#ifndef OPIE_SESSION_H 1#ifndef OPIE_SESSION_H
2#define OPIE_SESSION_H 2#define OPIE_SESSION_H
3 3
4#include <qwidget.h> 4#include <qwidgetstack.h>
5 5
6class IOLayer; 6class IOLayer;
7class EmulationLayer;
8class Widget;
7/** 9/**
8 * This is a Session. A session contains 10 * This is a Session. A session contains
9 * a QWidget pointer and a IOLayer 11 * a QWidget pointer and a IOLayer
10 * Imagine a session like a collection of what 12 * Imagine a session like a collection of what
11 * is needed to show your widget in a tab ;) 13 * is needed to show your widget in a tab ;)
12 */ 14 */
@@ -14,35 +16,59 @@ class Session {
14public: 16public:
15 /** 17 /**
16 * c'tor with widget and layer 18 * c'tor with widget and layer
17 * ownership get's transfered 19 * ownership get's transfered
18 */ 20 */
19 Session(); 21 Session();
20 Session( const QString&, QWidget* widget, IOLayer* ); 22 Session( const QString&, QWidgetStack* widget, IOLayer* );
21 ~Session(); 23 ~Session();
22 24
23 /** 25 /**
24 * return the name of the session 26 * return the name of the session
25 */ 27 */
26 QString name()const; 28 QString name()const;
27 29
28 /** 30 /**
29 * return the widget 31 * return the widgetstack
32 * this is used to be semi modal
33 * for FileTransfer
34 *
35 * semi modal == SessionModal
30 */ 36 */
31 QWidget* widget(); 37 QWidgetStack* widgetStack();
32 38
33 /** 39 /**
34 * return the layer 40 * return the layer
35 */ 41 */
36 IOLayer* layer(); 42 IOLayer* layer();
37 void setWidget( QWidget* widget ); 43
44 EmulationLayer* emulationLayer();
45 Widget* emulationWidget();
46
47 /*
48 * connects the data flow from
49 * the IOLayer to the EmulationLayer
50 */
51 void connect();
52
53 /*
54 * disconnect the dataflow
55 * this will be done for ft
56 */
57 void disconnect();
58
59 void setWidgetStack( QWidgetStack* widget );
60 void setEmulationLayer( EmulationLayer* lay );
61 void setEmulationWidget( Widget* lay );
38 void setIOLayer( IOLayer* ); 62 void setIOLayer( IOLayer* );
39 void setName( const QString& ); 63 void setName( const QString& );
40 64
41private: 65private:
42 QString m_name; 66 QString m_name;
43 QWidget* m_widget; 67 QWidgetStack* m_widget;
44 IOLayer* m_layer; 68 IOLayer* m_layer;
69 EmulationLayer* m_emLay;
70 Widget* m_widLay;
45 71
46}; 72};
47 73
48#endif 74#endif