Hi Noam, Thanks for your reply. Will Qt Community accept if I try to implement the feature I requested & submit the patch?. Can I start doing that?
On 23 January 2013 16:04, <noam.rosent...@nokia.com> wrote: > Hi Arunprasad > There is currently no API for that; > The way to accomplish the same result, is by having a function in your own > QObject that returns a new QObject, something like > window.myNativeFactory.createObject() > > Noam > ------------------------------ > *From:* webkit-qt-boun...@lists.webkit.org [ > webkit-qt-boun...@lists.webkit.org] on behalf of ext Arunprasad Rajkumar [ > ararunpra...@gmail.com] > *Sent:* Wednesday, January 23, 2013 10:02 AM > *To:* webkit-qt@lists.webkit.org > *Subject:* [webkit-qt] How to add new class to DOM in QtWebKit? > > Hello Developers, > > I came to know QtWebKit has the way to add new property to "window" > object using QWebFrame::addToJavaScriptWindowObject(). Really nice & > intuitive because it just takes the QObject & name of the object. MOC > rocks here :) > > But I want to add anew Class to the window class, so that it is > instantiate-able from JavaScript. > > eg) > var a = new MyNativeQtClass(); > a.myqtInvocableMethod(); > > In the above snippet "MyNativeQtClass" is as a C++/QtClass derived from > QObject. > > How to do that? > -- > *Arunprasad Rajkumar* > http://in.linkedin.com/in/ararunprasad > -- *Arunprasad Rajkumar* http://in.linkedin.com/in/ararunprasad
_______________________________________________ webkit-qt mailing list webkit-qt@lists.webkit.org http://lists.webkit.org/mailman/listinfo/webkit-qt