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

Side by Side Diff: chrome/renderer/chrome_render_view_observer.h

Issue 10831163: Update favicon URLs on FinishLoad for main frame (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Moved the function to match the order in the header file. Created 8 years, 4 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
« no previous file with comments | « no previous file | chrome/renderer/chrome_render_view_observer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 CHROME_RENDERER_CHROME_RENDER_VIEW_OBSERVER_H_ 5 #ifndef CHROME_RENDERER_CHROME_RENDER_VIEW_OBSERVER_H_
6 #define CHROME_RENDERER_CHROME_RENDER_VIEW_OBSERVER_H_ 6 #define CHROME_RENDERER_CHROME_RENDER_VIEW_OBSERVER_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 string16 frame_xpath; 59 string16 frame_xpath;
60 string16 jscript; 60 string16 jscript;
61 int id; 61 int id;
62 bool notify_result; 62 bool notify_result;
63 }; 63 };
64 64
65 // RenderViewObserver implementation. 65 // RenderViewObserver implementation.
66 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; 66 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
67 virtual void DidStartLoading() OVERRIDE; 67 virtual void DidStartLoading() OVERRIDE;
68 virtual void DidStopLoading() OVERRIDE; 68 virtual void DidStopLoading() OVERRIDE;
69 virtual void DidFinishLoad(WebKit::WebFrame* frame) OVERRIDE;
69 virtual void DidChangeIcon(WebKit::WebFrame* frame, 70 virtual void DidChangeIcon(WebKit::WebFrame* frame,
70 WebKit::WebIconURL::Type icon_type) OVERRIDE; 71 WebKit::WebIconURL::Type icon_type) OVERRIDE;
71 virtual void DidCommitProvisionalLoad(WebKit::WebFrame* frame, 72 virtual void DidCommitProvisionalLoad(WebKit::WebFrame* frame,
72 bool is_new_navigation) OVERRIDE; 73 bool is_new_navigation) OVERRIDE;
73 virtual void DidClearWindowObject(WebKit::WebFrame* frame) OVERRIDE; 74 virtual void DidClearWindowObject(WebKit::WebFrame* frame) OVERRIDE;
74 virtual void DidHandleTouchEvent(const WebKit::WebTouchEvent& event) OVERRIDE; 75 virtual void DidHandleTouchEvent(const WebKit::WebTouchEvent& event) OVERRIDE;
75 76
76 // WebKit::WebPermissionClient implementation. 77 // WebKit::WebPermissionClient implementation.
77 virtual bool allowDatabase(WebKit::WebFrame* frame, 78 virtual bool allowDatabase(WebKit::WebFrame* frame,
78 const WebKit::WebString& name, 79 const WebKit::WebString& name,
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 // request was successfully started, false otherwise. id is used to 176 // request was successfully started, false otherwise. id is used to
176 // uniquely identify the request and passed back to the 177 // uniquely identify the request and passed back to the
177 // DidDownloadFavicon method. If the image has multiple frames, the 178 // DidDownloadFavicon method. If the image has multiple frames, the
178 // frame whose size is image_size is returned. If the image doesn't 179 // frame whose size is image_size is returned. If the image doesn't
179 // have a frame at the specified size, the first is returned. 180 // have a frame at the specified size, the first is returned.
180 bool DownloadFavicon(int id, const GURL& image_url, int image_size); 181 bool DownloadFavicon(int id, const GURL& image_url, int image_size);
181 182
182 // Decodes a data: URL image or returns an empty image in case of failure. 183 // Decodes a data: URL image or returns an empty image in case of failure.
183 SkBitmap ImageFromDataUrl(const GURL&) const; 184 SkBitmap ImageFromDataUrl(const GURL&) const;
184 185
186 // Collects favicons of given types from the frame and sends UpdateFaviconURL.
187 void CollectAndUpdateFaviconURLs(WebKit::WebFrame* frame, int icon_types);
188
185 // Determines if a host is in the strict security host set. 189 // Determines if a host is in the strict security host set.
186 bool IsStrictSecurityHost(const std::string& host); 190 bool IsStrictSecurityHost(const std::string& host);
187 191
188 // Checks if |origin| correponds to an installed extension that has been 192 // Checks if |origin| correponds to an installed extension that has been
189 // granted the |permission|. 193 // granted the |permission|.
190 bool HasExtensionPermission(const WebKit::WebSecurityOrigin& origin, 194 bool HasExtensionPermission(const WebKit::WebSecurityOrigin& origin,
191 extensions::APIPermission::ID permission) const; 195 extensions::APIPermission::ID permission) const;
192 196
193 // Save the JavaScript to preload if a ViewMsg_WebUIJavaScript is received. 197 // Save the JavaScript to preload if a ViewMsg_WebUIJavaScript is received.
194 scoped_ptr<WebUIJavaScript> webui_javascript_; 198 scoped_ptr<WebUIJavaScript> webui_javascript_;
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 // A color page overlay when visually de-emaphasized. 231 // A color page overlay when visually de-emaphasized.
228 scoped_ptr<WebViewColorOverlay> dimmed_color_overlay_; 232 scoped_ptr<WebViewColorOverlay> dimmed_color_overlay_;
229 233
230 // Used to delay calling CapturePageInfo. 234 // Used to delay calling CapturePageInfo.
231 base::Timer capture_timer_; 235 base::Timer capture_timer_;
232 236
233 DISALLOW_COPY_AND_ASSIGN(ChromeRenderViewObserver); 237 DISALLOW_COPY_AND_ASSIGN(ChromeRenderViewObserver);
234 }; 238 };
235 239
236 #endif // CHROME_RENDERER_CHROME_RENDER_VIEW_OBSERVER_H_ 240 #endif // CHROME_RENDERER_CHROME_RENDER_VIEW_OBSERVER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/renderer/chrome_render_view_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698