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

Side by Side Diff: chrome/browser/plugin_service.cc

Issue 2955005: Factor out PluginGroup into a separate class in common/. (Closed)
Patch Set: baseline updates Created 10 years, 5 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
« no previous file with comments | « chrome/browser/dom_ui/plugins_ui.cc ('k') | chrome/browser/plugin_updater.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "build/build_config.h" 5 #include "build/build_config.h"
6 6
7 #include "chrome/browser/plugin_service.h" 7 #include "chrome/browser/plugin_service.h"
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 #endif 53 #endif
54 54
55 // static 55 // static
56 bool PluginService::enable_chrome_plugins_ = true; 56 bool PluginService::enable_chrome_plugins_ = true;
57 57
58 // static 58 // static
59 void PluginService::InitGlobalInstance(Profile* profile) { 59 void PluginService::InitGlobalInstance(Profile* profile) {
60 DCHECK(ChromeThread::CurrentlyOn(ChromeThread::UI)); 60 DCHECK(ChromeThread::CurrentlyOn(ChromeThread::UI));
61 61
62 // We first group the plugins and then figure out which groups to disable. 62 // We first group the plugins and then figure out which groups to disable.
63 PluginUpdater::GetInstance()->DisablePluginGroupsFromPrefs(profile); 63 plugin_updater::DisablePluginGroupsFromPrefs(profile);
64 64
65 // Have Chrome plugins write their data to the profile directory. 65 // Have Chrome plugins write their data to the profile directory.
66 GetInstance()->SetChromePluginDataDir(profile->GetPath()); 66 GetInstance()->SetChromePluginDataDir(profile->GetPath());
67 } 67 }
68 68
69 // static 69 // static
70 PluginService* PluginService::GetInstance() { 70 PluginService* PluginService::GetInstance() {
71 return Singleton<PluginService>::get(); 71 return Singleton<PluginService>::get();
72 } 72 }
73 73
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 info.mime_types = ASCIIToWide(JoinString(plugins[i].mime_types, '|')); 371 info.mime_types = ASCIIToWide(JoinString(plugins[i].mime_types, '|'));
372 372
373 // These NPAPI entry points will never be called. TODO(darin): Come up 373 // These NPAPI entry points will never be called. TODO(darin): Come up
374 // with a cleaner way to register pepper plugins with the NPAPI PluginList, 374 // with a cleaner way to register pepper plugins with the NPAPI PluginList,
375 // or perhaps refactor the PluginList to be less specific to NPAPI. 375 // or perhaps refactor the PluginList to be less specific to NPAPI.
376 memset(&info.entry_points, 0, sizeof(info.entry_points)); 376 memset(&info.entry_points, 0, sizeof(info.entry_points));
377 377
378 NPAPI::PluginList::Singleton()->RegisterInternalPlugin(info); 378 NPAPI::PluginList::Singleton()->RegisterInternalPlugin(info);
379 } 379 }
380 } 380 }
OLDNEW
« no previous file with comments | « chrome/browser/dom_ui/plugins_ui.cc ('k') | chrome/browser/plugin_updater.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698