OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #include "base/prefs/pref_service.h" | |
6 #include "chrome/browser/browser_process.h" | |
7 #include "chrome/browser/chromeos/oobe/oobe.h" | |
8 #include "chrome/browser/lifetime/application_lifetime.h" | |
9 #include "chrome/browser/profiles/profile.h" | |
10 #include "chrome/common/pref_names.h" | |
11 | |
12 void Oobe::Register() { | |
Nikita (slow)
2015/02/24 15:32:41
nit: Add // static
comment
Ivan Podogov
2015/02/24 16:33:20
Done.
| |
13 gen::OobeViewModel::SetFactory( | |
14 [](content::BrowserContext* context) -> gen::OobeViewModel* { | |
15 return new Oobe(Profile::FromBrowserContext(context)); | |
16 }); | |
17 } | |
18 | |
19 Oobe::Oobe(Profile* profile) : profile_(profile) { | |
20 } | |
21 | |
22 Oobe::~Oobe() { | |
23 } | |
24 | |
25 void Oobe::Initialize() { | |
26 } | |
27 | |
28 void Oobe::OnButtonClicked() { | |
29 g_browser_process->local_state()->SetBoolean(prefs::kNewOobe, false); | |
30 chrome::AttemptRestart(); | |
31 } | |
OLD | NEW |