Changeset 441 in vbox for trunk/src/VBox
- Timestamp:
- Jan 30, 2007 6:07:31 PM (18 years ago)
- Location:
- trunk/src/VBox
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/ui/VBoxVMSettingsDlg.ui.h
r382 r441 974 974 else if (pg == pageVRDP) 975 975 { 976 valid = !(grbVRDP->isChecked() && 977 (leVRDPPort->text().isEmpty() || leVRDPTimeout->text().isEmpty())); 978 if (!valid && leVRDPPort->text().isEmpty()) 979 setWarning (tr ("VRDP Port is not set.")); 980 if (!valid && leVRDPTimeout->text().isEmpty()) 981 setWarning (tr ("VRDP Timeout is not set.")); 976 if (pageVRDP->isEnabled()) 977 { 978 valid = !(grbVRDP->isChecked() && 979 (leVRDPPort->text().isEmpty() || leVRDPTimeout->text().isEmpty())); 980 if (!valid && leVRDPPort->text().isEmpty()) 981 setWarning (tr ("VRDP Port is not set.")); 982 if (!valid && leVRDPTimeout->text().isEmpty()) 983 setWarning (tr ("VRDP Timeout is not set.")); 984 } 985 else 986 valid = true; 982 987 } 983 988 … … 1232 1237 usbItem->setVisible (false); 1233 1238 1239 /* disable validators if any */ 1240 pageUSB->setEnabled (false); 1241 1234 1242 /* if machine has something to say, show the message */ 1235 1243 vboxProblem().cannotLoadMachineSettings (machine, false /* strict */); … … 1244 1252 1245 1253 lvUSBFilters->setCurrentItem (lvUSBFilters->firstChild()); 1246 /* 1247 * silly, silly Qt -- doesn't emit currentChanged after adding the 1248 * first item to an empty list 1249 */ 1254 /* silly Qt -- doesn't emit currentChanged after adding the 1255 * first item to an empty list */ 1250 1256 lvUSBFilters_currentChanged (lvUSBFilters->firstChild()); 1251 1257 } … … 1255 1261 { 1256 1262 CVRDPServer vrdp = machine.GetVRDPServer(); 1257 grbVRDP->setChecked (vrdp.GetEnabled()); 1258 leVRDPPort->setText (QString::number (vrdp.GetPort())); 1259 cbVRDPAuthType->setCurrentText (vboxGlobal().toString (vrdp.GetAuthType())); 1260 leVRDPTimeout->setText (QString::number (vrdp.GetAuthTimeout())); 1263 1264 if (vrdp.isNull()) 1265 { 1266 /* disable the VRDP category if VRDP is 1267 * not available (i.e. in VirtualBox OSE) */ 1268 1269 QListViewItem *vrdpItem = listView->findItem ("#vrdp", listView_Link); 1270 Assert (vrdpItem); 1271 if (vrdpItem) 1272 vrdpItem->setVisible (false); 1273 1274 /* disable validators if any */ 1275 pageVRDP->setEnabled (false); 1276 1277 /* if machine has something to say, show the message */ 1278 vboxProblem().cannotLoadMachineSettings (machine, false /* strict */); 1279 } 1280 else 1281 { 1282 grbVRDP->setChecked (vrdp.GetEnabled()); 1283 leVRDPPort->setText (QString::number (vrdp.GetPort())); 1284 cbVRDPAuthType->setCurrentText (vboxGlobal().toString (vrdp.GetAuthType())); 1285 leVRDPTimeout->setText (QString::number (vrdp.GetAuthTimeout())); 1286 } 1261 1287 } 1262 1288 … … 1271 1297 wvalDVD->revalidate(); 1272 1298 wvalFloppy->revalidate(); 1299 wvalVRDP->revalidate(); 1273 1300 } 1274 1301 … … 1479 1506 { 1480 1507 CVRDPServer vrdp = cmachine.GetVRDPServer(); 1481 vrdp.SetEnabled (grbVRDP->isChecked()); 1482 vrdp.SetPort (leVRDPPort->text().toULong()); 1483 vrdp.SetAuthType (vboxGlobal().toVRDPAuthType (cbVRDPAuthType->currentText())); 1484 vrdp.SetAuthTimeout (leVRDPTimeout->text().toULong()); 1508 1509 if (!vrdp.isNull()) 1510 { 1511 /* VRDP may be unavailable (i.e. in VirtualBox OSE) */ 1512 vrdp.SetEnabled (grbVRDP->isChecked()); 1513 vrdp.SetPort (leVRDPPort->text().toULong()); 1514 vrdp.SetAuthType (vboxGlobal().toVRDPAuthType (cbVRDPAuthType->currentText())); 1515 vrdp.SetAuthTimeout (leVRDPTimeout->text().toULong()); 1516 } 1485 1517 } 1486 1518 -
trunk/src/VBox/Main/ConsoleImpl.cpp
r436 r441 258 258 AssertComRCReturn (rc, rc); 259 259 260 #ifdef VBOX_VRDP 260 261 rc = mMachine->COMGETTER(VRDPServer) (unconst (mVRDPServer).asOutParam()); 261 262 AssertComRCReturn (rc, rc); 263 #endif 262 264 263 265 rc = mMachine->COMGETTER(DVDDrive) (unconst (mDVDDrive).asOutParam()); … … 410 412 unconst (mFloppyDrive).setNull(); 411 413 unconst (mDVDDrive).setNull(); 414 #ifdef VBOX_VRDP 412 415 unconst (mVRDPServer).setNull(); 416 #endif 413 417 414 418 unconst (mControl).setNull(); -
trunk/src/VBox/Main/MachineImpl.cpp
r436 r441 1046 1046 STDMETHODIMP Machine::COMGETTER(VRDPServer)(IVRDPServer **vrdpServer) 1047 1047 { 1048 #ifdef VBOX_VRDP 1048 1049 if (!vrdpServer) 1049 1050 return E_POINTER; … … 1054 1055 AutoReaderLock alock (this); 1055 1056 1056 #ifdef VBOX_VRDP1057 1057 Assert (!!mVRDPServer); 1058 1058 mVRDPServer.queryInterfaceTo (vrdpServer); 1059 1060 return S_OK; 1059 1061 #else 1060 *vrdpServer = NULL;1062 return E_NOTIMPL; 1061 1063 #endif 1062 1063 return S_OK;1064 1064 } 1065 1065
Note:
See TracChangeset
for help on using the changeset viewer.