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

Side by Side Diff: webkit/plugins/ppapi/ppb_flash_impl.cc

Issue 11413200: Refactored PPB_Flash GetSettings to the new pepper resource model (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 "webkit/plugins/ppapi/ppb_flash_impl.h" 5 #include "webkit/plugins/ppapi/ppb_flash_impl.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "googleurl/src/gurl.h" 10 #include "googleurl/src/gurl.h"
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 return instance_->delegate()->GetLocalTimeZoneOffset(PPTimeToTime(t)); 183 return instance_->delegate()->GetLocalTimeZoneOffset(PPTimeToTime(t));
184 } 184 }
185 185
186 PP_Bool PPB_Flash_Impl::IsRectTopmost(PP_Instance instance, 186 PP_Bool PPB_Flash_Impl::IsRectTopmost(PP_Instance instance,
187 const PP_Rect* rect) { 187 const PP_Rect* rect) {
188 return PP_FromBool(instance_->IsRectTopmost( 188 return PP_FromBool(instance_->IsRectTopmost(
189 gfx::Rect(rect->point.x, rect->point.y, 189 gfx::Rect(rect->point.x, rect->point.y,
190 rect->size.width, rect->size.height))); 190 rect->size.width, rect->size.height)));
191 } 191 }
192 192
193 PP_Var PPB_Flash_Impl::GetSetting(PP_Instance instance,
194 PP_FlashSetting setting) {
195 switch(setting) {
196 case PP_FLASHSETTING_LSORESTRICTIONS: {
197 return PP_MakeInt32(
198 instance_->delegate()->GetLocalDataRestrictions(
199 instance_->container()->element().document().url(),
200 instance_->plugin_url()));
201 }
202 default:
203 // No other settings are supported in-process.
204 return PP_MakeUndefined();
205 }
206 }
207
208 } // namespace ppapi 193 } // namespace ppapi
209 } // namespace webkit 194 } // namespace webkit
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698