| 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 286 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 297 return; | 297 return; |
| 298 g_pnacl_resource_host.Get()->ReportTranslationFinished(instance, success); | 298 g_pnacl_resource_host.Get()->ReportTranslationFinished(instance, success); |
| 299 } | 299 } |
| 300 | 300 |
| 301 PP_Bool IsOffTheRecord() { | 301 PP_Bool IsOffTheRecord() { |
| 302 return PP_FromBool(ChromeRenderProcessObserver::is_incognito_process()); | 302 return PP_FromBool(ChromeRenderProcessObserver::is_incognito_process()); |
| 303 } | 303 } |
| 304 | 304 |
| 305 PP_Bool IsPnaclEnabled() { | 305 PP_Bool IsPnaclEnabled() { |
| 306 return PP_FromBool( | 306 return PP_FromBool( |
| 307 !CommandLine::ForCurrentProcess()->HasSwitch(switches::kDisablePnacl)); | 307 CommandLine::ForCurrentProcess()->HasSwitch(switches::kEnablePnacl)); |
| 308 } | 308 } |
| 309 | 309 |
| 310 PP_ExternalPluginResult ReportNaClError(PP_Instance instance, | 310 PP_ExternalPluginResult ReportNaClError(PP_Instance instance, |
| 311 PP_NaClError error_id) { | 311 PP_NaClError error_id) { |
| 312 IPC::Sender* sender = content::RenderThread::Get(); | 312 IPC::Sender* sender = content::RenderThread::Get(); |
| 313 | 313 |
| 314 if (!sender->Send( | 314 if (!sender->Send( |
| 315 new NaClHostMsg_NaClErrorStatus( | 315 new NaClHostMsg_NaClErrorStatus( |
| 316 // TODO(dschuff): does this enum need to be sent as an int, | 316 // TODO(dschuff): does this enum need to be sent as an int, |
| 317 // or is it safe to include the appropriate headers in | 317 // or is it safe to include the appropriate headers in |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 367 &OpenNaClExecutable | 367 &OpenNaClExecutable |
| 368 }; | 368 }; |
| 369 | 369 |
| 370 } // namespace | 370 } // namespace |
| 371 | 371 |
| 372 const PPB_NaCl_Private* PPB_NaCl_Private_Impl::GetInterface() { | 372 const PPB_NaCl_Private* PPB_NaCl_Private_Impl::GetInterface() { |
| 373 return &nacl_interface; | 373 return &nacl_interface; |
| 374 } | 374 } |
| 375 | 375 |
| 376 #endif // DISABLE_NACL | 376 #endif // DISABLE_NACL |
| OLD | NEW |