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/network/tray_network.h" | 5 #include "ash/system/network/tray_network.h" |
6 | 6 |
7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
8 #include "ash/shell_window_ids.h" | 8 #include "ash/shell_window_ids.h" |
9 #include "ash/system/tray/system_tray.h" | 9 #include "ash/system/tray/system_tray.h" |
10 #include "ash/system/tray/system_tray_delegate.h" | 10 #include "ash/system/tray/system_tray_delegate.h" |
(...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
461 } | 461 } |
462 | 462 |
463 // Overridden from ViewClickListener. | 463 // Overridden from ViewClickListener. |
464 virtual void ClickedOn(views::View* sender) OVERRIDE { | 464 virtual void ClickedOn(views::View* sender) OVERRIDE { |
465 ash::SystemTrayDelegate* delegate = | 465 ash::SystemTrayDelegate* delegate = |
466 ash::Shell::GetInstance()->tray_delegate(); | 466 ash::Shell::GetInstance()->tray_delegate(); |
467 // If the info bubble was visible, close it when some other item is clicked | 467 // If the info bubble was visible, close it when some other item is clicked |
468 // on. | 468 // on. |
469 ResetInfoBubble(); | 469 ResetInfoBubble(); |
470 | 470 |
471 if (sender == footer()->content()) | 471 if (sender == footer()->content()) { |
472 Shell::GetInstance()->tray()->ShowDefaultView(BUBBLE_USE_EXISTING); | 472 Shell::GetInstance()->tray()->ShowDefaultView(BUBBLE_USE_EXISTING); |
| 473 return; |
| 474 } |
473 | 475 |
474 if (login_ == user::LOGGED_IN_LOCKED) | 476 if (login_ == user::LOGGED_IN_LOCKED) |
475 return; | 477 return; |
476 | 478 |
477 if (sender == view_mobile_account_) { | 479 if (sender == view_mobile_account_) { |
478 delegate->ShowCellularURL(topup_url_); | 480 delegate->ShowCellularURL(topup_url_); |
479 } else if (sender == setup_mobile_account_) { | 481 } else if (sender == setup_mobile_account_) { |
480 delegate->ShowCellularURL(setup_url_); | 482 delegate->ShowCellularURL(setup_url_); |
481 } else if (sender == airplane_) { | 483 } else if (sender == airplane_) { |
482 delegate->ToggleAirplaneMode(); | 484 delegate->ToggleAirplaneMode(); |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
560 if (tray_) | 562 if (tray_) |
561 tray_->Update(info); | 563 tray_->Update(info); |
562 if (default_) | 564 if (default_) |
563 default_->Update(); | 565 default_->Update(); |
564 if (detailed_) | 566 if (detailed_) |
565 detailed_->Update(); | 567 detailed_->Update(); |
566 } | 568 } |
567 | 569 |
568 } // namespace internal | 570 } // namespace internal |
569 } // namespace ash | 571 } // namespace ash |
OLD | NEW |