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

Side by Side Diff: content/browser/screen_orientation/screen_orientation.h

Issue 2685513002: [For trybots test] [ScreenOrientation] Hide ScreenOrientationProvider inside WebContentsImpl. (Closed)
Patch Set: Fix android bots Created 3 years, 10 months 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_BROWSER_SCREEN_ORIENTATION_SCREEN_ORIENTATION_H
6 #define CONTENT_BROWSER_SCREEN_ORIENTATION_SCREEN_ORIENTATION_H
7
8 #include "base/memory/weak_ptr.h"
9 #include "content/public/browser/web_contents_binding_set.h"
10 #include "content/public/browser/web_contents_observer.h"
11 #include "device/screen_orientation/public/interfaces/screen_orientation.mojom.h "
12
13 namespace content {
14
15 class ScreenOrientationProvider;
16 class WebContents;
17
18 class ScreenOrientation : public device::mojom::ScreenOrientation,
19 public WebContentsObserver {
20 public:
21 explicit ScreenOrientation(WebContents* web_contents);
22 ~ScreenOrientation() override;
23
24 ScreenOrientationProvider* GetScreenOrientationProvider();
25
26 private:
27 // ScreenOrientation:
28 void LockOrientation(blink::WebScreenOrientationLockType orientation,
29 const LockOrientationCallback& callback) override;
30 void UnlockOrientation() override;
31
32 // WebContentsObserver:
33 void DidFinishNavigation(NavigationHandle* navigation_handle) override;
34
35 std::unique_ptr<ScreenOrientationProvider> provider_;
36 WebContentsFrameBindingSet<device::mojom::ScreenOrientation> bindings_;
37 base::WeakPtrFactory<ScreenOrientation> weak_factory_;
38 };
39
40 } // namespace content
41
42 #endif // CONTENT_BROWSER_SCREEN_ORIENTATION_SCREEN_ORIENTATION_H
OLDNEW
« no previous file with comments | « content/browser/frame_host/render_frame_host_delegate.cc ('k') | content/browser/screen_orientation/screen_orientation.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698