Chromium Code Reviews| Index: ui/gfx/size.h |
| diff --git a/ui/gfx/size.h b/ui/gfx/size.h |
| index 2d01eeea5004f53893d214c3c3915b113ad84050..16f7e3e1aabd9174e0dc1735b33eef45b5c4f9dc 100644 |
| --- a/ui/gfx/size.h |
| +++ b/ui/gfx/size.h |
| @@ -10,6 +10,7 @@ |
| #include "build/build_config.h" |
| #include "ui/base/ui_export.h" |
| #include "ui/gfx/size_base.h" |
| +#include "ui/gfx/size_f.h" |
| #if defined(OS_WIN) |
| typedef struct tagSIZE SIZE; |
| @@ -43,6 +44,10 @@ class UI_EXPORT Size : public SizeBase<Size, int> { |
| #endif |
| std::string ToString() const; |
| + |
| + operator SizeF() const { |
|
sky
2012/10/01 21:02:20
Why is this better than ToSizeF?
|
| + return SizeF(width(), height()); |
| + } |
| }; |
| #if !defined(COMPILER_MSVC) |