[kupfer] objects: Include Source name in Source's repr



commit 0d0d663679d71858ff9e335afa086589ecf4713f
Author: Ulrik Sverdrup <ulrik sverdrup gmail com>
Date:   Thu Aug 20 23:27:17 2009 +0200

    objects: Include Source name in Source's repr
    
    If not, it will not be reloaded on locale change

 kupfer/objects.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/kupfer/objects.py b/kupfer/objects.py
index c601184..ffb5ae4 100644
--- a/kupfer/objects.py
+++ b/kupfer/objects.py
@@ -784,7 +784,8 @@ class Source (KupferObject, pretty.OutputMixin):
 		return hash(repr(self))
 
 	def repr_key(self):
-		return ""
+		# use the source's name so that it is reloaded on locale change
+		return self
 
 	def get_items(self):
 		"""



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]