changeset 144:bfab04d0a745

ListOption: add __hash__ method
author Goffi <goffi@goffi.org>
date Sun, 27 Oct 2019 18:55:47 +0100
parents 144bdf877d21
children d505d9ee792e
files urwid_satext/sat_widgets.py
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/urwid_satext/sat_widgets.py	Tue Aug 13 08:55:41 2019 +0200
+++ b/urwid_satext/sat_widgets.py	Sun Oct 27 18:55:47 2019 +0100
@@ -410,6 +410,9 @@
         except AttributeError:
             return self._value != other
 
+    def __hash__(self):
+        return hash(self._value)
+
     @property
     def value(self):
         """ return option value """