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

Side by Side Diff: chrome/browser/chromeos/login/screens/error_screen.h

Issue 494633003: UMA: How often are different network error screens encountered during OOBE (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 4 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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_ERROR_SCREEN_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_ERROR_SCREEN_H_
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_ERROR_SCREEN_H_ 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_ERROR_SCREEN_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 18 matching lines...) Expand all
29 UI_STATE_UPDATE, 29 UI_STATE_UPDATE,
30 UI_STATE_SIGNIN, 30 UI_STATE_SIGNIN,
31 UI_STATE_SUPERVISED, 31 UI_STATE_SUPERVISED,
32 UI_STATE_KIOSK_MODE, 32 UI_STATE_KIOSK_MODE,
33 UI_STATE_LOCAL_STATE_ERROR, 33 UI_STATE_LOCAL_STATE_ERROR,
34 UI_STATE_AUTO_ENROLLMENT_ERROR, 34 UI_STATE_AUTO_ENROLLMENT_ERROR,
35 UI_STATE_ROLLBACK_ERROR, 35 UI_STATE_ROLLBACK_ERROR,
36 }; 36 };
37 37
38 enum ErrorState { 38 enum ErrorState {
39 ERROR_STATE_UNKNOWN = 0, 39 ERROR_STATE_NONE = 0,
40 ERROR_STATE_PORTAL, 40 ERROR_STATE_PORTAL,
41 ERROR_STATE_OFFLINE, 41 ERROR_STATE_OFFLINE,
42 ERROR_STATE_PROXY, 42 ERROR_STATE_PROXY,
43 ERROR_STATE_AUTH_EXT_TIMEOUT, 43 ERROR_STATE_AUTH_EXT_TIMEOUT,
44 ERROR_STATE_KIOSK_ONLINE 44 // States above are being logged to histograms.
45 ERROR_STATE_KIOSK_ONLINE,
46 ERROR_STATE_UNKNOWN
45 }; 47 };
48 static const int kHistogramErrorStateNum = 5;
46 49
47 ErrorScreen(ScreenObserver* screen_observer, ErrorScreenActor* actor); 50 ErrorScreen(ScreenObserver* screen_observer, ErrorScreenActor* actor);
48 virtual ~ErrorScreen(); 51 virtual ~ErrorScreen();
49 52
50 // WizardScreen implementation. 53 // WizardScreen implementation.
51 virtual void PrepareToShow() OVERRIDE; 54 virtual void PrepareToShow() OVERRIDE;
52 virtual void Show() OVERRIDE; 55 virtual void Show() OVERRIDE;
53 virtual void Hide() OVERRIDE; 56 virtual void Hide() OVERRIDE;
54 virtual std::string GetName() const OVERRIDE; 57 virtual std::string GetName() const OVERRIDE;
55 58
(...skipping 23 matching lines...) Expand all
79 82
80 // Sets current UI state. 83 // Sets current UI state.
81 void SetUIState(UIState ui_state); 84 void SetUIState(UIState ui_state);
82 85
83 UIState GetUIState() const; 86 UIState GetUIState() const;
84 87
85 // Sets current error screen content according to current UI state, 88 // Sets current error screen content according to current UI state,
86 // |error_state|, and |network|. 89 // |error_state|, and |network|.
87 void SetErrorState(ErrorState error_state, const std::string& network); 90 void SetErrorState(ErrorState error_state, const std::string& network);
88 91
92 ErrorState GetErrorState() const;
93
89 // Toggles the guest sign-in prompt. 94 // Toggles the guest sign-in prompt.
90 void AllowGuestSignin(bool allow); 95 void AllowGuestSignin(bool allow);
91 96
92 // Toggles the connection pending indicator. 97 // Toggles the connection pending indicator.
93 void ShowConnectingIndicator(bool show); 98 void ShowConnectingIndicator(bool show);
94 99
95 void set_parent_screen(OobeDisplay::Screen parent_screen) { 100 void set_parent_screen(OobeDisplay::Screen parent_screen) {
96 parent_screen_ = parent_screen; 101 parent_screen_ = parent_screen;
97 } 102 }
98 OobeDisplay::Screen parent_screen() const { return parent_screen_; } 103 OobeDisplay::Screen parent_screen() const { return parent_screen_; }
(...skipping 13 matching lines...) Expand all
112 scoped_ptr<LoginPerformer> guest_login_performer_; 117 scoped_ptr<LoginPerformer> guest_login_performer_;
113 118
114 base::WeakPtrFactory<ErrorScreen> weak_factory_; 119 base::WeakPtrFactory<ErrorScreen> weak_factory_;
115 120
116 DISALLOW_COPY_AND_ASSIGN(ErrorScreen); 121 DISALLOW_COPY_AND_ASSIGN(ErrorScreen);
117 }; 122 };
118 123
119 } // namespace chromeos 124 } // namespace chromeos
120 125
121 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_ERROR_SCREEN_H_ 126 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_ERROR_SCREEN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698