Only in Formulator-PATCHED: #FieldRegistry.py# diff -c Formulator/FieldHelpTopic.py Formulator-PATCHED/FieldHelpTopic.py *** Formulator/FieldHelpTopic.py Tue Mar 16 12:06:46 2004 --- Formulator-PATCHED/FieldHelpTopic.py Mon May 24 16:59:06 2004 *************** *** 33,35 **** --- 33,57 ---- """ return self.field_class.form.get_fields_in_group(group) + + def __eq__(self,other): + try: + gs= self.get_groups() + if gs != other.get_groups(): return 0 + for g in gs: + fs= self.get_fields_in_group(g) + ofs= other.get_fields_in_group(g) + if len(fs) != len(ofs): return 0 + for i in range(len(fs)): + f= fs[i]; of= ofs[i] + if f.id != of.id \ + or f.get_value('title') != of.get_value('title') \ + or f.get_value('description') != of.get_value('description'): + return 0 + return 1 + except AttributeError: return 0 + + + def __ne__(self,other): return not (self == other) + + Only in Formulator-PATCHED: FieldHelpTopic.py.orig diff -c Formulator/FieldRegistry.py Formulator-PATCHED/FieldRegistry.py *** Formulator/FieldRegistry.py Tue Mar 16 12:06:46 2004 --- Formulator-PATCHED/FieldRegistry.py Mon May 24 17:04:37 2004 *************** *** 50,64 **** getattr(field_class, 'internal_field')): continue - # unregister any help topic already registered - if field_name in help.objectIds('Help Topic'): - help._delObject(field_name) # register help topic ht = FieldHelpTopic(field_name, "Formulator Field - %s" % field_name, field_class) context.registerHelpTopic(field_name, ht) def initializeFields(self): --- 50,66 ---- getattr(field_class, 'internal_field')): continue # register help topic ht = FieldHelpTopic(field_name, "Formulator Field - %s" % field_name, field_class) + # unregister, if necessary + if field_name in help.objectIds('Help Topic'): + if ht == help._getOb(field_name): continue + help._delObject(field_name) + context.registerHelpTopic(field_name, ht) def initializeFields(self): Only in Formulator-PATCHED: FieldRegistry.py.ORIG Only in Formulator-PATCHED: FieldRegistry.py.orig Only in Formulator-PATCHED: __init__.py.ORIG Common subdirectories: Formulator/dtml and Formulator-PATCHED/dtml Common subdirectories: Formulator/help and Formulator-PATCHED/help Common subdirectories: Formulator/tests and Formulator-PATCHED/tests Common subdirectories: Formulator/www and Formulator-PATCHED/www