[POS-commit] Kiwi/Kiwi List.py,1.88,1.89 Validators.py,1.16,1.17
Views.py,1.110,1.111 __init__.py,1.43,1.44
Christian Robottom Reis
kiko at async.com.br
Sat Oct 25 01:36:15 BRDT 2003
- Previous message: [POS-commit] Kiwi/Kiwi List.py,1.87,1.88 Validators.py,1.15,1.16
Views.py,1.109,1.110 __init__.py,1.42,1.43
- Next message: [POS-commit] Kiwi/Kiwi Validators.py,1.17,1.18
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvs/Kiwi/Kiwi
In directory anthem:/tmp/cvs-serv24253
Modified Files:
List.py Validators.py Views.py __init__.py
Log Message:
Reverting last checkin to get annotation right
Index: __init__.py
===================================================================
RCS file: /cvs/Kiwi/Kiwi/__init__.py,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -d -r1.43 -r1.44
--- __init__.py 25 Oct 2003 00:19:50 -0000 1.43
+++ __init__.py 25 Oct 2003 00:36:13 -0000 1.44
@@ -30,19 +30,22 @@
# Wanted:
# - Entry Validation
# - Check for dependencies on installation and adjust pygtk.require?
+# - Use callable() where appropriate
+# - Use Widget() to specify widgets, more flexible
#
# - Right-aligned Entry (jdahlin) -> gtkhacks
#
-# - Use Widget() to specify widgets, more flexible
# - Proxy: make it work through Composition
# - Try and clean up the hack in Proxies for _connect() et al.
-# - Proxy: warn if Model doesn't inherit from FrameWork.Model and
+# - Allow creating a Proxy with an empty model
+# - Proxy: warn if Model doesn't inherit from FrameWork.model and
# multiple Views are attached
#
# - CListDelegate display handler/filter
# - Make CList and CTree share some functions through a common base
# class
# - Allow cycling alignment in CList without breaking the arrow boxes
+# - Combo signal attaching for list items
# - Kiwi Menu factories
#
# Janitorial:
Index: Validators.py
===================================================================
RCS file: /cvs/Kiwi/Kiwi/Validators.py,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- Validators.py 25 Oct 2003 00:19:50 -0000 1.16
+++ Validators.py 25 Oct 2003 00:36:13 -0000 1.17
@@ -22,6 +22,8 @@
# Author(s): Guilherme Salgado <salgado at async.com.br>
#
+import string
+
from initgtk import gtk, _warn, TRUE, FALSE
from Proxies import _attrwarn, ValueUnset, kgetattr
Index: Views.py
===================================================================
RCS file: /cvs/Kiwi/Kiwi/Views.py,v
retrieving revision 1.110
retrieving revision 1.111
diff -u -d -r1.110 -r1.111
--- Views.py 25 Oct 2003 00:19:50 -0000 1.110
+++ Views.py 25 Oct 2003 00:36:13 -0000 1.111
@@ -29,7 +29,7 @@
"""
import os, string, re, sys
-from types import StringType, ListType, TupleType
+from types import StringType, ListType, TupleType, FunctionType
from initgtk import _warn, _non_interactive, ktype, TRUE, FALSE
import gtk, libglade, GDK
@@ -483,7 +483,7 @@
dict = {}
for name, method in methods.items():
- if callable(method):
+ if type(method) == FunctionType:
dict[name] = method
self.tree.signal_autoconnect(dict)
Index: List.py
===================================================================
RCS file: /cvs/Kiwi/Kiwi/List.py,v
retrieving revision 1.88
retrieving revision 1.89
diff -u -d -r1.88 -r1.89
--- List.py 25 Oct 2003 00:19:50 -0000 1.88
+++ List.py 25 Oct 2003 00:36:13 -0000 1.89
@@ -26,8 +26,8 @@
"""Defines enhanced versions of CTree and CList"""
import string
-from types import TypeType, TupleType, FloatType, IntType, ListType, \
- StringType, NoneType
+from types import TypeType, TupleType, FunctionType,\
+ FloatType, IntType, ListType, MethodType, NoneType, StringType
import initgtk
from initgtk import _warn, ktype, USE_MX, TRUE, FALSE
@@ -593,7 +593,7 @@
raise IndexError, "list index out of range"
tp = type(items)
if tp not in (TupleType, ListType):
- raise TypeError, "Argument to __setitem__ must be a sequence"
+ raise TypeError, "Argument to __setitem__ must be a list"
# This is a bit of a hack designed to permit both forms:
# clist[3] = ["aaa", "bbb" ]
# clist[3] = [ ["aaa", "bbb"], row_data ]
@@ -1090,7 +1090,7 @@
# if sort is already enabled, no need to redo
return TRUE
if callback:
- if not callable(callback):
+ if type(callback) not in (MethodType, FunctionType):
msg = "second attribute must be callable, found %s"
raise TypeError, msg % callback
self.sort_callback = callback
@@ -1103,9 +1103,9 @@
# sort_with_type.
if typelist:
for t in typelist:
- if t is NoneType:
+ if type(t) is NoneType:
raise TypeError, "Types in list may *not* be of NoneType"
- if t is not StringType:
+ if type(t) is not StringType:
# The first non-string occurence indicates we need
# kiwi's special sorting.
self.typelist = typelist
- Previous message: [POS-commit] Kiwi/Kiwi List.py,1.87,1.88 Validators.py,1.15,1.16
Views.py,1.109,1.110 __init__.py,1.42,1.43
- Next message: [POS-commit] Kiwi/Kiwi Validators.py,1.17,1.18
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the POS-commit
mailing list