Plasmoid: How to create engine-based applet?
Aaron J. Seigo
aseigo at kde.org
Mon Jun 23 20:16:21 CEST 2008
On Monday 23 June 2008, Henk te Sligte wrote:
> My applet source can be found here: http://pastebin.com/f5312340b (I
if(!mEngine || !mEngine->isValid())
Applet::dataEngine is guaranteed to return a non-null pointer; it may return a
non-valid engine, but mEngine will never be null.
mEngine->connectSource("test01applet", this);
dataUpdated("test01applet", mEngine->query("test01applet"));
the dataUpdated call should also not be necessary. upon first connect
dataUpdated will be called if there is any data to respond to.
> the engine source here: http://pastebin.com/f53e650d0
in your code i see this:
setDrawStandardBackground(true);
that's the old api. however in your engine:
sourceRequestEvent( const QString &name )
that's the new api!
so evidently you're mixing old and new api, therefore your problems =) in the
old api, DataEngine::sourceRequestEvent was DataEngine::sourceRequested.
what version of libplasma are you developing against?
--
Aaron J. Seigo
humru othro a kohnu se
GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA EE75 D6B7 2EB1 A7F1 DB43
KDE core developer sponsored by Trolltech
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 194 bytes
Desc: This is a digitally signed message part.
Url : http://mail.kde.org/pipermail/panel-devel/attachments/20080623/043607a4/attachment.pgp
More information about the Panel-devel
mailing list