OLD | NEW |
---|---|
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 "chrome/renderer/pepper/ppb_nacl_private_impl.h" | 5 #include "chrome/renderer/pepper/ppb_nacl_private_impl.h" |
6 | 6 |
7 #ifndef DISABLE_NACL | 7 #ifndef DISABLE_NACL |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/lazy_instance.h" | 10 #include "base/lazy_instance.h" |
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
300 | 300 |
301 if (transit_fd == IPC::InvalidPlatformFileForTransit()) { | 301 if (transit_fd == IPC::InvalidPlatformFileForTransit()) { |
302 return base::kInvalidPlatformFileValue; | 302 return base::kInvalidPlatformFileValue; |
303 } | 303 } |
304 | 304 |
305 base::PlatformFile handle = IPC::PlatformFileForTransitToPlatformFile( | 305 base::PlatformFile handle = IPC::PlatformFileForTransitToPlatformFile( |
306 transit_fd); | 306 transit_fd); |
307 return handle; | 307 return handle; |
308 } | 308 } |
309 | 309 |
310 PP_Bool IsOffTheRecord() { | |
311 bool is_off_the_record; | |
312 content::RenderThread::Get()->Send(new ChromeViewHostMsg_IsOffTheRecord( | |
313 &is_off_the_record)); | |
314 if (is_off_the_record) { | |
brettw
2012/08/02 19:50:47
This should just be:
return PP_FromBool(is_off_t
jvoung (off chromium)
2012/08/02 22:26:08
Done. Also used the renderer bit.
| |
315 return PP_TRUE; | |
316 } else { | |
317 return PP_FALSE; | |
318 } | |
319 } | |
320 | |
310 const PPB_NaCl_Private nacl_interface = { | 321 const PPB_NaCl_Private nacl_interface = { |
311 &LaunchSelLdr, | 322 &LaunchSelLdr, |
312 &StartPpapiProxy, | 323 &StartPpapiProxy, |
313 &UrandomFD, | 324 &UrandomFD, |
314 &Are3DInterfacesDisabled, | 325 &Are3DInterfacesDisabled, |
315 &EnableBackgroundSelLdrLaunch, | 326 &EnableBackgroundSelLdrLaunch, |
316 &BrokerDuplicateHandle, | 327 &BrokerDuplicateHandle, |
317 &GetReadonlyPnaclFD, | 328 &GetReadonlyPnaclFD, |
318 &CreateTemporaryFile | 329 &CreateTemporaryFile, |
330 &IsOffTheRecord | |
319 }; | 331 }; |
320 | 332 |
321 } // namespace | 333 } // namespace |
322 | 334 |
323 const PPB_NaCl_Private* PPB_NaCl_Private_Impl::GetInterface() { | 335 const PPB_NaCl_Private* PPB_NaCl_Private_Impl::GetInterface() { |
324 return &nacl_interface; | 336 return &nacl_interface; |
325 } | 337 } |
326 | 338 |
327 #endif // DISABLE_NACL | 339 #endif // DISABLE_NACL |
OLD | NEW |