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

Unified Diff: ppapi/cpp/var.h

Issue 8502030: Draft of a PPAPI interface for ArrayBuffer and typed arrays. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 9 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 side-by-side diff with in-line comments
Download patch
Index: ppapi/cpp/var.h
diff --git a/ppapi/cpp/var.h b/ppapi/cpp/var.h
index 0cd82185b83b02b21eab3e3f945dd47bc1e3a015..fc65d382c0218757177ac56a0360d5511c3cb9b9 100644
--- a/ppapi/cpp/var.h
+++ b/ppapi/cpp/var.h
@@ -158,6 +158,9 @@ class Var {
var_.type == PP_VARTYPE_DOUBLE;
}
+ /// This function determines if this <code>Var</code> is an ArrayBuffer.
+ bool is_array_buffer() const { return var_.type == PP_VARTYPE_ARRAY_BUFFER; }
+
/// AsBool() converts this <code>Var</code> to a bool. Assumes the
/// internal representation is_bool(). If it's not, it will assert in debug
/// mode, and return false.
« no previous file with comments | « ppapi/cpp/dev/var_array_buffer_dev.cc ('k') | ppapi/native_client/src/shared/ppapi_proxy/object_serialize.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698