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

Side by Side Diff: chrome/browser/ui/webui/chromeos/proxy_settings_ui.cc

Issue 2763013003: Specify AllowCaching = false for some ChromeOS UI pages (Closed)
Patch Set: one more build fix 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 #include "chrome/browser/ui/webui/chromeos/proxy_settings_ui.h" 5 #include "chrome/browser/ui/webui/chromeos/proxy_settings_ui.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/memory/ptr_util.h" 10 #include "base/memory/ptr_util.h"
(...skipping 28 matching lines...) Expand all
39 // content::URLDataSource implementation. 39 // content::URLDataSource implementation.
40 std::string GetSource() const override; 40 std::string GetSource() const override;
41 void StartDataRequest( 41 void StartDataRequest(
42 const std::string& path, 42 const std::string& path,
43 const content::ResourceRequestInfo::WebContentsGetter& wc_getter, 43 const content::ResourceRequestInfo::WebContentsGetter& wc_getter,
44 const content::URLDataSource::GotDataCallback& callback) override; 44 const content::URLDataSource::GotDataCallback& callback) override;
45 std::string GetMimeType(const std::string&) const override { 45 std::string GetMimeType(const std::string&) const override {
46 return "text/html"; 46 return "text/html";
47 } 47 }
48 bool ShouldAddContentSecurityPolicy() const override { return false; } 48 bool ShouldAddContentSecurityPolicy() const override { return false; }
49 bool AllowCaching() const override {
50 // Should not be cached to reflect dynamically-generated contents that
51 // may depend on current settings.
52 return false;
53 }
49 54
50 protected: 55 protected:
51 ~ProxySettingsHTMLSource() override {} 56 ~ProxySettingsHTMLSource() override {}
52 57
53 private: 58 private:
54 std::unique_ptr<base::DictionaryValue> localized_strings_; 59 std::unique_ptr<base::DictionaryValue> localized_strings_;
55 60
56 DISALLOW_COPY_AND_ASSIGN(ProxySettingsHTMLSource); 61 DISALLOW_COPY_AND_ASSIGN(ProxySettingsHTMLSource);
57 }; 62 };
58 63
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 if (!initialized_handlers_) { 131 if (!initialized_handlers_) {
127 core_handler_->InitializeHandler(); 132 core_handler_->InitializeHandler();
128 proxy_handler_->InitializeHandler(); 133 proxy_handler_->InitializeHandler();
129 initialized_handlers_ = true; 134 initialized_handlers_ = true;
130 } 135 }
131 core_handler_->InitializePage(); 136 core_handler_->InitializePage();
132 proxy_handler_->InitializePage(); 137 proxy_handler_->InitializePage();
133 } 138 }
134 139
135 } // namespace chromeos 140 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/chromeos/mobile_setup_ui.cc ('k') | chrome/browser/ui/webui/chromeos/sim_unlock_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698