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

Side by Side Diff: content/renderer/pepper/content_renderer_pepper_host_factory.cc

Issue 12310041: experiment with -Wimplicit-fallthrough Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: rebase Created 6 years, 12 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
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/pepper/content_renderer_pepper_host_factory.h" 5 #include "content/renderer/pepper/content_renderer_pepper_host_factory.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/strings/string_util.h" 8 #include "base/strings/string_util.h"
9 #include "content/public/common/content_client.h" 9 #include "content/public/common/content_client.h"
10 #include "content/public/renderer/content_renderer_client.h" 10 #include "content/public/renderer/content_renderer_client.h"
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 return scoped_ptr<ResourceHost>(new PepperWebSocketHost( 122 return scoped_ptr<ResourceHost>(new PepperWebSocketHost(
123 host_, instance, params.pp_resource())); 123 host_, instance, params.pp_resource()));
124 #if defined(ENABLE_WEBRTC) 124 #if defined(ENABLE_WEBRTC)
125 // These private MediaStream interfaces are exposed as if they were public 125 // These private MediaStream interfaces are exposed as if they were public
126 // so they can be used by NaCl plugins. However, they are available only 126 // so they can be used by NaCl plugins. However, they are available only
127 // for whitelisted apps. 127 // for whitelisted apps.
128 case PpapiHostMsg_VideoDestination_Create::ID: 128 case PpapiHostMsg_VideoDestination_Create::ID:
129 if (CanUseMediaStreamAPI(host_, instance)) 129 if (CanUseMediaStreamAPI(host_, instance))
130 return scoped_ptr<ResourceHost>(new PepperVideoDestinationHost( 130 return scoped_ptr<ResourceHost>(new PepperVideoDestinationHost(
131 host_, instance, params.pp_resource())); 131 host_, instance, params.pp_resource()));
132 break;
132 case PpapiHostMsg_VideoSource_Create::ID: 133 case PpapiHostMsg_VideoSource_Create::ID:
133 if (CanUseMediaStreamAPI(host_, instance)) 134 if (CanUseMediaStreamAPI(host_, instance))
134 return scoped_ptr<ResourceHost>(new PepperVideoSourceHost( 135 return scoped_ptr<ResourceHost>(new PepperVideoSourceHost(
135 host_, instance, params.pp_resource())); 136 host_, instance, params.pp_resource()));
136 #endif // defined(ENABLE_WEBRTC) 137 #endif // defined(ENABLE_WEBRTC)
137 } 138 }
138 139
139 // Dev interfaces. 140 // Dev interfaces.
140 if (GetPermissions().HasPermission(ppapi::PERMISSION_DEV)) { 141 if (GetPermissions().HasPermission(ppapi::PERMISSION_DEV)) {
141 switch (message.type()) { 142 switch (message.type()) {
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 175
175 return scoped_ptr<ResourceHost>(); 176 return scoped_ptr<ResourceHost>();
176 } 177 }
177 178
178 const ppapi::PpapiPermissions& 179 const ppapi::PpapiPermissions&
179 ContentRendererPepperHostFactory::GetPermissions() const { 180 ContentRendererPepperHostFactory::GetPermissions() const {
180 return host_->GetPpapiHost()->permissions(); 181 return host_->GetPpapiHost()->permissions();
181 } 182 }
182 183
183 } // namespace content 184 } // namespace content
OLDNEW
« no previous file with comments | « content/common/gpu/client/gl_helper_scaling.cc ('k') | content/renderer/pepper/pepper_platform_context_3d.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698