comment key use
This commit is contained in:
@@ -514,8 +514,11 @@ By \a clicking on a header the list get \a reordered, first up, and then down al
|
||||
void append(std::initializer_list<nana::string>); ///<Appends categories at the end
|
||||
cat_proxy insert(cat_proxy, nana::string);
|
||||
cat_proxy at(size_type pos) const;
|
||||
|
||||
/// add categories in order when use a key?
|
||||
listbox& ordered_categories(bool);
|
||||
|
||||
/// return a proxy to tha cat with the key or create a new one in the right order
|
||||
template<typename Key>
|
||||
cat_proxy operator[](const Key & ck)
|
||||
{
|
||||
|
||||
@@ -22,10 +22,10 @@ namespace nana
|
||||
virtual ~key_interface(){}
|
||||
|
||||
virtual bool same_type(const key_interface*) const = 0;
|
||||
virtual bool compare(const key_interface*) const = 0;
|
||||
virtual bool compare(const key_interface*) const = 0; ///< is this key less than right key? [call it less(rk), less_than(rk) or compare_less(rk)?: if (lk.less_than(rk )) ]
|
||||
}; //end class key_interface
|
||||
|
||||
//Use less compare for equal compare
|
||||
//Use less compare for equal compare [call it equal_by_less()?]
|
||||
inline bool pred_equal_by_less(const key_interface * left, const key_interface* right)
|
||||
{
|
||||
return (left->compare(right) == false) && (right->compare(left) == false);
|
||||
|
||||
Reference in New Issue
Block a user