From 35fac86d24d3a5db7e3fa9180feed772bb73be75 Mon Sep 17 00:00:00 2001 From: Dave Schuyler Date: Thu, 27 Jan 2005 00:35:55 +0000 Subject: [PATCH] changed debugCall and debugStateCall --- direct/src/directnotify/Notifier.py | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/direct/src/directnotify/Notifier.py b/direct/src/directnotify/Notifier.py index 1437d94287..eca88ac9e7 100644 --- a/direct/src/directnotify/Notifier.py +++ b/direct/src/directnotify/Notifier.py @@ -213,6 +213,7 @@ class Notifier: call followed by the [fsm state] notifier category and the function call (with parameters). """ + #f.f_locals['self'].__init__.im_class.__name__ if (self.__debug): state = '' doId = '' @@ -234,20 +235,18 @@ class Notifier: if hasattr(obj, 'doId'): doId = " doId:%s"%(obj.doId,) - if 1 or type(obj) == types.ClassType: - name = "%s."%(obj.__class__.__name__,) - else: - name = "%s "%(self.__name,) - string = ":%s [%-7s]%s %s %s%s"%( + #if type(obj) == types.ClassType: + # name = "%s."%(obj.__class__.__name__,) + string = ":%s:%s [%-7s] id(%s)%s %s"%( self.getOnlyTime(), + self.__name, state, - doId, id(obj), - name, + doId, PythonUtil.traceParentCall()) self.__log(string) self.__print(string) - return 1 # to allow assert(myNotify.debug("blah")) + return 1 # to allow assert self.notify.debugStateCall(self) def debugCall(self, debugString=''): """ @@ -256,12 +255,12 @@ class Notifier: the function call (with parameters). """ if (self.__debug): - string = ":%s %s %s.%s"%( + string = ":%s:%s \"%s\" %s"%( self.getOnlyTime(), - debugString, self.__name, + debugString, PythonUtil.traceParentCall()) self.__log(string) self.__print(string) - return 1 # to allow assert(myNotify.debug("blah")) + return 1 # to allow assert self.notify.debugCall("blah")