| 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/system_tray_bubble.h" | 5 #include "ash/system/tray/system_tray_bubble.h" |
| 6 | 6 |
| 7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
| 8 #include "ash/system/tray/system_tray.h" | 8 #include "ash/system/tray/system_tray.h" |
| 9 #include "ash/system/tray/system_tray_delegate.h" | 9 #include "ash/system/tray/system_tray_delegate.h" |
| 10 #include "ash/system/tray/system_tray_item.h" | 10 #include "ash/system/tray/system_tray_item.h" |
| (...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 312 InitializeAndShowBubble(bubble_widget_, bubble_view_, tray_); | 312 InitializeAndShowBubble(bubble_widget_, bubble_view_, tray_); |
| 313 } | 313 } |
| 314 | 314 |
| 315 void SystemTrayBubble::BubbleViewDestroyed() { | 315 void SystemTrayBubble::BubbleViewDestroyed() { |
| 316 DestroyItemViews(); | 316 DestroyItemViews(); |
| 317 bubble_view_ = NULL; | 317 bubble_view_ = NULL; |
| 318 } | 318 } |
| 319 | 319 |
| 320 void SystemTrayBubble::OnMouseEnteredView() { | 320 void SystemTrayBubble::OnMouseEnteredView() { |
| 321 StopAutoCloseTimer(); | 321 StopAutoCloseTimer(); |
| 322 tray_->UpdateShouldShowLauncher(); | |
| 323 } | 322 } |
| 324 | 323 |
| 325 void SystemTrayBubble::OnMouseExitedView() { | 324 void SystemTrayBubble::OnMouseExitedView() { |
| 326 RestartAutoCloseTimer(); | 325 RestartAutoCloseTimer(); |
| 327 tray_->UpdateShouldShowLauncher(); | |
| 328 } | 326 } |
| 329 | 327 |
| 330 void SystemTrayBubble::OnClickedOutsideView() { | 328 void SystemTrayBubble::OnClickedOutsideView() { |
| 331 if (bubble_type_ != BUBBLE_TYPE_NOTIFICATION) | 329 if (bubble_type_ != BUBBLE_TYPE_NOTIFICATION) |
| 332 bubble_widget_->Close(); | 330 bubble_widget_->Close(); |
| 333 } | 331 } |
| 334 | 332 |
| 335 string16 SystemTrayBubble::GetAccessibleName() { | 333 string16 SystemTrayBubble::GetAccessibleName() { |
| 336 return tray_->GetAccessibleName(); | 334 return tray_->GetAccessibleName(); |
| 337 } | 335 } |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 415 } | 413 } |
| 416 | 414 |
| 417 void SystemTrayBubble::OnWidgetClosing(views::Widget* widget) { | 415 void SystemTrayBubble::OnWidgetClosing(views::Widget* widget) { |
| 418 CHECK_EQ(bubble_widget_, widget); | 416 CHECK_EQ(bubble_widget_, widget); |
| 419 bubble_widget_ = NULL; | 417 bubble_widget_ = NULL; |
| 420 tray_->RemoveBubble(this); | 418 tray_->RemoveBubble(this); |
| 421 } | 419 } |
| 422 | 420 |
| 423 } // namespace internal | 421 } // namespace internal |
| 424 } // namespace ash | 422 } // namespace ash |
| OLD | NEW |