Hi all, since i'm going forward with the porting of the qml scriptengine to plasma2, i got to think about the current implementation and how to implement missing pieces (that leads to what to change)
This could be a topic for a monday telco, but putting this forward already. right now the scriptengine already lost most of the files/stuff it had in plasma1, what remains is common: * authorization.h * scriptenv.cpp/.h declarative: *packageaccessmanager *packageaccessfactory *qmlobject (this is basically the api of QQuickView, but just a qobject, so makes very easy to parse qml with its own scriptengine in a way completely independent from a view: is probably material for KDeclarative) plasmoid: * appletinterface * declarativeappletscript Now, what i would change: * ScriptEnv is basically not used anymore and should probably go: it was a class to register dynamic properties and methods to the plasmoid object. unfortunately there is no way to do it in qml anymore, so plasmoid will have a static number of properties/methods, can onlt be 1:1 to the exported stuff of AppletInterface * DeclarativeappletScript and AppletInterface: I tought for approximately 0.22 seconds about merging those two, but would be a quite bad idea, since we need anyways a class that is a graphical object, so DeclarativeappletScript becomes simply what instantiates AppletScript and not much else. AppletScript becomes a QQuickItem (it is already in master) and is the one that actually instantiates the qml part of the plasmoid. if the qml object instantiation is moved all there means that will be quite easy to restore the behavior of popupapplet, just it loading a piece of qml from the Corona package that provides ui for the icon and the popup. so most of the functionality goes from DeclarativeappletScript, apart being pretty much a relayer of signals from the applet to the appletinterface. Cheers, Marco Martin _______________________________________________ Plasma-devel mailing list [email protected] https://mail.kde.org/mailman/listinfo/plasma-devel
