Roll src/third_party/WebKit d9c6159:8139f33 (svn 201974:201975)
[chromium-blink-merge.git] / ui / aura / client / capture_delegate.h
blob7ebcaee5b7eecbf53774da09daa6b850c7bc64c1
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef UI_AURA_CLIENT_CAPTURE_DELEGATE_H_
6 #define UI_AURA_CLIENT_CAPTURE_DELEGATE_H_
8 #include "ui/aura/aura_export.h"
10 namespace aura {
11 class Window;
12 namespace client {
14 // This interface provides API to change the root Window's capture state without
15 // exposing them as RootWindow API.
16 class AURA_EXPORT CaptureDelegate {
17 public:
18 // Called when a capture is set on |new_capture| and/or a capture is
19 // released on |old_capture|.
20 // NOTE: |old_capture| and |new_capture| are not necessarily contained in the
21 // window hierarchy of the delegate.
22 virtual void UpdateCapture(aura::Window* old_capture,
23 aura::Window* new_capture) = 0;
25 // Called when another root gets capture.
26 virtual void OnOtherRootGotCapture() = 0;
28 // Sets/Release a native capture on host windows.
29 virtual void SetNativeCapture() = 0;
30 virtual void ReleaseNativeCapture() = 0;
32 protected:
33 virtual ~CaptureDelegate() {}
36 } // namespace client
37 } // namespace aura
39 #endif // UI_AURA_CLIENT_CAPTURE_DELEGATE_H_