Il 25/06/2013 11:44, Michael Andres ha scritto:
>>    {
>>      frame->setWeight( YD_HORIZ, 1 );
>>      frame		= YUI::widgetFactory()->createHVCenter( frame );
>>      frame		= YUI::widgetFactory()->createVBox( frame );
>>  
>>      auto w = YUI::widgetFactory()->createMultiLineEdit( frame, "MultiLineEdit" );
>> +    cbf->handleChildrenEnablement(cbf->value());
> 
> Why do I need to call this manually? Why can't a CheckBoxFrame handle this internally? 
> It does so when changing state, so it should also be possible initially. To me it looks like ncurses does it correctly (subwidgets seem to be correctly enabled  according to the frames state). Only Qt has a wrong initial child state, so this should be IMO fixed in Qt rather than bothering the user with this call.
> 
> ---
> Reply to this email directly or view it on GitHub:
> https://github.com/libyui/libyui/pull/56/files#r4862407
> 
/**
     * Handle enabling/disabling of child widgets based on 'isChecked' (the
     * current status of the check box) and autoEnable() and
     * invertAutoEnable().
     *
     * Derived classes should call this when the check box status changes
     * rather than try to handle it on their level.
     *
     * This method also needs to be called after new child widgets are
added to
     * establish the initial enabled or disabled state of the child widgets.
     **/
    void handleChildrenEnablement( bool isChecked );