blob: 3681476873383baa5ee5875eb6f281f02629bf3a [file] [log] [blame]
kylechar55f0eaf22017-01-11 22:57:371// Copyright 2017 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "ash/touch/ash_touch_transform_controller.h"
6
7#include "ash/shell.h"
8#include "ui/display/manager/display_manager.h"
9
10namespace ash {
11
12AshTouchTransformController::AshTouchTransformController(
13 display::DisplayConfigurator* display_configurator,
14 display::DisplayManager* display_manager)
15 : TouchTransformController(display_configurator, display_manager) {
skycb4be5b2017-04-06 17:52:4516 Shell::Get()->window_tree_host_manager()->AddObserver(this);
kylechar55f0eaf22017-01-11 22:57:3717}
18
19AshTouchTransformController::~AshTouchTransformController() {
skycb4be5b2017-04-06 17:52:4520 Shell::Get()->window_tree_host_manager()->RemoveObserver(this);
kylechar55f0eaf22017-01-11 22:57:3721}
22
23void AshTouchTransformController::OnDisplaysInitialized() {
24 UpdateTouchTransforms();
25}
26
27void AshTouchTransformController::OnDisplayConfigurationChanged() {
28 UpdateTouchTransforms();
29}
30
31} // namespace ash