OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/ui/webui/options/options_browsertest.h" | 5 #include "chrome/browser/ui/webui/options/options_browsertest.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/prefs/pref_service.h" | |
9 #include "base/values.h" | 8 #include "base/values.h" |
10 #include "chrome/browser/profiles/profile.h" | 9 #include "chrome/browser/profiles/profile.h" |
11 #include "chrome/browser/ui/browser.h" | 10 #include "chrome/browser/ui/browser.h" |
12 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 11 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
| 12 #include "components/prefs/pref_service.h" |
13 #include "content/public/browser/navigation_controller.h" | 13 #include "content/public/browser/navigation_controller.h" |
14 #include "content/public/browser/navigation_entry.h" | 14 #include "content/public/browser/navigation_entry.h" |
15 #include "content/public/browser/web_contents.h" | 15 #include "content/public/browser/web_contents.h" |
16 #include "content/public/browser/web_ui.h" | 16 #include "content/public/browser/web_ui.h" |
17 #include "url/gurl.h" | 17 #include "url/gurl.h" |
18 | 18 |
19 using content::NavigationController; | 19 using content::NavigationController; |
20 using content::NavigationEntry; | 20 using content::NavigationEntry; |
21 using content::WebUIMessageHandler; | 21 using content::WebUIMessageHandler; |
22 | 22 |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 ASSERT_TRUE(args->GetString(0, &pref_name)); | 61 ASSERT_TRUE(args->GetString(0, &pref_name)); |
62 const base::Value* pref_value; | 62 const base::Value* pref_value; |
63 ASSERT_TRUE(args->Get(1, &pref_value)); | 63 ASSERT_TRUE(args->Get(1, &pref_value)); |
64 | 64 |
65 browser()->profile()->GetPrefs()->Set(pref_name.c_str(), *pref_value); | 65 browser()->profile()->GetPrefs()->Set(pref_name.c_str(), *pref_value); |
66 } | 66 } |
67 | 67 |
68 content::WebUIMessageHandler* OptionsBrowserTest::GetMockMessageHandler() { | 68 content::WebUIMessageHandler* OptionsBrowserTest::GetMockMessageHandler() { |
69 return this; | 69 return this; |
70 } | 70 } |
OLD | NEW |