Changeset 18001 in vbox for trunk/src/VBox/Frontends/VirtualBox
- Timestamp:
- Mar 17, 2009 9:07:17 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/VBoxImportApplianceWgt.cpp
r17827 r18001 28 28 #include "VBoxOSTypeSelectorButton.h" 29 29 30 /* Qt includes */ 30 31 #include <QItemDelegate> 31 32 #include <QSortFilterProxyModel> 32 33 #include <QHeaderView> 33 34 #include <QLineEdit> 35 #include <QTextEdit> 34 36 #include <QSpinBox> 35 37 #include <QComboBox> … … 249 251 { 250 252 case KVirtualSystemDescriptionType_Name: v = VBoxImportApplianceWgt::tr ("Name"); break; 253 case KVirtualSystemDescriptionType_Description: v = VBoxImportApplianceWgt::tr ("Description"); break; 251 254 case KVirtualSystemDescriptionType_OS: v = VBoxImportApplianceWgt::tr ("Guest OS Type"); break; 252 255 case KVirtualSystemDescriptionType_CPU: v = VBoxImportApplianceWgt::tr ("CPU"); break; … … 295 298 { 296 299 case KVirtualSystemDescriptionType_Name: v = QIcon (":/name_16px.png"); break; 300 case KVirtualSystemDescriptionType_Description: v = QIcon (":/name_16px.png"); break; 297 301 case KVirtualSystemDescriptionType_OS: v = QIcon (":/os_type_16px.png"); break; 298 302 case KVirtualSystemDescriptionType_CPU: v = QIcon (":/cpu_16px.png"); break; … … 369 373 /* Some items are editable */ 370 374 if ((mType == KVirtualSystemDescriptionType_Name || 375 mType == KVirtualSystemDescriptionType_Description || 371 376 mType == KVirtualSystemDescriptionType_OS || 372 377 mType == KVirtualSystemDescriptionType_Memory || … … 405 410 break; 406 411 } 412 case KVirtualSystemDescriptionType_Description: 413 { 414 QTextEdit *e = new QTextEdit (aParent); 415 editor = e; 416 break; 417 } 407 418 case KVirtualSystemDescriptionType_CPU: 408 419 { … … 510 521 break; 511 522 } 523 case KVirtualSystemDescriptionType_Description: 524 { 525 if (QTextEdit *e = qobject_cast<QTextEdit*> (aEditor)) 526 { 527 e->setPlainText (mConfigValue); 528 fDone = true; 529 } 530 break; 531 } 512 532 case KVirtualSystemDescriptionType_SoundCard: 513 533 case KVirtualSystemDescriptionType_NetworkAdapter: … … 579 599 { 580 600 mConfigValue = e->text(); 601 fDone = true; 602 } 603 break; 604 } 605 case KVirtualSystemDescriptionType_Description: 606 { 607 if (QTextEdit *e = qobject_cast<QTextEdit*> (aEditor)) 608 { 609 mConfigValue = e->toPlainText(); 581 610 fDone = true; 582 611 } … … 723 752 { 724 753 KVirtualSystemDescriptionType_Name, 754 KVirtualSystemDescriptionType_Description, 725 755 KVirtualSystemDescriptionType_OS, 726 756 KVirtualSystemDescriptionType_CPU,
Note:
See TracChangeset
for help on using the changeset viewer.