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

Unified Diff: content/renderer/pepper/pepper_try_catch.cc

Issue 459553003: Replace NPObject usage in ppapi with gin (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/pepper/pepper_try_catch.cc
diff --git a/content/renderer/pepper/pepper_try_catch.cc b/content/renderer/pepper/pepper_try_catch.cc
index f5d8b3bf47b045861f67de5e38c85e9bb6624085..3833d17e70dd52f09ab3cb6cd9264d5c672a7f33 100644
--- a/content/renderer/pepper/pepper_try_catch.cc
+++ b/content/renderer/pepper/pepper_try_catch.cc
@@ -5,7 +5,6 @@
#include "content/renderer/pepper/pepper_try_catch.h"
#include "content/renderer/pepper/pepper_plugin_instance_impl.h"
-#include "content/renderer/pepper/v8_var_converter.h"
#include "gin/converter.h"
#include "ppapi/shared_impl/ppapi_globals.h"
#include "ppapi/shared_impl/var_tracker.h"
@@ -21,7 +20,7 @@ const char kInvalidException[] = "Error: An invalid exception was thrown.";
} // namespace
PepperTryCatch::PepperTryCatch(PepperPluginInstanceImpl* instance,
- bool convert_objects)
+ V8VarConverter::AllowObjectVars convert_objects)
: instance_(instance),
convert_objects_(convert_objects) {}
@@ -57,9 +56,10 @@ ppapi::ScopedPPVar PepperTryCatch::FromV8(v8::Handle<v8::Value> v8_value) {
return result;
}
-PepperTryCatchV8::PepperTryCatchV8(PepperPluginInstanceImpl* instance,
- bool convert_objects,
- v8::Isolate* isolate)
+PepperTryCatchV8::PepperTryCatchV8(
+ PepperPluginInstanceImpl* instance,
+ V8VarConverter::AllowObjectVars convert_objects,
+ v8::Isolate* isolate)
: PepperTryCatch(instance, convert_objects),
exception_(PP_MakeUndefined()) {
// Typically when using PepperTryCatchV8 we are passed an isolate. We verify
@@ -107,9 +107,8 @@ void PepperTryCatchV8::SetException(const char* message) {
}
PepperTryCatchVar::PepperTryCatchVar(PepperPluginInstanceImpl* instance,
- bool convert_objects,
PP_Var* exception)
- : PepperTryCatch(instance, convert_objects),
+ : PepperTryCatch(instance, V8VarConverter::kAllowObjectVars),
handle_scope_(instance_->GetIsolate()),
exception_(exception),
exception_is_set_(false) {

Powered by Google App Engine
This is Rietveld 408576698