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

Side by Side Diff: chrome/browser/chromeos/login/screens/user_image_screen.cc

Issue 2705363002: cros: Move BaseScreenDelegate::ExitCodes into separate file, ScreenExitCode. (Closed)
Patch Set: Rebase Created 3 years, 9 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/chromeos/login/screens/user_image_screen.h" 5 #include "chrome/browser/chromeos/login/screens/user_image_screen.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 } 327 }
328 if (view_) 328 if (view_)
329 view_->HideCurtain(); 329 view_->HideCurtain();
330 } 330 }
331 331
332 void UserImageScreen::ExitScreen() { 332 void UserImageScreen::ExitScreen() {
333 policy_registrar_.reset(); 333 policy_registrar_.reset();
334 sync_timer_.reset(); 334 sync_timer_.reset();
335 if (UserImageSyncObserver* sync_observer = GetSyncObserver()) 335 if (UserImageSyncObserver* sync_observer = GetSyncObserver())
336 sync_observer->RemoveObserver(this); 336 sync_observer->RemoveObserver(this);
337 Finish(BaseScreenDelegate::USER_IMAGE_SELECTED); 337 Finish(ScreenExitCode::USER_IMAGE_SELECTED);
338 } 338 }
339 339
340 void UserImageScreen::ReportSyncResult(SyncResult timed_out) const { 340 void UserImageScreen::ReportSyncResult(SyncResult timed_out) const {
341 base::TimeDelta duration = base::Time::Now() - sync_waiting_start_time_; 341 base::TimeDelta duration = base::Time::Now() - sync_waiting_start_time_;
342 UMA_HISTOGRAM_TIMES("Login.NewUserPriorityPrefsSyncTime", duration); 342 UMA_HISTOGRAM_TIMES("Login.NewUserPriorityPrefsSyncTime", duration);
343 UMA_HISTOGRAM_ENUMERATION("Login.NewUserPriorityPrefsSyncResult", 343 UMA_HISTOGRAM_ENUMERATION("Login.NewUserPriorityPrefsSyncResult",
344 static_cast<int>(timed_out), 344 static_cast<int>(timed_out),
345 static_cast<int>(SyncResult::COUNT)); 345 static_cast<int>(SyncResult::COUNT));
346 } 346 }
347 347
348 } // namespace chromeos 348 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698