[Spambayes-checkins] spambayes/Outlook2000 addin.py,1.69,1.70

Mark Hammond mhammond at users.sourceforge.net
Tue Jul 8 05:34:06 EDT 2003


Update of /cvsroot/spambayes/spambayes/Outlook2000
In directory sc8-pr-cvs1:/tmp/cvs-serv21335

Modified Files:
	addin.py 
Log Message:
Dont allow failure of a single toolbar item to prevent other toolbar items
from being created (they may well all fail, but...)


Index: addin.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/Outlook2000/addin.py,v
retrieving revision 1.69
retrieving revision 1.70
diff -C2 -d -r1.69 -r1.70
*** addin.py	1 Jul 2003 03:15:37 -0000	1.69
--- addin.py	8 Jul 2003 11:34:03 -0000	1.70
***************
*** 621,625 ****
                  parent = self.toolbar
              # Now add the item itself to the parent.
!             item = parent.Controls.Add(Type=control_type, Temporary=False)
          # Hook events for the item, but only if we haven't already in some
          # other explorer instance.
--- 621,631 ----
                  parent = self.toolbar
              # Now add the item itself to the parent.
!             try:
!                 item = parent.Controls.Add(Type=control_type, Temporary=False)
!             except pythoncom.com_error, e:
!                 # Toolbars seem to still fail randomly for some users.
!                 # eg, bug [ 755738 ] Latest CVS outllok doesn't work
!                 print "FAILED to add the toolbar item '%s' - %s" % (tag,e)
!                 return
          # Hook events for the item, but only if we haven't already in some
          # other explorer instance.





More information about the Spambayes-checkins mailing list