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

List:       kde-core-devel
Subject:    Re: PATCH: KFileItem private pointer cleanup
From:       Rolf Magnus <ramagnus () t-online ! de>
Date:       2002-03-06 18:50:13
[Download RAW message or body]

On Wednesday 06 March 2002 19:08, Carsten Pfeiffer wrote:

> Oh, I see, looked at the wrong c'tor. So it's just about creating all the
> objects in advance or not. How's the usecase currently? Are they only
> accessed on mouseover, or more often?

Currently only on mouseover, though this will change in 3.1 with the detailed 
list view.

> In the former case, I see no
> disadvantage of creating them on demand.

well, I can't see an advantage either because 
sizeof(KFileMetaInfo)==sizeof(KFileMetaInfo*), so no advantage in size. So as 
long as the info is empty, there is no difference at all. When info is 
written into the object (either by setMetaInfo() or by metaInfo()) your 
version needs space for an additional pointer as well as the internal memory 
that malloc needs for it, so it's slightly more.
And in the small tutorial about KFMI that I plan to write, I wanted to add a 
note that you usually never need to have pointers to KFMI objects... ;)
[prev in list] [next in list] [prev in thread] [next in thread] 

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