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 #import "ios/chrome/browser/signin/browser_state_data_remover.h" | 5 #import "ios/chrome/browser/signin/browser_state_data_remover.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
9 #include "base/prefs/pref_service.h" | 9 #include "components/prefs/pref_service.h" |
10 #include "components/signin/core/common/signin_pref_names.h" | 10 #include "components/signin/core/common/signin_pref_names.h" |
11 #include "ios/chrome/browser/bookmarks/bookmarks_utils.h" | 11 #include "ios/chrome/browser/bookmarks/bookmarks_utils.h" |
12 #import "ios/chrome/browser/ui/commands/UIKit+ChromeExecuteCommand.h" | 12 #import "ios/chrome/browser/ui/commands/UIKit+ChromeExecuteCommand.h" |
13 #import "ios/chrome/browser/ui/commands/clear_browsing_data_command.h" | 13 #import "ios/chrome/browser/ui/commands/clear_browsing_data_command.h" |
14 #include "ios/public/provider/chrome/browser/browser_state/chrome_browser_state.
h" | 14 #include "ios/public/provider/chrome/browser/browser_state/chrome_browser_state.
h" |
15 | 15 |
16 namespace { | 16 namespace { |
17 const int kRemoveAllDataMask = ~0; | 17 const int kRemoveAllDataMask = ~0; |
18 } | 18 } |
19 | 19 |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 if (forget_last_username_) { | 64 if (forget_last_username_) { |
65 browser_state_->GetPrefs()->ClearPref(prefs::kGoogleServicesLastAccountId); | 65 browser_state_->GetPrefs()->ClearPref(prefs::kGoogleServicesLastAccountId); |
66 browser_state_->GetPrefs()->ClearPref(prefs::kGoogleServicesLastUsername); | 66 browser_state_->GetPrefs()->ClearPref(prefs::kGoogleServicesLastUsername); |
67 } | 67 } |
68 | 68 |
69 if (callback_) | 69 if (callback_) |
70 callback_.get()(); | 70 callback_.get()(); |
71 | 71 |
72 base::MessageLoop::current()->DeleteSoon(FROM_HERE, this); | 72 base::MessageLoop::current()->DeleteSoon(FROM_HERE, this); |
73 } | 73 } |
OLD | NEW |