QML and Plasma -> progress()

Marco Martin notmart at gmail.com
Thu Sep 16 20:03:24 CEST 2010


On Thursday 16 September 2010, Aaron J. Seigo wrote:

> > it is not possible to override plasmoid functions in javascript with
> > things like plasmoid.dataUpdated = function() as far i know, but i could
> > be wrong, i don't thik we really need this tough.
> 
> it's probably avoidable now that we have event listeners and the ability to
> connect random functions and objects to signals and what not. overriding
> functions in plasmoid is indeed probably avoidable now, but it will be
> desirable with other objects.

i found that the following structure looks nice:
in the root element implement a javascript function with the proper name, like

Item {
 function configChangd() 
 {
     do stuff
 }
}

and then call it from the appletscript c++ when it's necessary

> > i -think- most of our bindings in javascript/simplebindings/  aren't of
> > much use, since they use qscriptvalues, that is another thing that if
> > it's used is buried pretty deep, all you pass around seems to be a
> > simple qvariant, so simple thngs like colors,rects,sizes seems to just
> > work.
> 
> yes, i'm not so concerned about simpmle things like colors, etc. but
> consistency with things like DataEngines, Services, AddOns, Extensions,
> etc. it would be great to avoid having two different ways to, for example,
> respond to events such as addonCreated.

yeah, i'll look into reciclyng as much as that code is possible, or at least 
doing things that are used in the most similar way possible.
i'm arguing with services right now let's see what i get out of

Cheers,
Marco Martin


More information about the Plasma-devel mailing list