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 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
116 if (visible() == child->visible()) | 116 if (visible() == child->visible()) |
117 return; | 117 return; |
118 SetVisible(child->visible()); | 118 SetVisible(child->visible()); |
119 PreferredSizeChanged(); | 119 PreferredSizeChanged(); |
120 } | 120 } |
121 | 121 |
122 virtual void ChildPreferredSizeChanged(View* child) OVERRIDE { | 122 virtual void ChildPreferredSizeChanged(View* child) OVERRIDE { |
123 PreferredSizeChanged(); | 123 PreferredSizeChanged(); |
124 } | 124 } |
125 | 125 |
126 virtual void OnMouseEntered(const views::MouseEvent& event) OVERRIDE { | 126 virtual void OnMouseEntered(const ui::MouseEvent& event) OVERRIDE { |
127 hover_ = true; | 127 hover_ = true; |
128 SchedulePaint(); | 128 SchedulePaint(); |
129 } | 129 } |
130 | 130 |
131 virtual void OnMouseExited(const views::MouseEvent& event) OVERRIDE { | 131 virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE { |
132 hover_ = false; | 132 hover_ = false; |
133 SchedulePaint(); | 133 SchedulePaint(); |
134 } | 134 } |
135 | 135 |
136 virtual void OnPaintBackground(gfx::Canvas* canvas) OVERRIDE { | 136 virtual void OnPaintBackground(gfx::Canvas* canvas) OVERRIDE { |
137 if (child_count() == 0) | 137 if (child_count() == 0) |
138 return; | 138 return; |
139 | 139 |
140 views::View* view = child_at(0); | 140 views::View* view = child_at(0); |
141 if (!view->background()) { | 141 if (!view->background()) { |
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
410 } | 410 } |
411 | 411 |
412 void SystemTrayBubble::OnWidgetClosing(views::Widget* widget) { | 412 void SystemTrayBubble::OnWidgetClosing(views::Widget* widget) { |
413 CHECK_EQ(bubble_widget_, widget); | 413 CHECK_EQ(bubble_widget_, widget); |
414 bubble_widget_ = NULL; | 414 bubble_widget_ = NULL; |
415 tray_->RemoveBubble(this); | 415 tray_->RemoveBubble(this); |
416 } | 416 } |
417 | 417 |
418 } // namespace internal | 418 } // namespace internal |
419 } // namespace ash | 419 } // namespace ash |
OLD | NEW |