00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 
00021 
00022 
00023 
00024 
00025 
00026 
00027 
00028 
00029 
00030 
00031 
00032 
00033 
00034 
00035 
00036 
00037 
00038 
00039 
00040 
00041 
00042 
00043 
00044 
00045 
00046 
00047 
00048 
00049 
00050 
00051 
00052 
00053 
00054 
00055 
00056 
00057 
00058 
00059 
00060 
00061 
00062 
00063 
00064 
00065 
00066 
00067 
00068    
00069 
00070 #ifndef SJOBPROPVIEW_H
00071 #define SJOBPROPVIEW_H 
00072 
00073 
00074 
00075 
00076 #include "../model/STaskSystem.h"
00077 #include "../general/SObserver.h"
00078 #include "SView.h"
00079 
00080 
00081 #include <qframe.h>
00082 #include <qlabel.h>
00083 #include <qlineedit.h>
00084 #include <qlayout.h>
00085 #include <qpushbutton.h>
00086 #include <qlistview.h>
00087 
00096 class SJobPropView : public SView, SObserver
00097 {
00098   Q_OBJECT
00099 
00100 public:
00105   SJobPropView( STaskSystem &ts, int job, 
00106     QWidget *parent = NULL, const char *name = "" );
00107   ~SJobPropView() {};
00108   
00113   virtual QSize sizeHint() { return _pGrid->totalSizeHint(); };
00114 
00115 protected:
00118   virtual void update( const class SEvent & );
00119  
00120 private:
00121   STaskSystem *_pTS;
00124   int _job;
00127   QGridLayout *_pGrid;
00130   QLineEdit *_pNumOpsEdit;
00133   QLineEdit *_pWeightEdit;
00136   QLineEdit *_pProcTimeEdit;
00137   QLineEdit *_pExpProcTimeEdit;
00140   QLabel *_pRemProcTimeLabel;
00141 
00142   QLabel *_pDistLabel;
00145   QLabel *_pExpProcTimeLabel;
00148   QLabel *_pReleaseTimeLabel;
00151   QLabel *_pStateLabel;
00154   QLabel *_pDueTimeLabel; 
00155   QListView *_pOpTimeMachListView; 
00156   QButtonGroup *_pOpTimeMachGroup;
00157   QLineEdit *_pMachEdit, *_pPartProcTimeEdit;
00158   QPushButton *_pApplyBtn;
00162   void displayProperties();
00165   void displayShopProperties();
00166 
00167 private slots:
00170   void set();
00175   void timeMachSelChanged( QListViewItem* );
00179   void changeOperation();
00182   void enableApplyBtn( const QString& );
00185   void closeAndDelete();
00186 };
00187 
00188 #endif //SJOBPROPVIEW_H