Author: schubi2 Date: Tue Dec 4 10:56:07 2007 New Revision: 8016 URL: http://svn.opensuse.org/viewcvs/zypp?rev=8016&view=rev Log: improved layout Modified: trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.cc trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.h Modified: trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.cc URL: http://svn.opensuse.org/viewcvs/zypp/trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.cc?rev=8016&r1=8015&r2=8016&view=diff ============================================================================== --- trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.cc (original) +++ trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.cc Tue Dec 4 10:56:07 2007 @@ -53,26 +53,28 @@ _details = ""; } -void ProblemSolutionCombi::addSingleAction( PoolItem_Ref item, const TransactionKind action, - const std::string description) +void ProblemSolutionCombi::addSingleAction( PoolItem_Ref item, const TransactionKind action) { - TransactionSolutionAction *actionTransact = new TransactionSolutionAction(item, action); - addAction (actionTransact); - - if (description.size() == 0) { - ostringstream details; - details << *actionTransact; - _details += details.str(); - } else { - _details += description; - } + addAction (new TransactionSolutionAction(item, action)); } void ProblemSolutionCombi::addDescription( const std::string description) { - if ( _description.size() > 0) - _description += "\n"; - _description += description; + if ( _description.size() == 0 + && _details.size() == 0) { + // first entry + _description = description; + } else { + if ( _description.size() > 0 + && _details.size() == 0) { + // second entry + _details = _description; + _description = _("Following actions will be done:"); + } + // all other + _details += "\n"; + _details += description; + } } /////////////////////////////////////////////////////////////////// Modified: trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.h URL: http://svn.opensuse.org/viewcvs/zypp/trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.h?rev=8016&r1=8015&r2=8016&view=diff ============================================================================== --- trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.h (original) +++ trunk/libzypp/zypp/solver/detail/ProblemSolutionCombi.h Tue Dec 4 10:56:07 2007 @@ -53,7 +53,7 @@ /** * Add a single action */ - void addSingleAction( PoolItem_Ref item, const TransactionKind action, const std::string description = ""); + void addSingleAction( PoolItem_Ref item, const TransactionKind action); /** * Set description text */ -- To unsubscribe, e-mail: zypp-commit+unsubscribe@opensuse.org For additional commands, e-mail: zypp-commit+help@opensuse.org