Changeset 48285 in vbox for trunk/src/VBox
- Timestamp:
- Sep 5, 2013 12:58:07 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxShell/vboxshell.py
r47981 r48285 207 207 oVBoxMgr = _ctx['global']; 208 208 if oVBoxMgr.errIsOurXcptKind(e): 209 print colored('%s: %s' % (oVBoxMgr. errToString(e), oVBoxMgr.errGetMessage(e)), 'red');209 print colored('%s: %s' % (oVBoxMgr.xcptToString(e), oVBoxMgr.xcptGetMessage(e)), 'red'); 210 210 else: 211 211 print colored(str(e), 'red') … … 845 845 def enum(self): 846 846 return [XPathNodeHolderNIC(self, self.obj), 847 XPathNodeValue(self, self.obj.BIOSSettings, 'bios'), 848 XPathNodeValue(self, self.obj.USBController, 'usb')] 847 XPathNodeValue(self, self.obj.BIOSSettings, 'bios'), ] 849 848 850 849 class XPathNodeHolderNIC(XPathNodeHolder): … … 992 991 if mach.audioAdapter.enabled: 993 992 print " Audio [via audioAdapter]: chip %s; host driver %s" % (asEnumElem(ctx, "AudioControllerType", mach.audioAdapter.audioController), asEnumElem(ctx, "AudioDriverType", mach.audioAdapter.audioDriver)) 994 if mach.USBController.enabled:995 print " USB [via USBController]: high speed %s" % (asState(mach.USBController.enabledEHCI))996 993 print " CPU hotplugging [CPUHotPlugEnabled]: %s" % (asState(mach.CPUHotPlugEnabled)) 997 994 … … 1004 1001 except: 1005 1002 pass 1003 1004 print 1005 print colCat(ctx, " USB Controllers:") 1006 for oUsbCtrl in ctx['global'].getArray(mach, 'USBControllers'): 1007 print " '%s': type %s standard: %#x" \ 1008 % (oUsbCtrl.name, asEnumElem(ctx, "USBControllerType", oUsbCtrl.type), oUsbCtrl.USBStandard); 1009 1006 1010 print 1007 1011 print colCat(ctx, " I/O subsystem info:") … … 1012 1016 if controllers: 1013 1017 print 1014 print colCat(ctx, " Controllers:")1018 print colCat(ctx, " Storage Controllers:") 1015 1019 for controller in controllers: 1016 1020 print " '%s': bus %s type %s" % (controller.name, asEnumElem(ctx, "StorageBus", controller.bus), asEnumElem(ctx, "StorageControllerType", controller.controllerType)) … … 3524 3528 3525 3529 if options.autopath: 3526 cwd = os.getcwd() 3530 asLocations = [ os.getcwd(), ]; 3531 try: sScriptDir = os.path.dirname(os.path.abspath(__file__)); 3532 except: pass; # In case __file__ isn't there. 3533 else: 3534 if platform.system() in [ 'SunOS', ]: 3535 asLocations.append(os.path.join(sScriptDir, 'amd64')); 3536 asLocations.append(sScriptDir); 3537 3538 3527 3539 vpp = os.environ.get("VBOX_PROGRAM_PATH") 3528 if vpp is None \ 3529 and ( os.path.isfile(os.path.join(cwd, "VirtualBox")) \ 3530 or os.path.isfile(os.path.join(cwd, "VirtualBox.exe")) ): 3531 vpp = cwd 3532 print "Autodetected VBOX_PROGRAM_PATH as", vpp 3533 os.environ["VBOX_PROGRAM_PATH"] = vpp 3534 sys.path.append(os.path.join(vpp, "sdk", "installer")) 3540 if vpp is None: 3541 for sCurLoc in asLocations: 3542 print "checking '%s'..." % (sCurLoc,) 3543 3544 if os.path.isfile(os.path.join(sCurLoc, "VirtualBox")) \ 3545 or os.path.isfile(os.path.join(sCurLoc, "VirtualBox.exe")): 3546 print "Autodetected VBOX_PROGRAM_PATH as", sCurLoc 3547 os.environ["VBOX_PROGRAM_PATH"] = sCurLoc 3548 sys.path.append(os.path.join(sCurLoc, "sdk", "installer")) 3549 3535 3550 vsp = os.environ.get("VBOX_SDK_PATH") 3536 if vsp is None and os.path.isfile(os.path.join(cwd, "sdk", "bindings", "VirtualBox.xidl")) : 3537 vsp = os.path.join(cwd, "sdk") 3538 if vsp is None and vpp is not None and os.path.isfile(os.path.join(vpp, "sdk", "bindings", "VirtualBox.xidl")) : 3539 vsp = os.path.join(vpp, "sdk") 3540 if vsp is not None : 3541 print "Autodetected VBOX_SDK_PATH as", vsp 3542 os.environ["VBOX_SDK_PATH"] = vsp 3551 if vsp is None: 3552 for sCurLoc in asLocations: 3553 if os.path.isfile(os.path.join(sCurLoc, "sdk", "bindings", "VirtualBox.xidl")): 3554 print "Autodetected VBOX_SDK_PATH as", sCurLoc 3555 os.environ["VBOX_SDK_PATH"] = sCurLoc 3556 sTmp = os.path.join(sCurLoc, 'sdk', 'bindings', 'xpcom', 'python'); 3557 if os.path.isdir(sTmp): 3558 sys.path.append(sTmp); 3559 del sTmp; 3560 del vsp, vpp, asLocations; 3561 3543 3562 3544 3563 #
Note:
See TracChangeset
for help on using the changeset viewer.