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
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_VIEW_MANAGER_VIEW_COORDINATE_CONVERSIONS_H_
6 #define COMPONENTS_VIEW_MANAGER_VIEW_COORDINATE_CONVERSIONS_H_
14 namespace view_manager
{
18 // Converts |point| from the coordinates of |from| to the coordinates of |to|.
19 // |from| and |to| must be an ancestors or descendants of each other.
20 gfx::Point
ConvertPointBetweenViews(const ServerView
* from
,
22 const gfx::Point
& point
);
23 gfx::PointF
ConvertPointFBetweenViews(const ServerView
* from
,
25 const gfx::PointF
& point
);
27 // Converts |rect| from the coordinates of |from| to the coordinates of |to|.
28 // |from| and |to| must be an ancestors or descendants of each other.
29 gfx::Rect
ConvertRectBetweenViews(const ServerView
* from
,
31 const gfx::Rect
& rect
);
33 } // namespace view_manager
35 #endif // COMPONENTS_VIEW_MANAGER_VIEW_COORDINATE_CONVERSIONS_H_