Changeset 19239 in vbox for trunk/src/VBox/Frontends/VirtualBox/include
- Timestamp:
- Apr 28, 2009 1:19:14 PM (16 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/include
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/include/VBoxGlobal.h
r19203 r19239 25 25 26 26 #include "COMDefs.h" 27 #include "VBox/com/Guid.h" 27 28 28 29 #include "VBoxGlobalSettings.h" … … 51 52 { 52 53 public: 53 VBoxMachineStateChangeEvent (const Q Uuid&aId, KMachineState aState)54 VBoxMachineStateChangeEvent (const QString &aId, KMachineState aState) 54 55 : QEvent ((QEvent::Type) VBoxDefs::MachineStateChangeEventType) 55 56 , id (aId), state (aState) 56 57 {} 57 58 58 const Q Uuidid;59 const QString id; 59 60 const KMachineState state; 60 61 }; … … 63 64 { 64 65 public: 65 VBoxMachineDataChangeEvent (const Q Uuid&aId)66 VBoxMachineDataChangeEvent (const QString &aId) 66 67 : QEvent ((QEvent::Type) VBoxDefs::MachineDataChangeEventType) 67 68 , id (aId) 68 69 {} 69 70 70 const Q Uuidid;71 const QString id; 71 72 }; 72 73 … … 74 75 { 75 76 public: 76 VBoxMachineRegisteredEvent (const Q Uuid&aId, bool aRegistered)77 VBoxMachineRegisteredEvent (const QString &aId, bool aRegistered) 77 78 : QEvent ((QEvent::Type) VBoxDefs::MachineRegisteredEventType) 78 79 , id (aId), registered (aRegistered) 79 80 {} 80 81 81 const Q Uuidid;82 const QString id; 82 83 const bool registered; 83 84 }; … … 86 87 { 87 88 public: 88 VBoxSessionStateChangeEvent (const Q Uuid&aId, KSessionState aState)89 VBoxSessionStateChangeEvent (const QString &aId, KSessionState aState) 89 90 : QEvent ((QEvent::Type) VBoxDefs::SessionStateChangeEventType) 90 91 , id (aId), state (aState) 91 92 {} 92 93 93 const Q Uuidid;94 const QString id; 94 95 const KSessionState state; 95 96 }; … … 101 102 enum What { Taken, Discarded, Changed }; 102 103 103 VBoxSnapshotEvent (const Q Uuid &aMachineId, const QUuid&aSnapshotId,104 VBoxSnapshotEvent (const QString &aMachineId, const QString &aSnapshotId, 104 105 What aWhat) 105 106 : QEvent ((QEvent::Type) VBoxDefs::SnapshotEventType) … … 110 111 const What what; 111 112 112 const Q UuidmachineId;113 const Q UuidsnapshotId;113 const QString machineId; 114 const QString snapshotId; 114 115 }; 115 116 … … 285 286 bool trayIconInstall(); 286 287 #endif 287 Q UuidmanagedVMUuid() const { return vmUuid; }288 QString managedVMUuid() const { return vmUuid; } 288 289 289 290 VBoxDefs::RenderMode vmRenderMode() const { return vm_render_mode; } … … 609 610 { checkForAutoConvertedSettings (true); } 610 611 611 CSession openSession (const Q Uuid&aId, bool aExisting = false);612 CSession openSession (const QString &aId, bool aExisting = false); 612 613 613 614 /** Shortcut to openSession (aId, true). */ 614 CSession openExistingSession (const Q Uuid&aId) { return openSession (aId, true); }615 616 bool startMachine (const Q Uuid&id);615 CSession openExistingSession (const QString &aId) { return openSession (aId, true); } 616 617 bool startMachine (const QString &id); 617 618 618 619 void startEnumeratingMedia(); … … 634 635 void addMedium (const VBoxMedium &); 635 636 void updateMedium (const VBoxMedium &); 636 void removeMedium (VBoxDefs::MediaType, const Q Uuid&);637 void removeMedium (VBoxDefs::MediaType, const QString &); 637 638 638 639 bool findMedium (const CMedium &, VBoxMedium &) const; … … 795 796 796 797 /** Emitted when the media is removed using #removeMedia(). */ 797 void mediumRemoved (VBoxDefs::MediaType, const Q Uuid&);798 void mediumRemoved (VBoxDefs::MediaType, const QString &); 798 799 799 800 /* signals emitted when the VirtualBox callback is called by the server … … 852 853 VBoxUpdateDlg *mUpdDlg; 853 854 854 Q UuidvmUuid;855 QString vmUuid; 855 856 856 857 #ifdef VBOX_GUI_WITH_SYSTRAY -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxMediaComboBox.h
r13580 r19239 35 35 public: 36 36 37 typedef QMap <Q Uuid, QUuid> BaseToDiffMap;37 typedef QMap <QString, QString> BaseToDiffMap; 38 38 39 39 VBoxMediaComboBox (QWidget *aParent); … … 42 42 void repopulate(); 43 43 44 Q Uuidid (int = -1) const;44 QString id (int = -1) const; 45 45 QString location (int = -1) const; 46 46 47 void setCurrentItem (const Q Uuid&aItemId);47 void setCurrentItem (const QString &aItemId); 48 48 void setType (VBoxDefs::MediaType aMediaType); 49 void setMachineId (const Q Uuid &aMachineId = QUuid());49 void setMachineId (const QString &aMachineId = QString::null); 50 50 51 51 void setShowDiffs (bool aShowDiffs); … … 59 59 void mediumAdded (const VBoxMedium &); 60 60 void mediumUpdated (const VBoxMedium &); 61 void mediumRemoved (VBoxDefs::MediaType, const Q Uuid&);61 void mediumRemoved (VBoxDefs::MediaType, const QString &); 62 62 63 63 void processActivated (int aIndex); … … 75 75 void replaceItem (int, const VBoxMedium &); 76 76 77 bool findMediaIndex (const Q Uuid&aId, int &aIndex);77 bool findMediaIndex (const QString &aId, int &aIndex); 78 78 79 79 VBoxDefs::MediaType mType; … … 83 83 { 84 84 Medium() {} 85 Medium (const Q Uuid&aId, const QString &aLocation,85 Medium (const QString &aId, const QString &aLocation, 86 86 const QString aToolTip) 87 87 : id (aId), location (aLocation), toolTip (aToolTip) {} 88 88 89 Q Uuidid;89 QString id; 90 90 QString location; 91 91 QString toolTip; … … 95 95 Media mMedia; 96 96 97 Q UuidmLastId;97 QString mLastId; 98 98 99 99 bool mShowDiffs : 1; 100 100 101 Q UuidmMachineId;101 QString mMachineId; 102 102 }; 103 103 -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxMediaManagerDlg.h
r13580 r19239 52 52 bool aRefresh = true, 53 53 const CMachine &aSessionMachine = CMachine(), 54 const Q Uuid &aSelectId = QUuid(),54 const QString &aSelectId = QString::null, 55 55 bool aShowDiffs = true); 56 56 57 57 static void showModeless (QWidget *aParent = NULL, bool aRefresh = true); 58 58 59 Q UuidselectedId() const;59 QString selectedId() const; 60 60 QString selectedLocation() const; 61 61 … … 77 77 void mediumAdded (const VBoxMedium &aMedium); 78 78 void mediumUpdated (const VBoxMedium &aMedium); 79 void mediumRemoved (VBoxDefs::MediaType aType, const Q Uuid&aId);79 void mediumRemoved (VBoxDefs::MediaType aType, const QString &aId); 80 80 81 81 void mediumEnumStarted(); … … 88 88 void doReleaseMedium(); 89 89 90 bool releaseMediumFrom (const VBoxMedium &aMedium, const Q Uuid&aMachineId);90 bool releaseMediumFrom (const VBoxMedium &aMedium, const QString &aMachineId); 91 91 92 92 void processCurrentChanged (int index = -1); … … 117 117 void updateTabIcons (MediaItem *aItem, ItemAction aAction); 118 118 119 MediaItem* searchItem (QTreeWidget *aTree, const Q Uuid&aId) const;119 MediaItem* searchItem (QTreeWidget *aTree, const QString &aId) const; 120 120 121 121 bool checkMediumFor (MediaItem *aItem, Action aAction); … … 162 162 /* Machine */ 163 163 CMachine mSessionMachine; 164 Q UuidmSessionMachineId;164 QString mSessionMachineId; 165 165 bool mHardDisksInaccessible; 166 166 bool mDVDImagesInaccessible; 167 167 bool mFloppyImagesInaccessible; 168 Q UuidmHDSelectedId;169 Q UuidmDVDSelectedId;170 Q UuidmFloppySelectedId;168 QString mHDSelectedId; 169 QString mDVDSelectedId; 170 QString mFloppySelectedId; 171 171 }; 172 172 -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxMedium.h
r17385 r19239 135 135 const CFloppyImage &floppyImage() const { return mFloppyImage; } 136 136 137 Q Uuidid() const { return mId; }137 QString id() const { return mId; } 138 138 139 139 QString location (bool aNoDiffs = false) const … … 179 179 * current state. 180 180 */ 181 bool isAttachedInCurStateTo (const Q Uuid&aMachineId) const181 bool isAttachedInCurStateTo (const QString &aMachineId) const 182 182 { return mCurStateMachineIds.indexOf (aMachineId) >= 0; } 183 183 … … 186 186 * to in their current state (i.e. excluding snapshots). 187 187 */ 188 const QList <Q Uuid> &curStateMachineIds() const188 const QList <QString> &curStateMachineIds() const 189 189 { return mCurStateMachineIds; } 190 190 … … 235 235 CFloppyImage mFloppyImage; 236 236 237 Q UuidmId;237 QString mId; 238 238 QString mLocation; 239 239 QString mName; … … 250 250 bool mIsUsedInSnapshots : 1; 251 251 252 QList <Q Uuid> mCurStateMachineIds;252 QList <QString> mCurStateMachineIds; 253 253 254 254 VBoxMedium *mParent; -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxSelectorWnd.h
r17730 r19239 77 77 void vmSettings (const QString &aCategory = QString::null, 78 78 const QString &aControl = QString::null, 79 const Q Uuid & = QUuid_null);80 void vmDelete (const Q Uuid & = QUuid_null);81 void vmStart (const Q Uuid & = QUuid_null);82 void vmDiscard (const Q Uuid & = QUuid_null);83 void vmPause (bool, const Q Uuid & = QUuid_null);84 void vmRefresh (const Q Uuid & = QUuid_null);85 void vmShowLogs (const Q Uuid & = QUuid_null);79 const QString & = QString::null); 80 void vmDelete (const QString & = QString::null); 81 void vmStart (const QString & = QString::null); 82 void vmDiscard (const QString & = QString::null); 83 void vmPause (bool, const QString & = QString::null); 84 void vmRefresh (const QString & = QString::null); 85 void vmShowLogs (const QString & = QString::null); 86 86 87 87 void refreshVMList(); 88 void refreshVMItem (const Q Uuid&aID, bool aDetails,88 void refreshVMItem (const QString &aID, bool aDetails, 89 89 bool aSnapshots, 90 90 bool aDescription); … … 189 189 #ifdef VBOX_GUI_WITH_SYSTRAY 190 190 191 Q_DECLARE_METATYPE(Q Uuid);191 Q_DECLARE_METATYPE(QString); 192 192 193 193 class VBoxTrayIcon : public QSystemTrayIcon -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxSnapshotsWgt.h
r10852 r19239 73 73 74 74 void refreshAll (bool aKeepSelected = true); 75 SnapshotWgtItem* findItem (const Q Uuid&aSnapshotId);75 SnapshotWgtItem* findItem (const QString &aSnapshotId); 76 76 SnapshotWgtItem* curStateItem(); 77 77 void populateSnapshots (const CSnapshot &aSnapshot, QTreeWidgetItem *aItem); 78 78 79 79 CMachine mMachine; 80 Q UuidmMachineId;80 QString mMachineId; 81 81 KSessionState mSessionState; 82 82 SnapshotWgtItem *mCurSnapshotItem; -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxVMListView.h
r17412 r19239 44 44 QString name() const { return mName; } 45 45 QIcon osIcon() const { return mAccessible ? vboxGlobal().vmGuestOSTypeIcon (mOSTypeId) : QPixmap (":/os_other.png"); } 46 Q Uuidid() const { return mId; }46 QString id() const { return mId; } 47 47 48 48 QString sessionStateName() const; … … 70 70 71 71 /* Cached machine data (to minimize server requests) */ 72 Q UuidmId;72 QString mId; 73 73 QString mSettingsFile; 74 74 … … 113 113 void clear(); 114 114 115 VBoxVMItem *itemById (const Q Uuid&aId) const;115 VBoxVMItem *itemById (const QString &aId) const; 116 116 VBoxVMItem *itemByRow (int aRow) const; 117 QModelIndex indexById (const Q Uuid&aId) const;118 119 int rowById (const Q Uuid&aId) const;;117 QModelIndex indexById (const QString &aId) const; 118 119 int rowById (const QString &aId) const;; 120 120 121 121 void sort (Qt::SortOrder aOrder = Qt::AscendingOrder) { sort (0, aOrder); } … … 148 148 149 149 void selectItemByRow (int row); 150 void selectItemById (const Q Uuid&aID);150 void selectItemById (const QString &aID); 151 151 void ensureSomeRowSelected (int aRowHint); 152 152 VBoxVMItem * selectedItem() const; -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxVMSettingsCD.h
r13580 r19239 65 65 QIWidgetValidator *mValidator; 66 66 QVector<CHostDVDDrive> mHostCDs; 67 Q UuidmUuidIsoCD;67 QString mUuidIsoCD; 68 68 QRadioButton *mLastSelected; 69 69 }; -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxVMSettingsFD.h
r13580 r19239 65 65 QIWidgetValidator *mValidator; 66 66 QVector<CHostFloppyDrive> mHostFDs; 67 Q UuidmUuidIsoFD;67 QString mUuidIsoFD; 68 68 QRadioButton *mLastSelected; 69 69 }; -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxVMSettingsHD.h
r17884 r19239 79 79 public: 80 80 DiskValue() 81 : id (Q Uuid())81 : id (QString::null) 82 82 , name (QString::null), tip (QString::null), pix (QPixmap()) {} 83 DiskValue (const Q Uuid&aId);83 DiskValue (const QString &aId); 84 84 DiskValue (const DiskValue &aOther) 85 85 : id (aOther.id) … … 105 105 } 106 106 107 Q Uuidid;107 QString id; 108 108 QString name; 109 109 QString tip; … … 382 382 383 383 /* private functions */ 384 Q Uuid getWithMediaManager (const QUuid &aInitialId = QUuid());385 Q UuidgetWithNewHDWizard();384 QString getWithMediaManager (const QString &aInitialId = QString::null); 385 QString getWithNewHDWizard(); 386 386 int maxNameLength() const; 387 387 void prepareComboboxes();
Note:
See TracChangeset
for help on using the changeset viewer.