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

Side by Side Diff: chrome/browser/importer/profile_writer.cc

Issue 23742004: Move PasswordForm from //content to //autofill. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_password_form_conversion_utils
Patch Set: Rebase Created 7 years, 3 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/importer/profile_writer.h" 5 #include "chrome/browser/importer/profile_writer.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 10
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 ProfileWriter::ProfileWriter(Profile* profile) : profile_(profile) {} 72 ProfileWriter::ProfileWriter(Profile* profile) : profile_(profile) {}
73 73
74 bool ProfileWriter::BookmarkModelIsLoaded() const { 74 bool ProfileWriter::BookmarkModelIsLoaded() const {
75 return BookmarkModelFactory::GetForProfile(profile_)->loaded(); 75 return BookmarkModelFactory::GetForProfile(profile_)->loaded();
76 } 76 }
77 77
78 bool ProfileWriter::TemplateURLServiceIsLoaded() const { 78 bool ProfileWriter::TemplateURLServiceIsLoaded() const {
79 return TemplateURLServiceFactory::GetForProfile(profile_)->loaded(); 79 return TemplateURLServiceFactory::GetForProfile(profile_)->loaded();
80 } 80 }
81 81
82 void ProfileWriter::AddPasswordForm(const content::PasswordForm& form) { 82 void ProfileWriter::AddPasswordForm(const autofill::PasswordForm& form) {
83 PasswordStoreFactory::GetForProfile( 83 PasswordStoreFactory::GetForProfile(
84 profile_, Profile::EXPLICIT_ACCESS)->AddLogin(form); 84 profile_, Profile::EXPLICIT_ACCESS)->AddLogin(form);
85 } 85 }
86 86
87 #if defined(OS_WIN) 87 #if defined(OS_WIN)
88 void ProfileWriter::AddIE7PasswordInfo(const IE7PasswordInfo& info) { 88 void ProfileWriter::AddIE7PasswordInfo(const IE7PasswordInfo& info) {
89 WebDataService::FromBrowserContext(profile_)->AddIE7Login(info); 89 WebDataService::FromBrowserContext(profile_)->AddIE7Login(info);
90 } 90 }
91 #endif 91 #endif
92 92
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
310 310
311 // Only add valid TemplateURLs to the model. 311 // Only add valid TemplateURLs to the model.
312 if ((*i)->url_ref().IsValid()) { 312 if ((*i)->url_ref().IsValid()) {
313 model->AddAndSetProfile(*i, profile_); // Takes ownership. 313 model->AddAndSetProfile(*i, profile_); // Takes ownership.
314 *i = NULL; // Prevent the vector from deleting *i later. 314 *i = NULL; // Prevent the vector from deleting *i later.
315 } 315 }
316 } 316 }
317 } 317 }
318 318
319 ProfileWriter::~ProfileWriter() {} 319 ProfileWriter::~ProfileWriter() {}
OLDNEW
« no previous file with comments | « chrome/browser/importer/profile_writer.h ('k') | chrome/browser/password_manager/login_database.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698