does HTTP extension work in plasma qml?

Kevin Krammer krammer at kde.org
Tue Jul 16 14:37:07 UTC 2013


On Tuesday, 2013-07-16, Sebastian Kügler wrote:
> Hi Bruce,
> 
> On Tuesday, July 16, 2013 19:51:09 bruce wrote:
> > i have wrote a little plasma-qml applet.i try to utilize HTTP extension
> > from plasma-javascript to retreive web resources. but plasmoid.getUrl()
> > returned undefined. in plasma-javascript works well.
> > i have pasted the main.qml code into paste.kde.org, link follows:
> > http://paste.kde.org/p1f0f7ab5/
> > the attachment is the whole project zip file.
> > 
> > i have add line X-Plasma-RequiredExtensions=LaunchApp,HTTP in this qml
> > plasmoid metadata.desktop is HTTP extension available in QML?
> 
> This is a little different in QML, you can load content from a http:// url
> in many components without this extension. We are not able to sandbox QML
> as we do with JavaScript, so our QML API, while being very similar to the
> JS one, is less restrictive.

I guess it would be possible to register a QScriptEngine subclass or wrapper 
with the QML type system and have it execute the script in question.

Cheers,
Kevin
-- 
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20130716/27fcd954/attachment.sig>


More information about the Plasma-devel mailing list