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

Side by Side Diff: content/browser/plugin_service_impl.cc

Issue 271753006: Linux: Remove some unused NPAPI code. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 6 years, 7 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
« no previous file with comments | « no previous file | content/common/plugin_list.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) 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 "content/browser/plugin_service_impl.h" 5 #include "content/browser/plugin_service_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after
754 } 754 }
755 base::TimeDelta delta = base::Time::Now() - i->second[0]; 755 base::TimeDelta delta = base::Time::Now() - i->second[0];
756 return delta.InSeconds() <= kCrashesInterval; 756 return delta.InSeconds() <= kCrashesInterval;
757 } 757 }
758 758
759 void PluginServiceImpl::RefreshPlugins() { 759 void PluginServiceImpl::RefreshPlugins() {
760 PluginList::Singleton()->RefreshPlugins(); 760 PluginList::Singleton()->RefreshPlugins();
761 } 761 }
762 762
763 void PluginServiceImpl::AddExtraPluginPath(const base::FilePath& path) { 763 void PluginServiceImpl::AddExtraPluginPath(const base::FilePath& path) {
764 if (!NPAPIPluginsSupported()) { 764 if (!NPAPIPluginsSupported()) {
765 // TODO(jam): remove and just have CHECK once we're sure this doesn't get 765 // TODO(jam): remove and just have CHECK once we're sure this doesn't get
766 // triggered. 766 // triggered.
767 DVLOG(0) << "NPAPI plugins not supported"; 767 DVLOG(0) << "NPAPI plugins not supported";
768 return; 768 return;
769 } 769 }
770 PluginList::Singleton()->AddExtraPluginPath(path); 770 PluginList::Singleton()->AddExtraPluginPath(path);
771 } 771 }
772 772
773 void PluginServiceImpl::RemoveExtraPluginPath(const base::FilePath& path) { 773 void PluginServiceImpl::RemoveExtraPluginPath(const base::FilePath& path) {
774 PluginList::Singleton()->RemoveExtraPluginPath(path); 774 PluginList::Singleton()->RemoveExtraPluginPath(path);
(...skipping 17 matching lines...) Expand all
792 void PluginServiceImpl::UnregisterInternalPlugin(const base::FilePath& path) { 792 void PluginServiceImpl::UnregisterInternalPlugin(const base::FilePath& path) {
793 PluginList::Singleton()->UnregisterInternalPlugin(path); 793 PluginList::Singleton()->UnregisterInternalPlugin(path);
794 } 794 }
795 795
796 void PluginServiceImpl::GetInternalPlugins( 796 void PluginServiceImpl::GetInternalPlugins(
797 std::vector<WebPluginInfo>* plugins) { 797 std::vector<WebPluginInfo>* plugins) {
798 PluginList::Singleton()->GetInternalPlugins(plugins); 798 PluginList::Singleton()->GetInternalPlugins(plugins);
799 } 799 }
800 800
801 bool PluginServiceImpl::NPAPIPluginsSupported() { 801 bool PluginServiceImpl::NPAPIPluginsSupported() {
802 #if defined(OS_WIN) || defined(OS_MACOSX) || defined(OS_BSD) || \ 802 #if defined(OS_WIN) || defined(OS_MACOSX)
803 (defined(OS_LINUX) && !defined(USE_AURA))
804 return true; 803 return true;
805 #else 804 #else
806 return false; 805 return false;
807 #endif 806 #endif
808 } 807 }
809 808
810 void PluginServiceImpl::DisablePluginsDiscoveryForTesting() { 809 void PluginServiceImpl::DisablePluginsDiscoveryForTesting() {
811 PluginList::Singleton()->DisablePluginsDiscovery(); 810 PluginList::Singleton()->DisablePluginsDiscovery();
812 } 811 }
813 812
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
852 return gfx::GetClassName(window) == base::string16(kNativeWindowClassName); 851 return gfx::GetClassName(window) == base::string16(kNativeWindowClassName);
853 } 852 }
854 #endif 853 #endif
855 854
856 bool PluginServiceImpl::PpapiDevChannelSupported() { 855 bool PluginServiceImpl::PpapiDevChannelSupported() {
857 return content::GetContentClient()->browser()-> 856 return content::GetContentClient()->browser()->
858 IsPluginAllowedToUseDevChannelAPIs(); 857 IsPluginAllowedToUseDevChannelAPIs();
859 } 858 }
860 859
861 } // namespace content 860 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/common/plugin_list.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698