[webkit-dev] call function from c++ to js using JSObject

Honey honeysaini88 at gmail.com
Mon Feb 3 09:04:52 PST 2014


I have exposed a function setObject() through webkit idl. Suppose i have a javascript class like

function Player () { var speed = 5; var x = 50; var y = 50;}
var p = new Player();
setObject(p);

In webkit, i am getting the p as JSValue object. I want to retrieve the value of x through this JSValue object. how can i do that?
any help would be appreciated..


Sent from my iPad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-dev/attachments/20140203/3f2e2727/attachment.html>


More information about the webkit-dev mailing list