Changeset 27644 in vbox for trunk/src/VBox/Main
- Timestamp:
- Mar 23, 2010 4:07:49 PM (15 years ago)
- Location:
- trunk/src/VBox/Main
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/MachineImpl.cpp
r27610 r27644 7253 7253 * #isReallyModified() returns false. This is necessary for cases when we 7254 7254 * change machine data directly, not through the backup()/commit() mechanism. 7255 * - SaveS_Force: settings will be saved without doing a deep compare of the 7256 * settings structures. This is used when this is called because snapshots 7257 * have changed to avoid the overhead of the deep compare. 7255 7258 * 7256 7259 * @note Must be called from under this object's write lock. Locks children for … … 7355 7358 if (aFlags & SaveS_ResetCurStateModified) 7356 7359 { 7357 // this gets set by restoreSnapshot()7360 // this gets set by takeSnapshot() (if offline snapshot) and restoreSnapshot() 7358 7361 mData->mCurrentStateModified = FALSE; 7362 fNeedsWrite = true; // always, no need to compare 7363 } 7364 else if (aFlags & SaveS_Force) 7365 { 7359 7366 fNeedsWrite = true; // always, no need to compare 7360 7367 } -
trunk/src/VBox/Main/SnapshotImpl.cpp
r27607 r27644 1456 1456 mData->mFirstSnapshot = mData->mCurrentSnapshot; 1457 1457 1458 int flSaveSettings = SaveS_Force; // do not do a deep compare in machine settings, 1459 // snapshots change, so we know we need to save 1458 1460 if (!fOnline) 1459 1461 /* the machine was powered off or saved when taking a snapshot, so 1460 1462 * reset the mCurrentStateModified flag */ 1461 mData->mCurrentStateModified = FALSE;1462 1463 rc = saveSettings(NULL );1463 flSaveSettings |= SaveS_ResetCurStateModified; 1464 1465 rc = saveSettings(NULL, flSaveSettings); 1464 1466 // no need to change for whether VirtualBox.xml needs saving since 1465 1467 // we'll save the global settings below anyway -
trunk/src/VBox/Main/include/MachineImpl.h
r27607 r27644 725 725 SaveS_ResetCurStateModified = 0x01, 726 726 SaveS_InformCallbacksAnyway = 0x02, 727 /* flags for #saveSnapshotSettings() */ 728 SaveSS_CurStateModified = 0x40, 729 SaveSS_CurrentId = 0x80, 727 SaveS_Force = 0x04, 730 728 /* flags for #saveStateSettings() */ 731 729 SaveSTS_CurStateModified = 0x20,
Note:
See TracChangeset
for help on using the changeset viewer.