OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium 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 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #include <limits.h> | 7 #include <limits.h> |
8 | 8 |
9 #include "core/fxcrt/include/fx_coordinates.h" | 9 #include "core/fxcrt/fx_coordinates.h" |
10 #include "core/fxcrt/include/fx_ext.h" | 10 #include "core/fxcrt/fx_ext.h" |
11 | 11 |
12 void FX_RECT::Normalize() { | 12 void FX_RECT::Normalize() { |
13 if (left > right) { | 13 if (left > right) { |
14 int temp = left; | 14 int temp = left; |
15 left = right; | 15 left = right; |
16 right = temp; | 16 right = temp; |
17 } | 17 } |
18 if (top > bottom) { | 18 if (top > bottom) { |
19 int temp = top; | 19 int temp = top; |
20 top = bottom; | 20 top = bottom; |
(...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
508 left = x[i]; | 508 left = x[i]; |
509 } | 509 } |
510 if (top < y[i]) { | 510 if (top < y[i]) { |
511 top = y[i]; | 511 top = y[i]; |
512 } | 512 } |
513 if (bottom > y[i]) { | 513 if (bottom > y[i]) { |
514 bottom = y[i]; | 514 bottom = y[i]; |
515 } | 515 } |
516 } | 516 } |
517 } | 517 } |
OLD | NEW |