| OLD | NEW |
| 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 <stddef.h> | 5 #include <stddef.h> |
| 6 #include <stdint.h> | 6 #include <stdint.h> |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 488 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 499 bool ok = false; | 499 bool ok = false; |
| 500 plugin_prefs->EnablePlugin(enabled, plugin->path, | 500 plugin_prefs->EnablePlugin(enabled, plugin->path, |
| 501 base::Bind(CopyValueAndQuit<bool>, &ok)); | 501 base::Bind(CopyValueAndQuit<bool>, &ok)); |
| 502 content::RunMessageLoop(); | 502 content::RunMessageLoop(); |
| 503 return ok; | 503 return ok; |
| 504 } | 504 } |
| 505 | 505 |
| 506 int CountPluginsOnIOThread() { | 506 int CountPluginsOnIOThread() { |
| 507 int count = 0; | 507 int count = 0; |
| 508 for (content::BrowserChildProcessHostIterator iter; !iter.Done(); ++iter) { | 508 for (content::BrowserChildProcessHostIterator iter; !iter.Done(); ++iter) { |
| 509 if (iter.GetData().process_type == content::PROCESS_TYPE_PLUGIN || | 509 if (iter.GetData().process_type == content::PROCESS_TYPE_PPAPI_PLUGIN) { |
| 510 iter.GetData().process_type == content::PROCESS_TYPE_PPAPI_PLUGIN) { | |
| 511 count++; | 510 count++; |
| 512 } | 511 } |
| 513 } | 512 } |
| 514 return count; | 513 return count; |
| 515 } | 514 } |
| 516 | 515 |
| 517 int CountPlugins() { | 516 int CountPlugins() { |
| 518 int count = -1; | 517 int count = -1; |
| 519 BrowserThread::PostTaskAndReplyWithResult( | 518 BrowserThread::PostTaskAndReplyWithResult( |
| 520 BrowserThread::IO, FROM_HERE, | 519 BrowserThread::IO, FROM_HERE, |
| (...skipping 3706 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4227 | 4226 |
| 4228 SetEmptyPolicy(); | 4227 SetEmptyPolicy(); |
| 4229 // Policy not set. | 4228 // Policy not set. |
| 4230 CheckSystemTimezoneAutomaticDetectionPolicyUnset(); | 4229 CheckSystemTimezoneAutomaticDetectionPolicyUnset(); |
| 4231 EXPECT_TRUE(CheckResolveTimezoneByGeolocation(true, false)); | 4230 EXPECT_TRUE(CheckResolveTimezoneByGeolocation(true, false)); |
| 4232 EXPECT_TRUE(manager->TimeZoneResolverShouldBeRunningForTests()); | 4231 EXPECT_TRUE(manager->TimeZoneResolverShouldBeRunningForTests()); |
| 4233 } | 4232 } |
| 4234 #endif // defined(OS_CHROMEOS) | 4233 #endif // defined(OS_CHROMEOS) |
| 4235 | 4234 |
| 4236 } // namespace policy | 4235 } // namespace policy |
| OLD | NEW |