From cf6cb4897f288c619fa62a2c538b2e39ddc2f780 Mon Sep 17 00:00:00 2001 From: Josh Wilson Date: Thu, 18 Sep 2008 03:53:30 +0000 Subject: [PATCH] __dev__ -> __debug__ --- direct/src/gui/DirectGuiBase.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/direct/src/gui/DirectGuiBase.py b/direct/src/gui/DirectGuiBase.py index cb28054112..37b6bbafd3 100644 --- a/direct/src/gui/DirectGuiBase.py +++ b/direct/src/gui/DirectGuiBase.py @@ -652,7 +652,10 @@ def toggleGuiGridSnap(): def setGuiGridSpacing(spacing): DirectGuiWidget.gridSpacing = spacing -if config.GetBool('record-gui-creation-stack', __dev__): +# this should trigger off of __dev__, but it's not available at this point. +# __debug__ works because the production client is not __debug__ and the +# production AI doesn't create any GUI. +if config.GetBool('record-gui-creation-stack', __debug__): # this will help track down the code that created DirectGui objects # call obj.printCreationStackTrace() to figure out what code created it DirectGuiBase = recordCreationStackStr(DirectGuiBase)