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/common/system/tray/system_tray_bubble.h" | 5 #include "ash/common/system/tray/system_tray_bubble.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ash/common/material_design/material_design_controller.h" | 10 #include "ash/common/material_design/material_design_controller.h" |
(...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
343 } | 343 } |
344 } | 344 } |
345 | 345 |
346 if (!MaterialDesignController::IsSystemTrayMenuMaterial()) { | 346 if (!MaterialDesignController::IsSystemTrayMenuMaterial()) { |
347 // For default view, draw bottom border for each item, except the last | 347 // For default view, draw bottom border for each item, except the last |
348 // 2 items, which are the bottom header row and the one just above it. | 348 // 2 items, which are the bottom header row and the one just above it. |
349 if (is_default_bubble) { | 349 if (is_default_bubble) { |
350 const int last_item_with_border = | 350 const int last_item_with_border = |
351 static_cast<int>(item_containers.size()) - 2; | 351 static_cast<int>(item_containers.size()) - 2; |
352 for (int i = 0; i < last_item_with_border; ++i) { | 352 for (int i = 0; i < last_item_with_border; ++i) { |
353 item_containers.at(i)->SetBorder(views::Border::CreateSolidSidedBorder( | 353 item_containers.at(i)->SetBorder( |
354 0, 0, 1, 0, kBorderLightColor)); | 354 views::CreateSolidSidedBorder(0, 0, 1, 0, kBorderLightColor)); |
355 } | 355 } |
356 } | 356 } |
357 } | 357 } |
358 | 358 |
359 if (focus_view) { | 359 if (focus_view) { |
360 tray_->ActivateBubble(); | 360 tray_->ActivateBubble(); |
361 focus_view->RequestFocus(); | 361 focus_view->RequestFocus(); |
362 } | 362 } |
363 } | 363 } |
364 | 364 |
365 } // namespace ash | 365 } // namespace ash |
OLD | NEW |