#include <categoryListItem.hpp>
Public Types | |
| typedef QCheckListItem::Type | Type |
Public Member Functions | |
| CategoryListItem (QListView *parent, const QString &text) | |
| virtual int | compare (QListViewItem *i, int col, bool ascending) const |
Definition at line 25 of file categoryListItem.hpp.
| typedef QCheckListItem::Type CategoryListItem::Type |
Definition at line 29 of file categoryListItem.hpp.
| CategoryListItem::CategoryListItem | ( | QListView * | parent, | |
| const QString & | text | |||
| ) |
| int CategoryListItem::compare | ( | QListViewItem * | i, | |
| int | col, | |||
| bool | ascending | |||
| ) | const [virtual] |
Definition at line 27 of file categoryListItem.cpp.
00028 { 00029 int retVal; 00030 if ( col != 1 ) { 00031 double 00032 a = atof( key( col, ascending ) ), 00033 b = atof( i->key( col, ascending ) ); 00034 if ( a < b ) 00035 retVal = -1; 00036 else 00037 if ( a > b ) 00038 retVal = 1; 00039 else 00040 retVal = 0; 00041 } else 00042 retVal = QCheckListItem::compare( i, col, ascending ); 00043 return retVal; 00044 }