Switch global error menu icon to vectorized MD asset
[chromium-blink-merge.git] / content / public / browser / screen_orientation_delegate.h
blob06822a18c3adcbc2642f108b0b9e4b14c4c2c34f
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
3 // found in the LICENSE file.
5 #ifndef CONTENT_PUBLIC_BROWSER_SCREEN_ORIENTATION_DELEGATE_H_
6 #define CONTENT_PUBLIC_BROWSER_SCREEN_ORIENTATION_DELEGATE_H_
8 #include "base/macros.h"
9 #include "content/common/content_export.h"
10 #include "third_party/WebKit/public/platform/modules/screen_orientation/WebScreenOrientationLockType.h"
12 namespace content {
14 class WebContents;
16 // Can be implemented to provide platform specific functionality for
17 // ScreenOrientationProvider.
18 class CONTENT_EXPORT ScreenOrientationDelegate {
19 public:
20 ScreenOrientationDelegate() {};
21 virtual ~ScreenOrientationDelegate() {}
23 // Returns true if the tab must be fullscreen in order for
24 // ScreenOrientationProvider to respond to requests.
25 virtual bool FullScreenRequired(WebContents* web_contents) = 0;
27 // Lock display to the given orientation.
28 virtual void Lock(WebContents* web_contents,
29 blink::WebScreenOrientationLockType lock_orientation) = 0;
31 // Are ScreenOrientationProvider requests currently supported by the platform.
32 virtual bool ScreenOrientationProviderSupported() = 0;
34 // Unlocks the display, allowing hardware rotation to resume.
35 virtual void Unlock(WebContents* web_contents) = 0;
37 private:
38 DISALLOW_COPY_AND_ASSIGN(ScreenOrientationDelegate);
41 } // namespace content
43 #endif // CONTENT_PUBLIC_BROWSER_SCREEN_ORIENTATION_DELEGATE_H_