summaryrefslogtreecommitdiffstats
path: root/ash/touch/touch_observer_hud.cc
diff options
context:
space:
mode:
Diffstat (limited to 'ash/touch/touch_observer_hud.cc')
-rw-r--r--ash/touch/touch_observer_hud.cc14
1 files changed, 8 insertions, 6 deletions
diff --git a/ash/touch/touch_observer_hud.cc b/ash/touch/touch_observer_hud.cc
index 87d6d4e..f3f0b35 100644
--- a/ash/touch/touch_observer_hud.cc
+++ b/ash/touch/touch_observer_hud.cc
@@ -86,12 +86,6 @@ void TouchObserverHUD::OnWidgetDestroying(views::Widget* widget) {
delete this;
}
-void TouchObserverHUD::OnDisplayBoundsChanged(const gfx::Display& display) {
- if (display.id() != display_id_)
- return;
- widget_->SetSize(display.size());
-}
-
void TouchObserverHUD::OnDisplayAdded(const gfx::Display& new_display) {}
void TouchObserverHUD::OnDisplayRemoved(const gfx::Display& old_display) {
@@ -100,6 +94,14 @@ void TouchObserverHUD::OnDisplayRemoved(const gfx::Display& old_display) {
widget_->CloseNow();
}
+void TouchObserverHUD::OnDisplayMetricsChanged(const gfx::Display& display,
+ uint32_t metrics) {
+ if (display.id() != display_id_ || !(metrics & DISPLAY_METRIC_BOUNDS))
+ return;
+
+ widget_->SetSize(display.size());
+}
+
#if defined(OS_CHROMEOS)
void TouchObserverHUD::OnDisplayModeChanged(
const ui::DisplayConfigurator::DisplayStateList& outputs) {