~unity-team/unity-lens-bliss/trunk

« back to all changes in this revision

Viewing changes to bliss/apps.py

  • Committer: Mikkel Kamstrup Erlandsen
  • Date: 2011-11-04 09:58:40 UTC
  • Revision ID: mikkel.kamstrup@gmail.com-20111104095840-wvq66dpmr5rym08p
Fix some snafu with sorting between scored and unscored results

Show diffs side-by-side

added added

removed removed

Lines of Context:
33
33
                self.score = score
34
34
        
35
35
        def __lt__ (self, other):
36
 
                if other.score :
 
36
                if self.score :
37
37
                        return self.score > other.score # scores sort reverse
38
38
                return self.display_name < other.display_name
39
39
        
40
40
        def __gt__ (self, other):
41
 
                if self.score :
 
41
                if other.score :
42
42
                        return self.score < other.score # scores sort reverse
43
43
                return self.display_name < other.display_name
44
44