| Index: ppapi/cpp/instance.h
|
| diff --git a/ppapi/cpp/instance.h b/ppapi/cpp/instance.h
|
| index 5e7931cb16926eb05e3090ddc46b1d48e904f681..00eaadcfe959b3bdae8a6c2fe80a979ec819c022 100644
|
| --- a/ppapi/cpp/instance.h
|
| +++ b/ppapi/cpp/instance.h
|
| @@ -14,6 +14,7 @@
|
| #include "ppapi/c/pp_instance.h"
|
| #include "ppapi/c/pp_resource.h"
|
| #include "ppapi/c/pp_stdint.h"
|
| +#include "ppapi/c/ppb_console.h"
|
| #include "ppapi/cpp/instance_handle.h"
|
| #include "ppapi/cpp/view.h"
|
|
|
| @@ -472,6 +473,29 @@ class Instance {
|
|
|
| /// @}
|
|
|
| + /// @{
|
| + /// @name PPB_Console methods for logging to the console:
|
| +
|
| + /// Logs the given message to the JavaScript console associated with the
|
| + /// given plugin instance with the given logging level. The name of the plugin
|
| + /// issuing the log message will be automatically prepended to the message.
|
| + /// The value may be any type of Var.
|
| + void LogToConsole(PP_LogLevel level, const Var& value);
|
| +
|
| + /// Logs a message to the console with the given source information rather
|
| + /// than using the internal PPAPI plugin name. The name must be a string var.
|
| + ///
|
| + /// The regular log function will automatically prepend the name of your
|
| + /// plugin to the message as the "source" of the message. Some plugins may
|
| + /// wish to override this. For example, if your plugin is a Python
|
| + /// interpreter, you would want log messages to contain the source .py file
|
| + /// doing the log statement rather than have "python" show up in the console.
|
| + void LogToConsoleWithSource(PP_LogLevel level,
|
| + const Var& source,
|
| + const Var& value);
|
| +
|
| + /// @}
|
| +
|
| /// AddPerInstanceObject() associates an instance with an interface,
|
| /// creating an object.
|
| ///
|
|
|