Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(524)

Unified Diff: ui/gfx/size_f.cc

Issue 11359194: Revert 167255 - ui: Remove gfx::Size::ClampToNonNegative, prevent negative sizes always. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gfx/size_base_impl.h ('k') | ui/gfx/size_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/size_f.cc
===================================================================
--- ui/gfx/size_f.cc (revision 167502)
+++ ui/gfx/size_f.cc (working copy)
@@ -4,8 +4,8 @@
#include "ui/gfx/size_f.h"
+#include "base/logging.h"
#include "base/stringprintf.h"
-#include "ui/gfx/size_base_impl.h"
namespace gfx {
@@ -13,8 +13,9 @@
SizeF::SizeF() : SizeBase<SizeF, float>(0, 0) {}
-SizeF::SizeF(float width, float height)
- : SizeBase<SizeF, float>(width, height) {
+SizeF::SizeF(float width, float height) : SizeBase<SizeF, float>(0, 0) {
+ set_width(width);
+ set_height(height);
}
SizeF::~SizeF() {}
« no previous file with comments | « ui/gfx/size_base_impl.h ('k') | ui/gfx/size_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698