VirtualBox

Ignore:
Timestamp:
Jul 1, 2020 10:42:45 AM (4 years ago)
Author:
vboxsync
Message:

DnD/Main: Renaming internal send/receive data contexts to emphasize that these actually are classes and not POD types.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-client/GuestDnDTargetImpl.cpp

    r84998 r85018  
    7878public:
    7979
    80     SendDataTask(GuestDnDTarget *pTarget, PSENDDATACTX pCtx)
     80    SendDataTask(GuestDnDTarget *pTarget, GuestDnDSendCtx *pCtx)
    8181        : GuestDnDTargetTask(pTarget),
    8282          mpCtx(pCtx)
     
    100100
    101101
    102     PSENDDATACTX getCtx(void) { return mpCtx; }
     102    GuestDnDSendCtx *getCtx(void) { return mpCtx; }
    103103
    104104protected:
    105105
    106106    /** Pointer to send data context. */
    107     PSENDDATACTX mpCtx;
     107    GuestDnDSendCtx *mpCtx;
    108108};
    109109
     
    633633
    634634    SendDataTask *pTask = NULL;
    635     PSENDDATACTX pSendCtx = NULL;
     635    GuestDnDSendCtx *pSendCtx = NULL;
    636636
    637637    try
    638638    {
    639639        //pSendCtx is passed into SendDataTask where one is deleted in destructor
    640         pSendCtx = new SENDDATACTX;
    641         RT_BZERO(pSendCtx, sizeof(SENDDATACTX));
     640        pSendCtx = new GuestDnDSendCtx();
     641        RT_BZERO(pSendCtx, sizeof(GuestDnDSendCtx));
    642642
    643643        pSendCtx->mpTarget      = this;
     
    762762 *          intentional or not.
    763763 */
    764 int GuestDnDTarget::i_sendData(PSENDDATACTX pCtx, RTMSINTERVAL msTimeout)
     764int GuestDnDTarget::i_sendData(GuestDnDSendCtx *pCtx, RTMSINTERVAL msTimeout)
    765765{
    766766    AssertPtrReturn(pCtx, VERR_INVALID_POINTER);
     
    802802}
    803803
    804 int GuestDnDTarget::i_sendDataBody(PSENDDATACTX pCtx, GuestDnDData *pData)
     804int GuestDnDTarget::i_sendDataBody(GuestDnDSendCtx *pCtx, GuestDnDData *pData)
    805805{
    806806    AssertPtrReturn(pCtx,  VERR_INVALID_POINTER);
     
    844844}
    845845
    846 int GuestDnDTarget::i_sendDataHeader(PSENDDATACTX pCtx, GuestDnDData *pData, GuestDnDURIData *pURIData /* = NULL */)
     846int GuestDnDTarget::i_sendDataHeader(GuestDnDSendCtx *pCtx, GuestDnDData *pData, GuestDnDURIData *pURIData /* = NULL */)
    847847{
    848848    AssertPtrReturn(pCtx,  VERR_INVALID_POINTER);
     
    873873}
    874874
    875 int GuestDnDTarget::i_sendDirectory(PSENDDATACTX pCtx, GuestDnDURIObjCtx *pObjCtx, GuestDnDMsg *pMsg)
     875int GuestDnDTarget::i_sendDirectory(GuestDnDSendCtx *pCtx, GuestDnDURIObjCtx *pObjCtx, GuestDnDMsg *pMsg)
    876876{
    877877    AssertPtrReturn(pCtx,    VERR_INVALID_POINTER);
     
    900900}
    901901
    902 int GuestDnDTarget::i_sendFile(PSENDDATACTX pCtx, GuestDnDURIObjCtx *pObjCtx, GuestDnDMsg *pMsg)
     902int GuestDnDTarget::i_sendFile(GuestDnDSendCtx *pCtx, GuestDnDURIObjCtx *pObjCtx, GuestDnDMsg *pMsg)
    903903{
    904904    AssertPtrReturn(pCtx,    VERR_INVALID_POINTER);
     
    985985}
    986986
    987 int GuestDnDTarget::i_sendFileData(PSENDDATACTX pCtx, GuestDnDURIObjCtx *pObjCtx, GuestDnDMsg *pMsg)
     987int GuestDnDTarget::i_sendFileData(GuestDnDSendCtx *pCtx, GuestDnDURIObjCtx *pObjCtx, GuestDnDMsg *pMsg)
    988988{
    989989    AssertPtrReturn(pCtx,    VERR_INVALID_POINTER);
     
    10651065DECLCALLBACK(int) GuestDnDTarget::i_sendURIDataCallback(uint32_t uMsg, void *pvParms, size_t cbParms, void *pvUser)
    10661066{
    1067     PSENDDATACTX pCtx = (PSENDDATACTX)pvUser;
     1067    GuestDnDSendCtx *pCtx = (GuestDnDSendCtx *)pvUser;
    10681068    AssertPtrReturn(pCtx, VERR_INVALID_POINTER);
    10691069
     
    12741274}
    12751275
    1276 int GuestDnDTarget::i_sendURIData(PSENDDATACTX pCtx, RTMSINTERVAL msTimeout)
     1276int GuestDnDTarget::i_sendURIData(GuestDnDSendCtx *pCtx, RTMSINTERVAL msTimeout)
    12771277{
    12781278    AssertPtrReturn(pCtx, VERR_INVALID_POINTER);
     
    14301430}
    14311431
    1432 int GuestDnDTarget::i_sendURIDataLoop(PSENDDATACTX pCtx, GuestDnDMsg *pMsg)
     1432int GuestDnDTarget::i_sendURIDataLoop(GuestDnDSendCtx *pCtx, GuestDnDMsg *pMsg)
    14331433{
    14341434    AssertPtrReturn(pCtx, VERR_INVALID_POINTER);
     
    14891489}
    14901490
    1491 int GuestDnDTarget::i_sendRawData(PSENDDATACTX pCtx, RTMSINTERVAL msTimeout)
     1491int GuestDnDTarget::i_sendRawData(GuestDnDSendCtx *pCtx, RTMSINTERVAL msTimeout)
    14921492{
    14931493    AssertPtrReturn(pCtx, VERR_INVALID_POINTER);
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