VirtualBox

Changeset 91103 in vbox


Ignore:
Timestamp:
Sep 3, 2021 12:22:29 PM (3 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:10067: More careful create/revoke logic for UINotificationMessage.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/notificationcenter/UINotificationObjects.cpp

    r91102 r91103  
    484484        return;
    485485    /* Check if message already exists: */
    486     if (m_messages.contains(strInternalName))
     486    if (   !strInternalName.isEmpty()
     487        && m_messages.contains(strInternalName))
    487488        return;
    488489
    489490    /* Create message finally: */
    490     m_messages[strInternalName] = gpNotificationCenter->append(new UINotificationMessage(strName,
    491                                                                                          strDetails,
    492                                                                                          strInternalName,
    493                                                                                          strHelpKeyword));
     491    const QUuid uId = gpNotificationCenter->append(new UINotificationMessage(strName,
     492                                                                             strDetails,
     493                                                                             strInternalName,
     494                                                                             strHelpKeyword));
     495    if (!strInternalName.isEmpty())
     496        m_messages[strInternalName] = uId;
    494497}
    495498
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