#include <monitorwidget.h>
Public Slots | |
| void | addEntry (QString name, QString pid, QString cpu, QString owner) |
| void | removeEntry () |
| void | refreshImage () |
Signals | |
| void | doubleClicked (QModelIndex) |
Public Member Functions | |
| MonitorWidget (QWidget *parent=0) | |
| void | loadImage (const QString &fileName, QImage *image, QToolButton *button) |
Private Member Functions | |
| void | setupTabs () |
Private Attributes | |
| QImage * | image |
| QTimer * | timer |
| QSortFilterProxyModel * | proxyModel |
| QToolButton * | btn |
| Plot | p |
| TableModel * | table |
| SysInfoTab * | sysInfoTab |
| MonitorWidget::MonitorWidget | ( | QWidget * | parent = 0 |
) |
This constructor sets up tabs in the central primary window and adds a tab to it.It also initializes a new instance of TableModel type.
| void MonitorWidget::addEntry | ( | QString | name, | |
| QString | pid, | |||
| QString | cpu, | |||
| QString | owner | |||
| ) | [slot] |
| void MonitorWidget::doubleClicked | ( | QModelIndex | ) | [signal] |
| void MonitorWidget::loadImage | ( | const QString & | fileName, | |
| QImage * | image, | |||
| QToolButton * | button | |||
| ) |
Function to load graph image into CPU utilization
| void MonitorWidget::refreshImage | ( | ) | [slot] |
This function is called when the timer signal is raised to update the graph image.
| void MonitorWidget::removeEntry | ( | ) | [slot] |
This function deletes all rows in the table
| void MonitorWidget::setupTabs | ( | ) | [private] |
This function sets all the right properties of the tabs in the primary window. It also raises a call to the rowSelected function in the event of a row being double clicked.
QToolButton* MonitorWidget::btn [private] |
QImage* MonitorWidget::image [private] |
Plot MonitorWidget::p [private] |
QSortFilterProxyModel* MonitorWidget::proxyModel [private] |
SysInfoTab* MonitorWidget::sysInfoTab [private] |
TableModel* MonitorWidget::table [private] |
QTimer* MonitorWidget::timer [private] |
1.4.7