summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-console/emulation_handler.h
Side-by-side diff
Diffstat (limited to 'noncore/apps/opie-console/emulation_handler.h') (more/less context) (show whitespace changes)
-rw-r--r--noncore/apps/opie-console/emulation_handler.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/noncore/apps/opie-console/emulation_handler.h b/noncore/apps/opie-console/emulation_handler.h
index 1338525..1092c82 100644
--- a/noncore/apps/opie-console/emulation_handler.h
+++ b/noncore/apps/opie-console/emulation_handler.h
@@ -18,27 +18,31 @@
* This nice QObject here will get stuff from
* got a slot and a signal
* the signal for data
* the slot for receiving
* it'll set up the widget internally
* and manage the communication between
* the pre QByteArray world!
*/
class Profile;
class QWidget;
class QPushButton;
class TEWidget;
+class QFile;
class TEmulation;
class QFont;
+class QTextStream;
class Script;
+class Logger;
+
class EmulationHandler : public QObject {
Q_OBJECT
public:
/**
* simple c'tor the parent of the TEWdiget
* and a name
* and a Profile
*/
EmulationHandler( const Profile&, QWidget* parent, const char* name = 0l );
/**
* delete all components
@@ -46,33 +50,43 @@ public:
~EmulationHandler();
void load( const Profile& );
QWidget* widget();
TEmulation *emulation();
void setColor( const QColor& fore, const QColor& back );
QPushButton* cornerButton();
/* Scripts */
/* Create a new script and record all typed characters */
void startRecording();
+ void startLogging(const QString);
+
/* Return whether we are currently recording a script */
bool isRecording();
+ /* Return whether we are currently recording a log */
+ bool isLogging();
+
+ QString logFileName();
+
/* Return the current script (or NULL) */
Script *script();
/* Stop recording and remove the current script from memory */
void clearScript();
+ /* Stop logging and remove the current log from memory */
+ void clearLog();
+
/* Run a script by forwarding its keys to the EmulationLayer */
void runScript(const Script *);
/* Propagate change to widget */
void setWrap(int columns);
signals:
void send( const QByteArray& );
void changeSize(int rows, int cols );
public slots:
void recv( const QByteArray& );
@@ -81,15 +95,17 @@ public slots:
private slots:
void recvEmulation( const char*, int len );
private:
QFont font( int );
QColor foreColor(int );
QColor backColor(int );
private:
TEWidget* m_teWid;
TEmulation* m_teEmu;
Script * m_script;
+ Logger *m_log;
+ QString m_logFileName;
};
#endif