Created attachment 51720 [details] Test applet Version: unspecified (using KDE 4.5.1) OS: Linux Attached is the test applet. Basically i connect to the systemmonitor dataEngine and the source "system/uptime". Then after 6 seconds this is disconnected again. And then 3 seconds later it is connected again. However connecting the 2nd time seems to fail, since my dataUpdated function is never ever called again... also in TestApplet::init() I connect then disconnect and connect again, to show that the dataUpdated function needs to be called at least once to produce this bug (i.e. connecting --> disconnecting --> connecting works fine if dataUpdated had no chance to be called) Another issue I realized is that the constructor gets called as often as I started plasmoidviewer with this plasmoid, i.e. if I started plasmoidviewer already 5 times, than 5 times my constructor is called (but only once the init() method). Really??? are u serious with this behaviour? The constructor gets even called if I start plasmoidviewer with a completely different plasmoid (lets say "plasmoidviewer tasks"). I.e. do sth like this: plasmoidviewer test_applet plasmoidviewer test_applet plasmoidviewer test_applet plasmoidviewer tasks Really I have no idea why the tasks plasmoid needs to call the constructor for test_applet... This must be a bug??? Reproducible: Always Steps to Reproduce: Download attached program Install the plasmoid Start it inside plasmoidviewer Wait 6 seconds until the source is disconnected (6 times dataUpdated should be printed) Wait 3 seconds until source is connected again (some message appears on std::cout) Wait for dataUpdated to be called again (but don't wait too long, coz it won't happen ;) ) Actual Results: dataUpdated is not called after the second connectSource Expected Results: dataUpdated should be called again
"Really??? are u serious with this behaviour?" i could ask the same about your bug report ;) c'mon, keep it collegial, ok? that said, the plasmoidviewer bug has already been fixed and backported. reconnecting to sources in Plasma::DataEngine does indeed work (i know because i have doing exactly that all day yesterday and today, as it happens). this is actually a bug in the system-monitor engine, and which is being worked on.
Sorry if you felt offended, I did not intend to insult someone (was just a bit wondering why this happened, because in my real applet it crashed and I first could not understand why). Is there a bug report for the problem with the systemmonitor data engine, because I could not find it?
"Is there a bug report for the problem with the systemmonitor data engine, because I could not find it?" no, if there was we would have marked this one as a duplicate. i put Alex on the cc list for the report as he was working on a fix for this.
SVN commit 1177289 by alexmerry: Fix updating of the source when it was connected to before being populated. BUG: 251459 M +12 -0 systemmonitor.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1177289
SVN commit 1177290 by alexmerry: Backport r1177289: Fix updating of the source when it was connected to before being populated. CCBUG: 251459 M +12 -0 systemmonitor.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1177290