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

Side by Side Diff: content/renderer/renderer_blink_platform_impl.cc

Issue 1483733002: Remove support for NPObjects. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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
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/renderer/renderer_blink_platform_impl.h" 5 #include "content/renderer/renderer_blink_platform_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 11 matching lines...) Expand all
22 #include "cc/blink/context_provider_web_context.h" 22 #include "cc/blink/context_provider_web_context.h"
23 #include "components/scheduler/child/web_scheduler_impl.h" 23 #include "components/scheduler/child/web_scheduler_impl.h"
24 #include "components/scheduler/child/web_task_runner_impl.h" 24 #include "components/scheduler/child/web_task_runner_impl.h"
25 #include "components/scheduler/renderer/renderer_scheduler.h" 25 #include "components/scheduler/renderer/renderer_scheduler.h"
26 #include "components/scheduler/renderer/webthread_impl_for_renderer_scheduler.h" 26 #include "components/scheduler/renderer/webthread_impl_for_renderer_scheduler.h"
27 #include "components/url_formatter/url_formatter.h" 27 #include "components/url_formatter/url_formatter.h"
28 #include "content/child/database_util.h" 28 #include "content/child/database_util.h"
29 #include "content/child/file_info_util.h" 29 #include "content/child/file_info_util.h"
30 #include "content/child/fileapi/webfilesystem_impl.h" 30 #include "content/child/fileapi/webfilesystem_impl.h"
31 #include "content/child/indexed_db/webidbfactory_impl.h" 31 #include "content/child/indexed_db/webidbfactory_impl.h"
32 #include "content/child/npapi/npobject_util.h"
33 #include "content/child/quota_dispatcher.h" 32 #include "content/child/quota_dispatcher.h"
34 #include "content/child/quota_message_filter.h" 33 #include "content/child/quota_message_filter.h"
35 #include "content/child/simple_webmimeregistry_impl.h" 34 #include "content/child/simple_webmimeregistry_impl.h"
36 #include "content/child/storage_util.h" 35 #include "content/child/storage_util.h"
37 #include "content/child/thread_safe_sender.h" 36 #include "content/child/thread_safe_sender.h"
38 #include "content/child/web_database_observer_impl.h" 37 #include "content/child/web_database_observer_impl.h"
39 #include "content/child/web_url_loader_impl.h" 38 #include "content/child/web_url_loader_impl.h"
40 #include "content/child/webblobregistry_impl.h" 39 #include "content/child/webblobregistry_impl.h"
41 #include "content/child/webfileutilities_impl.h" 40 #include "content/child/webfileutilities_impl.h"
42 #include "content/child/webmessageportchannel_impl.h" 41 #include "content/child/webmessageportchannel_impl.h"
(...skipping 431 matching lines...) Expand 10 before | Expand all | Expand 10 after
474 std::vector<std::string> parsed_codec_ids; 473 std::vector<std::string> parsed_codec_ids;
475 media::ParseCodecString(ToASCIIOrEmpty(codecs), &parsed_codec_ids, false); 474 media::ParseCodecString(ToASCIIOrEmpty(codecs), &parsed_codec_ids, false);
476 if (mime_type_ascii.empty()) 475 if (mime_type_ascii.empty())
477 return false; 476 return false;
478 return media::StreamParserFactory::IsTypeSupported( 477 return media::StreamParserFactory::IsTypeSupported(
479 mime_type_ascii, parsed_codec_ids); 478 mime_type_ascii, parsed_codec_ids);
480 } 479 }
481 480
482 WebString RendererBlinkPlatformImpl::MimeRegistry::mimeTypeForExtension( 481 WebString RendererBlinkPlatformImpl::MimeRegistry::mimeTypeForExtension(
483 const WebString& file_extension) { 482 const WebString& file_extension) {
484 if (IsPluginProcess())
485 return SimpleWebMimeRegistryImpl::mimeTypeForExtension(file_extension);
486
487 // The sandbox restricts our access to the registry, so we need to proxy 483 // The sandbox restricts our access to the registry, so we need to proxy
488 // these calls over to the browser process. 484 // these calls over to the browser process.
489 std::string mime_type; 485 std::string mime_type;
490 RenderThread::Get()->Send( 486 RenderThread::Get()->Send(
491 new MimeRegistryMsg_GetMimeTypeFromExtension( 487 new MimeRegistryMsg_GetMimeTypeFromExtension(
492 blink::WebStringToFilePath(file_extension).value(), &mime_type)); 488 blink::WebStringToFilePath(file_extension).value(), &mime_type));
493 return base::ASCIIToUTF16(mime_type); 489 return base::ASCIIToUTF16(mime_type);
494 } 490 }
495 491
496 //------------------------------------------------------------------------------ 492 //------------------------------------------------------------------------------
(...skipping 766 matching lines...) Expand 10 before | Expand all | Expand 10 after
1263 } 1259 }
1264 1260
1265 //------------------------------------------------------------------------------ 1261 //------------------------------------------------------------------------------
1266 1262
1267 blink::WebTrialTokenValidator* 1263 blink::WebTrialTokenValidator*
1268 RendererBlinkPlatformImpl::trialTokenValidator() { 1264 RendererBlinkPlatformImpl::trialTokenValidator() {
1269 return &trial_token_validator_; 1265 return &trial_token_validator_;
1270 } 1266 }
1271 1267
1272 } // namespace content 1268 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698