VirtualBox

Changeset 99184 in vbox for trunk


Ignore:
Timestamp:
Mar 27, 2023 11:05:18 AM (22 months ago)
Author:
vboxsync
Message:

FE/Qt: bugref:10067: Notification-center: Hide keep-finished-progresses button for release build; It's mostly used for debugging notification issues and confuses people in release build.

Location:
trunk/src/VBox/Frontends/VirtualBox
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/Makefile.kmk

    r99040 r99184  
    278278if "$(KBUILD_TYPE)" != "release" || defined(VBOX_GUI_WITH_EXTRADATA_MANAGER_UI)
    279279 UICommon_DEFS        += VBOX_GUI_WITH_EXTRADATA_MANAGER_UI
     280endif
     281if "$(KBUILD_TYPE)" != "release" || defined(VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON)
     282 UICommon_DEFS        += VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    280283endif
    281284ifndef VBOX_WITHOUT_LESS_VIRTUALBOX_INCLUDING
  • trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataDefs.cpp

    r98103 r99184  
    3838const char *UIExtraDataDefs::GUI_SuppressMessages = "GUI/SuppressMessages";
    3939const char *UIExtraDataDefs::GUI_InvertMessageOption = "GUI/InvertMessageOption";
     40#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    4041const char *UIExtraDataDefs::GUI_NotificationCenter_KeepSuccessfullProgresses = "GUI/NotificationCenter/KeepSuccessfullProgresses";
     42#endif
    4143const char *UIExtraDataDefs::GUI_NotificationCenter_Alignment = "GUI/NotificationCenter/Alignment";
    4244const char *UIExtraDataDefs::GUI_NotificationCenter_Order = "GUI/NotificationCenter/Order";
  • trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataDefs.h

    r98524 r99184  
    6767        /** Holds the list of messages for the Message/Popup center frameworks with inverted check-box state. */
    6868        SHARED_LIBRARY_STUFF extern const char *GUI_InvertMessageOption;
     69#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    6970        /** Holds whether successfull notification-progresses should NOT close automatically. */
    7071        SHARED_LIBRARY_STUFF extern const char *GUI_NotificationCenter_KeepSuccessfullProgresses;
     72#endif
    7173        /** Holds notification-center alignment. */
    7274        SHARED_LIBRARY_STUFF extern const char *GUI_NotificationCenter_Alignment;
  • trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.cpp

    r98103 r99184  
    19151915           << GUI_RestrictedDialogs
    19161916           << GUI_SuppressMessages << GUI_InvertMessageOption
     1917#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    19171918           << GUI_NotificationCenter_KeepSuccessfullProgresses
     1919#endif
    19181920           << GUI_NotificationCenter_Alignment
    19191921           << GUI_NotificationCenter_Order
     
    19211923#ifdef VBOX_GUI_WITH_NETWORK_MANAGER
    19221924           << GUI_PreventApplicationUpdate << GUI_UpdateDate << GUI_UpdateCheckCount
    1923 #endif /* VBOX_GUI_WITH_NETWORK_MANAGER */
     1925#endif
    19241926           << GUI_Progress_LegacyMode
    19251927           << GUI_Customizations
     
    19541956#ifndef VBOX_WS_MAC
    19551957           << GUI_MachineWindowIcons << GUI_MachineWindowNamePostfix
    1956 #endif /* !VBOX_WS_MAC */
     1958#endif
    19571959           << GUI_LastNormalWindowPosition << GUI_LastScaleWindowPosition
    19581960#ifndef VBOX_WS_MAC
     
    19681970#ifdef VBOX_WITH_DEBUGGER_GUI
    19691971           << GUI_RestrictedRuntimeDebuggerMenuActions
    1970 #endif /* VBOX_WITH_DEBUGGER_GUI */
     1972#endif
    19711973#ifdef VBOX_WS_MAC
    19721974           << GUI_RestrictedRuntimeWindowMenuActions
    1973 #endif /* VBOX_WS_MAC */
     1975#endif
    19741976           << GUI_RestrictedRuntimeHelpMenuActions
    19751977           << GUI_RestrictedVisualStates
     
    19781980           << GUI_Fullscreen_LegacyMode
    19791981           << GUI_DistinguishMachineWindowGroups
    1980 #endif /* VBOX_WS_X11 */
     1982#endif
    19811983           << GUI_AutoresizeGuest << GUI_LastVisibilityStatusForGuestScreen << GUI_LastGuestSizeHint
    19821984           << GUI_VirtualScreenToHostScreen << GUI_AutomountGuestScreens
    19831985#ifndef VBOX_WS_MAC
    19841986           << GUI_ShowMiniToolBar << GUI_MiniToolBarAutoHide << GUI_MiniToolBarAlignment
    1985 #endif /* !VBOX_WS_MAC */
     1987#endif
    19861988           << GUI_StatusBar_Enabled << GUI_StatusBar_ContextMenu_Enabled << GUI_RestrictedStatusBarIndicators << GUI_StatusBar_IndicatorOrder
    19871989#ifdef VBOX_WS_MAC
    19881990           << GUI_RealtimeDockIconUpdateEnabled << GUI_RealtimeDockIconUpdateMonitor << GUI_DockIconDisableOverlay
    1989 #endif /* VBOX_WS_MAC */
     1991#endif
    19901992           << GUI_PassCAD
    19911993           << GUI_MouseCapturePolicy
     
    20022004#ifdef VBOX_WITH_DEBUGGER_GUI
    20032005           << GUI_Dbg_Enabled << GUI_Dbg_AutoShow
    2004 #endif /* VBOX_WITH_DEBUGGER_GUI */
     2006#endif
    20052007           << GUI_ExtraDataManager_Geometry << GUI_ExtraDataManager_SplitterHints
    20062008           << GUI_LogWindowGeometry
     
    23662368}
    23672369
     2370#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    23682371bool UIExtraDataManager::keepSuccessfullNotificationProgresses()
    23692372{
     
    23772380    setExtraDataString(GUI_NotificationCenter_KeepSuccessfullProgresses, toFeatureAllowed(fKeep));
    23782381}
     2382#endif /* VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON */
    23792383
    23802384Qt::Alignment UIExtraDataManager::notificationCenterAlignment()
  • trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.h

    r98103 r99184  
    202202        QStringList messagesWithInvertedOption();
    203203
     204#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    204205        /** Returns whether successfull notification-progresses should NOT close automatically. */
    205206        bool keepSuccessfullNotificationProgresses();
    206207        /** Defines whether successfull notification-progresses should NOT close (@a fKeep) automatically. */
    207208        void setKeepSuccessfullNotificationProgresses(bool fKeep);
     209#endif /* VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON */
    208210
    209211        /** Returns notification-center alignment. */
  • trunk/src/VBox/Frontends/VirtualBox/src/notificationcenter/UINotificationCenter.cpp

    r98928 r99184  
    165165    , m_pButtonOpen(0)
    166166    , m_pButtonToggleSorting(0)
     167#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    167168    , m_pButtonKeepFinished(0)
     169#endif
    168170    , m_pButtonRemoveFinished(0)
    169171    , m_pLayoutItems(0)
     
    294296    if (m_pButtonToggleSorting)
    295297        m_pButtonToggleSorting->setToolTip(tr("Toggle ascending/descending order"));
     298#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    296299    if (m_pButtonKeepFinished)
    297300        m_pButtonKeepFinished->setToolTip(tr("Keep finished progresses"));
     301#endif
    298302    if (m_pButtonRemoveFinished)
    299303        m_pButtonRemoveFinished->setToolTip(tr("Delete finished notifications"));
     
    420424}
    421425
     426#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    422427void UINotificationCenter::sltHandleKeepButtonToggled(bool fToggled)
    423428{
    424429    gEDataManager->setKeepSuccessfullNotificationProgresses(fToggled);
    425430}
     431#endif /* VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON */
    426432
    427433void UINotificationCenter::sltHandleRemoveFinishedButtonClicked()
     
    632638            }
    633639
     640#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    634641            /* Prepare keep-finished button: */
    635642            m_pButtonKeepFinished = new QIToolButton(this);
     
    642649                m_pLayoutButtons->addWidget(m_pButtonKeepFinished);
    643650            }
     651#endif /* VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON */
    644652
    645653            /* Prepare remove-finished button: */
  • trunk/src/VBox/Frontends/VirtualBox/src/notificationcenter/UINotificationCenter.h

    r98928 r99184  
    121121    /** Issues request to make open button @a fToggled. */
    122122    void sltHandleOpenButtonToggled(bool fToggled);
     123#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    123124    /** Toggles notification-progresses keep approach. */
    124125    void sltHandleKeepButtonToggled(bool fToggled);
     126#endif
    125127    /** Removes finished notifications. */
    126128    void sltHandleRemoveFinishedButtonClicked();
     
    190192    /** Holds the toggle-sorting button instance. */
    191193    QIToolButton *m_pButtonToggleSorting;
     194#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
    192195    /** Holds the keep-finished button instance. */
    193196    QIToolButton *m_pButtonKeepFinished;
     197#endif
    194198    /** Holds the remove-finished button instance. */
    195199    QIToolButton *m_pButtonRemoveFinished;
  • trunk/src/VBox/Frontends/VirtualBox/src/notificationcenter/UINotificationObject.cpp

    r98103 r99184  
    215215    /* If there was no error and no reason to keep progress alive, - finish him! */
    216216    if (   error().isEmpty()
    217         && !gEDataManager->keepSuccessfullNotificationProgresses())
     217#ifdef VBOX_NOTIFICATION_CENTER_WITH_KEEP_BUTTON
     218        && !gEDataManager->keepSuccessfullNotificationProgresses()
     219#endif
     220        )
    218221        close();
    219222}
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