KConfigDialog patch

Benjamin Meyer ben at meyerhome.net
Sat Aug 11 15:12:10 BST 2007


On Aug 11, 2007, at 4:00 PM, Jos Poortvliet wrote:

> On 8/11/07, Joris Guisson <joris.guisson at gmail.com> wrote:
>>
>> I have been working on the KDE 4 port of ktorrent. Obviously we  
>> need a
>> config dialog for that. And after some looking around in the API  
>> docs I
>> found KConfigDialog, which is brilliant in the way it works with  
>> KConfigXT.
>> It seems to be in the API for quite some time now, so it's a bit  
>> strange I
>> never discovered this before.
>>
>> Anyway, it's brilliant except for one tiny thing, you cannot add  
>> pages
>> when the dialog is shown. This is very annoying for ktorrent, we  
>> have a page
>> in the dialog which allows you to load and unload plugins, some of  
>> these
>> plugins have preference pages. So when I press load, I want the  
>> preference
>> page of the plugin to be added to the dialog.
>>
>> So I decided to have a look at the code, and I noticed that if I  
>> remove
>> the if test which prevents adding a page when the dialog is shown,  
>> things
>> still work. The only problem was that the widgets are not initialized
>> properly, which could easily be fixed by setting the value from  
>> the settings
>> in KConfigDialogManager::setupWidget. So that the widget  
>> immediately has
>> it's proper value.
>>
>> This all then leads to the attached patch. Can this patch be  
>> included in
>> kdelibs ?
>>
>> Joris,
>>
>
> Seems nobody objects... I guess I'd just commit, and see how those  
> following
> the commits respond...

Um five hours isn't much time.  If you ask for feedback you should  
wait at least a day.

-Benjamin Meyer





More information about the kde-core-devel mailing list