| Index: ui/gfx/display_layout_builder.cc
|
| diff --git a/ui/gfx/display_layout_builder.cc b/ui/gfx/display_layout_builder.cc
|
| index a29fe7c809dd427abcfb02a02f343b3d8868a536..7f7fb7727f6fbce0084b97e6252a94a2ef986399 100644
|
| --- a/ui/gfx/display_layout_builder.cc
|
| +++ b/ui/gfx/display_layout_builder.cc
|
| @@ -37,12 +37,19 @@ DisplayLayoutBuilder& DisplayLayoutBuilder::AddDisplayPlacement(
|
| int64_t parent_display_id,
|
| DisplayPlacement::Position position,
|
| int offset) {
|
| - scoped_ptr<DisplayPlacement> placement(new DisplayPlacement);
|
| - placement->position = position;
|
| - placement->offset = offset;
|
| - placement->display_id = display_id;
|
| - placement->parent_display_id = parent_display_id;
|
| - layout_->placement_list.push_back(std::move(placement));
|
| + DisplayPlacement placement;
|
| + placement.position = position;
|
| + placement.offset = offset;
|
| + placement.display_id = display_id;
|
| + placement.parent_display_id = parent_display_id;
|
| + AddDisplayPlacement(placement);
|
| + return *this;
|
| +}
|
| +
|
| +DisplayLayoutBuilder& DisplayLayoutBuilder::AddDisplayPlacement(
|
| + const DisplayPlacement& placement) {
|
| + layout_->placement_list.push_back(
|
| + make_scoped_ptr(new DisplayPlacement(placement)));
|
| return *this;
|
| }
|
|
|
|
|