mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
allow want-direct to work with window-type none
This commit is contained in:
parent
4ff0a5af0e
commit
86d6eeefaf
@ -307,13 +307,6 @@ class ShowBase(DirectObject.DirectObject):
|
||||
# This needs to be allocated even if the viewer is off.
|
||||
self.bufferViewer = BufferViewer()
|
||||
|
||||
# Start Tk and DIRECT if specified by Config.prc
|
||||
fTk = self.config.GetBool('want-tk', 0)
|
||||
# Start DIRECT if specified in Config.prc or in cluster mode
|
||||
fDirect = (self.config.GetBool('want-directtools', 0) or
|
||||
(base.config.GetString("cluster-mode", '') != ''))
|
||||
# Set fWantTk to 0 to avoid starting Tk with this call
|
||||
self.startDirect(fWantDirect = fDirect, fWantTk = fTk)
|
||||
# Start IGLOOP
|
||||
self.restart()
|
||||
|
||||
@ -582,6 +575,14 @@ class ShowBase(DirectObject.DirectObject):
|
||||
# error not to open a window.
|
||||
raise StandardError, 'Could not open window.'
|
||||
|
||||
# Start Tk and DIRECT if specified by Config.prc
|
||||
fTk = self.config.GetBool('want-tk', 0)
|
||||
# Start DIRECT if specified in Config.prc or in cluster mode
|
||||
fDirect = (self.config.GetBool('want-directtools', 0) or
|
||||
(base.config.GetString("cluster-mode", '') != ''))
|
||||
# Set fWantTk to 0 to avoid starting Tk with this call
|
||||
self.startDirect(fWantDirect = fDirect, fWantTk = fTk)
|
||||
|
||||
return self.win != None
|
||||
|
||||
def isMainWindowOpen(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user