Extender tutorial on techbase

Marco Martin notmart at gmail.com
Fri Sep 12 16:16:05 CEST 2008


On Thursday 11 September 2008, Rob Scheepmaker wrote:
> On Thursday 11 September 2008 17:06:10 Marco Martin wrote:
> > with furter investigation i've found that it doesn't crash anymore if i
> > remove line 194 of applet.cpp
> >   //destroy temporary extender items, or items that aren't detached, so
> > their //configuration won't linger after a plasma restart.
> >   item->destroy();
> >
> > why items are destroyed when the config is saved? did'nt understand very
> > well the logic of this
>
> That way their configuration is removed. It doesn't really make sense to
> make items that are still attached, or are temporary persistent. Upon
> creation ExtenderItems get a config group so information can be stored, and
> this is to be removed if the item turns out to not be needed anymore after
> plasma restarts. destroy() deletes this config group. Apparently something
> goes wrong there in this case, I'll investigate further later today.
> Kuiserver doesn't have this problem so I'll have to find out what is
> different here.
Kuiserver crashes as well with this patch, it doesn't crash anymore with the 
last version:
this because it sets its own layout, a layout is set already in popupapplet, 
so to not make subclasses expode i can't keep a local pointer to layout but 
retrieve with layout() every time.

it always remain the second problemof the crash on add:
it seem to happen only when there is a proxywidget in the extenderitem (aah, 
qt bug? deletelater crashes for proxywidgets perhaps?)
if there is a normal graphicswidget like a plasma::icon it doesn't crash, but 
when a clock is added to the desktop the popup is empty, because the extender 
item has been deleted by an applet save state

Cheers,
Marco Martin
>
> > should i set setAutoExpireDelay(0)?
> > that would make sense but it's weird, because that problem would arise to
> > everybody trying to use extenders in this way?
>
> an autoExpireDelay of 0 is the default, so that wouldn't change anything.
>
> regards,
> Rob Scheepmaker
> _______________________________________________
> Plasma-devel mailing list
> Plasma-devel at kde.org
> https://mail.kde.org/mailman/listinfo/plasma-devel




More information about the Plasma-devel mailing list