forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdisplay_transform.h
30 lines (22 loc) · 876 Bytes
/
display_transform.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
// Copyright 2019 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef UI_DISPLAY_DISPLAY_TRANSFORM_H_
#define UI_DISPLAY_DISPLAY_TRANSFORM_H_
#include "ui/display/display.h"
#include "ui/display/display_export.h"
#include "ui/gfx/overlay_transform.h"
namespace gfx {
class SizeF;
class Transform;
} // namespace gfx
namespace display {
// Creates an exact gfx::Transform for a rotation.
DISPLAY_EXPORT gfx::Transform CreateRotationTransform(
display::Display::Rotation rotation,
const gfx::SizeF& size_to_rotate);
// Maps display::Display::Rotation to gfx::OverlayTransform.
DISPLAY_EXPORT gfx::OverlayTransform DisplayRotationToOverlayTransform(
display::Display::Rotation rotation);
} // namespace display
#endif // UI_DISPLAY_DISPLAY_TRANSFORM_H_