mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
disable-garbage-logging -> auto-garbage-logging
This commit is contained in:
parent
f58c5b591b
commit
bd155bb2e3
@ -535,7 +535,7 @@ class _CFGLGlobals:
|
|||||||
def checkForGarbageLeaks():
|
def checkForGarbageLeaks():
|
||||||
gc.collect()
|
gc.collect()
|
||||||
numGarbage = len(gc.garbage)
|
numGarbage = len(gc.garbage)
|
||||||
if (numGarbage > 0 and (not config.GetBool('disable-garbage-logging', 1))):
|
if (numGarbage > 0 and config.GetBool('auto-garbage-logging', 0)):
|
||||||
if (numGarbage != _CFGLGlobals.LastNumGarbage):
|
if (numGarbage != _CFGLGlobals.LastNumGarbage):
|
||||||
print
|
print
|
||||||
gr = GarbageReport('found garbage', threaded=False, collect=False)
|
gr = GarbageReport('found garbage', threaded=False, collect=False)
|
||||||
|
@ -2401,7 +2401,7 @@ class ShowBase(DirectObject.DirectObject):
|
|||||||
if not properties.getOpen():
|
if not properties.getOpen():
|
||||||
# If the user closes the main window, we should exit.
|
# If the user closes the main window, we should exit.
|
||||||
self.notify.info("User closed main window.")
|
self.notify.info("User closed main window.")
|
||||||
if __dev__ and (not config.GetBool('disable-garbage-logging', 1)):
|
if __dev__ and config.GetBool('auto-garbage-logging', 0):
|
||||||
GarbageReport.b_checkForGarbageLeaks()
|
GarbageReport.b_checkForGarbageLeaks()
|
||||||
self.userExit()
|
self.userExit()
|
||||||
|
|
||||||
@ -2409,7 +2409,7 @@ class ShowBase(DirectObject.DirectObject):
|
|||||||
self.mainWinForeground = 1
|
self.mainWinForeground = 1
|
||||||
elif not properties.getForeground() and self.mainWinForeground:
|
elif not properties.getForeground() and self.mainWinForeground:
|
||||||
self.mainWinForeground = 0
|
self.mainWinForeground = 0
|
||||||
if __dev__ and (not config.GetBool('disable-garbage-logging', 1)):
|
if __dev__ and config.GetBool('auto-garbage-logging', 0):
|
||||||
GarbageReport.b_checkForGarbageLeaks()
|
GarbageReport.b_checkForGarbageLeaks()
|
||||||
|
|
||||||
if properties.getMinimized() and not self.mainWinMinimized:
|
if properties.getMinimized() and not self.mainWinMinimized:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user