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

Side by Side Diff: android_webview/browser/renderer_host/aw_render_view_host_ext.h

Issue 11860014: Android WebView visited link highlighting implementation part 1 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase to pass no_disk parameter instead of using delegate. Created 7 years, 11 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 | Annotate | Revision Log
OLDNEW
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 ANDROID_WEBVIEW_BROWSER_RENDER_HOST_RENDER_VIEW_HOST_EXT_H_ 5 #ifndef ANDROID_WEBVIEW_BROWSER_RENDER_HOST_RENDER_VIEW_HOST_EXT_H_
6 #define ANDROID_WEBVIEW_BROWSER_RENDER_HOST_RENDER_VIEW_HOST_EXT_H_ 6 #define ANDROID_WEBVIEW_BROWSER_RENDER_HOST_RENDER_VIEW_HOST_EXT_H_
7 7
8 #include "content/public/browser/web_contents_observer.h" 8 #include "content/public/browser/web_contents_observer.h"
9 9
10 #include "android_webview/common/aw_hit_test_data.h" 10 #include "android_webview/common/aw_hit_test_data.h"
11 #include "base/callback_forward.h" 11 #include "base/callback_forward.h"
12 #include "base/threading/non_thread_safe.h" 12 #include "base/threading/non_thread_safe.h"
13 13
14 class GURL;
15
16 namespace content {
17 struct FrameNavigateParams;
18 struct LoadCommittedDetails;
19 } // namespace content
20
14 namespace android_webview { 21 namespace android_webview {
15 22
16 // Provides RenderViewHost wrapper functionality for sending WebView-specific 23 // Provides RenderViewHost wrapper functionality for sending WebView-specific
17 // IPC messages to the renderer and from there to WebKit. 24 // IPC messages to the renderer and from there to WebKit.
18 class AwRenderViewHostExt : public content::WebContentsObserver, 25 class AwRenderViewHostExt : public content::WebContentsObserver,
19 public base::NonThreadSafe { 26 public base::NonThreadSafe {
20 public: 27 public:
21 class Client { 28 class Client {
22 public: 29 public:
23 virtual void OnPictureUpdated(int process_id, int render_view_id) = 0; 30 virtual void OnPictureUpdated(int process_id, int render_view_id) = 0;
(...skipping 22 matching lines...) Expand all
46 bool HasNewHitTestData() const; 53 bool HasNewHitTestData() const;
47 void MarkHitTestDataRead(); 54 void MarkHitTestDataRead();
48 55
49 // Return |last_hit_test_data_|. Note that this is unavoidably racy; 56 // Return |last_hit_test_data_|. Note that this is unavoidably racy;
50 // the corresponding public WebView API is as well. 57 // the corresponding public WebView API is as well.
51 const AwHitTestData& GetLastHitTestData() const; 58 const AwHitTestData& GetLastHitTestData() const;
52 59
53 private: 60 private:
54 // content::WebContentsObserver implementation. 61 // content::WebContentsObserver implementation.
55 virtual void RenderViewGone(base::TerminationStatus status) OVERRIDE; 62 virtual void RenderViewGone(base::TerminationStatus status) OVERRIDE;
63 virtual void DidNavigateAnyFrame(
64 const content::LoadCommittedDetails& details,
65 const content::FrameNavigateParams& params) OVERRIDE;
56 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; 66 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
57 67
58 void OnDocumentHasImagesResponse(int msg_id, bool has_images); 68 void OnDocumentHasImagesResponse(int msg_id, bool has_images);
59 void OnUpdateHitTestData(const AwHitTestData& hit_test_data); 69 void OnUpdateHitTestData(const AwHitTestData& hit_test_data);
60 void OnPictureUpdated(); 70 void OnPictureUpdated();
61 71
62 std::map<int, DocumentHasImagesResult> pending_document_has_images_requests_; 72 std::map<int, DocumentHasImagesResult> pending_document_has_images_requests_;
63 73
64 // Master copy of hit test data on the browser side. This is updated 74 // Master copy of hit test data on the browser side. This is updated
65 // as a result of DoHitTest called explicitly or when the FocusedNodeChanged 75 // as a result of DoHitTest called explicitly or when the FocusedNodeChanged
66 // is called in AwRenderViewExt. 76 // is called in AwRenderViewExt.
67 AwHitTestData last_hit_test_data_; 77 AwHitTestData last_hit_test_data_;
68 78
69 bool has_new_hit_test_data_; 79 bool has_new_hit_test_data_;
70 80
71 Client* client_; 81 Client* client_;
72 82
73 DISALLOW_COPY_AND_ASSIGN(AwRenderViewHostExt); 83 DISALLOW_COPY_AND_ASSIGN(AwRenderViewHostExt);
74 }; 84 };
75 85
76 } // namespace android_webview 86 } // namespace android_webview
77 87
78 #endif // ANDROID_WEBVIEW_BROWSER_RENDER_HOST_RENDER_VIEW_HOST_EXT_H_ 88 #endif // ANDROID_WEBVIEW_BROWSER_RENDER_HOST_RENDER_VIEW_HOST_EXT_H_
OLDNEW
« no previous file with comments | « android_webview/browser/aw_browser_main_parts.cc ('k') | android_webview/browser/renderer_host/aw_render_view_host_ext.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698