From dca91a3b842ba70817b128d30cdb728326129e93 Mon Sep 17 00:00:00 2001
From: Freeman Lou <freemanlou2430@Yahoo.com>
Date: Thu, 5 Dec 2013 15:14:38 +0000
Subject: [PATCH] diskusage background color
---
src/apps/diskusage/PieView.cpp | 9 +++++++--
src/apps/diskusage/PieView.h | 1 +
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/src/apps/diskusage/PieView.cpp b/src/apps/diskusage/PieView.cpp
index 80534fd..d271977 100644
a
|
b
|
void
|
166 | 166 | PieView::AttachedToWindow() |
167 | 167 | { |
168 | 168 | fWindow = (MainWindow*)Window(); |
| 169 | if (Parent()) { |
| 170 | fBackGroundColor = Parent()->ViewColor(); |
| 171 | SetViewColor(fBackGroundColor); |
| 172 | } |
169 | 173 | } |
170 | 174 | |
171 | 175 | |
… |
… |
PieView::_DrawProgressBar(BRect updateRect)
|
354 | 358 | |
355 | 359 | fMouseOverInfo.clear(); |
356 | 360 | |
357 | | FillRect(updateRect, B_SOLID_LOW); |
| 361 | SetHighColor(fBackGroundColor); |
| 362 | FillRect(updateRect); |
358 | 363 | |
359 | 364 | // Draw the progress bar. |
360 | 365 | BRect b = Bounds(); |
… |
… |
PieView::_DrawPieChart(BRect updateRect)
|
388 | 393 | |
389 | 394 | pieRect.InsetBy(kPieOuterMargin, kPieOuterMargin); |
390 | 395 | |
391 | | SetHighColor(kPieBGColor); |
| 396 | SetHighColor(fBackGroundColor); |
392 | 397 | FillRect(updateRect); |
393 | 398 | |
394 | 399 | // constraint proportions |
diff --git a/src/apps/diskusage/PieView.h b/src/apps/diskusage/PieView.h
index 4890de8..47f396d 100644
a
|
b
|
private:
|
94 | 94 | FileInfo* fClickedFile; |
95 | 95 | BPoint fLastWhere; |
96 | 96 | bool fUpdateFileAt; |
| 97 | rgb_color fBackGroundColor; |
97 | 98 | }; |
98 | 99 | |
99 | 100 | #endif // PIE_VIEW_H |