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

Side by Side Diff: components/password_manager/core/browser/password_manager_util.h

Issue 2376123003: [Sync] Move //components/sync to the syncer namespace. (Closed)
Patch Set: Rebase. 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_MANAGER_UTIL_H_ 5 #ifndef COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_MANAGER_UTIL_H_
6 #define COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_MANAGER_UTIL_H_ 6 #define COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_MANAGER_UTIL_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/callback.h" 11 #include "base/callback.h"
12 #include "base/memory/scoped_vector.h" 12 #include "base/memory/scoped_vector.h"
13 #include "components/password_manager/core/browser/password_manager_client.h" 13 #include "components/password_manager/core/browser/password_manager_client.h"
14 #include "ui/gfx/native_widget_types.h" 14 #include "ui/gfx/native_widget_types.h"
15 15
16 namespace autofill { 16 namespace autofill {
17 struct PasswordForm; 17 struct PasswordForm;
18 } 18 }
19 19
20 namespace sync_driver { 20 namespace syncer {
21 class SyncService; 21 class SyncService;
22 } 22 }
23 23
24 namespace password_manager_util { 24 namespace password_manager_util {
25 25
26 // Reports whether and how passwords are currently synced. In particular, for a 26 // Reports whether and how passwords are currently synced. In particular, for a
27 // null |sync_service| returns NOT_SYNCING_PASSWORDS. 27 // null |sync_service| returns NOT_SYNCING_PASSWORDS.
28 password_manager::PasswordSyncState GetPasswordSyncState( 28 password_manager::PasswordSyncState GetPasswordSyncState(
29 const sync_driver::SyncService* sync_service); 29 const syncer::SyncService* sync_service);
30 30
31 // Finds the forms with a duplicate sync tags in |forms|. The first one of 31 // Finds the forms with a duplicate sync tags in |forms|. The first one of
32 // the duplicated entries stays in |forms|, the others are moved to 32 // the duplicated entries stays in |forms|, the others are moved to
33 // |duplicates|. 33 // |duplicates|.
34 // |tag_groups| is optional. It will contain |forms| and |duplicates| grouped by 34 // |tag_groups| is optional. It will contain |forms| and |duplicates| grouped by
35 // the sync tag. The first element in each group is one from |forms|. It's 35 // the sync tag. The first element in each group is one from |forms|. It's
36 // followed by the duplicates. 36 // followed by the duplicates.
37 void FindDuplicates( 37 void FindDuplicates(
38 ScopedVector<autofill::PasswordForm>* forms, 38 ScopedVector<autofill::PasswordForm>* forms,
39 ScopedVector<autofill::PasswordForm>* duplicates, 39 ScopedVector<autofill::PasswordForm>* duplicates,
(...skipping 11 matching lines...) Expand all
51 51
52 // A convenience function for testing that |client| has a non-null LogManager 52 // A convenience function for testing that |client| has a non-null LogManager
53 // and that that LogManager returns true for IsLoggingActive. This function can 53 // and that that LogManager returns true for IsLoggingActive. This function can
54 // be removed once PasswordManagerClient::GetLogManager is implemented on iOS 54 // be removed once PasswordManagerClient::GetLogManager is implemented on iOS
55 // and required to always return non-null. 55 // and required to always return non-null.
56 bool IsLoggingActive(const password_manager::PasswordManagerClient* client); 56 bool IsLoggingActive(const password_manager::PasswordManagerClient* client);
57 57
58 } // namespace password_manager_util 58 } // namespace password_manager_util
59 59
60 #endif // COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_MANAGER_UTIL_H_ 60 #endif // COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_MANAGER_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698