[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-panel-devel
Subject:    Re: [Panel-devel] Applet updating
From:       Petri Damsten <petri.damsten () iki ! fi>
Date:       2007-09-16 16:49:46
Message-ID: 200709161949.46454.petri.damsten () iki ! fi
[Download RAW message or body]

[Attachment #2 (multipart/signed)]


On Sunday 16 September 2007 18:43:13 Aaron J. Seigo wrote:
> On Sunday 16 September 2007, Petri Damsten wrote:
> > Trying to get applet update behave similarly whether data is ready in
> > DataEngine::updateSource() or not. After all applet writer should not
> > have to know how engine gets it's data.
>
> what's the use care for where it matters?

I try to solve the issue that news applet doesn't work at all at the moment 
and would like to see updated called similarly whether engine has the data or 
has to wait for it.

> > 1. Data might not be ready yet so don't call update yet. It gets called
> > when engine calls setData.
>
> which breaks every call to connectSource to existing data sources. this
> part of the patch is wrong.

OK, didn't thought that. Well it's just one extra updated call if data isn't 
ready.

> > 2. Call source with createWhenMissing true so DataContainer gets created
> > even if setData is not called in DataEngine::updateSource()
>
> this is incorrect; if the engine rejects the source request (returns false)
> the source should not be created.

But if sourceRequested returns false it doesn't get to the source call (the 
second one)?

> > 3. queue to true so updated gets called after first setData
>
> hm.. doesn't it already? or is this a side effect of not calling updated
> immediately as per point #1?

Yes for engines which setData in updateSource but not for the engines that has 
to wait for the data. If #1 call is there I guess it could be:
if (!dc->hasUpdates()) {  
		m_queued = true; 
}
     
Petri

-- 
AIRPORTS: A place where people hurry up and wait.
           (Terry Pratchett, Wings)

["signature.asc" (application/pgp-signature)]

_______________________________________________
Panel-devel mailing list
Panel-devel@kde.org
https://mail.kde.org/mailman/listinfo/panel-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic