[Python-checkins] python/dist/src/Mac/Tools/IDE MacPrefs.py,1.4,1.5
jackjansen@users.sourceforge.net
jackjansen@users.sourceforge.net
Fri, 13 Dec 2002 15:32:53 -0800
Update of /cvsroot/python/python/dist/src/Mac/Tools/IDE
In directory sc8-pr-cvs1:/tmp/cvs-serv2589
Modified Files:
MacPrefs.py
Log Message:
Sigh: the Jaguar workaround for the prefs file broke saving it on OS9. Temporary workaround is to ignore the exception (it's only about file creator/type anyway).
Index: MacPrefs.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Mac/Tools/IDE/MacPrefs.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** MacPrefs.py 30 Nov 2002 00:01:24 -0000 1.4
--- MacPrefs.py 13 Dec 2002 23:32:51 -0000 1.5
***************
*** 71,76 ****
prefdict[key] = value
marshal.dump(prefdict, open(self.__path, 'wb'))
! fss = macfs.FSSpec(macfs.FSRef(self.__path))
! fss.SetCreatorType(self.__creator, 'pref')
def __getattr__(self, attr):
--- 71,79 ----
prefdict[key] = value
marshal.dump(prefdict, open(self.__path, 'wb'))
! try:
! fss = macfs.FSSpec(macfs.FSRef(self.__path))
! fss.SetCreatorType(self.__creator, 'pref')
! except:
! pass
def __getattr__(self, attr):