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

Side by Side Diff: ash/system/tray/tray_empty.cc

Issue 11415014: Stop using shell::GetInstance()->system_tray() in system tray items (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ash/system/tray/tray_empty.h" 5 #include "ash/system/tray/tray_empty.h"
6 6
7 #include "ui/views/layout/box_layout.h" 7 #include "ui/views/layout/box_layout.h"
8 #include "ui/views/background.h" 8 #include "ui/views/background.h"
9 #include "ui/views/view.h" 9 #include "ui/views/view.h"
10 10
(...skipping 17 matching lines...) Expand all
28 namespace internal { 28 namespace internal {
29 29
30 TrayEmpty::TrayEmpty() {} 30 TrayEmpty::TrayEmpty() {}
31 31
32 TrayEmpty::~TrayEmpty() {} 32 TrayEmpty::~TrayEmpty() {}
33 33
34 views::View* TrayEmpty::CreateTrayView(user::LoginStatus status) { 34 views::View* TrayEmpty::CreateTrayView(user::LoginStatus status) {
35 return NULL; 35 return NULL;
36 } 36 }
37 37
38 views::View* TrayEmpty::CreateDefaultView(user::LoginStatus status) { 38 views::View* TrayEmpty::CreateDefaultView(user::LoginStatus status,
39 int bubble_width) {
39 if (status == user::LOGGED_IN_NONE) 40 if (status == user::LOGGED_IN_NONE)
40 return NULL; 41 return NULL;
41 42
42 views::View* view = new views::View; 43 views::View* view = new views::View;
43 view->set_background(new EmptyBackground()); 44 view->set_background(new EmptyBackground());
44 view->set_border(views::Border::CreateEmptyBorder(10, 0, 0, 0)); 45 view->set_border(views::Border::CreateEmptyBorder(10, 0, 0, 0));
45 view->SetLayoutManager(new views::BoxLayout(views::BoxLayout::kVertical, 46 view->SetLayoutManager(new views::BoxLayout(views::BoxLayout::kVertical,
46 0, 0, 0)); 47 0, 0, 0));
47 view->SetPaintToLayer(true); 48 view->SetPaintToLayer(true);
48 view->SetFillsBoundsOpaquely(false); 49 view->SetFillsBoundsOpaquely(false);
49 return view; 50 return view;
50 } 51 }
51 52
52 views::View* TrayEmpty::CreateDetailedView(user::LoginStatus status) { 53 views::View* TrayEmpty::CreateDetailedView(user::LoginStatus status) {
53 return NULL; 54 return NULL;
54 } 55 }
55 56
56 void TrayEmpty::DestroyTrayView() {} 57 void TrayEmpty::DestroyTrayView() {}
57 58
58 void TrayEmpty::DestroyDefaultView() {} 59 void TrayEmpty::DestroyDefaultView() {}
59 60
60 void TrayEmpty::DestroyDetailedView() {} 61 void TrayEmpty::DestroyDetailedView() {}
61 62
62 void TrayEmpty::UpdateAfterLoginStatusChange(user::LoginStatus status) {} 63 void TrayEmpty::UpdateAfterLoginStatusChange(user::LoginStatus status) {}
63 64
64 } // namespace internal 65 } // namespace internal
65 } // namespace ash 66 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698