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

Unified Diff: content/browser/webui/web_ui_data_source_impl.h

Issue 2399553002: Gzip compress chrome://accessibility resources (Closed)
Patch Set: asdf Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/accessibility/accessibility_ui.cc ('k') | content/browser/webui/web_ui_data_source_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/webui/web_ui_data_source_impl.h
diff --git a/content/browser/webui/web_ui_data_source_impl.h b/content/browser/webui/web_ui_data_source_impl.h
index 64515feeff5f4e0d0665a1d18b9dc24ce18ac94d..387209ebc3d988694ba8f0b3b73100a7eaa7e1cb 100644
--- a/content/browser/webui/web_ui_data_source_impl.h
+++ b/content/browser/webui/web_ui_data_source_impl.h
@@ -9,6 +9,7 @@
#include <map>
#include <string>
+#include <unordered_set>
#include "base/callback.h"
#include "base/compiler_specific.h"
@@ -49,6 +50,9 @@ class CONTENT_EXPORT WebUIDataSourceImpl
void DisableDenyXFrameOptions() override;
void DisableI18nAndUseGzipForAllPaths() override;
+ // When DisableI18nAndUseGzipForAllPaths is enabled, exclude the given |path|.
+ void ExcludePathFromGzip(const std::string& path);
+
protected:
~WebUIDataSourceImpl() override;
@@ -85,6 +89,7 @@ class CONTENT_EXPORT WebUIDataSourceImpl
int default_resource_;
std::string json_path_;
std::map<std::string, int> path_to_idr_map_;
+ std::unordered_set<std::string> excluded_paths_;
// The |replacements_| is intended to replace |localized_strings_|.
// TODO(dschuyler): phase out |localized_strings_| in Q1 2016. (Or rename
// to |load_time_flags_| if the usage is reduced to storing flags only).
« no previous file with comments | « content/browser/accessibility/accessibility_ui.cc ('k') | content/browser/webui/web_ui_data_source_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698