VirtualBox

Changeset 75417 in vbox


Ignore:
Timestamp:
Nov 13, 2018 12:07:20 PM (6 years ago)
Author:
vboxsync
Message:

Recording/Main: Simplified code a bit; use the stream settings file name instead of having another file name defined.

Location:
trunk/src/VBox/Main
Files:
2 edited

Legend:

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

    r75361 r75417  
    174174        /** File handle to use for writing. */
    175175        RTFILE              hFile;
    176         /** File name being used for this stream. */
    177         Utf8Str             strName;
    178176        /** Pointer to WebM writer instance being used. */
    179177        WebMWriter         *pWEBM;
  • trunk/src/VBox/Main/src-client/RecordingStream.cpp

    r75393 r75417  
    155155                if (RT_SUCCESS(rc))
    156156                {
    157                     this->File.hFile   = hFile;
    158                     this->File.strName = pszFile;
     157                    this->File.hFile = hFile;
     158                    this->ScreenSettings.File.strName = pszFile;
    159159                }
    160160            }
     
    697697int RecordingStream::initInternal(RecordingContext *a_pCtx, uint32_t uScreen, const settings::RecordingScreenSettings &Settings)
    698698{
     699    this->pCtx           = a_pCtx;
     700    this->uScreenID      = uScreen;
     701    this->ScreenSettings = Settings;
     702
    699703    int rc = parseOptionsString(Settings.strOptions);
    700704    if (RT_FAILURE(rc))
     
    730734        case RecordingDestination_File:
    731735        {
     736            Assert(this->ScreenSettings.File.strName.isNotEmpty());
    732737            const char *pszFile = this->ScreenSettings.File.strName.c_str();
    733738
     
    811816    if (RT_SUCCESS(rc))
    812817    {
    813         this->pCtx           = a_pCtx;
    814         this->enmState       = RECORDINGSTREAMSTATE_INITIALIZED;
    815         this->fEnabled       = true;
    816         this->uScreenID      = uScreen;
    817         this->tsStartMs      = RTTimeMilliTS();
    818         this->ScreenSettings = Settings;
     818        this->enmState  = RECORDINGSTREAMSTATE_INITIALIZED;
     819        this->fEnabled  = true;
     820        this->tsStartMs = RTTimeMilliTS();
    819821    }
    820822    else
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