[PATCH] Support for PopupApplets in Python

Simon Edwards simon at simonzone.com
Sun Feb 28 21:26:52 CET 2010


Richard Dale wrote:
> On Sat, Feb 27, 2010 at 4:42 PM, Luca Beltrame <einar at heavensinferno.net> wrote:
>> In data sabato 27 febbraio 2010 15:13:23, Petri Damstén ha scritto:
>>> Python popup applet with extenders:
>>> http://websvn.kde.org/trunk/KDE/kdeexamples/plasma/python/applets/pyhello/
>> Thanks, then my patch is completely unnecessary, as the standard __getattr__
>> method is enough.
>> I'll probably use your example, dissect it a bit , then write a tutorial on
>> Techbase so that things are more clear for people new to applet development (I
>> admit I managed to miss this example...)
> But shouldn't there still be Python plasma scripting PopupApplet and
> Containment classes? Is the C++ instance correctly wrapped as a
> Plasma::PopupApplet or Plasma::Container, as opposed to a vanilla
> Plasma::Applet?

If I remember correctly, (it has been a while since I've looked), the 
Python code doesn't create the instance of the Applet itself. Plasma 
does this by itself, but the plasmoid developer has to provide their own 
AppletScript object which acts a proxy. There is no PopupAppletScript in 
plasma libs. So I guess the needed code exists already in libplasma in 
the related scripting classes.

cheers,

-- 
Simon Edwards             | KDE-NL, Guidance tools, Guarddog Firewall
simon at simonzone.com       | http://www.simonzone.com/software/
Nijmegen, The Netherlands | "ZooTV? You made the right choice."


More information about the Plasma-devel mailing list