| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "components/dom_distiller/core/viewer.h" | 5 #include "components/dom_distiller/core/viewer.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/json/json_writer.h" | 10 #include "base/json/json_writer.h" |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 l10n_util::GetStringUTF8( | 137 l10n_util::GetStringUTF8( |
| 138 IDS_DOM_DISTILLER_JAVASCRIPT_DISABLED_CONTENT)); // $5 | 138 IDS_DOM_DISTILLER_JAVASCRIPT_DISABLED_CONTENT)); // $5 |
| 139 | 139 |
| 140 substitutions.push_back(original_url); // $6 | 140 substitutions.push_back(original_url); // $6 |
| 141 substitutions.push_back( | 141 substitutions.push_back( |
| 142 l10n_util::GetStringUTF8( | 142 l10n_util::GetStringUTF8( |
| 143 IDS_DOM_DISTILLER_VIEWER_CLOSE_READER_VIEW)); // $7 | 143 IDS_DOM_DISTILLER_VIEWER_CLOSE_READER_VIEW)); // $7 |
| 144 | 144 |
| 145 substitutions.push_back(script.str()); // $8 | 145 substitutions.push_back(script.str()); // $8 |
| 146 | 146 |
| 147 return ReplaceStringPlaceholders(html_template, substitutions, NULL); | 147 return base::ReplaceStringPlaceholders(html_template, substitutions, NULL); |
| 148 } | 148 } |
| 149 | 149 |
| 150 } // namespace | 150 } // namespace |
| 151 | 151 |
| 152 namespace viewer { | 152 namespace viewer { |
| 153 | 153 |
| 154 const std::string GetShowFeedbackFormJs() { | 154 const std::string GetShowFeedbackFormJs() { |
| 155 base::StringValue question_val( | 155 base::StringValue question_val( |
| 156 l10n_util::GetStringUTF8(IDS_DOM_DISTILLER_QUALITY_QUESTION)); | 156 l10n_util::GetStringUTF8(IDS_DOM_DISTILLER_QUALITY_QUESTION)); |
| 157 base::StringValue no_val( | 157 base::StringValue no_val( |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 299 } | 299 } |
| 300 | 300 |
| 301 const std::string GetDistilledPageFontFamilyJs( | 301 const std::string GetDistilledPageFontFamilyJs( |
| 302 DistilledPagePrefs::FontFamily font_family) { | 302 DistilledPagePrefs::FontFamily font_family) { |
| 303 return "useFontFamily('" + GetJsFontFamily(font_family) + "');"; | 303 return "useFontFamily('" + GetJsFontFamily(font_family) + "');"; |
| 304 } | 304 } |
| 305 | 305 |
| 306 } // namespace viewer | 306 } // namespace viewer |
| 307 | 307 |
| 308 } // namespace dom_distiller | 308 } // namespace dom_distiller |
| OLD | NEW |