| OLD | NEW |
| (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 CHROME_BROWSER_ANDROID_VR_SHELL_VR_WEB_CONTENTS_OBSERVER_H_ |
| 6 #define CHROME_BROWSER_ANDROID_VR_SHELL_VR_WEB_CONTENTS_OBSERVER_H_ |
| 7 |
| 8 #include "base/macros.h" |
| 9 #include "content/public/browser/web_contents_observer.h" |
| 10 |
| 11 namespace content { |
| 12 class NavigationHandle; |
| 13 } |
| 14 |
| 15 namespace vr_shell { |
| 16 |
| 17 class UiInterface; |
| 18 |
| 19 class CONTENT_EXPORT VrWebContentsObserver |
| 20 : public content::WebContentsObserver { |
| 21 public: |
| 22 VrWebContentsObserver(content::WebContents* web_contents, |
| 23 UiInterface* ui_interface); |
| 24 ~VrWebContentsObserver() override; |
| 25 |
| 26 void SetUiInterface(UiInterface* ui_interface); |
| 27 |
| 28 // WebContentsObserver implementation. |
| 29 void DidStartLoading() override; |
| 30 void DidStopLoading() override; |
| 31 void DidStartNavigation( |
| 32 content::NavigationHandle* navigation_handle) override; |
| 33 void DidRedirectNavigation( |
| 34 content::NavigationHandle* navigation_handle) override; |
| 35 void DidFinishNavigation( |
| 36 content::NavigationHandle* navigation_handle) override; |
| 37 |
| 38 private: |
| 39 // This class does not own the UI interface. |
| 40 UiInterface* ui_interface_; |
| 41 |
| 42 DISALLOW_COPY_AND_ASSIGN(VrWebContentsObserver); |
| 43 }; |
| 44 |
| 45 } // namespace vr_shell |
| 46 |
| 47 #endif // CHROME_BROWSER_ANDROID_VR_SHELL_VR_WEB_CONTENTS_OBSERVER_H_ |
| OLD | NEW |