OLD | NEW |
---|---|
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/options/import_data_handler.h" | 5 #include "chrome/browser/ui/webui/options/import_data_handler.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
176 base::ListValue browser_profiles; | 176 base::ListValue browser_profiles; |
177 for (size_t i = 0; i < importer_list_->count(); ++i) { | 177 for (size_t i = 0; i < importer_list_->count(); ++i) { |
178 const importer::SourceProfile& source_profile = | 178 const importer::SourceProfile& source_profile = |
179 importer_list_->GetSourceProfileAt(i); | 179 importer_list_->GetSourceProfileAt(i); |
180 uint16 browser_services = source_profile.services_supported; | 180 uint16 browser_services = source_profile.services_supported; |
181 | 181 |
182 base::DictionaryValue* browser_profile = new base::DictionaryValue(); | 182 base::DictionaryValue* browser_profile = new base::DictionaryValue(); |
183 browser_profile->SetString("name", source_profile.importer_name); | 183 browser_profile->SetString("name", source_profile.importer_name); |
184 browser_profile->SetInteger("index", i); | 184 browser_profile->SetInteger("index", i); |
185 browser_profile->SetBoolean("history", | 185 browser_profile->SetBoolean("history", |
186 (browser_services & importer::HISTORY) != 0); | 186 (browser_services & importer::HISTORY) != 0); |
187 browser_profile->SetBoolean("favorites", | 187 browser_profile->SetBoolean("favorites", |
188 (browser_services & importer::FAVORITES) != 0); | 188 (browser_services & importer::FAVORITES) != 0); |
189 browser_profile->SetBoolean("passwords", | 189 browser_profile->SetBoolean("passwords", |
190 (browser_services & importer::PASSWORDS) != 0); | 190 (browser_services & importer::PASSWORDS) != 0); |
191 browser_profile->SetBoolean("search", | 191 browser_profile->SetBoolean( |
192 (browser_services & importer::SEARCH_ENGINES) != 0); | 192 "search", (browser_services & importer::SEARCH_ENGINES) != 0); |
193 browser_profile->SetBoolean("autofill-form-data", | 193 browser_profile->SetBoolean( |
194 "autofill-form-data", | |
194 (browser_services & importer::AUTOFILL_FORM_DATA) != 0); | 195 (browser_services & importer::AUTOFILL_FORM_DATA) != 0); |
195 | 196 browser_profile->SetBoolean( |
196 browser_profile->SetBoolean("show_bottom_bar", | 197 "show_bottom_bar", |
Dan Beam
2014/09/23 05:55:35
if there's no functional change here (and it's jus
Nikhil
2014/09/23 06:00:26
Hmm, there is no functional change. But it was ide
Dan Beam
2014/09/23 18:41:32
it seems like it'd be pretty easy to run clang for
Nikhil
2014/09/29 06:10:43
Acknowledged.
| |
197 #if defined(OS_MACOSX) | 198 #if defined(OS_MACOSX) |
198 source_profile.importer_type == importer::TYPE_SAFARI); | 199 source_profile.importer_type == importer::TYPE_SAFARI); |
199 #else | 200 #else |
200 false); | 201 false); |
201 #endif | 202 #endif |
202 | 203 |
203 browser_profiles.Append(browser_profile); | 204 browser_profiles.Append(browser_profile); |
204 } | 205 } |
205 | 206 |
206 web_ui()->CallJavascriptFunction("ImportDataOverlay.updateSupportedBrowsers", | 207 web_ui()->CallJavascriptFunction("ImportDataOverlay.updateSupportedBrowsers", |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
270 base::string16(), | 271 base::string16(), |
271 base::FilePath(), | 272 base::FilePath(), |
272 &file_type_info, | 273 &file_type_info, |
273 0, | 274 0, |
274 base::FilePath::StringType(), | 275 base::FilePath::StringType(), |
275 browser->window()->GetNativeWindow(), | 276 browser->window()->GetNativeWindow(), |
276 NULL); | 277 NULL); |
277 } | 278 } |
278 | 279 |
279 } // namespace options | 280 } // namespace options |
OLD | NEW |