VirtualBox

Ignore:
Timestamp:
May 17, 2016 5:18:29 PM (9 years ago)
Author:
vboxsync
Message:

Main: big settings cleanup and writing optimization. Moved constructors/equality/default checks into the .cpp file, and write only settings which aren't at the default value. Greatly reduces the effort needed to write everything out, especially when a lot of snapshots have to be dealt with. Move the storage controllers to the hardware settings, where they always belonged. No change to the XML file (yet). Lots of settings related cleanups in the API code.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/include/MachineImpl.h

    r60765 r61009  
    3636#include "BandwidthControlImpl.h"
    3737#include "BandwidthGroupImpl.h"
    38 #include "VBox/settings.h"
    3938#ifdef VBOX_WITH_RESOURCE_USAGE_API
    4039#include "Performance.h"
     
    5554
    5655#include "MachineWrap.h"
     56
     57/** @todo r=klaus after moving the various Machine settings structs to
     58 * MachineImpl.cpp it should be possible to eliminate this include. */
     59#include <VBox/settings.h>
    5760
    5861// defines
     
    7679class SessionMachine;
    7780
    78 namespace settings
    79 {
    80     class MachineConfigFile;
    81     struct Snapshot;
    82     struct Hardware;
    83     struct Storage;
    84     struct StorageController;
    85     struct MachineRegistryEntry;
    86 }
    87 
    8881// Machine class
    8982////////////////////////////////////////////////////////////////////////////////
     
    229222    {
    230223        settings::MachineUserData s;
    231         typedef  std::vector<uint8_t> IconBlob;
    232         IconBlob mIcon;
    233224    };
    234225
     
    643634                           const Guid &aCurSnapshotId,
    644635                           Snapshot *aParentSnapshot);
    645     HRESULT i_loadHardware(const settings::Hardware &data, const settings::Debugging *pDbg,
     636    HRESULT i_loadHardware(const Guid *puuidRegistry,
     637                           const Guid *puuidSnapshot,
     638                           const settings::Hardware &data,
     639                           const settings::Debugging *pDbg,
    646640                           const settings::Autostart *pAutostart);
    647641    HRESULT i_loadDebugging(const settings::Debugging *pDbg);
     
    15701564                             const settings::Debugging *pDbg,
    15711565                             const settings::Autostart *pAutostart,
    1572                              const settings::Storage &storage,
    15731566                             IN_GUID aSnapshotId,
    15741567                             const Utf8Str &aStateFilePath);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette