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

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

Issue 2740013008: Fix tab restore for view-source Chrome extension pages. (Closed)
Patch Set: Created 3 years, 9 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
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_CONTENT_BROWSER_CLIENT_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_
6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ 6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 // isolation is enabled for this URL, and is a bug workaround. 209 // isolation is enabled for this URL, and is a bug workaround.
210 // 210 //
211 // TODO(nick): Remove this function once https://crbug.com/160576 is fixed, 211 // TODO(nick): Remove this function once https://crbug.com/160576 is fixed,
212 // and origin lock can be applied to all URLs. 212 // and origin lock can be applied to all URLs.
213 virtual bool ShouldLockToOrigin(BrowserContext* browser_context, 213 virtual bool ShouldLockToOrigin(BrowserContext* browser_context,
214 const GURL& effective_url); 214 const GURL& effective_url);
215 215
216 // Returns a list additional WebUI schemes, if any. These additional schemes 216 // Returns a list additional WebUI schemes, if any. These additional schemes
217 // act as aliases to the chrome: scheme. The additional schemes may or may 217 // act as aliases to the chrome: scheme. The additional schemes may or may
218 // not serve specific WebUI pages depending on the particular URLDataSource 218 // not serve specific WebUI pages depending on the particular URLDataSource
219 // and its override of URLDataSource::ShouldServiceRequest. For all schemes 219 // and its override of URLDataSource::ShouldServiceRequest.
220 // returned here, view-source is allowed.
221 virtual void GetAdditionalWebUISchemes( 220 virtual void GetAdditionalWebUISchemes(
222 std::vector<std::string>* additional_schemes) {} 221 std::vector<std::string>* additional_schemes) {}
223 222
223 // Returns a list of additional schemes allowed for view-source.
224 virtual void GetAdditionalViewSourceSchemes(
225 std::vector<std::string>* additional_schemes) {}
Charlie Reis 2017/03/15 15:03:31 I wonder if there's a risk that this breaks view-s
alexmos 2017/03/16 20:07:30 Good idea. Done.
226
224 // Called when WebUI objects are created to get aggregate usage data (i.e. is 227 // Called when WebUI objects are created to get aggregate usage data (i.e. is
225 // chrome://downloads used more than chrome://bookmarks?). Only internal (e.g. 228 // chrome://downloads used more than chrome://bookmarks?). Only internal (e.g.
226 // chrome://) URLs are logged. Returns whether the URL was actually logged. 229 // chrome://) URLs are logged. Returns whether the URL was actually logged.
227 virtual bool LogWebUIUrl(const GURL& web_ui_url) const; 230 virtual bool LogWebUIUrl(const GURL& web_ui_url) const;
228 231
229 // Returns whether a specified URL is handled by the embedder's internal 232 // Returns whether a specified URL is handled by the embedder's internal
230 // protocol handlers. 233 // protocol handlers.
231 virtual bool IsHandledURL(const GURL& url); 234 virtual bool IsHandledURL(const GURL& url);
232 235
233 // Returns whether the given process is allowed to commit |url|. This is a 236 // Returns whether the given process is allowed to commit |url|. This is a
(...skipping 590 matching lines...) Expand 10 before | Expand all | Expand 10 after
824 virtual bool ShouldRedirectDOMStorageTaskRunner(); 827 virtual bool ShouldRedirectDOMStorageTaskRunner();
825 828
826 // If this returns true, all BrowserThreads (but UI/IO) that support it on 829 // If this returns true, all BrowserThreads (but UI/IO) that support it on
827 // this platform will experimentally be redirected to TaskScheduler. 830 // this platform will experimentally be redirected to TaskScheduler.
828 virtual bool RedirectNonUINonIOBrowserThreadsToTaskScheduler(); 831 virtual bool RedirectNonUINonIOBrowserThreadsToTaskScheduler();
829 }; 832 };
830 833
831 } // namespace content 834 } // namespace content
832 835
833 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ 836 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_
OLDNEW
« content/browser/browser_url_handler_impl.cc ('K') | « content/browser/browser_url_handler_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698