Flutter Engine
 
Loading...
Searching...
No Matches
rect_helper.h
Go to the documentation of this file.
1// Copyright 2013 The Flutter 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 "Windows.h"
6
7#ifndef FLUTTER_SHELL_PLATFORM_WINDOWS_RECT_HELPER_H_
8#define FLUTTER_SHELL_PLATFORM_WINDOWS_RECT_HELPER_H_
9
10namespace flutter {
11LONG RectWidth(const RECT& r) {
12 return r.right - r.left;
13}
14
15LONG RectHeight(const RECT& r) {
16 return r.bottom - r.top;
17}
18
19bool AreRectsEqual(const RECT& a, const RECT& b) {
20 return a.left == b.left && a.top == b.top && a.right == b.right &&
21 a.bottom == b.bottom;
22}
23} // namespace flutter
24
25#endif // FLUTTER_SHELL_PLATFORM_WINDOWS_RECT_HELPER_H_
LONG RectWidth(const RECT &r)
Definition rect_helper.h:11
bool AreRectsEqual(const RECT &a, const RECT &b)
Definition rect_helper.h:19
LONG RectHeight(const RECT &r)
Definition rect_helper.h:15
long LONG