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

Side by Side Diff: chrome/browser/ui/webui/options/browser_options_handler.h

Issue 15774008: Pass errors generated during limited-user registration up to the UI for display. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Addressed James's comments Created 7 years, 6 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 | Annotate | Revision Log
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_UI_WEBUI_OPTIONS_BROWSER_OPTIONS_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS_BROWSER_OPTIONS_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_BROWSER_OPTIONS_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_BROWSER_OPTIONS_HANDLER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 // name: "Profile Name", 137 // name: "Profile Name",
138 // iconURL: "chrome://path/to/icon/image", 138 // iconURL: "chrome://path/to/icon/image",
139 // filePath: "/path/to/profile/data/on/disk", 139 // filePath: "/path/to/profile/data/on/disk",
140 // isCurrentProfile: false 140 // isCurrentProfile: false
141 // }; 141 // };
142 scoped_ptr<ListValue> GetProfilesInfoList(); 142 scoped_ptr<ListValue> GetProfilesInfoList();
143 143
144 // Sends an array of Profile objects to javascript. 144 // Sends an array of Profile objects to javascript.
145 void SendProfilesInfo(); 145 void SendProfilesInfo();
146 146
147 // Asynchronously opens a new browser window to create a new profile. 147 // Asynchronously creates and initializes a new profile.
148 // The arguments are as follows: 148 // The arguments are as follows:
149 // 0: name (string) 149 // 0: name (string)
150 // 1: icon (string) 150 // 1: icon (string)
151 // 2: a flag stating whether we should create a profile desktop shortcut 151 // 2: a flag stating whether we should create a profile desktop shortcut
152 // (optional, boolean) 152 // (optional, boolean)
153 // 3: a flag stating whether the user should be managed (optional, boolean) 153 // 3: a flag stating whether the user should be managed (optional, boolean)
154 void CreateProfile(const base::ListValue* args); 154 void CreateProfile(const base::ListValue* args);
155 155
156 // Handles final tasks when a new profile has been created, running any queued 156 // After a new managed-user profile has been created, registers the user with
157 // callbacks and updating the UI. 157 // the management server. This is a class method to ensure that the
158 void OnProfileCreated( 158 // registration service (on the custodian's profile, along with this WebUI
159 // class) still exists after the new managed profile has been created
160 // asynchronously.
161 void RegisterNewManagedUser(const ProfileManager::CreateCallback& callback,
162 Profile* profile,
163 Profile::CreateStatus status);
164
165 // Updates the UI as the final task after a new profile has been created.
166 void ShowProfileCreationFeedback(
159 chrome::HostDesktopType desktop_type, 167 chrome::HostDesktopType desktop_type,
160 bool is_managed, 168 bool is_managed,
161 const std::vector<ProfileManager::CreateCallback>& callbacks,
162 Profile* profile, 169 Profile* profile,
163 Profile::CreateStatus status); 170 Profile::CreateStatus status);
164 171
172 // Deletes the given profile. Expects one argument:
173 // 0: profile file path (string)
174 void DeleteProfile(const base::ListValue* args);
175
176 // Deletes the profile at the given |file_path|.
177 void DeleteProfileAtPath(base::FilePath file_path);
178
165 void ObserveThemeChanged(); 179 void ObserveThemeChanged();
166 void ThemesReset(const base::ListValue* args); 180 void ThemesReset(const base::ListValue* args);
167 #if defined(TOOLKIT_GTK) 181 #if defined(TOOLKIT_GTK)
168 void ThemesSetGTK(const base::ListValue* args); 182 void ThemesSetGTK(const base::ListValue* args);
169 #endif 183 #endif
170 184
171 #if defined(OS_CHROMEOS) 185 #if defined(OS_CHROMEOS)
172 void UpdateAccountPicture(); 186 void UpdateAccountPicture();
173 #endif 187 #endif
174 188
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 DoublePrefMember default_zoom_level_; 323 DoublePrefMember default_zoom_level_;
310 324
311 PrefChangeRegistrar profile_pref_registrar_; 325 PrefChangeRegistrar profile_pref_registrar_;
312 326
313 DISALLOW_COPY_AND_ASSIGN(BrowserOptionsHandler); 327 DISALLOW_COPY_AND_ASSIGN(BrowserOptionsHandler);
314 }; 328 };
315 329
316 } // namespace options 330 } // namespace options
317 331
318 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_BROWSER_OPTIONS_HANDLER_H_ 332 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_BROWSER_OPTIONS_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698