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

Side by Side Diff: ui/aura/client/transient_window_client_observer.h

Issue 2517853002: Fixes bug in handling restacking because of transients (Closed)
Patch Set: feedback Created 4 years 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef UI_AURA_CLIENT_TRANSIENT_WINDOW_CLIENT_OBSERVER_H_ 5 #ifndef UI_AURA_CLIENT_TRANSIENT_WINDOW_CLIENT_OBSERVER_H_
6 #define UI_AURA_CLIENT_TRANSIENT_WINDOW_CLIENT_OBSERVER_H_ 6 #define UI_AURA_CLIENT_TRANSIENT_WINDOW_CLIENT_OBSERVER_H_
7 7
8 #include "ui/aura/aura_export.h" 8 #include "ui/aura/aura_export.h"
9 9
10 namespace aura { 10 namespace aura {
11 11
12 class Window; 12 class Window;
13 13
14 namespace client { 14 namespace client {
15 15
16 class AURA_EXPORT TransientWindowClientObserver { 16 class AURA_EXPORT TransientWindowClientObserver {
17 public: 17 public:
18 // Called when a window is added as a transient child. This is called once 18 // Called when a window is added as a transient child. This is called once
19 // the child is added as a transient, but before any restacking occurs. 19 // the child is added as a transient, but before any restacking occurs.
20 virtual void OnTransientChildWindowAdded(Window* parent, 20 virtual void OnTransientChildWindowAdded(Window* parent,
21 Window* transient_child) = 0; 21 Window* transient_child) = 0;
22 22
23 // Called when a window is removed as a transient child. This is called once 23 // Called when a window is removed as a transient child. This is called once
24 // the child is removed as a transient, but before any restacking occurs. 24 // the child is removed as a transient, but before any restacking occurs.
25 virtual void OnTransientChildWindowRemoved(Window* parent, 25 virtual void OnTransientChildWindowRemoved(Window* parent,
26 Window* transient_child) = 0; 26 Window* transient_child) = 0;
27 27
28 // Called when adding or removing a transient results in restacking.
29 // |transient_child| is the window being stacked above |parent|. |parent| is
30 // the window the transient was added or removed from. This is followed by a
31 // call to Window::StackChildAbove() and then
32 // OnDidRestackTransientChildAbove().
33 virtual void OnWillRestackTransientChildAbove(Window* parent,
msw 2016/11/21 22:34:49 optional nit: rename 'stack'->'order' throughout.
sky 2016/11/21 22:41:10 I left this as stack. It better fits with the Stac
34 Window* transient_child) = 0;
35 virtual void OnDidRestackTransientChildAbove(Window* parent,
36 Window* transient_child) = 0;
37
28 protected: 38 protected:
29 virtual ~TransientWindowClientObserver() {} 39 virtual ~TransientWindowClientObserver() {}
30 }; 40 };
31 41
32 } // namespace client 42 } // namespace client
33 } // namespace aura 43 } // namespace aura
34 44
35 #endif // UI_AURA_CLIENT_TRANSIENT_WINDOW_CLIENT_OBSERVER_H_ 45 #endif // UI_AURA_CLIENT_TRANSIENT_WINDOW_CLIENT_OBSERVER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698