def setPandaErrorCode(self, code): self.pandaErrorCode = code if self.WIN32: self.notify.info('setting panda error code to %s' % code) exitCode2exitPage = {OTPLauncherGlobals.ExitEnableChat: 'chat', OTPLauncherGlobals.ExitSetParentPassword: '******', OTPLauncherGlobals.ExitPurchase: 'purchase'} if code in exitCode2exitPage: self.setRegistry('EXIT_PAGE', exitCode2exitPage[code]) self.setRegistry(self.PandaErrorCodeKey, 0) else: self.setRegistry(self.PandaErrorCodeKey, code) else: LauncherBase.setPandaErrorCode(self, code)
def setPandaErrorCode(self, code): self.pandaErrorCode = code if self.WIN32: self.notify.info('setting panda error code to %s' % code) exitCode2exitPage = { OTPLauncherGlobals.ExitEnableChat: 'chat', OTPLauncherGlobals.ExitSetParentPassword: '******', OTPLauncherGlobals.ExitPurchase: 'purchase'} if code in exitCode2exitPage: self.setRegistry('EXIT_PAGE', exitCode2exitPage[code]) self.setRegistry(self.PandaErrorCodeKey, 0) else: self.setRegistry(self.PandaErrorCodeKey, code) else: LauncherBase.setPandaErrorCode(self, code)
def setPandaErrorCode(self, code): self.pandaErrorCode = code if self.WIN32: self.notify.info("setting panda error code to %s" % code) exitCode2exitPage = { OTPLauncherGlobals.ExitEnableChat: "chat", OTPLauncherGlobals.ExitSetParentPassword: "******", OTPLauncherGlobals.ExitPurchase: "purchase", } if code in exitCode2exitPage: self.setRegistry("EXIT_PAGE", exitCode2exitPage[code]) self.setRegistry(self.PandaErrorCodeKey, 0) else: self.setRegistry(self.PandaErrorCodeKey, code) else: LauncherBase.setPandaErrorCode(self, code)
def setPandaErrorCode(self, code): """ Set the exit code of panda. 0 means everything ok """ self.pandaErrorCode = code if self.WIN32: self.notify.info("setting panda error code to %s" % (code)) exitCode2exitPage = { OTPLauncherGlobals.ExitEnableChat: "chat", OTPLauncherGlobals.ExitSetParentPassword: "******", OTPLauncherGlobals.ExitPurchase: "purchase", } if code in exitCode2exitPage: self.setRegistry("EXIT_PAGE", exitCode2exitPage[code]) self.setRegistry(self.PandaErrorCodeKey, 0) else: # Under Windows, this (currently) goes to the registry. self.setRegistry(self.PandaErrorCodeKey, code) else: # On OSX, we dump the error code to a file on disk. LauncherBase.setPandaErrorCode(self, code)