Re: [webkit-dev] KJS::JSObject question

2009-05-21 Thread Jack Wootton
Hello, Having read through the following document Using JavaScript From Objective-C: http://developer.apple.com/documentation/AppleApplications/Conceptual/SafariJSProgTopics/Tasks/ObjCFromJavaScript.html#//apple_ref/doc/uid/30001215-BBCBFJCD It seems that the method:

Re: [webkit-dev] KJS::JSObject question

2009-05-17 Thread Darin Adler
On May 15, 2009, at 7:35 AM, Jack Wootton wrote: 4. Create the context: JSGlobalContextRef context = JSGlobalContextCreate(globalObjectClass); You will only do this if you’re using JavaScript outside of a web page. If you want to do this in conjunction with WebKit you’ll need to get the

Re: [webkit-dev] KJS::JSObject question

2009-05-15 Thread Jack Wootton
OK. It seems I was on completely the wrong track. I was under the impression WebKit didn't have public and non public APIs as such, at least I haven't read anything to this effect. Where can I read what the published Vs non published APIs are? Or which ones I should use and which ones I

Re: [webkit-dev] KJS::JSObject question

2009-05-15 Thread Jack Wootton
the JavaScriptCore/API directory. Following file is need carefully. JavaScriptCore/API/tests/testapi.c Thanks. -Xiong Original Message   Subject: Re: [webkit-dev] KJS::JSObject question From: Jack Wootton jackwoot...@gmail.com To: Darin Adler da...@apple.com Cc: webkit-dev

[webkit-dev] KJS::JSObject question

2009-05-14 Thread Jack Wootton
Hello all, I'm looking at the JSObject class in the KJS namespace. The file is JavaScriptCore/kjs/object.h. My understanding of this class is that it must be subclassed when adding new JavaScript objects to suplement the standard global objects such as document or window etc. I have a vague

Re: [webkit-dev] KJS::JSObject question

2009-05-14 Thread Darin Adler
On May 14, 2009, at 8:03 AM, Jack Wootton wrote: My question: I do not understand how JSObject can be used to allow for the JavaScript syntax of : myNewJSObject.someObject.hello(). My first comment is that you should not be using JSObject directly. The right way to do this is to use the