mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-02 09:18:52 +00:00
AK: Make Vector use size_t for its size and capacity
This commit is contained in:
parent
9c6f7d3e7d
commit
ceec1a7d38
Notes:
sideshowbarker
2024-07-19 09:04:32 +09:00
Author: https://github.com/awesomekling
Commit: ceec1a7d38
94 changed files with 323 additions and 317 deletions
|
@ -143,7 +143,7 @@ void LayoutBlock::layout_inline_children()
|
|||
|
||||
float justified_space_width = whitespace_count ? (excess_horizontal_space_including_whitespace / (float)whitespace_count) : 0;
|
||||
|
||||
for (int i = 0; i < line_box.fragments().size(); ++i) {
|
||||
for (size_t i = 0; i < line_box.fragments().size(); ++i) {
|
||||
auto& fragment = line_box.fragments()[i];
|
||||
// Vertically align everyone's bottom to the line.
|
||||
// FIXME: Support other kinds of vertical alignment.
|
||||
|
@ -156,7 +156,7 @@ void LayoutBlock::layout_inline_children()
|
|||
float diff = justified_space_width - fragment.rect().width();
|
||||
fragment.rect().set_width(justified_space_width);
|
||||
// Shift subsequent sibling fragments to the right to adjust for change in width.
|
||||
for (int j = i + 1; j < line_box.fragments().size(); ++j) {
|
||||
for (size_t j = i + 1; j < line_box.fragments().size(); ++j) {
|
||||
line_box.fragments()[j].rect().move_by(diff, 0);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue