diff options
author | ncbray@chromium.org <ncbray@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-12-13 01:34:32 +0000 |
---|---|---|
committer | ncbray@chromium.org <ncbray@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-12-13 01:34:32 +0000 |
commit | 598816adfcd9f6d47f51b1209ec890d0bdacdee6 (patch) | |
tree | 594984d4a7e5201230fca35638505c5f65990f28 /ppapi/cpp/instance.h | |
parent | b171d8d2c0cdca2cb56df93e03438d210dfe031c (diff) | |
download | chromium_src-598816adfcd9f6d47f51b1209ec890d0bdacdee6.zip chromium_src-598816adfcd9f6d47f51b1209ec890d0bdacdee6.tar.gz chromium_src-598816adfcd9f6d47f51b1209ec890d0bdacdee6.tar.bz2 |
PPAPI: Move PPB_Console out of dev.
PPB_Console was not added to the SRPC proxy because this proxy is deprecated.
BUG= none
Review URL: https://chromiumcodereview.appspot.com/11416214
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@172762 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi/cpp/instance.h')
-rw-r--r-- | ppapi/cpp/instance.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/ppapi/cpp/instance.h b/ppapi/cpp/instance.h index 5e7931c..00eaadc 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. /// |