Changeset 11820 in vbox for trunk/src/VBox/Main/MachineImpl.cpp
- Timestamp:
- Aug 29, 2008 2:09:39 PM (17 years ago)
- svn:sync-xref-src-repo-rev:
- 35651
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/MachineImpl.cpp
r11699 r11820 1275 1275 STDMETHODIMP Machine::COMGETTER(VRDPServer)(IVRDPServer **vrdpServer) 1276 1276 { 1277 #ifdef VBOX_ VRDP1277 #ifdef VBOX_WITH_VRDP 1278 1278 if (!vrdpServer) 1279 1279 return E_POINTER; … … 3624 3624 3625 3625 Bstr type (aType); 3626 if (type == "gui" || type == "GUI/Qt3") 3627 { 3628 #ifdef RT_OS_DARWIN /* Avoid Lanuch Services confusing this with the selector by using a helper app. */ 3629 const char VirtualBox_exe[] = "../Resources/VirtualBoxVM.app/Contents/MacOS/VirtualBoxVM3"; 3630 #else 3631 const char VirtualBox_exe[] = "VirtualBox3" HOSTSUFF_EXE; 3632 #endif 3626 3627 /* Qt4 is default */ 3628 #ifdef VBOX_WITH_QT4GUI 3629 if (type == "gui" || type == "GUI/Qt4") 3630 { 3631 # ifdef RT_OS_DARWIN /* Avoid Lanuch Services confusing this with the selector by using a helper app. */ 3632 const char VirtualBox_exe[] = "../Resources/VirtualBoxVM.app/Contents/MacOS/VirtualBoxVM"; 3633 # else 3634 const char VirtualBox_exe[] = "VirtualBox" HOSTSUFF_EXE; 3635 # endif 3633 3636 Assert (sz >= sizeof (VirtualBox_exe)); 3634 3637 strcpy (cmd, VirtualBox_exe); 3635 3638 3636 3639 Utf8Str idStr = mData->mUuid.toString(); 3637 # ifdef RT_OS_WINDOWS /** @todo drop this once the RTProcCreate bug has been fixed */3640 # ifdef RT_OS_WINDOWS /** @todo drop this once the RTProcCreate bug has been fixed */ 3638 3641 const char * args[] = {path, "-startvm", idStr, 0 }; 3639 # else3642 # else 3640 3643 Utf8Str name = mUserData->mName; 3641 3644 const char * args[] = {path, "-comment", name, "-startvm", idStr, 0 }; 3642 # endif3645 # endif 3643 3646 vrc = RTProcCreate (path, args, env, 0, &pid); 3644 3647 } 3648 #else /* !VBOX_WITH_QT4GUI */ 3649 if (0) 3650 ; 3651 #endif /* VBOX_WITH_QT4GUI */ 3652 3645 3653 else 3646 if (type == "GUI/Qt4") 3647 { 3648 #ifdef RT_OS_DARWIN /* Avoid Lanuch Services confusing this with the selector by using a helper app. */ 3649 const char VirtualBox_exe[] = "../Resources/VirtualBoxVM.app/Contents/MacOS/VirtualBoxVM"; 3650 #else 3651 const char VirtualBox_exe[] = "VirtualBox" HOSTSUFF_EXE; 3652 #endif 3654 3655 /* Qt3 is used sometimes as well, OS/2 does not have Qt4 at all */ 3656 #ifdef VBOX_WITH_QTGUI 3657 if (type == "gui" || type == "GUI/Qt3") 3658 { 3659 # ifdef RT_OS_DARWIN /* Avoid Lanuch Services confusing this with the selector by using a helper app. */ 3660 const char VirtualBox_exe[] = "../Resources/VirtualBoxVM.app/Contents/MacOS/VirtualBoxVM3"; 3661 # else 3662 const char VirtualBox_exe[] = "VirtualBox3" HOSTSUFF_EXE; 3663 # endif 3653 3664 Assert (sz >= sizeof (VirtualBox_exe)); 3654 3665 strcpy (cmd, VirtualBox_exe); 3655 3666 3656 3667 Utf8Str idStr = mData->mUuid.toString(); 3657 # ifdef RT_OS_WINDOWS /** @todo drop this once the RTProcCreate bug has been fixed */3668 # ifdef RT_OS_WINDOWS /** @todo drop this once the RTProcCreate bug has been fixed */ 3658 3669 const char * args[] = {path, "-startvm", idStr, 0 }; 3659 # else3670 # else 3660 3671 Utf8Str name = mUserData->mName; 3661 3672 const char * args[] = {path, "-comment", name, "-startvm", idStr, 0 }; 3662 # endif3673 # endif 3663 3674 vrc = RTProcCreate (path, args, env, 0, &pid); 3664 3675 } 3676 #else /* !VBOX_WITH_QTGUI */ 3677 if (0) 3678 ; 3679 #endif /* !VBOX_WITH_QTGUI */ 3680 3665 3681 else 3666 #ifdef VBOX_VRDP 3682 3683 #ifdef VBOX_WITH_VRDP 3667 3684 if (type == "vrdp") 3668 3685 { … … 3672 3689 3673 3690 Utf8Str idStr = mData->mUuid.toString(); 3674 # ifdef RT_OS_WINDOWS3691 # ifdef RT_OS_WINDOWS 3675 3692 const char * args[] = {path, "-startvm", idStr, 0 }; 3676 # else3693 # else 3677 3694 Utf8Str name = mUserData->mName; 3678 3695 const char * args[] = {path, "-comment", name, "-startvm", idStr, 0 }; 3679 # endif3696 # endif 3680 3697 vrc = RTProcCreate (path, args, env, 0, &pid); 3681 3698 } 3699 #else /* !VBOX_WITH_VRDP */ 3700 if (0) 3701 ; 3702 #endif /* !VBOX_WITH_VRDP */ 3703 3682 3704 else 3683 #endif /* VBOX_VRDP */ 3705 3706 #ifdef VBOX_WITH_HEADLESS 3684 3707 if (type == "capture") 3685 3708 { … … 3689 3712 3690 3713 Utf8Str idStr = mData->mUuid.toString(); 3691 # ifdef RT_OS_WINDOWS3714 # ifdef RT_OS_WINDOWS 3692 3715 const char * args[] = {path, "-startvm", idStr, "-capture", 0 }; 3693 # else3716 # else 3694 3717 Utf8Str name = mUserData->mName; 3695 3718 const char * args[] = {path, "-comment", name, "-startvm", idStr, "-capture", 0 }; 3696 # endif3719 # endif 3697 3720 vrc = RTProcCreate (path, args, env, 0, &pid); 3698 3721 } 3722 #else /* !VBOX_WITH_HEADLESS */ 3723 if (0) 3724 ; 3725 #endif /* !VBOX_WITH_HEADLESS */ 3699 3726 else 3700 3727 { … … 4123 4150 mBIOSSettings->init (this); 4124 4151 4125 #ifdef VBOX_ VRDP4152 #ifdef VBOX_WITH_VRDP 4126 4153 /* create an associated VRDPServer object (default is disabled) */ 4127 4154 unconst (mVRDPServer).createObject(); … … 4252 4279 } 4253 4280 4254 #ifdef VBOX_ VRDP4281 #ifdef VBOX_WITH_VRDP 4255 4282 if (mVRDPServer) 4256 4283 { … … 4808 4835 } 4809 4836 4810 #ifdef VBOX_ VRDP4837 #ifdef VBOX_WITH_VRDP 4811 4838 /* RemoteDisplay */ 4812 4839 rc = mVRDPServer->loadSettings (aNode); … … 6193 6220 } 6194 6221 6195 #ifdef VBOX_ VRDP6222 #ifdef VBOX_WITH_VRDP 6196 6223 /* VRDP settings (optional) */ 6197 6224 rc = mVRDPServer->saveSettings (aNode); … … 7275 7302 mHWData.isBackedUp() || 7276 7303 mHDData.isBackedUp() || 7277 #ifdef VBOX_ VRDP7304 #ifdef VBOX_WITH_VRDP 7278 7305 (mVRDPServer && mVRDPServer->isModified()) || 7279 7306 #endif … … 7318 7345 /* ignore mHDData */ 7319 7346 //mHDData.hasActualChanges() || 7320 #ifdef VBOX_ VRDP7347 #ifdef VBOX_WITH_VRDP 7321 7348 (mVRDPServer && mVRDPServer->isReallyModified()) || 7322 7349 #endif … … 7394 7421 mBIOSSettings->rollback(); 7395 7422 7396 #ifdef VBOX_ VRDP7423 #ifdef VBOX_WITH_VRDP 7397 7424 if (mVRDPServer) 7398 7425 vrdpChanged = mVRDPServer->rollback(); … … 7495 7522 7496 7523 mBIOSSettings->commit(); 7497 #ifdef VBOX_ VRDP7524 #ifdef VBOX_WITH_VRDP 7498 7525 mVRDPServer->commit(); 7499 7526 #endif … … 7561 7588 7562 7589 mBIOSSettings->copyFrom (aThat->mBIOSSettings); 7563 #ifdef VBOX_ VRDP7590 #ifdef VBOX_WITH_VRDP 7564 7591 mVRDPServer->copyFrom (aThat->mVRDPServer); 7565 7592 #endif … … 7808 7835 unconst (mBIOSSettings).createObject(); 7809 7836 mBIOSSettings->init (this, aMachine->mBIOSSettings); 7810 #ifdef VBOX_ VRDP7837 #ifdef VBOX_WITH_VRDP 7811 7838 /* create another VRDPServer object that will be mutable */ 7812 7839 unconst (mVRDPServer).createObject(); … … 10566 10593 mBIOSSettings->initCopy (this, mPeer->mBIOSSettings); 10567 10594 10568 #ifdef VBOX_ VRDP10595 #ifdef VBOX_WITH_VRDP 10569 10596 unconst (mVRDPServer).createObject(); 10570 10597 mVRDPServer->initCopy (this, mPeer->mVRDPServer); … … 10668 10695 mBIOSSettings->init (this); 10669 10696 10670 #ifdef VBOX_ VRDP10697 #ifdef VBOX_WITH_VRDP 10671 10698 unconst (mVRDPServer).createObject(); 10672 10699 mVRDPServer->init (this);
Note:
See TracChangeset
for help on using the changeset viewer.