Modernize to C++11: Use for-range loop.

This commit is contained in:
Haojian Wu 2016-07-10 13:32:40 +02:00
parent 3bdeac98bf
commit 55b3f1936f
17 changed files with 66 additions and 71 deletions

View file

@ -132,10 +132,10 @@ void AtomRenderViewObserver::DraggableRegionsChanged(blink::WebFrame* frame) {
blink::WebVector<blink::WebDraggableRegion> webregions =
frame->document().draggableRegions();
std::vector<DraggableRegion> regions;
for (size_t i = 0; i < webregions.size(); ++i) {
for (auto& webregion : webregions) {
DraggableRegion region;
region.bounds = webregions[i].bounds;
region.draggable = webregions[i].draggable;
region.bounds = webregion.bounds;
region.draggable = webregion.draggable;
regions.push_back(region);
}
Send(new AtomViewHostMsg_UpdateDraggableRegions(routing_id(), regions));