|
Implicit coversion operators from integer geometry types to floating point.
This change allows you to call a function that expects a floating point
object with an integer object and have things just work. The addition
operator for Points is outside the Point classes so it can add/subtract integer
and float points together implicitly.
Tested to verify compilation with:
ui_unittests:RectTest.ToRectF
ui_unittests:SizeTest.ToSizeF
ui_unittests:PointTest.ToPointF
BUG= 147395
R=sky@chromium.org
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=161415
Total comments: 2
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+169 lines, -79 lines) |
Patch |
 |
M |
chrome/browser/notifications/balloon_collection_impl.cc
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
content/renderer/paint_aggregator.cc
|
View
|
1
2
|
1 chunk |
+1 line, -2 lines |
0 comments
|
Download
|
 |
M |
ui/base/win/hwnd_util.cc
|
View
|
1
2
3
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
ui/gfx/point.h
|
View
|
1
|
2 chunks |
+9 lines, -1 line |
0 comments
|
Download
|
 |
M |
ui/gfx/point_base.h
|
View
|
1
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
 |
M |
ui/gfx/point_f.h
|
View
|
1
|
1 chunk |
+8 lines, -0 lines |
0 comments
|
Download
|
 |
A |
ui/gfx/point_unittest.cc
|
View
|
1
|
1 chunk |
+31 lines, -0 lines |
0 comments
|
Download
|
 |
M |
ui/gfx/rect.h
|
View
|
1
|
2 chunks |
+11 lines, -2 lines |
0 comments
|
Download
|
 |
M |
ui/gfx/rect_base.h
|
View
|
1
|
2 chunks |
+0 lines, -11 lines |
0 comments
|
Download
|
 |
M |
ui/gfx/rect_base_impl.h
|
View
|
1
|
1 chunk |
+0 lines, -10 lines |
0 comments
|
Download
|
 |
M |
ui/gfx/rect_f.h
|
View
|
1
|
1 chunk |
+8 lines, -0 lines |
0 comments
|
Download
|
 |
M |
ui/gfx/rect_unittest.cc
|
View
|
1
|
4 chunks |
+47 lines, -32 lines |
0 comments
|
Download
|
 |
M |
ui/gfx/size.h
|
View
|
1
|
2 chunks |
+9 lines, -1 line |
0 comments
|
Download
|
 |
M |
ui/gfx/size_base.h
|
View
|
1
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
 |
M |
ui/gfx/size_f.h
|
View
|
1
|
1 chunk |
+8 lines, -0 lines |
0 comments
|
Download
|
 |
A |
ui/gfx/size_unittest.cc
|
View
|
1
|
1 chunk |
+31 lines, -0 lines |
0 comments
|
Download
|
 |
M |
ui/ui_unittests.gypi
|
View
|
1
2
3
4
5
6
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
 |
M |
webkit/plugins/ppapi/ppb_graphics_2d_impl_unittest.cc
|
View
|
1
2
3
4
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
webkit/plugins/webview_plugin.cc
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
Total messages: 20 (0 generated)
|