| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ | 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 346 // invokes this method. If there are ongoing navigations, their respective | 346 // invokes this method. If there are ongoing navigations, their respective |
| 347 // failure methods will also be invoked. | 347 // failure methods will also be invoked. |
| 348 virtual void NavigationStopped() {} | 348 virtual void NavigationStopped() {} |
| 349 | 349 |
| 350 // Called when there has been direct user interaction with the WebContents. | 350 // Called when there has been direct user interaction with the WebContents. |
| 351 // The type argument specifies the kind of interaction. Direct user input | 351 // The type argument specifies the kind of interaction. Direct user input |
| 352 // signalled through this callback includes: | 352 // signalled through this callback includes: |
| 353 // 1) any mouse down event (blink::WebInputEvent::MouseDown); | 353 // 1) any mouse down event (blink::WebInputEvent::MouseDown); |
| 354 // 2) the start of a scroll (blink::WebInputEvent::GestureScrollBegin); | 354 // 2) the start of a scroll (blink::WebInputEvent::GestureScrollBegin); |
| 355 // 3) any raw key down event (blink::WebInputEvent::RawKeyDown); | 355 // 3) any raw key down event (blink::WebInputEvent::RawKeyDown); |
| 356 // 4) any gesture tap event (blink::WebInputEvent::GestureTapDown); and | 356 // 4) any touch event (inc. scrolls) (blink::WebInputEvent::TouchStart); and |
| 357 // 5) a browser navigation or reload (blink::WebInputEvent::Undefined). | 357 // 5) a browser navigation or reload (blink::WebInputEvent::Undefined). |
| 358 virtual void DidGetUserInteraction(const blink::WebInputEvent::Type type) {} | 358 virtual void DidGetUserInteraction(const blink::WebInputEvent::Type type) {} |
| 359 | 359 |
| 360 // This method is invoked when a RenderViewHost of this WebContents was | 360 // This method is invoked when a RenderViewHost of this WebContents was |
| 361 // configured to ignore UI events, and an UI event took place. | 361 // configured to ignore UI events, and an UI event took place. |
| 362 virtual void DidGetIgnoredUIEvent() {} | 362 virtual void DidGetIgnoredUIEvent() {} |
| 363 | 363 |
| 364 // These methods are invoked every time the WebContents changes visibility. | 364 // These methods are invoked every time the WebContents changes visibility. |
| 365 virtual void WasShown() {} | 365 virtual void WasShown() {} |
| 366 virtual void WasHidden() {} | 366 virtual void WasHidden() {} |
| (...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 514 void ResetWebContents(); | 514 void ResetWebContents(); |
| 515 | 515 |
| 516 WebContentsImpl* web_contents_; | 516 WebContentsImpl* web_contents_; |
| 517 | 517 |
| 518 DISALLOW_COPY_AND_ASSIGN(WebContentsObserver); | 518 DISALLOW_COPY_AND_ASSIGN(WebContentsObserver); |
| 519 }; | 519 }; |
| 520 | 520 |
| 521 } // namespace content | 521 } // namespace content |
| 522 | 522 |
| 523 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ | 523 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ |
| OLD | NEW |