diff options
author | 杨宇千 <crupest@outlook.com> | 2018-11-13 22:44:07 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-13 22:44:07 +0800 |
commit | b08ba6c83902d140fb14131b3f01837985d39c17 (patch) | |
tree | 98719593d5854f2162ea8d87b7fecdc3472968bc /src/ui/convert_util.hpp | |
parent | 91dda866a0919f9e6cfb5e7857ac0466572d96d8 (diff) | |
parent | 6d0a44597eb6e35993b46642ebf85abd94bca2d7 (diff) | |
download | cru-b08ba6c83902d140fb14131b3f01837985d39c17.tar.gz cru-b08ba6c83902d140fb14131b3f01837985d39c17.tar.bz2 cru-b08ba6c83902d140fb14131b3f01837985d39c17.zip |
Merge pull request #18 from crupest/bound
Add support for enhanced bound check.
Diffstat (limited to 'src/ui/convert_util.hpp')
-rw-r--r-- | src/ui/convert_util.hpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/ui/convert_util.hpp b/src/ui/convert_util.hpp index 1c18f59b..6deb7fff 100644 --- a/src/ui/convert_util.hpp +++ b/src/ui/convert_util.hpp @@ -6,6 +6,11 @@ namespace cru::ui { + inline D2D1_POINT_2F Convert(const Point& point) + { + return D2D1::Point2F(point.x, point.y); + } + inline D2D1_RECT_F Convert(const Rect& rect) { return D2D1::RectF(rect.left, rect.top, rect.left + rect.width, rect.top + rect.height); |