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

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

Issue 2872593003: [LayoutNG] Introduce NGPositionedFloat. (Closed)
Patch Set: small fixes Created 3 years, 7 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_floats_utils.h
diff --git a/third_party/WebKit/Source/core/layout/ng/ng_floats_utils.h b/third_party/WebKit/Source/core/layout/ng/ng_floats_utils.h
index 449b6c56915a51e996d891f51193fe5233c862e5..5342ba6551c17f63efe9bbefd2ebaa95b6a6b4c9 100644
--- a/third_party/WebKit/Source/core/layout/ng/ng_floats_utils.h
+++ b/third_party/WebKit/Source/core/layout/ng/ng_floats_utils.h
@@ -9,19 +9,22 @@
#include "core/layout/ng/ng_constraint_space.h"
#include "core/layout/ng/ng_floating_object.h"
#include "core/layout/ng/ng_fragment_builder.h"
+#include "core/layout/ng/ng_positioned_float.h"
namespace blink {
// Positions {@code floating_object} into {@code new_parent_space}.
-// @returns Logical offset of the positioned float.
-CORE_EXPORT NGLogicalOffset PositionFloat(NGFloatingObject*,
- NGConstraintSpace* new_parent_space);
+// @returns A positioned float.
+CORE_EXPORT NGPositionedFloat
+PositionFloat(NGFloatingObject*, NGConstraintSpace* new_parent_space);
-// Positions the list of floats by updating their {@code logical_offset}.
-void PositionFloats(LayoutUnit origin_block_offset,
- LayoutUnit from_block_offset,
- const Vector<RefPtr<NGFloatingObject>>&,
- NGConstraintSpace*);
+// Positions the a list of floats. Adds them as exclusions to {@code space} and
+// if given appends them to {@code positioned_floats}.
+CORE_EXPORT void PositionFloats(LayoutUnit origin_block_offset,
+ LayoutUnit from_block_offset,
+ const Vector<RefPtr<NGFloatingObject>>&,
+ Vector<NGPositionedFloat>* positioned_floats,
Gleb Lanbin 2017/05/08 19:03:38 please change the API to return the positioned_flo
ikilpatrick 2017/05/08 19:18:19 Done.
+ NGConstraintSpace* space);
} // namespace blink
#endif // NGFloatsUtils_h

Powered by Google App Engine
This is Rietveld 408576698