From: Albert Astals Cid Date: Mon, 17 Sep 2012 17:19:36 +0000 (+0200) Subject: Apply the +1 to the grade X-Git-Tag: v4.9.2~1 X-Git-Url: https://git.rmz.fi/?a=commitdiff_plain;h=6a20fd0e2832cdc8c129c774d24c0cf399390cfe;p=libqmvoc.git Apply the +1 to the grade And not to the max of (grad, 1) since grad starts at 0, means after an inc it went straight to 2 Acked by fregl --- diff --git a/keduvocdocument/keduvoctext.cpp b/keduvocdocument/keduvoctext.cpp index 4df6bd7..41d44d0 100644 --- a/keduvocdocument/keduvoctext.cpp +++ b/keduvocdocument/keduvoctext.cpp @@ -91,7 +91,7 @@ void KEduVocText::setGrade( grade_t grade ) void KEduVocText::incGrade() { - setGrade( qMax(grade(), KV_LEV1_GRADE ) + 1 ); + setGrade( qMax(grade() + 1, KV_LEV1_GRADE ) ); }