Author: kmachalkova Date: Mon Aug 6 19:17:26 2007 New Revision: 40040 URL: http://svn.opensuse.org/viewcvs/yast?rev=40040&view=rev Log: Added text referring to whereabouts of the license text to license agreement popup (FaTE #302018) Modified: trunk/ncurses/src/NCPkgTable.cc trunk/ncurses/src/NCPopupInfo.cc trunk/ncurses/src/NCPopupInfo.h trunk/ncurses/src/pkg/NCPackageSelector.cc trunk/ncurses/src/pkg/NCPkgNames.cc trunk/ncurses/src/pkg/NCPkgNames.h Modified: trunk/ncurses/src/NCPkgTable.cc URL: http://svn.opensuse.org/viewcvs/yast/trunk/ncurses/src/NCPkgTable.cc?rev=40040&r1=40039&r2=40040&view=diff ============================================================================== --- trunk/ncurses/src/NCPkgTable.cc (original) +++ trunk/ncurses/src/NCPkgTable.cc Mon Aug 6 19:17:26 2007 @@ -268,7 +268,8 @@ //YCPString(_("End User License Agreement") ), YCPString( "<i>" + pkgName + "</i><br><br>" + packager->createDescrText( license ) ), NCPkgNames::AcceptLabel(), - NCPkgNames::CancelLabel() ); + NCPkgNames::CancelLabel(), + NCPkgNames::PrintLicenseText()); info.setNiceSize( (NCurses::cols() * 80)/100, (NCurses::lines()*80)/100); license_confirmed = info.showInfoPopup( ) != NCursesEvent::cancel; } Modified: trunk/ncurses/src/NCPopupInfo.cc URL: http://svn.opensuse.org/viewcvs/yast/trunk/ncurses/src/NCPopupInfo.cc?rev=40040&r1=40039&r2=40040&view=diff ============================================================================== --- trunk/ncurses/src/NCPopupInfo.cc (original) +++ trunk/ncurses/src/NCPopupInfo.cc Mon Aug 6 19:17:26 2007 @@ -43,7 +43,8 @@ const YCPString & headline, const YCPString & text, string okButtonLabel, - string cancelButtonLabel ) + string cancelButtonLabel, + string printLicenseText ) : NCPopup( at, false ) , helpText( 0 ) , okButton( 0 ) @@ -52,7 +53,7 @@ , vDim( 20 ) , visible ( false ) { - createLayout( headline, text, okButtonLabel, cancelButtonLabel ); + createLayout( headline, text, okButtonLabel, cancelButtonLabel, printLicenseText ); } /////////////////////////////////////////////////////////////////// @@ -78,7 +79,8 @@ void NCPopupInfo::createLayout( const YCPString & headline, const YCPString & text, string okButtonLabel, - string cancelButtonLabel ) + string cancelButtonLabel, + string printLicenseText ) { YWidgetOpt opt; @@ -96,6 +98,14 @@ helpText = new NCRichText( split, opt, text ); split->addChild( helpText ); + if (printLicenseText != "" ) + { + NCLabel *printLabel = new NCLabel (split, opt, printLicenseText ); + split->addChild( new NCSpacing( split, opt, 1, false, true ) ); + split->addChild( printLabel ); + split->addChild( new NCSpacing( split, opt, 1, false, true ) ); + } + NCSplit * hSplit = new NCSplit( split, opt, YD_HORIZ ); split->addChild( hSplit ); if ( okButtonLabel != "" && cancelButtonLabel != "" ) @@ -126,6 +136,7 @@ hSplit->addChild( new NCSpacing( hSplit, opt, 0.4, true, false ) ); } + split->addChild( new NCSpacing( split, opt, 0.5, false, true ) ); } Modified: trunk/ncurses/src/NCPopupInfo.h URL: http://svn.opensuse.org/viewcvs/yast/trunk/ncurses/src/NCPopupInfo.h?rev=40040&r1=40039&r2=40040&view=diff ============================================================================== --- trunk/ncurses/src/NCPopupInfo.h (original) +++ trunk/ncurses/src/NCPopupInfo.h Mon Aug 6 19:17:26 2007 @@ -73,7 +73,8 @@ const YCPString & text, // the label of an OK button string okButtonLabel = _( "&OK" ), - string cancelButtonLabel = "" ); + string cancelButtonLabel = "", + string printLicenseText = "" ); virtual ~NCPopupInfo(); @@ -82,7 +83,8 @@ void createLayout( const YCPString & headline, const YCPString & text, string okButtonLabel, - string cancelButtonLabel ); + string cancelButtonLabel, + string printLicenseText ); NCursesEvent & showInfoPopup( ); Modified: trunk/ncurses/src/pkg/NCPackageSelector.cc URL: http://svn.opensuse.org/viewcvs/yast/trunk/ncurses/src/pkg/NCPackageSelector.cc?rev=40040&r1=40039&r2=40040&view=diff ============================================================================== --- trunk/ncurses/src/pkg/NCPackageSelector.cc (original) +++ trunk/ncurses/src/pkg/NCPackageSelector.cc Mon Aug 6 19:17:26 2007 @@ -2509,7 +2509,8 @@ NCPkgNames::NotifyLabel(), YCPString( "<i>" + pkgName + "</i><br><br>" + createDescrText( licenseText ) ), NCPkgNames::AcceptLabel(), - NCPkgNames::CancelLabel() ); + NCPkgNames::CancelLabel(), + NCPkgNames::PrintLicenseText() ); info.setNiceSize( (NCurses::cols() * 80)/100, (NCurses::lines()*80)/100); license_confirmed = info.showInfoPopup( ) != NCursesEvent::cancel; Modified: trunk/ncurses/src/pkg/NCPkgNames.cc URL: http://svn.opensuse.org/viewcvs/yast/trunk/ncurses/src/pkg/NCPkgNames.cc?rev=40040&r1=40039&r2=40040&view=diff ============================================================================== --- trunk/ncurses/src/pkg/NCPkgNames.cc (original) +++ trunk/ncurses/src/pkg/NCPkgNames.cc Mon Aug 6 19:17:26 2007 @@ -1211,6 +1211,13 @@ return value; } +const string NCPkgNames::PrintLicenseText() +{ + //zzZZzz + static const string value = _( "If you would like to print this license,\ncheck the EULA.txt file on the first media" ); + return value; +} + const string NCPkgNames::ContinueRequ() { // label continues the part required by ... Modified: trunk/ncurses/src/pkg/NCPkgNames.h URL: http://svn.opensuse.org/viewcvs/yast/trunk/ncurses/src/pkg/NCPkgNames.h?rev=40040&r1=40039&r2=40040&view=diff ============================================================================== --- trunk/ncurses/src/pkg/NCPkgNames.h (original) +++ trunk/ncurses/src/pkg/NCPkgNames.h Mon Aug 6 19:17:26 2007 @@ -878,6 +878,7 @@ static const string ConflictText(); static const string NoConflictText(); static const string NotAvailableText(); + static const string PrintLicenseText(); static const string MenuEtc(); static const string MenuDeps(); -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org