Author: gs Date: Fri Jul 13 10:16:33 2007 New Revision: 39388 URL: http://svn.opensuse.org/viewcvs/yast?rev=39388&view=rev Log: remove obsolete addChild() - now handled by libyui Modified: branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDeps.cc branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDescr.cc branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDiskspace.cc branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSearch.cc branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSelection.cc branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTable.cc branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTree.cc Modified: branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDeps.cc URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDeps.cc?rev=39388&r1=39387&r2=39388&view=diff ============================================================================== --- branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDeps.cc (original) +++ branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDeps.cc Fri Jul 13 10:16:33 2007 @@ -121,35 +121,29 @@ // vertical split is the (only) child of the dialog NCLayoutBox * vSplit = new NCLayoutBox( this, YD_VERT ); - addChild( vSplit ); + // addChild( ) is obsolete (handled by new libyui) + // FIXME // opt.vWeight.setValue( 40 ); opt.notifyMode.setValue( true ); - //vSplit->addChild( new NCSpacing( vSplit, opt, 0.8, false, true ) ); - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, true, 0.8 ) ); - - // opt.isHeading.setValue( true ); - //head = new NCLabel( vSplit, opt, YCPString("") ); + new NCSpacing( vSplit, YD_VERT, true, 0.8 ); head = new NCLabel( vSplit, "", true, false ); // isHeading = true - vSplit->addChild( head ); //vSplit->addChild( new NCSpacing( vSplit, opt, 0.4, false, true ) ); - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, true, 0.4 ) ); + new NCSpacing( vSplit, YD_VERT, true, 0.4 ); // add the list containing packages with unresolved dependencies problemw = new NCProblemSelectionBox( vSplit, opt, _("&Problems"), this); - vSplit->addChild( problemw ); + opt.isHStretchable.setValue( true ); - // FIXME - // opt.isHeading.setValue( false ); //vSplit->addChild( new NCSpacing( vSplit, opt, 0.2, false, true ) ); - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, true, 0.2 ) ); // stretchable = true + new NCSpacing( vSplit, YD_VERT, true, 0.2 ); // stretchable = true details = new NCInputField( vSplit, "", @@ -158,25 +152,20 @@ // FIXME //details->setMaxFld( 200 ); - vSplit->addChild( details ); //vSplit->addChild( new NCSpacing( vSplit, opt, 0.8, false, true ) ); - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, true, 0.8 ) ); // stretchable = true + new NCSpacing( vSplit, YD_VERT, true, 0.8 ); // stretchable = true // add the package list containing the dependencies solutionw = new NCSolutionSelectionBox ( vSplit, opt, _("P&ossible Solutions"), this); - vSplit->addChild( solutionw ); opt.isHStretchable.setValue( false ); - // FIXME - //opt.isHeading.setValue( true ); //vSplit->addChild( new NCSpacing( vSplit, opt, 0.6, false, true ) ); - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, false, 0.6 ) ); // stretchable = false + new NCSpacing( vSplit, YD_VERT, false, 0.6 ); // stretchable = false NCLayoutBox * hSplit = new NCLayoutBox( vSplit, YD_HORIZ ); - vSplit->addChild( hSplit ); opt.isHStretchable.setValue( true ); @@ -186,10 +175,9 @@ //solveButton->setId( NCPkgNames::Solve () ); YStringWidgetID * solveID = new YStringWidgetID("solve"); solveButton->setId( solveID ); - hSplit->addChild( solveButton ); //hSplit->addChild( new NCSpacing( hSplit, opt, 0.2, true, false ) ); - hSplit->addChild( new NCSpacing( hSplit, YD_HORIZ, true, 0.2 ) ); // stretchable = true + new NCSpacing( hSplit, YD_HORIZ, true, 0.2 ); // stretchable = true // add the cancel button opt.key_Fxx.setValue( 9 ); @@ -197,8 +185,7 @@ // cancelButton->setId( NCPkgNames::Cancel () ); YStringWidgetID * cancelID = new YStringWidgetID("cancel"); cancelButton->setId( cancelID ); - hSplit->addChild( cancelButton ); - + } /////////////////////////////////////////////////////////////////// Modified: branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDescr.cc URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDescr.cc?rev=39388&r1=39387&r2=39388&view=diff ============================================================================== --- branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDescr.cc (original) +++ branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDescr.cc Fri Jul 13 10:16:33 2007 @@ -83,51 +83,45 @@ // the vertical split is the (only) child of the dialog NCLayoutBox * split = new NCLayoutBox( this, YD_VERT ); - addChild( split ); + + // addChild() is obsolete (handled by new libyui ) //split->addChild( new NCSpacing( split, opt, 0.8, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, false, 0.8 ) ); // stretchable = false + new NCSpacing( split, YD_VERT, false, 0.8 ); // stretchable = false headline = new NCLabel( split, "", true, false ); // isHeading = true - split->addChild( headline ); - //split->addChild( new NCSpacing( split, opt, 0.4, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, false, 0.4 ) ); + new NCSpacing( split, YD_VERT, false, 0.4 ); // add the rich text widget for the package description opt.isVStretchable.setValue( true ); descrText = new NCRichText( split, opt, YCPString( "" ) ); - split->addChild( descrText ); //split->addChild( new NCSpacing( split, opt, 0.6, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, true, 0.6 ) ); // stretchable = true + new NCSpacing( split, YD_VERT, true, 0.6 ); // stretchable = true // add the package table (use default type T_Packages) pkgTable = new NCPkgTable( split, opt ); pkgTable->setPackager( packager ); pkgTable->fillHeader(); - split->addChild( pkgTable ); //split->addChild( new NCSpacing( split, opt, 0.6, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, true, 0.6 ) ); + new NCSpacing( split, YD_VERT, true, 0.6 ); opt.isHStretchable.setValue( false ); //NCLabel * helplb = new NCLabel( split, opt, YCPString(NCPkgNames::DepsHelpLine()) ); // a help line for the dependency popup NCLabel * helplb = new NCLabel( split, _( " [+] Select [-] Delete [>] Update " ), false, false ); - split->addChild( helplb ); //split->addChild( new NCSpacing( split, opt, 0.6, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, false, 0.6 ) ); // stretchable = false + new NCSpacing( split, YD_VERT, false, 0.6 ); // stretchable = false // add the OK button opt.key_Fxx.setValue( 10 ); okButton = new NCPushButton( split, NCPkgNames::OKLabel() ); YStringWidgetID * okID = new YStringWidgetID( "ok" ); okButton->setId( okID ); - - split->addChild( okButton ); - + } /////////////////////////////////////////////////////////////////// Modified: branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDiskspace.cc URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDiskspace.cc?rev=39388&r1=39387&r2=39388&view=diff ============================================================================== --- branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDiskspace.cc (original) +++ branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupDiskspace.cc Fri Jul 13 10:16:33 2007 @@ -103,13 +103,10 @@ // the vertical split is the (only) child of the dialog NCLayoutBox * split = new NCLayoutBox( this, YD_VERT ); - addChild( split ); - - // opt.isHeading.setValue( true ); - //head = new NCLabel( split, opt, YCPString( "" ) ); - head = new NCLabel( split, "", true, false ); // isHeading = true - split->addChild( head ); + // addChild() is obsolete (handled by new libyui) + + head = new NCLabel( split, "", true, false ); // isHeading = true vector<string> header; header.reserve(5); @@ -122,15 +119,12 @@ // add the partition table partitions = new NCTable( split, opt, header, false ); - split->addChild( partitions ); - // add the ok button opt.key_Fxx.setValue( 10 ); okButton = new NCPushButton( split, NCPkgNames::OKLabel() ); YStringWidgetID * okID = new YStringWidgetID( "ok" ); okButton->setId( okID ); - - split->addChild( okButton ); + } /////////////////////////////////////////////////////////////////// Modified: branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSearch.cc URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSearch.cc?rev=39388&r1=39387&r2=39388&view=diff ============================================================================== --- branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSearch.cc (original) +++ branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSearch.cc Fri Jul 13 10:16:33 2007 @@ -89,17 +89,17 @@ // vertical split is the (only) child of the dialog NCLayoutBox * vSplit = new NCLayoutBox( this, YD_VERT ); - addChild( vSplit ); + + // addChild() is obsolete //vSplit->addChild( new NCSpacing( vSplit, opt, 0.8, false, true ) ); - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, false, 0.8 ) ); // stretchable = false + new NCSpacing( vSplit, YD_VERT, false, 0.8 ); // stretchable = false //NCLabel * head = new NCLabel( vSplit, opt, headline ); NCLabel * head = new NCLabel( vSplit, headline, true, false ); // isHeading = true - vSplit->addChild( head ); //vSplit->addChild( new NCSpacing( vSplit, opt, 0.6, false, true ) ); - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, false, 0.6 ) ); + new NCSpacing( vSplit, YD_VERT, false, 0.6 ); // add the input field (a editable combo box) opt.isHStretchable.setValue( true ); @@ -111,29 +111,26 @@ opt.isEditable.setValue( true ); searchExpr = new NCComboBox( frame0, opt, YCPString(NCPkgNames::SearchPhrase()) ); - frame0->addChild( searchExpr ); + YStringWidgetID * searchID = new YStringWidgetID ("search_box" ); searchExpr->setId( searchID ); searchExpr->itemAdded( YCPString( "" ), // set initial value 0, // index false ); // not selected //vSplit2->addChild( new NCSpacing( vSplit, opt, 0.6, false, true ) ); - vSplit2->addChild( new NCSpacing( vSplit, YD_VERT, false, 0.6 ) ); + new NCSpacing( vSplit, YD_VERT, false, 0.6 ); - vSplit->addChild( frame0 ); - if ( !packager->isYouMode() ) { // add the checkBox ignore case NCLayoutBox * hSplit2 = new NCLayoutBox( vSplit, YD_HORIZ ); - vSplit->addChild( hSplit2 ); + ignoreCase = new NCCheckBox( hSplit2, opt, YCPString(NCPkgNames::IgnoreCase()), true ); //hSplit2->addChild( new NCSpacing( hSplit2, opt, 0.1, true, false ) ); - hSplit2->addChild( new NCSpacing( hSplit2, YD_HORIZ, true, 0.1 ) ); - hSplit2->addChild( ignoreCase ); + new NCSpacing( hSplit2, YD_HORIZ, true, 0.1 ); //vSplit->addChild( new NCSpacing( vSplit, opt, 0.6, false, true ) ); // VSpacing - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, false, 0.6 ) ); + new NCSpacing( vSplit, YD_VERT, false, 0.6 ); // add a frame containing the other check boxes opt.isHStretchable.setValue( true ); @@ -150,21 +147,11 @@ checkProvides = new NCCheckBox( vSplit3, opt, YCPString(NCPkgNames::CheckProvides()), false ); checkRequires = new NCCheckBox( vSplit3, opt, YCPString(NCPkgNames::CheckRequires()), false ); - vSplit3->addChild( checkName ); - vSplit3->addChild( checkSummary ); - vSplit3->addChild( checkDescr ); - vSplit3->addChild( checkProvides ); - vSplit3->addChild( checkRequires ); - - frame->addChild( vSplit3 ); - vSplit->addChild( frame ); - //vSplit->addChild( new NCSpacing( vSplit, opt, 0.8, false, true ) ); // VSpacing - vSplit->addChild( new NCSpacing( vSplit, YD_VERT, false, 0.8 ) ); + new NCSpacing( vSplit, YD_VERT, false, 0.8 ); } NCLayoutBox * hSplit3 = new NCLayoutBox( vSplit, YD_HORIZ ); - vSplit->addChild( hSplit3 ); // add the cancel and the ok button opt.key_Fxx.setValue( 10 ); @@ -180,13 +167,13 @@ opt.isHStretchable.setValue( true ); //hSplit3->addChild( new NCSpacing( hSplit3, opt, 0.2, true, false ) ); - hSplit3->addChild( new NCSpacing( hSplit3, YD_HORIZ, true, 0.2 ) ); // stretchable = true - hSplit3->addChild( okButton ); + new NCSpacing( hSplit3, YD_HORIZ, true, 0.2 ); // stretchable = true + //hSplit3->addChild( new NCSpacing( hSplit3, opt, 0.4, true, false ) ); - hSplit3->addChild( new NCSpacing( hSplit3, YD_HORIZ, true, 0.4 ) ); - hSplit3->addChild( cancelButton ); + new NCSpacing( hSplit3, YD_HORIZ, true, 0.4 ); + //hSplit3->addChild( new NCSpacing( hSplit3, opt, 0.2, true, false ) ); - hSplit3->addChild( new NCSpacing( hSplit3, YD_HORIZ, true, 0.2 ) ); + new NCSpacing( hSplit3, YD_HORIZ, true, 0.2 ); } Modified: branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSelection.cc URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSelection.cc?rev=39388&r1=39387&r2=39388&view=diff ============================================================================== --- branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSelection.cc (original) +++ branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupSelection.cc Fri Jul 13 10:16:33 2007 @@ -98,14 +98,13 @@ // the vertical split is the (only) child of the dialog NCLayoutBox * split = new NCLayoutBox( this, YD_VERT ); - addChild( split ); + + // addChild( ) is obsolete (handled by new libyui) opt.notifyMode.setValue( false ); //NCLabel * head = new NCLabel( split, opt, label ); NCLabel * head = new NCLabel( split, label, true, false ); // isHeading = true - split->addChild( head ); - // add the selection list sel = new NCPkgTable( split, opt ); sel->setPackager( packager ); @@ -129,7 +128,6 @@ } sel->fillHeader(); - split->addChild( sel ); // FIXME opt.notifyMode.setValue( true ); @@ -137,10 +135,9 @@ //NCLabel * help = new NCLabel( split, opt, YCPString(NCPkgNames::DepsHelpLine()) ); // a help line for the dependency popup NCLabel * help = new NCLabel( split, _( " [+] Select [-] Delete [>] Update " ), false, false ); - split->addChild( help ); //split->addChild( new NCSpacing( split, opt, 0.4, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, false, 0.4 ) ); + new NCSpacing( split, YD_VERT, false, 0.4 ); // add an OK button opt.key_Fxx.setValue( 10 ); @@ -148,10 +145,8 @@ YStringWidgetID * okID = new YStringWidgetID("ok"); okButton->setId( okID ); - split->addChild( okButton ); - //split->addChild( new NCSpacing( split, opt, 0.4, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, false, 0.4 ) ); + new NCSpacing( split, YD_VERT, false, 0.4 ); } /////////////////////////////////////////////////////////////////// Modified: branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTable.cc URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTable.cc?rev=39388&r1=39387&r2=39388&view=diff ============================================================================== --- branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTable.cc (original) +++ branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTable.cc Fri Jul 13 10:16:33 2007 @@ -84,45 +84,38 @@ // the vertical split is the (only) child of the dialog NCLayoutBox * split = new NCLayoutBox( this, YD_VERT ); - addChild( split ); + + // addChild() is obsolete (handled by new libyui) //split->addChild( new NCSpacing( split, opt, 0.6, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, false, 0.6 ) ); // stretchable = false + new NCSpacing( split, YD_VERT, false, 0.6 ); // stretchable = false - //NCLabel * head = new NCLabel( split, opt, YCPString(NCPkgNames::AutoChangeLabel()) ); - // the headline of the popup containing a list with packages with status changes NCLabel * head = new NCLabel( split, _( "Automatic Changes" ), true, false ); // isHeading = true - split->addChild( head ); //split->addChild( new NCSpacing( split, opt, 0.6, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, false, 0.6 ) ); + new NCSpacing( split, YD_VERT, false, 0.6 ); //NCLabel * lb1 = new NCLabel( split, opt, YCPString(NCPkgNames::AutoChangeText1()) ); // text part1 of popup with automatic changes (it's a label; text continous) NCLabel * lb1 = new NCLabel( split, _( "In addition to your manual selections, the following" ), false, false ); - split->addChild( lb1 ); //NCLabel * lb2 = new NCLabel( split, opt, YCPString(NCPkgNames::AutoChangeText2()) ); // text part2 of popup with automatic changes NCLabel * lb2 = new NCLabel( split, _( "packages have been changed to resolve dependencies:" ), false, false ); - split->addChild( lb2 ); // add the package table (use default type T_Packages) pkgTable = new NCPkgTable( split, opt ); pkgTable->setPackager( packager ); pkgTable->fillHeader(); - split->addChild( pkgTable ); - // HBox for the buttons NCLayoutBox * hSplit = new NCLayoutBox( split, YD_HORIZ ); - split->addChild( hSplit ); opt.isHStretchable.setValue( true ); //hSplit->addChild( new NCSpacing( hSplit, opt, 0.2, true, false ) ); - hSplit->addChild( new NCSpacing( hSplit, YD_HORIZ, true, 0.2 ) ); // stretchable = true + new NCSpacing( hSplit, YD_HORIZ, true, 0.2 ); // stretchable = true // add the OK button opt.key_Fxx.setValue( 10 ); @@ -130,9 +123,8 @@ YStringWidgetID * okID = new YStringWidgetID( "ok" ); okButton->setId( okID ); - hSplit->addChild( okButton ); //hSplit->addChild( new NCSpacing( hSplit, opt, 0.4, true, false ) ); - hSplit->addChild( new NCSpacing( hSplit, YD_HORIZ, true, 0.4 ) ); + new NCSpacing( hSplit, YD_HORIZ, true, 0.4 ); // add the Cancel button opt.key_Fxx.setValue( 9 ); @@ -140,12 +132,11 @@ YStringWidgetID * cancelID = new YStringWidgetID( "cancel" ); cancelButton->setId( cancelID ); - hSplit->addChild( cancelButton ); //hSplit->addChild( new NCSpacing( hSplit, opt, 0.2, true, false ) ); - hSplit->addChild( new NCSpacing( hSplit, YD_HORIZ, true, 0.2 ) ); + new NCSpacing( hSplit, YD_HORIZ, true, 0.2 ); //split->addChild( new NCSpacing( split, opt, 0.6, false, true ) ); - split->addChild( new NCSpacing( split, YD_VERT, false, 0.6 ) ); + new NCSpacing( split, YD_VERT, false, 0.6 ); } Modified: branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTree.cc URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTree.cc?rev=39388&r1=39387&r2=39388&view=diff ============================================================================== --- branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTree.cc (original) +++ branches/tmp/sh/mod-ui/ncurses/src/pkg/NCPkgPopupTree.cc Fri Jul 13 10:16:33 2007 @@ -77,11 +77,11 @@ // the vertical split is the (only) child of the dialog NCLayoutBox * split = new NCLayoutBox( this, YD_VERT ); - addChild( split ); + + // addChild() is obsolete // create the tree filterTree = new NCTree( split, opt, label ); - split->addChild( filterTree ); } -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org