Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #ifndef QMITKMEMORYUSAGEINDICATORVIEW_WIDGET
00019 #define QMITKMEMORYUSAGEINDICATORVIEW_WIDGET
00020
00021 #include <QWidget>
00022 #include <qpixmap.h>
00023 #include "ui_QmitkMemoryUsageIndicator.h"
00024
00025 class QMITK_EXPORT QmitkMemoryUsageIndicatorView : public QWidget, public Ui::QmitkMemoryUsageIndicator
00026 {
00027
00028 Q_OBJECT
00029
00030 public:
00031
00033 QmitkMemoryUsageIndicatorView( QWidget * parent=0, Qt::WindowFlags f = 0 );
00034
00036 ~QmitkMemoryUsageIndicatorView();
00037
00038 protected slots:
00039 void UpdateMemoryUsage();
00040
00041 protected:
00042
00043 std::string FormatMemorySize( size_t size );
00044 std::string FormatPercentage( double val );
00045 std::string GetMemoryDescription( size_t processSize, float percentage );
00046
00047 QPixmap m_LEDGreen;
00048 QPixmap m_LEDYellow;
00049 QPixmap m_LEDOrange;
00050 QPixmap m_LEDRed;
00051 char m_PreviousState;
00052 };
00053 #endif //QMITKMEMORYUSAGEINDICATORVIEW_WIDGET