From 9303787b1a749039a88318f3f74a5c84d82e3c8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20A=C3=9Fmus?= Date: Sat, 25 Oct 2014 16:31:08 +0200 Subject: [PATCH] HaikuDepot: Show ratings in other languages with empty comments --- src/apps/haikudepot/ui/PackageInfoView.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/apps/haikudepot/ui/PackageInfoView.cpp b/src/apps/haikudepot/ui/PackageInfoView.cpp index 4b8eeafd7a..0578c9cbad 100644 --- a/src/apps/haikudepot/ui/PackageInfoView.cpp +++ b/src/apps/haikudepot/ui/PackageInfoView.cpp @@ -1265,7 +1265,10 @@ public: // TODO: Sort by age or usefullness rating for (int i = count - 1; i >= 0; i--) { const UserRating& rating = userRatings.ItemAtFast(i); - if (fPreferredLanguages.CountItems() > 0 + // Prevent ratings from showing that have a comment which + // is in another language + if (!rating.Comment().IsEmpty() + && fPreferredLanguages.CountItems() > 0 && !fPreferredLanguages.Contains(rating.Language())) { continue; }