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

Unified Diff: third_party/WebKit/Source/core/layout/ng/ng_min_max_content_size.h

Issue 2721613003: [LayoutNG] Move remaining ng_units structs to their own files (Closed)
Patch Set: Rebase w/HEAD Created 3 years, 10 months 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
Index: third_party/WebKit/Source/core/layout/ng/ng_min_max_content_size.h
diff --git a/third_party/WebKit/Source/core/layout/ng/ng_min_max_content_size.h b/third_party/WebKit/Source/core/layout/ng/ng_min_max_content_size.h
new file mode 100644
index 0000000000000000000000000000000000000000..ec617f189bd03df31560bb5cededd0e57b08b5d6
--- /dev/null
+++ b/third_party/WebKit/Source/core/layout/ng/ng_min_max_content_size.h
@@ -0,0 +1,28 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef NGUnits_h
+#define NGUnits_h
+
+#include "core/CoreExport.h"
+#include "core/layout/ng/ng_writing_mode.h"
+#include "platform/LayoutUnit.h"
+
+namespace blink {
+
+struct CORE_EXPORT MinAndMaxContentSizes {
mstensho (USE GERRIT) 2017/02/28 12:19:47 Should this be named NGMinMaxContentSize, to match
eae 2017/02/28 12:26:34 Yes! :) I'll rename one of them.
+ LayoutUnit min_content;
+ LayoutUnit max_content;
+ LayoutUnit ShrinkToFit(LayoutUnit available_size) const;
+ bool operator==(const MinAndMaxContentSizes& other) const;
+};
+
+inline std::ostream& operator<<(std::ostream& stream,
+ const MinAndMaxContentSizes& value) {
+ return stream << "(" << value.min_content << ", " << value.max_content << ")";
+}
+
+} // namespace blink
+
+#endif // NGUnits_h

Powered by Google App Engine
This is Rietveld 408576698