Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(454)

Side by Side Diff: ash/touch/touch_transformer_controller.h

Issue 1130983005: ash: Refactor of TouchTransformerController (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address review feedback Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | ash/touch/touch_transformer_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef ASH_TOUCH_TOUCH_TRANSFORMER_CONTROLLER_H_ 5 #ifndef ASH_TOUCH_TOUCH_TRANSFORMER_CONTROLLER_H_
6 #define ASH_TOUCH_TOUCH_TRANSFORMER_CONTROLLER_H_ 6 #define ASH_TOUCH_TOUCH_TRANSFORMER_CONTROLLER_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ash/display/display_controller.h" 9 #include "ash/display/display_controller.h"
10 #include "ui/gfx/transform.h" 10 #include "ui/gfx/transform.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 const ui::TouchscreenDevice& touchscreen, 54 const ui::TouchscreenDevice& touchscreen,
55 const gfx::Size& framebuffer_size) const; 55 const gfx::Size& framebuffer_size) const;
56 56
57 // Returns the scaling factor for the touch radius such that it scales the 57 // Returns the scaling factor for the touch radius such that it scales the
58 // radius from |touch_device|'s coordinate system to the |touch_display|'s 58 // radius from |touch_device|'s coordinate system to the |touch_display|'s
59 // coordinate system. 59 // coordinate system.
60 double GetTouchResolutionScale( 60 double GetTouchResolutionScale(
61 const DisplayInfo& touch_display, 61 const DisplayInfo& touch_display,
62 const ui::TouchscreenDevice& touch_device) const; 62 const ui::TouchscreenDevice& touch_device) const;
63 63
64 // For the provided |display| update the touch radius mapping.
65 void UpdateTouchRadius(const DisplayInfo& display) const;
66
67 // For a given |target_display| and |target_display_id| update the touch
68 // transformation based on the touchscreen associated with |touch_display|.
69 // |target_display_id| is the display id whose root window will receive the
70 // touch events.
71 // |touch_display| is the physical display that has the touchscreen
72 // from which the events arrive.
73 // |target_display| provides the dimensions to which the touch event will be
74 // transformed.
75 void UpdateTouchTransform(int64_t target_display_id,
76 const DisplayInfo& touch_display,
77 const DisplayInfo& target_display) const;
78
64 DISALLOW_COPY_AND_ASSIGN(TouchTransformerController); 79 DISALLOW_COPY_AND_ASSIGN(TouchTransformerController);
65 }; 80 };
66 81
67 } // namespace ash 82 } // namespace ash
68 83
69 #endif // ASH_TOUCH_TOUCH_TRANSFORMER_CONTROLLER_H_ 84 #endif // ASH_TOUCH_TOUCH_TRANSFORMER_CONTROLLER_H_
OLDNEW
« no previous file with comments | « no previous file | ash/touch/touch_transformer_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698