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

Side by Side Diff: ppapi/native_client/src/trusted/plugin/plugin.cc

Issue 9158005: RFC: Add an interface for having the browser open a pnacl support file (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add a test, do some tweaks. Created 8 years, 10 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 #ifdef _MSC_VER 5 #ifdef _MSC_VER
6 // Do not warn about use of std::copy with raw pointers. 6 // Do not warn about use of std::copy with raw pointers.
7 #pragma warning(disable : 4996) 7 #pragma warning(disable : 4996)
8 #endif 8 #endif
9 9
10 #include "native_client/src/trusted/plugin/plugin.h" 10 #include "native_client/src/trusted/plugin/plugin.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 #include "ppapi/cpp/image_data.h" 68 #include "ppapi/cpp/image_data.h"
69 #include "ppapi/cpp/input_event.h" 69 #include "ppapi/cpp/input_event.h"
70 #include "ppapi/cpp/module.h" 70 #include "ppapi/cpp/module.h"
71 #include "ppapi/cpp/mouse_lock.h" 71 #include "ppapi/cpp/mouse_lock.h"
72 #include "ppapi/cpp/rect.h" 72 #include "ppapi/cpp/rect.h"
73 73
74 using ppapi_proxy::BrowserPpp; 74 using ppapi_proxy::BrowserPpp;
75 75
76 namespace plugin { 76 namespace plugin {
77 77
78 GetReadonlyPnaclFdFunc get_readonly_pnacl_fd = NULL;
79
78 namespace { 80 namespace {
79 81
80 const char* const kTypeAttribute = "type"; 82 const char* const kTypeAttribute = "type";
81 // The "src" attribute of the <embed> tag. The value is expected to be either 83 // The "src" attribute of the <embed> tag. The value is expected to be either
82 // a URL or URI pointing to the manifest file (which is expected to contain 84 // a URL or URI pointing to the manifest file (which is expected to contain
83 // JSON matching ISAs with .nexe URLs). 85 // JSON matching ISAs with .nexe URLs).
84 const char* const kSrcManifestAttribute = "src"; 86 const char* const kSrcManifestAttribute = "src";
85 // The "nacl" attribute of the <embed> tag. We use the value of this attribute 87 // The "nacl" attribute of the <embed> tag. We use the value of this attribute
86 // to find the manifest file when NaCl is registered as a plug-in for another 88 // to find the manifest file when NaCl is registered as a plug-in for another
87 // MIME type because the "src" attribute is used to supply us with the resource 89 // MIME type because the "src" attribute is used to supply us with the resource
(...skipping 1829 matching lines...) Expand 10 before | Expand all | Expand 10 after
1917 static_cast<uint32_t>(text.size())); 1919 static_cast<uint32_t>(text.size()));
1918 const PPB_Console_Dev* console_interface = 1920 const PPB_Console_Dev* console_interface =
1919 static_cast<const PPB_Console_Dev*>( 1921 static_cast<const PPB_Console_Dev*>(
1920 module->GetBrowserInterface(PPB_CONSOLE_DEV_INTERFACE)); 1922 module->GetBrowserInterface(PPB_CONSOLE_DEV_INTERFACE));
1921 console_interface->LogWithSource(pp_instance(), PP_LOGLEVEL_LOG, prefix, str); 1923 console_interface->LogWithSource(pp_instance(), PP_LOGLEVEL_LOG, prefix, str);
1922 var_interface->Release(prefix); 1924 var_interface->Release(prefix);
1923 var_interface->Release(str); 1925 var_interface->Release(str);
1924 } 1926 }
1925 1927
1926 } // namespace plugin 1928 } // namespace plugin
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698