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

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

Issue 9235004: [Garbled Text][Infobar] Adding infobar to suggest turning on encoding detection. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase Created 8 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
« no previous file with comments | « chrome/common/render_messages.h ('k') | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #pragma once 7 #pragma once
8 8
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 void OnDownloadFavicon(int id, const GURL& image_url, int image_size); 131 void OnDownloadFavicon(int id, const GURL& image_url, int image_size);
132 void OnSetIsPrerendering(bool is_prerendering); 132 void OnSetIsPrerendering(bool is_prerendering);
133 void OnSetAllowDisplayingInsecureContent(bool allow); 133 void OnSetAllowDisplayingInsecureContent(bool allow);
134 void OnSetAllowRunningInsecureContent(bool allow); 134 void OnSetAllowRunningInsecureContent(bool allow);
135 void OnSetClientSidePhishingDetection(bool enable_phishing_detection); 135 void OnSetClientSidePhishingDetection(bool enable_phishing_detection);
136 void OnSetVisuallyDeemphasized(bool deemphasized); 136 void OnSetVisuallyDeemphasized(bool deemphasized);
137 void OnStartFrameSniffer(const string16& frame_name); 137 void OnStartFrameSniffer(const string16& frame_name);
138 void OnGetFPS(); 138 void OnGetFPS();
139 void OnAddStrictSecurityHost(const std::string& host); 139 void OnAddStrictSecurityHost(const std::string& host);
140 void OnSetAsInterstitial(); 140 void OnSetAsInterstitial();
141 void OnReloadFromCache();
142 void OnSetGarbledTextDetectionEnableState(bool enable);
141 143
142 // Captures the thumbnail and text contents for indexing for the given load 144 // Captures the thumbnail and text contents for indexing for the given load
143 // ID. If the view's load ID is different than the parameter, this call is 145 // ID. If the view's load ID is different than the parameter, this call is
144 // a NOP. Typically called on a timer, so the load ID may have changed in the 146 // a NOP. Typically called on a timer, so the load ID may have changed in the
145 // meantime. 147 // meantime.
146 void CapturePageInfo(int load_id, bool preliminary_capture); 148 void CapturePageInfo(int load_id, bool preliminary_capture);
147 149
148 // Retrieves the text from the given frame contents, the page text up to the 150 // Retrieves the text from the given frame contents, the page text up to the
149 // maximum amount kMaxIndexChars will be placed into the given buffer. 151 // maximum amount kMaxIndexChars will be placed into the given buffer.
150 void CaptureText(WebKit::WebFrame* frame, string16* contents); 152 void CaptureText(WebKit::WebFrame* frame, string16* contents);
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 bool allow_running_insecure_content_; 215 bool allow_running_insecure_content_;
214 std::set<std::string> strict_security_hosts_; 216 std::set<std::string> strict_security_hosts_;
215 217
216 // Allows JS to access DOM automation. The JS object is only exposed when the 218 // Allows JS to access DOM automation. The JS object is only exposed when the
217 // DOM automation bindings are enabled. 219 // DOM automation bindings are enabled.
218 scoped_ptr<DomAutomationController> dom_automation_controller_; 220 scoped_ptr<DomAutomationController> dom_automation_controller_;
219 221
220 // External host exposed through automation controller. 222 // External host exposed through automation controller.
221 scoped_ptr<ExternalHostBindings> external_host_bindings_; 223 scoped_ptr<ExternalHostBindings> external_host_bindings_;
222 224
225 // True if we should run garbled text detection.
226 bool garbled_text_detection_enabled_;
227
223 base::WeakPtrFactory<ChromeRenderViewObserver> weak_factory_; 228 base::WeakPtrFactory<ChromeRenderViewObserver> weak_factory_;
224 229
225 typedef std::vector<linked_ptr<webkit_glue::ImageResourceFetcher> > 230 typedef std::vector<linked_ptr<webkit_glue::ImageResourceFetcher> >
226 ImageResourceFetcherList; 231 ImageResourceFetcherList;
227 232
228 // ImageResourceFetchers schedule via DownloadImage. 233 // ImageResourceFetchers schedule via DownloadImage.
229 ImageResourceFetcherList image_fetchers_; 234 ImageResourceFetcherList image_fetchers_;
230 235
231 // A color page overlay when visually de-emaphasized. 236 // A color page overlay when visually de-emaphasized.
232 scoped_ptr<WebViewColorOverlay> dimmed_color_overlay_; 237 scoped_ptr<WebViewColorOverlay> dimmed_color_overlay_;
233 238
234 DISALLOW_COPY_AND_ASSIGN(ChromeRenderViewObserver); 239 DISALLOW_COPY_AND_ASSIGN(ChromeRenderViewObserver);
235 }; 240 };
236 241
237 #endif // CHROME_RENDERER_CHROME_RENDER_VIEW_OBSERVER_H_ 242 #endif // CHROME_RENDERER_CHROME_RENDER_VIEW_OBSERVER_H_
OLDNEW
« no previous file with comments | « chrome/common/render_messages.h ('k') | chrome/renderer/chrome_render_view_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698