Author: lslezak Date: Thu Apr 10 14:47:43 2008 New Revision: 46344 URL: http://svn.opensuse.org/viewcvs/yast?rev=46344&view=rev Log: - SW proposal - do not display selection summary if there is no selection Modified: trunk/packager/package/yast2-packager.changes trunk/packager/src/modules/Packages.ycp Modified: trunk/packager/package/yast2-packager.changes URL: http://svn.opensuse.org/viewcvs/yast/trunk/packager/package/yast2-packager.changes?rev=46344&r1=46343&r2=46344&view=diff ============================================================================== --- trunk/packager/package/yast2-packager.changes (original) +++ trunk/packager/package/yast2-packager.changes Thu Apr 10 14:47:43 2008 @@ -3,6 +3,8 @@ - repositories - do not initialize the package manager when started from sw_single (it's already done) +- SW proposal - do not display selection summary if there is no + selection ------------------------------------------------------------------- Thu Apr 10 13:07:25 CEST 2008 - locilka@suse.cz Modified: trunk/packager/src/modules/Packages.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/packager/src/modules/Packages.ycp?rev=46344&r1=46343&r2=46344&view=diff ============================================================================== --- trunk/packager/src/modules/Packages.ycp (original) +++ trunk/packager/src/modules/Packages.ycp Thu Apr 10 14:47:43 2008 @@ -273,13 +273,23 @@ // installation proposal - SW summary, %1 is name of the selected desktop or system type (e.g. KDE) output = (list<string>)add (output, sformat(_("System Type: %1"), DefaultDesktop::Description ())); if (contains (flags, `pattern)) - output = (list<string>) -// merge (output, ListSelected (`pattern, "+ %1")); - add (output, _("Patterns:<br>") + mergestring (ListSelected (`pattern, "+ %1"), "<br>")); + { + list<string> patterns = ListSelected (`pattern, "+ %1"); + + if (size(patterns) > 0) + { + output = (list<string>) add (output, _("Patterns:<br>") + mergestring (patterns, "<br>")); + } + } if (contains (flags, `selection)) - output = (list<string>) -// merge (output, ListSelected (`selection, "+ %1")); - add (output, _("Selections:<br>") + mergestring (ListSelected (`selection, "+ %1"), "<br>")); + { + list<string> selections = ListSelected (`selection, "+ %1"); + + if (size(selections) > 0) + { + output = (list<string>) add (output, _("Selections:<br>") + mergestring (selections, "<br>")); + } + } if (contains (flags, `size)) { output = (list<string>)add (output, -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org