VirtualBox

Changeset 89933 in vbox for trunk


Ignore:
Timestamp:
Jun 28, 2021 4:08:43 PM (4 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
145391
Message:

FE/Qt: bugref:10049. Refactoring message center functions to enable help button.

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/extensions/QIMessageBox.cpp

    r89928 r89933  
    3737
    3838
    39 QIMessageBox::QIMessageBox(const QString &strTitle, const QString &strMessage, AlertIconType iconType,
     39QIMessageBox::QIMessageBox(const QString &strTitle, const QString &strMessage, const QString &strHelpKeyword, AlertIconType iconType,
    4040                           int iButton1 /* = 0*/, int iButton2 /* = 0*/, int iButton3 /* = 0*/, QWidget *pParent /* = 0*/)
    4141    : QIDialog(pParent)
     
    4545    , m_strMessage(strMessage)
    4646    , m_pLabelText(0)
     47    , m_strHelpKeyword(strHelpKeyword)
    4748    , m_pFlagCheckBox(0)
    4849    , m_pDetailsContainer(0)
  • trunk/src/VBox/Frontends/VirtualBox/src/extensions/QIMessageBox.h

    r89928 r89933  
    9191      * @param  strTitle    Brings the title.
    9292      * @param  strMessage  Brings the message.
     93      * @param  strMessage  Brings the help keyword for context sensitive help
    9394      * @param  iconType    Brings the icon-type.
    9495      * @param  iButton1    Brings the integer-code for the 1st button.
    9596      * @param  iButton2    Brings the integer-code for the 2nd button.
    9697      * @param  iButton3    Brings the integer-code for the 3rd button. */
    97     QIMessageBox(const QString &strTitle, const QString &strMessage, AlertIconType iconType,
     98    QIMessageBox(const QString &strTitle, const QString &strMessage, const QString &strHelpKeyword, AlertIconType iconType,
    9899                 int iButton1 = 0, int iButton2 = 0, int iButton3 = 0, QWidget *pParent = 0);
    99100
     
    171172    /** Holds the message-label instance. */
    172173    QIRichTextLabel *m_pLabelText;
     174
     175    /** Holds the help keyword. */
     176    QString m_strHelpKeyword;
    173177
    174178    /** Holds the flag check-box instance. */
  • trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.cpp

    r89740 r89933  
    916916            if (!msgCenter().questionBinary(this, MessageType_Question,
    917917                                            QString("Overwriting already existing key, Continue?"),
     918                                            QString() /* help keyword */,
    918919                                            0 /* auto-confirm id */,
    919920                                            QString("Overwrite") /* ok button text */,
     
    11061107            if (!msgCenter().questionBinary(this, MessageType_Question,
    11071108                                            QString("Overwriting already existing key, Continue?"),
     1109                                            QString() /* help keyword */,
    11081110                                            0 /* auto-confirm id */,
    11091111                                            QString("Overwrite") /* ok button text */,
     
    11511153                                       QString("<p>Do you really wish to "
    11521154                                               "remove chosen records?</p>"),
    1153                                        strDetails))
     1155                                       strDetails,
     1156                                       QString() /* help keyword */))
    11541157        return;
    11551158
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.cpp

    r89928 r89933  
    156156                             const QString &strMessage,
    157157                             const QString &strDetails,
     158                             const QString &strHelpKeyword,
    158159                             const char *pcszAutoConfirmId /* = 0*/,
    159160                             int iButton1 /* = 0*/,
     
    170171         * to show a message-box in the GUI thread: */
    171172        emit sigToShowMessageBox(pParent, enmType,
    172                                  strMessage, strDetails,
     173                                 strMessage, strDetails, strHelpKeyword,
    173174                                 iButton1, iButton2, iButton3,
    174175                                 strButtonText1, strButtonText2, strButtonText3,
     
    179180    /* In usual case we can chow a message-box directly: */
    180181    return showMessageBox(pParent, enmType,
    181                           strMessage, strDetails,
     182                          strMessage, strDetails, strHelpKeyword,
    182183                          iButton1, iButton2, iButton3,
    183184                          strButtonText1, strButtonText2, strButtonText3,
     
    188189                           const QString &strMessage,
    189190                           const QString &strDetails,
     191                           const QString &strHelpKeyword  /* = QString() */,
    190192                           const char *pcszAutoConfirmId /* = 0*/) const
    191193{
    192     message(pParent, enmType, strMessage, strDetails, pcszAutoConfirmId,
     194    message(pParent, enmType, strMessage, strDetails, strHelpKeyword, pcszAutoConfirmId,
    193195            AlertButton_Ok | AlertButtonOption_Default | AlertButtonOption_Escape);
    194196}
     
    197199                                        const QString &strMessage,
    198200                                        const QString &strDetails,
     201                                        const QString &strHelpKeyword,
    199202                                        const char *pcszAutoConfirmId /* = 0*/,
    200203                                        const QString &strOkButtonText /* = QString()*/,
    201204                                        const QString &strCancelButtonText /* = QString()*/) const
    202205{
    203     return (message(pParent, enmType, strMessage, strDetails, pcszAutoConfirmId,
     206    return (message(pParent, enmType, strMessage, strDetails, strHelpKeyword, pcszAutoConfirmId,
    204207                    AlertButton_Ok | AlertButtonOption_Default,
    205208                    AlertButton_Cancel | AlertButtonOption_Escape,
     
    220223int UIMessageCenter::question(QWidget *pParent, MessageType enmType,
    221224                              const QString &strMessage,
     225                              const QString &strHelpKeyword,
    222226                              const char *pcszAutoConfirmId/* = 0*/,
    223227                              int iButton1 /* = 0*/,
     
    228232                              const QString &strButtonText3 /* = QString()*/) const
    229233{
    230     return message(pParent, enmType, strMessage, QString(), pcszAutoConfirmId,
     234    return message(pParent, enmType, strMessage, QString()  /* details */, strHelpKeyword, pcszAutoConfirmId,
    231235                   iButton1, iButton2, iButton3, strButtonText1, strButtonText2, strButtonText3);
    232236}
     
    234238bool UIMessageCenter::questionBinary(QWidget *pParent, MessageType enmType,
    235239                                     const QString &strMessage,
     240                                     const QString &strHelpKeyword /* = QString() */,
    236241                                     const char *pcszAutoConfirmId /* = 0*/,
    237242                                     const QString &strOkButtonText /* = QString()*/,
     
    240245{
    241246    return fDefaultFocusForOk ?
    242            ((question(pParent, enmType, strMessage, pcszAutoConfirmId,
     247           ((question(pParent, enmType, strMessage, strHelpKeyword, pcszAutoConfirmId,
    243248                      AlertButton_Ok | AlertButtonOption_Default,
    244249                      AlertButton_Cancel | AlertButtonOption_Escape,
     
    248253                      QString() /* third button */) &
    249254             AlertButtonMask) == AlertButton_Ok) :
    250            ((question(pParent, enmType, strMessage, pcszAutoConfirmId,
     255           ((question(pParent, enmType, strMessage, strHelpKeyword, pcszAutoConfirmId,
    251256                      AlertButton_Ok,
    252257                      AlertButton_Cancel | AlertButtonOption_Default | AlertButtonOption_Escape,
     
    260265int UIMessageCenter::questionTrinary(QWidget *pParent, MessageType enmType,
    261266                                     const QString &strMessage,
     267                                     const QString &strHelpKeyword /* = QString() */,
    262268                                     const char *pcszAutoConfirmId /* = 0*/,
    263269                                     const QString &strChoice1ButtonText /* = QString()*/,
     
    265271                                     const QString &strCancelButtonText /* = QString()*/) const
    266272{
    267     return question(pParent, enmType, strMessage, pcszAutoConfirmId,
     273    return question(pParent, enmType, strMessage, strHelpKeyword, pcszAutoConfirmId,
    268274                    AlertButton_Choice1,
    269275                    AlertButton_Choice2 | AlertButtonOption_Default,
     
    277283                                       const QString &strMessage,
    278284                                       const QString &strOptionText,
     285                                       const QString &strHelpKeyword,
    279286                                       bool fDefaultOptionValue /* = true */,
    280287                                       int iButton1 /* = 0*/,
     
    323330    /* Create message-box: */
    324331    QWidget *pBoxParent = windowManager().realParentWindow(pParent ? pParent : windowManager().mainWindowShown());
    325     QPointer<QIMessageBox> pBox = new QIMessageBox(strTitle, strMessage, icon,
     332    QPointer<QIMessageBox> pBox = new QIMessageBox(strTitle, strMessage, strHelpKeyword, icon,
    326333                                                   iButton1, iButton2, iButton3, pBoxParent);
    327334    windowManager().registerNewParent(pBox, pBoxParent);
     
    664671                             "<p>Would you like to automatically rename it?</p>")
    665672                             .arg(strName, strGroupName),
     673                          QString() /* = QString() */,
    666674                          0 /* auto-confirm id */,
    667675                          tr("Rename"));
     
    687695                             "<p><b>%1</b></p><p>Do you wish to proceed?</p>")
    688696                             .arg(names.join(", ")),
     697                          QString() /* help keyword */,
    689698                          0 /* auto-confirm id */,
    690699                          tr("Remove") /* ok button text */,
     
    758767    return cInacessibleMachineCount == machines.size() ?
    759768           message(0, MessageType_Question,
    760                    strText, QString(),
     769                   strText, QString(), QString() /* help keyword */,
    761770                   0 /* auto-confirm id */,
    762771                   AlertButton_Ok,
     
    765774                   tr("Remove")) :
    766775           message(0, MessageType_Question,
    767                    strText, QString(),
     776                   strText, QString(), QString() /* help keyword */,
    768777                   0 /* auto-confirm id */,
    769778                   AlertButton_Choice1,
     
    793802    /* Prepare message itself: */
    794803    return message(0, MessageType_Question,
    795                    strText, QString(),
     804                   strText, QString(), QString() /* help keyword */,
    796805                   0 /* auto-confirm id */,
    797806                   AlertButton_Choice1,
     
    843852                             "see which files are inaccessible, or press <b>Ignore</b> to "
    844853                             "ignore this message.</p>"),
     854                          QString() /* help keyword */,
    845855                          "warnAboutInaccessibleMedia",
    846856                          tr("Check", "inaccessible media message box"), tr("Ignore"));
     
    855865                             "the machine without doing a proper shutdown of the guest OS.</p>")
    856866                             .arg(strNames),
     867                          QString() /* help keyword */,
    857868                          0 /* auto-confirm id */,
    858869                          tr("Discard", "saved state"));
     
    865876                             "of the following virtual machines?</p><p><b>%1</b></p>")
    866877                             .arg(strNames),
     878                          QString() /* help keyword */,
    867879                          0 /* auto-confirm id */,
    868880                          tr("Terminate", "cloud instance"));
     
    876888                             "in applications running inside it to be lost.</p>")
    877889                             .arg(strNames),
     890                          QString() /* help keyword */,
    878891                          "confirmResetMachine" /* auto-confirm id */,
    879892                          tr("Reset", "machine"));
     
    886899                             "to the following virtual machines?</p><p><b>%1</b></p>")
    887900                             .arg(strNames),
     901                          QString() /* help keyword */,
    888902                          "confirmACPIShutdownMachine" /* auto-confirm id */,
    889903                          tr("ACPI Shutdown", "machine"));
     
    897911                             "running inside it to be lost.</p>")
    898912                             .arg(strNames),
     913                          QString() /* help keyword */,
    899914                          "confirmPowerOffMachine" /* auto-confirm id */,
    900915                          tr("Power Off", "machine"));
     
    11231138                                .arg(strSnapshotName),
    11241139                             tr("Create a snapshot of the current machine state"),
     1140                             QString() /* Help keyword */,
    11251141                             !gEDataManager->messagesWithInvertedOption().contains("confirmSnapshotRestoring"),
    11261142                             AlertButton_Ok,
     
    11321148                      .arg(strSnapshotName),
    11331149                   QString() /* details */,
     1150                   QString() /* help keyword */,
    11341151                   0 /* auto-confirm id */,
    11351152                   AlertButton_Ok,
     
    11471164                             "</p>Are you sure you want to delete the selected snapshot <b>%1</b>?</p>")
    11481165                             .arg(strSnapshotName),
     1166                          QString() /* help keyword */,
    11491167                          0 /* auto-confirm id */,
    11501168                          tr("Delete") /* ok button text */,
     
    11641182                              "the snapshot at your own risk.</p>")
    11651183                              .arg(strSnapshotName, strTargetImageName, strTargetImageMaxSize, strTargetFileSystemFree),
     1184                          QString() /* help keyword */,
    11661185                          0 /* auto-confirm id */,
    11671186                          tr("Delete") /* ok button text */,
     
    12731292                             "type.</p>")
    12741293                             .arg(strName),
     1294                          QString() /* help keyword */,
    12751295                          0 /* auto-confirm id */,
    12761296                          tr("Remove") /* ok button text */,
     
    13211341                             "You currently have unsaved setting changes.</p>"
    13221342                             "<p>Would you like to reload the changed settings or to keep your own changes?</p>"),
     1343                          QString() /* help keyword */,
    13231344                          0 /* auto-confirm id */,
    13241345                          tr("Reload settings"), tr("Keep changes"));
     
    13311352                             "<p>You will not be able to insert any optical disks or ISO images "
    13321353                             "or install the Guest Additions without it!</p>"),
     1354                          QString() /* help keyword */,
    13331355                          0 /* auto-confirm id */,
    13341356                          tr("&Remove", "medium") /* ok button text */,
     
    14301452                          tr("<p>There are unsaved changes in the port forwarding configuration.</p>"
    14311453                             "<p>If you proceed your changes will be discarded.</p>"),
     1454                          QString() /* help keyword */,
    14321455                          0 /* auto-confirm id */,
    14331456                          QString() /* ok button text */,
     
    15371560                               "<p>This will detach it from the following virtual machine(s): <b>%2</b>.</p>")
    15381561                               .arg(medium.location(), usage.join(", ")),
     1562                            QString() /* help keyword */,
    15391563                            0 /* auto-confirm id */,
    15401564                            tr("Release", "detach medium"))
     
    15451569                               "<p>This will detach it from the following virtual machine(s): <b>%2</b>.</p>")
    15461570                               .arg(medium.location(), usage.join(", ")),
     1571                            QString() /* help keyword */,
    15471572                            0 /* auto-confirm id */,
    15481573                            tr("Release", "detach medium"));
     
    15961621    return questionBinary(pParent, MessageType_Question,
    15971622                          strMessage.arg(medium.location()),
     1623                          QString() /* help keyword */,
    15981624                          0 /* auto-confirm id */,
    15991625                          tr("Remove", "medium") /* ok button text */,
     
    16151641                              "disk to the list later again.</p>")
    16161642                              .arg(strLocation),
     1643                           QString() /* help keyword */,
    16171644                           0 /* auto-confirm id */,
    16181645                           tr("Delete", "hard disk storage"),
     
    17291756                                 strMessage.arg(medium.isHostDrive() ? medium.name() : medium.location(), CMachine(machine).GetName()),
    17301757                                 UIErrorString::formatErrorInfo(machine),
     1758                                 QString() /* help keyword */,
    17311759                                 0 /* Auto Confirm ID */,
    17321760                                 tr("Force Unmount"));
     
    17841812                             "name or a different adapter attachment type.</p>")
    17851813                             .arg(strName),
     1814                          QString() /* help keyword */,
    17861815                          0 /* auto-confirm id */,
    17871816                          tr("Remove") /* ok button text */,
     
    21542183                          tr("<p>Do you want to remove the cloud profile <nobr><b>%1</b>?</nobr></p>")
    21552184                             .arg(strName),
     2185                          QString() /* help keyword */,
    21562186                          0 /* auto-confirm id */,
    21572187                          tr("Remove") /* ok button text */,
     
    21652195                          tr("<p>Do you want to import cloud profiles from external files?</p>"
    21662196                             "<p>VirtualBox cloud profiles will be overwritten and their data will be lost.</p>"),
     2197                          QString() /* help keyword */,
    21672198                          0 /* auto-confirm id */,
    21682199                          tr("Import") /* ok button text */,
     
    22132244                       "You can choose to <b>Accept</b> or <b>Reject</b> them automatically "
    22142245                       "or cancel to keep the dialog opened.</p>"),
     2246                    QString() /* help keyword */,
    22152247                    0 /* auto-confirm id */,
    22162248                    AlertButton_Choice1,
     
    22262258                          tr("<p>Do you want to remove the cloud console application <nobr><b>%1</b>?</nobr></p>")
    22272259                             .arg(strName),
     2260                          QString() /* help keyword */,
    22282261                          0 /* auto-confirm id */,
    22292262                          tr("Remove") /* ok button text */,
     
    22372270                          tr("<p>Do you want to remove the cloud console profile <nobr><b>%1</b>?</nobr></p>")
    22382271                             .arg(strName),
     2272                          QString() /* help keyword */,
    22392273                          0 /* auto-confirm id */,
    22402274                          tr("Remove") /* ok button text */,
     
    22502284                             "until you add one. In the mean time you will only be able to start the "
    22512285                             "machine using a virtual optical disk or from the network."),
     2286                          QString() /* help keyword */,
    22522287                          0 /* auto-confirm id */,
    22532288                          tr("Continue", "no hard disk attached"),
     
    24842519                             "how many machines are in the list and doesn't need to be told).", machineNames.size())
    24852520                             .arg(machineNames.join(", ")),
     2521                          QString() /* help keyword */,
    24862522                          0 /* auto-confirm id */,
    24872523                          tr("Continue"));
     
    26502686                             "so it is recommended to press <b>OK</b> now.</p>")
    26512687                             .arg(strLogFolder),
     2688                          QString() /* help keyword */,
    26522689                          0 /* auto-confirm id */,
    26532690                          QIMessageBox::tr("OK"),
     
    26822719                                 "Your 64-bit guest will fail to detect a 64-bit CPU and will not be able to boot.</p>"
    26832720                                 "<p>Please ensure that you have enabled VT-x/AMD-V properly in the BIOS of your host computer.</p>"),
     2721                              QString() /* help keyword */,
    26842722                              0 /* auto-confirm id */,
    26852723                              tr("Close VM"), tr("Continue"));
     
    26882726                              tr("<p>VT-x/AMD-V hardware acceleration is not available on your system. "
    26892727                                 "Your 64-bit guest will fail to detect a 64-bit CPU and will not be able to boot."),
     2728                              QString() /* help keyword */,
    26902729                              0 /* auto-confirm id */,
    26912730                              tr("Close VM"), tr("Continue"));
     
    26992738                                 "Certain guests (e.g. OS/2 and QNX) require this feature.</p>"
    27002739                                 "<p>Please ensure that you have enabled VT-x/AMD-V properly in the BIOS of your host computer.</p>"),
     2740                              QString() /* help keyword */,
    27012741                              0 /* auto-confirm id */,
    27022742                              tr("Close VM"), tr("Continue"));
     
    27052745                              tr("<p>VT-x/AMD-V hardware acceleration is not available on your system. "
    27062746                                 "Certain guests (e.g. OS/2 and QNX) require this feature and will fail to boot without it.</p>"),
     2747                              QString() /* help keyword */,
    27072748                              0 /* auto-confirm id */,
    27082749                              tr("Close VM"), tr("Continue"));
     
    27162757                             "<p>You can either change the machine's network settings or stop the machine.</p>")
    27172758                             .arg(strMachineName, strIfNames),
     2759                          QString() /* help keyword */,
    27182760                          0 /* auto-confirm id */,
    27192761                          tr("Change Network Settings"), tr("Close VM"));
     
    27502792                      tr("<p>The host key is currently defined as <b>%1</b>.</p>", "additional message box paragraph")
    27512793                         .arg(UIHostCombo::toReadableString(gEDataManager->hostKeyCombination())),
     2794                      QString() /* help keyword */,
    27522795                      "confirmInputCapture",
    27532796                      AlertButton_Ok | AlertButtonOption_Default,
     
    27702813                             "You can access it by pressing <b>Host+Home</b>.</p>")
    27712814                             .arg(strHotKey, UIHostCombo::toReadableString(gEDataManager->hostKeyCombination())),
     2815                          QString() /* help keyword */,
    27722816                          "confirmGoingFullscreen",
    27732817                          tr("Switch"));
     
    27832827                             "You can access it by pressing <b>Host+Home</b>.</p>")
    27842828                             .arg(strHotKey, UIHostCombo::toReadableString(gEDataManager->hostKeyCombination())),
     2829                          QString() /* help keyword */,
    27852830                          "confirmGoingSeamless",
    27862831                          tr("Switch"));
     
    27962841                             "You can access it by pressing <b>Host+Home</b>.</p>")
    27972842                             .arg(strHotKey, UIHostCombo::toReadableString(gEDataManager->hostKeyCombination())),
     2843                          QString() /* help keyword */,
    27982844                          "confirmGoingScale",
    27992845                          tr("Switch"));
     
    28072853                             "<p>Press <b>Ignore</b> to switch to full-screen mode anyway or press <b>Cancel</b> to cancel the operation.</p>")
    28082854                             .arg(UICommon::formatSize(uMinVRAM)),
     2855                          QString() /* help keyword */,
    28092856                          0 /* auto-confirm id */,
    28102857                          tr("Ignore"));
     
    28282875                             "<p>Press <b>Ignore</b> to switch the screen anyway or press <b>Cancel</b> to cancel the operation.</p>")
    28292876                             .arg(UICommon::formatSize(uMinVRAM)),
     2877                          QString() /* help keyword */,
    28302878                          0 /* auto-confirm id */,
    28312879                          tr("Ignore"));
     
    28922940                          tr("<p>Could not find the <b>VirtualBox Guest Additions</b> disk image file.</p>"
    28932941                             "<p>Do you wish to download this disk image file from the Internet?</p>"),
     2942                          QString() /* help keyword */,
    28942943                          0 /* auto-confirm id */,
    28952944                          tr("Download"));
     
    29022951                             "from <nobr><a href=\"%1\">%1</a></nobr> (size %2 bytes)?</p>")
    29032952                             .arg(strUrl, QLocale(UICommon::languageId()).toString(uSize)),
     2953                          QString() /* help keyword */,
    29042954                          0 /* auto-confirm id */,
    29052955                          tr("Download"));
     
    29242974                             "<p>Do you wish to register this disk image file and insert it into the virtual optical drive?</p>")
    29252975                             .arg(strUrl, strSrc),
     2976                          QString() /* help keyword */,
    29262977                          0 /* auto-confirm id */,
    29272978                          tr("Insert", "additions"));
     
    29533004                             "<p>Do you wish to download this file from the Internet?</p>")
    29543005                             .arg(strMissedLocation),
     3006                          QString() /* help keyword */,
    29553007                          0 /* auto-confirm id */,
    29563008                          tr("Download"));
     
    29633015                             "from <nobr><a href=\"%1\">%1</a></nobr> (size %2 bytes)?</p>")
    29643016                             .arg(strURL, QLocale(UICommon::languageId()).toString(uSize)),
     3017                          QString() /* help keyword */,
    29653018                          0 /* auto-confirm id */,
    29663019                          tr("Download"));
     
    29923045                             "<p>Do you wish to download latest one from the Internet?</p>")
    29933046                             .arg(strExtPackVersion).arg(strExtPackName),
     3047                          QString() /* help keyword */,
    29943048                          0 /* auto-confirm id */,
    29953049                          tr("Download"));
     
    30023056                             "from <nobr><a href=\"%2\">%2</a></nobr> (size %3 bytes)?</p>")
    30033057                             .arg(strExtPackName, strURL, QLocale(UICommon::languageId()).toString(uSize)),
     3058                          QString() /* help keyword */,
    30043059                          0 /* auto-confirm id */,
    30053060                          tr("Download"));
     
    30243079                             "<p>Do you wish to install this extension pack?</p>")
    30253080                             .arg(strExtPackName, strFrom, strTo),
     3081                          QString() /* help keyword */,
    30263082                          0 /* auto-confirm id */,
    30273083                          tr("Install", "extension pack"));
     
    30443100                          tr("Do you want to delete the downloaded file <nobr><b>%1</b></nobr>?")
    30453101                             .arg(strTo),
     3102                          QString() /* help keyword */,
    30463103                          0 /* auto-confirm id */,
    30473104                          tr("Delete", "extension pack"));
     
    30533110                          tr("Do you want to delete following list of files <nobr><b>%1</b></nobr>?")
    30543111                             .arg(strFiles.join(",")),
     3112                          QString() /* help keyword */,
    30553113                          0 /* auto-confirm id */,
    30563114                          tr("Delete", "extension pack"));
     
    30723130                             "</table></p>")
    30733131                             .arg(strPackName).arg(strPackVersion).arg(strPackDescription),
     3132                          QString() /* help keyword */,
    30743133                          0 /* auto-confirm id */,
    30753134                          tr("Install", "extension pack"));
     
    31043163                                "</table></p>")
    31053164                                .arg(strBelehrung).arg(strPackName).arg(strPackVersionNew).arg(strPackVersionOld).arg(strPackDescription),
     3165                             QString() /* help keyword */,
    31063166                             0 /* auto-confirm id */,
    31073167                             tr("&Upgrade"));
     
    31173177                                "</table></p>")
    31183178                                .arg(strBelehrung).arg(strPackName).arg(strPackVersionNew).arg(strPackVersionOld).arg(strPackDescription),
     3179                             QString() /* help keyword */,
    31193180                             0 /* auto-confirm id */,
    31203181                             tr("&Downgrade"));
     
    31293190                                "</table></p>")
    31303191                                .arg(strBelehrung).arg(strPackName).arg(strPackVersionOld).arg(strPackDescription),
     3192                             QString() /* help keyword */,
    31313193                             0 /* auto-confirm id */,
    31323194                             tr("&Reinstall"));
     
    31403202                             "<p>Are you sure you want to proceed?</p>")
    31413203                             .arg(strPackName),
     3204                          QString() /* help keyword */,
    31423205                          0 /* auto-confirm id */,
    31433206                          tr("&Remove") /* ok button text */,
     
    32723335                             "Replacing it will overwrite its contents.")
    32733336                             .arg(strPath),
     3337                          QString() /* help keyword */,
    32743338                          0 /* auto-confirm id */,
    32753339                          QString() /* ok button text */,
     
    32893353                                 "Replacing them will overwrite their contents.")
    32903354                                 .arg(QStringList(strPaths.toList()).join("<br />")),
     3355                              QString() /* help keyword */,
    32913356                              0 /* auto-confirm id */,
    32923357                              QString() /* ok button text */,
     
    34343499
    34353500void UIMessageCenter::sltShowMessageBox(QWidget *pParent, MessageType enmType,
    3436                                         const QString &strMessage, const QString &strDetails,
     3501                                        const QString &strMessage, const QString &strDetails, const QString &strHelpKeyword,
    34373502                                        int iButton1, int iButton2, int iButton3,
    34383503                                        const QString &strButtonText1, const QString &strButtonText2, const QString &strButtonText3,
     
    34413506    /* Now we can show a message-box directly: */
    34423507    showMessageBox(pParent, enmType,
    3443                    strMessage, strDetails,
     3508                   strMessage, strDetails, strHelpKeyword,
    34443509                   iButton1, iButton2, iButton3,
    34453510                   strButtonText1, strButtonText2, strButtonText3,
     
    35033568
    35043569int UIMessageCenter::showMessageBox(QWidget *pParent, MessageType enmType,
    3505                                     const QString &strMessage, const QString &strDetails,
     3570                                    const QString &strMessage, const QString &strDetails, const QString &strHelpKeyword,
    35063571                                    int iButton1, int iButton2, int iButton3,
    35073572                                    const QString &strButtonText1, const QString &strButtonText2, const QString &strButtonText3,
     
    35693634    /* Create message-box: */
    35703635    QWidget *pMessageBoxParent = windowManager().realParentWindow(pParent ? pParent : windowManager().mainWindowShown());
    3571     QPointer<QIMessageBox> pMessageBox = new QIMessageBox(title, strMessage, icon,
     3636    QPointer<QIMessageBox> pMessageBox = new QIMessageBox(title, strMessage, strHelpKeyword, icon,
    35723637                                                          iButton1, iButton2, iButton3,
    35733638                                                          pMessageBoxParent);
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.h

    r89928 r89933  
    6868      * @param  strMessage        Brings the message.
    6969      * @param  strDetails        Brings the details.
     70      * @param  strHelpKeyword    Brings the help keyword.
    7071      * @param  iButton1          Brings the button 1 type.
    7172      * @param  iButton2          Brings the button 2 type.
     
    7677      * @param  strAutoConfirmId  Brings whether this message can be auto-confirmed. */
    7778    void sigToShowMessageBox(QWidget *pParent, MessageType enmType,
    78                              const QString &strMessage, const QString &strDetails,
     79                             const QString &strMessage, const QString &strDetails, const QString &strHelpKeyword,
    7980                             int iButton1, int iButton2, int iButton3,
    8081                             const QString &strButtonText1, const QString &strButtonText2, const QString &strButtonText3,
     
    9899      * @param  strMessage         Brings the message.
    99100      * @param  strDetails         Brings the details.
     101      * @param  strHelpKeyword     Brings the help keyword
    100102      * @param  pcszAutoConfirmId  Brings the auto-confirm ID.
    101103      * @param  iButton1           Brings the button 1 type.
     
    106108      * @param  strButtonText3     Brings the button 3 text. */
    107109    int message(QWidget *pParent, MessageType enmType,
    108                 const QString &strMessage, const QString &strDetails,
     110                const QString &strMessage, const QString &strDetails, const QString &strHelpKeyword,
    109111                const char *pcszAutoConfirmId = 0,
    110112                int iButton1 = 0, int iButton2 = 0, int iButton3 = 0,
     
    119121      * @param  strMessage         Brings the message.
    120122      * @param  strDetails         Brings the details.
     123      * @param  strHelpKeyword     Brings the help keyword
    121124      * @param  pcszAutoConfirmId  Brings the auto-confirm ID. */
    122125    void error(QWidget *pParent, MessageType enmType,
    123126               const QString &strMessage,
    124127               const QString &strDetails,
     128               const QString &strHelpKeyword = QString(),
    125129               const char *pcszAutoConfirmId = 0) const;
    126130
     
    131135      * @param  strMessage           Brings the message.
    132136      * @param  strDetails           Brings the details.
     137      * @param  strHelpKeyword       Brings the help keyword
    133138      * @param  pcszAutoConfirmId    Brings the auto-confirm ID.
    134139      * @param  strOkButtonText      Brings the Ok button text.
     
    137142                           const QString &strMessage,
    138143                           const QString &strDetails,
     144                           const QString &strHelpKeyword,
    139145                           const char *pcszAutoConfirmId = 0,
    140146                           const QString &strOkButtonText = QString(),
     
    156162      * @param  enmType            Brings the message-box type.
    157163      * @param  strMessage         Brings the message.
     164      * @param  strHelpKeyword     Brings the help keyword.
    158165      * @param  pcszAutoConfirmId  Brings the auto-confirm ID.
    159166      * @param  iButton1           Brings the button 1 type.
     
    165172    int question(QWidget *pParent, MessageType enmType,
    166173                 const QString &strMessage,
     174                 const QString &strHelpKeyword,
    167175                 const char *pcszAutoConfirmId = 0,
    168176                 int iButton1 = 0, int iButton2 = 0, int iButton3 = 0,
     
    176184      * @param  enmType              Brings the message-box type.
    177185      * @param  strMessage           Brings the message.
     186      * @param  strHelpKeyword       Brings the help keyword.
    178187      * @param  pcszAutoConfirmId    Brings the auto-confirm ID.
    179188      * @param  strOkButtonText      Brings the button 1 text.
     
    182191    bool questionBinary(QWidget *pParent, MessageType enmType,
    183192                        const QString &strMessage,
     193                        const QString &strHelpKeyword = QString(),
    184194                        const char *pcszAutoConfirmId = 0,
    185195                        const QString &strOkButtonText = QString(),
     
    192202      * @param  enmType               Brings the message-box type.
    193203      * @param  strMessage            Brings the message.
     204      * @param  strHelpKeyword        Brings the help keyword.
    194205      * @param  pcszAutoConfirmId     Brings the auto-confirm ID.
    195206      * @param  strChoice1ButtonText  Brings the button 1 text.
     
    198209    int questionTrinary(QWidget *pParent, MessageType enmType,
    199210                        const QString &strMessage,
     211                        const QString &strHelpKeyword = QString(),
    200212                        const char *pcszAutoConfirmId = 0,
    201213                        const QString &strChoice1ButtonText = QString(),
     
    208220      * @param  strMessage           Brings the message.
    209221      * @param  strOptionText        Brings the option text.
     222      * @param  strHelpKeyword       Brings the help keyword which is used in context sensitive help.
    210223      * @param  fDefaultOptionValue  Brings the default option value.
    211224      * @param  iButton1             Brings the button 1 type.
     
    218231                          const QString &strMessage,
    219232                          const QString &strOptionText,
     233                          const QString &strHelpKeyword,
    220234                          bool fDefaultOptionValue = true,
    221235                          int iButton1 = 0, int iButton2 = 0, int iButton3 = 0,
     
    587601      * @param  enmType           Brings the message-box type.
    588602      * @param  strMessage        Brings the message.
     603      * @param  strMessage        Brings the help keyword.
    589604      * @param  strDetails        Brings the details.
    590605      * @param  iButton1          Brings the button 1 type.
     
    596611      * @param  strAutoConfirmId  Brings whether this message can be auto-confirmed. */
    597612    void sltShowMessageBox(QWidget *pParent, MessageType enmType,
    598                            const QString &strMessage, const QString &strDetails,
     613                           const QString &strMessage, const QString &strDetails, const QString &strHelpKeyword,
    599614                           int iButton1, int iButton2, int iButton3,
    600615                           const QString &strButtonText1, const QString &strButtonText2, const QString &strButtonText3,
     
    618633      * @param  strMessage        Brings the message.
    619634      * @param  strDetails        Brings the details.
     635      * @param  strHelpKeyword    Brings the help keyword
    620636      * @param  iButton1          Brings the button 1 type.
    621637      * @param  iButton2          Brings the button 2 type.
     
    626642      * @param  strAutoConfirmId  Brings whether this message can be auto-confirmed. */
    627643    int showMessageBox(QWidget *pParent, MessageType type,
    628                        const QString &strMessage, const QString &strDetails,
     644                       const QString &strMessage, const QString &strDetails, const QString &strHelpKeyword,
    629645                       int iButton1, int iButton2, int iButton3,
    630646                       const QString &strButtonText1, const QString &strButtonText2, const QString &strButtonText3,
  • trunk/src/VBox/Frontends/VirtualBox/src/softkeyboard/UISoftKeyboard.cpp

    r89568 r89933  
    27152715        if (!msgCenter().questionBinary(this, MessageType_Question,
    27162716                                        QString(UISoftKeyboard::tr("This will delete the keyboard layout file as well. Proceed?")),
     2717                                        QString() /* help keyword */,
    27172718                                        0 /* auto-confirm id */,
    27182719                                        QString("Delete") /* ok button text */,
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