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

Side by Side Diff: ui/wm/core/transient_window_manager.cc

Issue 2474163003: Remove stl_util's deletion function use from ui/. (Closed)
Patch Set: braces Created 4 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « ui/events/ozone/evdev/touch_noise/touch_noise_finder.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/wm/core/transient_window_manager.h" 5 #include "ui/wm/core/transient_window_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <functional> 8 #include <functional>
9 9
10 #include "base/auto_reset.h" 10 #include "base/auto_reset.h"
11 #include "base/stl_util.h"
12 #include "ui/aura/client/transient_window_client_observer.h" 11 #include "ui/aura/client/transient_window_client_observer.h"
13 #include "ui/aura/window.h" 12 #include "ui/aura/window.h"
14 #include "ui/aura/window_property.h" 13 #include "ui/aura/window_property.h"
15 #include "ui/aura/window_tracker.h" 14 #include "ui/aura/window_tracker.h"
16 #include "ui/wm/core/transient_window_controller.h" 15 #include "ui/wm/core/transient_window_controller.h"
17 #include "ui/wm/core/transient_window_observer.h" 16 #include "ui/wm/core/transient_window_observer.h"
18 #include "ui/wm/core/transient_window_stacking_client.h" 17 #include "ui/wm/core/transient_window_stacking_client.h"
19 #include "ui/wm/core/window_util.h" 18 #include "ui/wm/core/window_util.h"
20 19
21 using aura::Window; 20 using aura::Window;
(...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 // RootWindow). 223 // RootWindow).
225 if (transient_parent_) { 224 if (transient_parent_) {
226 TransientWindowManager::Get(transient_parent_)->RemoveTransientChild( 225 TransientWindowManager::Get(transient_parent_)->RemoveTransientChild(
227 window_); 226 window_);
228 } 227 }
229 228
230 // Destroy transient children, only after we've removed ourselves from our 229 // Destroy transient children, only after we've removed ourselves from our
231 // parent, as destroying an active transient child may otherwise attempt to 230 // parent, as destroying an active transient child may otherwise attempt to
232 // refocus us. 231 // refocus us.
233 Windows transient_children(transient_children_); 232 Windows transient_children(transient_children_);
234 base::STLDeleteElements(&transient_children); 233 for (auto* child : transient_children)
234 delete child;
235 DCHECK(transient_children_.empty()); 235 DCHECK(transient_children_.empty());
236 } 236 }
237 237
238 } // namespace wm 238 } // namespace wm
OLDNEW
« no previous file with comments | « ui/events/ozone/evdev/touch_noise/touch_noise_finder.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698