summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/applets/batteryapplet/batterystatus.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/core/applets/batteryapplet/batterystatus.cpp b/core/applets/batteryapplet/batterystatus.cpp
index 860db64..f27543c 100644
--- a/core/applets/batteryapplet/batterystatus.cpp
+++ b/core/applets/batteryapplet/batterystatus.cpp
@@ -130,63 +130,63 @@ void BatteryStatus::drawSegment( QPainter *p, const QRect &r, const QColor &topg
130} 130}
131 131
132QString BatteryStatus::statusText() const { 132QString BatteryStatus::statusText() const {
133 QString text; 133 QString text;
134 134
135 if ( ps->batteryStatus() == PowerStatus::Charging ) { 135 if ( ps->batteryStatus() == PowerStatus::Charging ) {
136 if (bat2) { 136 if (bat2) {
137 text = tr("Charging both devices"); 137 text = tr("Charging both devices");
138 } else { 138 } else {
139 text = tr("Charging"); 139 text = tr("Charging");
140 } 140 }
141 } else if ( ps->batteryPercentAccurate() ) { 141 } else if ( ps->batteryPercentAccurate() ) {
142 text.sprintf( tr("Percentage battery remaining") + ": %i%%", percent ); 142 text.sprintf( tr("Remaining Power") + ": %i%%", percent );
143 } else { 143 } else {
144 text = tr("Battery status: "); 144 text = tr("Battery status: ");
145 switch ( ps->batteryStatus() ) { 145 switch ( ps->batteryStatus() ) {
146 case PowerStatus::High: 146 case PowerStatus::High:
147 text += tr("Good"); 147 text += tr("Good");
148 break; 148 break;
149 case PowerStatus::Low: 149 case PowerStatus::Low:
150 text += tr("Low"); 150 text += tr("Low");
151 break; 151 break;
152 case PowerStatus::VeryLow: 152 case PowerStatus::VeryLow:
153 text += tr("Very Low"); 153 text += tr("Very Low");
154 break; 154 break;
155 case PowerStatus::Critical: 155 case PowerStatus::Critical:
156 text += tr("Critical"); 156 text += tr("Critical");
157 break; 157 break;
158 default: // NotPresent, etc. 158 default: // NotPresent, etc.
159 text += tr("Unknown"); 159 text += tr("Unknown");
160 } 160 }
161 } 161 }
162 162
163 if ( ps->acStatus() == PowerStatus::Backup ) 163 if ( ps->acStatus() == PowerStatus::Backup )
164 text += "\n" + tr("On backup power"); 164 text += "\n" + tr("On backup power");
165 else if ( ps->acStatus() == PowerStatus::Online ) 165 else if ( ps->acStatus() == PowerStatus::Online )
166 text += "\n" + tr("Power on-line"); 166 text += "\n" + tr("Power on-line");
167 else if ( ps->acStatus() == PowerStatus::Offline ) 167 else if ( ps->acStatus() == PowerStatus::Offline )
168 text += "\n" + tr("External power disconnected"); 168 text += "\n" + tr("External power disconnected");
169 169
170 if ( ps->batteryTimeRemaining() >= 0 ) { 170 if ( ps->batteryTimeRemaining() >= 0 ) {
171 text += "\n" + QString().sprintf( tr("Battery time remaining") + ": %im %02is", 171 text += "\n" + QString().sprintf( tr("Remaining Time") + ": %im %02is",
172 ps->batteryTimeRemaining() / 60, ps->batteryTimeRemaining() % 60 ); 172 ps->batteryTimeRemaining() / 60, ps->batteryTimeRemaining() % 60 );
173 } 173 }
174 return text; 174 return text;
175} 175}
176 176
177QString BatteryStatus::statusTextIpaq() const { 177QString BatteryStatus::statusTextIpaq() const {
178 QString text; 178 QString text;
179 text += tr("Percentage battery remaining: ") + perc2 + " " + jackStatus; 179 text += tr("Remaining Power: ") + perc2 + " " + jackStatus;
180 text += "\n" + tr("Battery time remaining: ") + sec2; 180 text += "\n" + tr("Remaining Time: ") + sec2;
181 return text; 181 return text;
182} 182}
183 183
184void BatteryStatus::paintEvent( QPaintEvent * ev ) { 184void BatteryStatus::paintEvent( QPaintEvent * ev ) {
185 185
186 QPainter p( this ); 186 QPainter p( this );
187 187
188 QString text = statusText(); 188 QString text = statusText();
189 p.drawText( 10, 50, width() - 20, 40 , AlignVCenter, text ); 189 p.drawText( 10, 50, width() - 20, 40 , AlignVCenter, text );
190 190
191 QColor c; 191 QColor c;
192 QColor darkc; 192 QColor darkc;