Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

QtFrontEnd Class Reference

QT Frontend. More...

#include <qtFrontEnd.h>

Inherits FrontEnd.

List of all members.

Public Methods

 QtFrontEnd (int argc, char** argv)
 ~QtFrontEnd ()
void update ()
 Update function. More...

void init ()
 Initialization function. More...

void displayUsers (int users)
 Display logged in Users. More...

void displayMatrices (int matrices)
 Display open matrices (OBSOLETE!!). More...

void displayDebugMessage (const char*)
 Display a debug message. More...


Private Attributes

FrontUpdatefrontUpdate
QTimer* timer
qtFronts
int argc
char** argv


Detailed Description

QT Frontend.

Definition at line 36 of file server/frontends/qt/qtFrontEnd.h.

00036 {
00037     public:
00038     QtFrontEnd (int argc, char** argv);
00039     ~QtFrontEnd ();
00040 
00041         void    update ();
00042 
00043     void    init();
00044 
00045     void    displayUsers (int users);   // amount of users logged in
00046     void    displayMatrices (int matrices); // amount of active matrices
00047 
00048     void    displayDebugMessage (const char*);
00049 
00050     private:
00051     FrontUpdate*    frontUpdate;
00052     QTimer*     timer;
00053     qtFront*    s;
00054 
00055     int         argc;
00056     char**      argv;
00057 }

Constructor & Destructor Documentation

QtFrontEnd::QtFrontEnd ( int argc,
char ** argv)

Definition at line 42 of file server/frontends/qt/qtFrontEnd.cpp.

00042 {
00043     this->argc=argc;
00044     this->argv=argv;
00045     
00046     myUsers    = 0;
00047     myMatrices = 0;
00048     
00049     usersChanged    = false;
00050     matricesChanged = false;
00051     strChanged      = false;
00052     
00053     myUsers    = 0;
00054     myMatrices = 0;
00055     myStr      = new Buffer ();
00056 }

QtFrontEnd::~QtFrontEnd ()

Definition at line 99 of file server/frontends/qt/qtFrontEnd.cpp.

00099 {
00100 }

Member Function Documentation

void QtFrontEnd::displayDebugMessage ( const char * msg) [virtual]

Display a debug message.

Parameters:
msg   the debug message

Reimplemented from FrontEnd.

Definition at line 159 of file server/frontends/qt/qtFrontEnd.cpp.

00159 {
00160     packet tmp;
00161     strcpy (tmp.data, msg);
00162     
00163     myStr->write (&tmp);
00164     
00165     strChanged = true;
00166 }

void QtFrontEnd::displayMatrices ( int matrices) [virtual]

Display open matrices (OBSOLETE!!).

Parameters:
matrices   number of open matrices

Reimplemented from FrontEnd.

Definition at line 143 of file server/frontends/qt/qtFrontEnd.cpp.

00143 {
00144     myMatrices = matrices;
00145     matricesChanged = true;
00146 }

void QtFrontEnd::displayUsers ( int users) [virtual]

Display logged in Users.

Parameters:
users   number of users to be displayed

Reimplemented from FrontEnd.

Definition at line 127 of file server/frontends/qt/qtFrontEnd.cpp.

00127 {
00128     myUsers = users;
00129     usersChanged = true;
00130 }

void QtFrontEnd::init () [virtual]

Initialization function.

Reimplemented from FrontEnd.

Definition at line 69 of file server/frontends/qt/qtFrontEnd.cpp.

00069 {
00070     QApplication* qapp;
00071     qapp = new QApplication (argc, argv);
00072     
00073     s=new qtFront();
00074     qapp->setMainWidget(s);
00075     s->show();
00076     
00077     frontUpdate = new FrontUpdate (s, s);
00078     
00079     timer = new QTimer ();
00080     QObject::connect (timer, SIGNAL (timeout ()), frontUpdate, SLOT (update ()));
00081     QObject::connect (frontUpdate, SIGNAL (sigUpdate ()), frontUpdate, SLOT (update ()));
00082     timer->start (100, FALSE);
00083     
00084     qapp->exec ();
00085     
00086     exit (0);
00087 }

void QtFrontEnd::update () [virtual]

Update function.

Reimplemented from FrontEnd.

Definition at line 112 of file server/frontends/qt/qtFrontEnd.cpp.

00112 {
00113 }

Member Data Documentation

int QtFrontEnd::argc [private]

Definition at line 55 of file server/frontends/qt/qtFrontEnd.h.

char ** QtFrontEnd::argv [private]

Definition at line 56 of file server/frontends/qt/qtFrontEnd.h.

FrontUpdate * QtFrontEnd::frontUpdate [private]

Definition at line 51 of file server/frontends/qt/qtFrontEnd.h.

qtFront * QtFrontEnd::s [private]

Definition at line 53 of file server/frontends/qt/qtFrontEnd.h.

QTimer * QtFrontEnd::timer [private]

Definition at line 52 of file server/frontends/qt/qtFrontEnd.h.


The documentation for this class was generated from the following files:
Generated at Sat May 13 13:50:27 2000 for 3Dsia by doxygen 1.1.2 written by Dimitri van Heesch, © 1997-2000