OLD | NEW |
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_accessibility.h" | 5 #include "ash/system/tray_accessibility.h" |
6 | 6 |
7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
8 #include "ash/shell_delegate.h" | 8 #include "ash/shell_delegate.h" |
9 #include "ash/system/tray/tray_constants.h" | 9 #include "ash/system/tray/tray_constants.h" |
10 #include "ash/system/tray/tray_views.h" | 10 #include "ash/system/tray/tray_views.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 detailed_(NULL) { | 63 detailed_(NULL) { |
64 } | 64 } |
65 | 65 |
66 TrayAccessibility::~TrayAccessibility() {} | 66 TrayAccessibility::~TrayAccessibility() {} |
67 | 67 |
68 bool TrayAccessibility::GetInitialVisibility() { | 68 bool TrayAccessibility::GetInitialVisibility() { |
69 return Shell::GetInstance()->delegate() && | 69 return Shell::GetInstance()->delegate() && |
70 Shell::GetInstance()->delegate()->IsSpokenFeedbackEnabled(); | 70 Shell::GetInstance()->delegate()->IsSpokenFeedbackEnabled(); |
71 } | 71 } |
72 | 72 |
73 views::View* TrayAccessibility::CreateDefaultView(user::LoginStatus status) { | 73 views::View* TrayAccessibility::CreateDefaultView(user::LoginStatus status, |
| 74 int bubble_width) { |
74 if (!Shell::GetInstance()->delegate()->IsSpokenFeedbackEnabled()) | 75 if (!Shell::GetInstance()->delegate()->IsSpokenFeedbackEnabled()) |
75 return NULL; | 76 return NULL; |
76 | 77 |
77 CHECK(default_ == NULL); | 78 CHECK(default_ == NULL); |
78 default_ = new DefaultAccessibilityView(); | 79 default_ = new DefaultAccessibilityView(); |
79 | 80 |
80 return default_; | 81 return default_; |
81 } | 82 } |
82 | 83 |
83 views::View* TrayAccessibility::CreateDetailedView(user::LoginStatus status) { | 84 views::View* TrayAccessibility::CreateDetailedView(user::LoginStatus status) { |
(...skipping 30 matching lines...) Expand all Loading... |
114 | 115 |
115 if (enabled) { | 116 if (enabled) { |
116 PopupDetailedView(kTrayPopupAutoCloseDelayForTextInSeconds, false); | 117 PopupDetailedView(kTrayPopupAutoCloseDelayForTextInSeconds, false); |
117 } else if (detailed_) { | 118 } else if (detailed_) { |
118 detailed_->GetWidget()->Close(); | 119 detailed_->GetWidget()->Close(); |
119 } | 120 } |
120 } | 121 } |
121 | 122 |
122 } // namespace internal | 123 } // namespace internal |
123 } // namespace ash | 124 } // namespace ash |
OLD | NEW |