[POS-commit] r3227 - in kiwi/trunk: .

Johan Dahlin jdahlin at async.com.br
Tue Apr 4 20:26:46 BRT 2006


Author: jdahlin
Date: Tue Apr  4 20:26:45 2006
New Revision: 3227

Modified:
   kiwi/trunk/ChangeLog
   kiwi/trunk/kiwi/ui/entry.py

Log:
    * kiwi/ui/entry.py: Clean up the handling of the exact_completion
    property.



Modified: kiwi/trunk/ChangeLog
==============================================================================
--- kiwi/trunk/ChangeLog	(original)
+++ kiwi/trunk/ChangeLog	Tue Apr  4 20:26:45 2006
@@ -1,5 +1,8 @@
 2006-04-04  Johan Dahlin  <jdahlin at async.com.br>
 
+	* kiwi/ui/entry.py: Clean up the handling of the exact_completion
+	property.
+
 	* kiwi/python.py: Get rid of GObject stuff in base classes, move 
 	it to kiwi utils
 	* kiwi/utils.py: inline class initiable meta here 

Modified: kiwi/trunk/kiwi/ui/entry.py
==============================================================================
--- kiwi/trunk/kiwi/ui/entry.py	(original)
+++ kiwi/trunk/kiwi/ui/entry.py	Tue Apr  4 20:26:45 2006
@@ -117,13 +117,7 @@
     # Properties
 
     def prop_set_exact_completion(self, value):
-        if value:
-            match_func = self._completion_exact_match_func
-        else:
-            match_func = self._completion_normal_match_func
-        completion = self._get_completion()
-        completion.set_match_func(match_func)
-
+        self.set_exact_completion(value)
         return value
 
     def prop_set_completion(self, value):
@@ -296,7 +290,12 @@
         @type value:  boolean
         """
 
-        self.exact_completion = value
+        if value:
+            match_func = self._completion_exact_match_func
+        else:
+            match_func = self._completion_normal_match_func
+        completion = self._get_completion()
+        completion.set_match_func(match_func)
 
     # Private
 
@@ -380,7 +379,7 @@
         gtk.Entry.set_completion(self, completion)
         completion.set_model(gtk.ListStore(str, object))
         completion.set_text_column(0)
-        self.exact_completion = False
+        self.set_exact_completion(False)
         completion.connect("match-selected",
                            self._on_completion__match_selected)
         self._current_object = None


More information about the POS-commit mailing list