OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/common/system/chromeos/screen_security/screen_tray_item.h" | 5 #include "ash/common/system/chromeos/screen_security/screen_tray_item.h" |
6 | 6 |
7 #include "ash/common/material_design/material_design_controller.h" | 7 #include "ash/common/material_design/material_design_controller.h" |
8 #include "ash/common/shelf/wm_shelf_util.h" | 8 #include "ash/common/shelf/wm_shelf_util.h" |
9 #include "ash/common/system/tray/fixed_sized_image_view.h" | 9 #include "ash/common/system/tray/fixed_sized_image_view.h" |
10 #include "ash/common/system/tray/tray_constants.h" | 10 #include "ash/common/system/tray/tray_constants.h" |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 // TODO(bruthig): Multiline Labels don't lay out well with borders. | 101 // TODO(bruthig): Multiline Labels don't lay out well with borders. |
102 // See https://crbug.com/678337 & https://crbug.com/682221. | 102 // See https://crbug.com/678337 & https://crbug.com/682221. |
103 label_->SetBorder(nullptr); | 103 label_->SetBorder(nullptr); |
104 TrayPopupItemStyle style(TrayPopupItemStyle::FontStyle::DEFAULT_VIEW_LABEL); | 104 TrayPopupItemStyle style(TrayPopupItemStyle::FontStyle::DEFAULT_VIEW_LABEL); |
105 style.SetupLabel(label_); | 105 style.SetupLabel(label_); |
106 | 106 |
107 stop_button_ = TrayPopupUtils::CreateTrayPopupButton(this, stop_button_text_); | 107 stop_button_ = TrayPopupUtils::CreateTrayPopupButton(this, stop_button_text_); |
108 } | 108 } |
109 | 109 |
110 void ScreenStatusView::UpdateFromScreenTrayItem() { | 110 void ScreenStatusView::UpdateFromScreenTrayItem() { |
111 // Hide the notification bubble when the ash tray bubble opens. | |
112 screen_tray_item_->HideNotificationView(); | |
113 SetVisible(screen_tray_item_->is_started()); | 111 SetVisible(screen_tray_item_->is_started()); |
114 } | 112 } |
115 | 113 |
116 ScreenNotificationDelegate::ScreenNotificationDelegate( | 114 ScreenNotificationDelegate::ScreenNotificationDelegate( |
117 ScreenTrayItem* screen_tray) | 115 ScreenTrayItem* screen_tray) |
118 : screen_tray_(screen_tray) {} | 116 : screen_tray_(screen_tray) {} |
119 | 117 |
120 ScreenNotificationDelegate::~ScreenNotificationDelegate() {} | 118 ScreenNotificationDelegate::~ScreenNotificationDelegate() {} |
121 | 119 |
122 void ScreenNotificationDelegate::ButtonClick(int button_index) { | 120 void ScreenNotificationDelegate::ButtonClick(int button_index) { |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 | 186 |
189 void ScreenTrayItem::DestroyTrayView() { | 187 void ScreenTrayItem::DestroyTrayView() { |
190 tray_view_ = nullptr; | 188 tray_view_ = nullptr; |
191 } | 189 } |
192 | 190 |
193 void ScreenTrayItem::DestroyDefaultView() { | 191 void ScreenTrayItem::DestroyDefaultView() { |
194 default_view_ = nullptr; | 192 default_view_ = nullptr; |
195 } | 193 } |
196 | 194 |
197 } // namespace ash | 195 } // namespace ash |
OLD | NEW |