[PATCHES] KCModule changes and kutils fixes

Rafael Fernández López ereslibre at gmail.com
Mon Aug 27 11:35:05 BST 2007


Hi Matthias and all,

As you can see in the KCModuleLoader and KCModuleProxy code there's no event
> processing happening between instantiating the KCModule and connecting the
> changed signal. So if 0 doesn't work and 10/100 works you should really
> start
> debugging as something wrong is happening (some code calling processEvents
> or
> so).


Yeah is just the fact that hard coded values makes me nervous... but as the
commit says it can be happily reverted if it is confusing. I'm not against
renaming the method either.

Which is the reason why my gut feeling is against the init method (which is
> a
> rather common (private) function name, btw, in many classes that have more
> than one ctor).


Yep.Probably it sounds like a private method name. We can rename it to
something else. It is not a problem, the important thing is what it does.

You're saying load() won't work because it will "emit changed(false)"? But
> it
> doesn't have to. For your special case the load() function will figure out
> that the configuration it shows is different than what's stored in the
> config
> file so it can "emit changed(true)".


No, I'm saying that if we usually call load() from the constructor of the
KCModule we are still on the same problem, because that emit changed(true)
that is supposed to be on the load() method (what I don't consider is right,
because we want that to happen when the plugin is loaded the first time, not
other times: note that if a plugin changed and the user clicks "Cancel", as
the dialog is "cached", load() is called) is not connected to any slot yet.


In summary: I don't think we have enough justification for init().


Right. We could call kcm->load() after the connections are done. What do you
think ?

Could you please revert my patch ? I have never reverted a patch and I've no
SVN right now (probably ADSL is coming today...), and I wont be able to be
on the other place with ADSL within Monday. That is the reason because I did
the commit since I hadn't time to come back on Monday. Sorry.


Bye and thank you,
Rafael Fernández López.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20070827/e07f6f9c/attachment.htm>


More information about the kde-core-devel mailing list