author | harlekin <harlekin> | 2004-05-11 22:41:22 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2004-05-11 22:41:22 (UTC) |
commit | 7a9cabb330284777113bb544139843dcf0593628 (patch) (side-by-side diff) | |
tree | ec706423d2abc2b7d2dcbbab8f3d846bcff45ee0 /core/applets/batteryapplet/batterystatus.h | |
parent | 81104f00cb87962333a024d3fa5ff6cf3d8d7d83 (diff) | |
download | opie-7a9cabb330284777113bb544139843dcf0593628.zip opie-7a9cabb330284777113bb544139843dcf0593628.tar.gz opie-7a9cabb330284777113bb544139843dcf0593628.tar.bz2 |
the "bett ery" commit, batteryapplet is now a popup, only shows second battery on ipaq if a second battery is present
Diffstat (limited to 'core/applets/batteryapplet/batterystatus.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/applets/batteryapplet/batterystatus.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/core/applets/batteryapplet/batterystatus.h b/core/applets/batteryapplet/batterystatus.h index a5ab804..bb95ece 100644 --- a/core/applets/batteryapplet/batterystatus.h +++ b/core/applets/batteryapplet/batterystatus.h @@ -15,46 +15,50 @@ ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #ifndef BATTERY_STATUS_H #define BATTERY_STATUS_H -#include <qwidget.h> +#include <qframe.h> class PowerStatus; -class BatteryStatus : public QWidget +class BatteryStatus : public QFrame { Q_OBJECT public: - BatteryStatus( const PowerStatus *s, QWidget *parent=0 ); + BatteryStatus( const PowerStatus *s, QWidget *parent=0, WFlags f = 0 ); ~BatteryStatus(); void updatePercent( int ); - + QSize sizeHint() const; protected: void drawSegment( QPainter *p, const QRect &r, const QColor &topgrad, const QColor &botgrad, const QColor &highlight, int hightlight_height ); void paintEvent( QPaintEvent *pe ); bool BatteryStatus::getProcApmStatusIpaq(); + private: + QString statusText() const; + QString statusTextIpaq() const; const PowerStatus *ps; int percent; int ipaqPercent; int jackPercent; int jackMinutes; QString perc1; QString sec1; QString perc2; QString sec2; QString ipaqStatus; QString jackStatus; QString ipaqChem; QString jackChem; bool bat2; + bool bat2inserted; int screenWidth; int screenHeight; }; #endif |