mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-10 05:47:09 +01:00
Merge pull request #620 from RobinD42/fix-issue595
Fix comparing TreeListItem __eq__ and __ne__
This commit is contained in:
@@ -54,6 +54,8 @@ Changes in this release include the following:
|
||||
* Various fixes in UltimateListCtrl, HyperTreeList and CheckListCtrlMixin.
|
||||
(#592, #349, #612)
|
||||
|
||||
* Fix comparing DataViewItem and TreeListItem objects with None. (#595)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -51,9 +51,10 @@ def run():
|
||||
return (long)self->GetID();
|
||||
""")
|
||||
|
||||
c.addCppMethod('bool', '__eq__', '(wxTreeListItem* other)', "return (self->GetID() == other->GetID());")
|
||||
c.addCppMethod('bool', '__ne__', '(wxTreeListItem* other)', "return (self->GetID() != other->GetID());")
|
||||
|
||||
c.addCppMethod('bool', '__eq__', '(wxTreeListItem* other)',
|
||||
"return other ? (self->GetID() == other->GetID()) : false;")
|
||||
c.addCppMethod('bool', '__ne__', '(wxTreeListItem* other)',
|
||||
"return other ? (self->GetID() != other->GetID()) : true;")
|
||||
|
||||
#-----------------------------------------------------------------
|
||||
c = module.find('wxTreeListItemComparator')
|
||||
|
||||
Reference in New Issue
Block a user