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

Side by Side Diff: content/public/browser/web_contents_delegate.h

Issue 10080018: Don't allow sending data URLs to WebUI, unless in a ChromeOS BalloonHost. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix compile errors and crash in tests. Created 8 years, 8 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 CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_
6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 const gfx::Point& location, 150 const gfx::Point& location,
151 bool motion) {} 151 bool motion) {}
152 152
153 // Request the delegate to change the zoom level of the current tab. 153 // Request the delegate to change the zoom level of the current tab.
154 virtual void ContentsZoomChange(bool zoom_in) {} 154 virtual void ContentsZoomChange(bool zoom_in) {}
155 155
156 // Check whether this contents is inside a window dedicated to running a web 156 // Check whether this contents is inside a window dedicated to running a web
157 // application. 157 // application.
158 virtual bool IsApplication() const; 158 virtual bool IsApplication() const;
159 159
160 // Check whether this contents is permitted to load data URLs in WebUI mode.
161 // This is normally disallowed for security.
162 virtual bool CanLoadDataURLsInWebUI() const;
163
160 // Detach the given tab and convert it to a "webapp" view. The tab must be 164 // Detach the given tab and convert it to a "webapp" view. The tab must be
161 // a WebContents with a valid WebApp set. 165 // a WebContents with a valid WebApp set.
162 virtual void ConvertContentsToApplication(WebContents* source) {} 166 virtual void ConvertContentsToApplication(WebContents* source) {}
163 167
164 // Whether the specified tab can be reloaded. 168 // Whether the specified tab can be reloaded.
165 // Reloading can be disabled e. g. for the DevTools window. 169 // Reloading can be disabled e. g. for the DevTools window.
166 virtual bool CanReloadContents(WebContents* source) const; 170 virtual bool CanReloadContents(WebContents* source) const;
167 171
168 // Return the rect where to display the resize corner, if any, otherwise 172 // Return the rect where to display the resize corner, if any, otherwise
169 // an empty rect. 173 // an empty rect.
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after
417 // Called when |this| is no longer the WebContentsDelegate for |source|. 421 // Called when |this| is no longer the WebContentsDelegate for |source|.
418 void Detach(WebContents* source); 422 void Detach(WebContents* source);
419 423
420 // The WebContents that this is currently a delegate for. 424 // The WebContents that this is currently a delegate for.
421 std::set<WebContents*> attached_contents_; 425 std::set<WebContents*> attached_contents_;
422 }; 426 };
423 427
424 } // namespace content 428 } // namespace content
425 429
426 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ 430 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_
OLDNEW
« no previous file with comments | « content/browser/web_contents/web_contents_impl_unittest.cc ('k') | content/public/browser/web_contents_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698