Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(353)

Unified Diff: athena/screen/background_controller.cc

Issue 302683002: athena: Add the concept of Activity and related managers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: athena/screen/background_controller.cc
diff --git a/athena/screen/background_controller.cc b/athena/screen/background_controller.cc
index 53cf3e249112ca1da3a27ced2569aab0dec865b9..dd7f6cc4470e44df6ed45140de78213c5b0a12f2 100644
--- a/athena/screen/background_controller.cc
+++ b/athena/screen/background_controller.cc
@@ -25,16 +25,20 @@ class BackgroundView : public views::View {
// views::View
virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE {
- canvas->DrawImageInt(image_,
- 0,
- 0,
- image_.width(),
- image_.height(),
- 0,
- 0,
- width(),
- height(),
- true);
+ if (!image_.isNull()) {
oshima 2014/05/31 00:58:01 StartAthena sets the default background, so you do
+ canvas->DrawImageInt(image_,
+ 0,
+ 0,
+ image_.width(),
+ image_.height(),
+ 0,
+ 0,
+ width(),
+ height(),
+ true);
+ } else {
+ canvas->DrawColor(SK_ColorRED);
+ }
}
private:
« athena/activity/activity_view_manager_impl.cc ('K') | « athena/main/web_activity.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698