VirtualBox

Changeset 34519 in vbox


Ignore:
Timestamp:
Nov 30, 2010 2:17:27 PM (14 years ago)
Author:
vboxsync
Message:

FE/Qt4: install extension packs on double click

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxDefs.cpp

    r34064 r34519  
    9090
    9191QStringList VBoxDefs::VBoxFileExts = QStringList() << "xml" << "vbox";
     92QStringList VBoxDefs::VBoxExtPackFileExts = QStringList() << "vbox-extpack";
    9293QStringList VBoxDefs::OVFFileExts = QStringList() << "ovf" << "ova";
    9394
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxDefs.h

    r34064 r34519  
    167167
    168168    static QStringList VBoxFileExts;
     169    static QStringList VBoxExtPackFileExts;
    169170    static QStringList OVFFileExts;
    170171};
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxProblemReporter.cpp

    r34479 r34519  
    24102410}
    24112411
     2412void VBoxProblemReporter::cannotInstallExtPack(const QString &strFilename, const CExtPackManager &extPackManager, QWidget *pParent /* = 0 */)
     2413{
     2414    message (pParent ? pParent : mainWindowShown(),
     2415             Error,
     2416             tr("Failed to install the Extension Pack <b>%1</b>.").arg(strFilename),
     2417             formatErrorInfo(extPackManager));
     2418}
     2419
    24122420void VBoxProblemReporter::warnAboutIncorrectPort (QWidget *pParent) const
    24132421{
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxProblemReporter.h

    r34479 r34519  
    383383    void cannotUpdateGuestAdditions (const CProgress &aProgress, QWidget *aParent /* = NULL */) const;
    384384
     385    void cannotInstallExtPack(const QString &strFilename, const CExtPackManager &extPackManager, QWidget *pParent = 0);
     386
    385387    void warnAboutIncorrectPort(QWidget *pParent) const;
    386388    bool confirmCancelingPortForwardingDialog(QWidget *pParent) const;
  • trunk/src/VBox/Frontends/VirtualBox/src/platform/darwin/Info.plist

    r34275 r34519  
    2020      <key>CFBundleTypeName</key>               <string>VirtualBox Extension Pack</string>
    2121      <key>CFBundleTypeExtensions</key>         <array><string>vbox-extpack</string></array>
    22       <key>CFBundleTypeRole</key>               <string>None</string>
     22      <key>CFBundleTypeRole</key>               <string>Viewer</string>
     23      <key>LSHandlerRank</key>                  <string>Owner</string>
    2324      <key>CFBundleTypeIconFile</key>           <string>virtualbox-vbox-extpack</string>
    2425     </dict>
  • trunk/src/VBox/Frontends/VirtualBox/src/selector/VBoxSelectorWnd.cpp

    r34498 r34519  
    10091009                break;
    10101010            }
     1011            else if (VBoxGlobal::hasAllowedExtension(strFile, VBoxDefs::VBoxExtPackFileExts))
     1012            {
     1013                CExtPackManager extPackManager = vboxGlobal().virtualBox().GetExtensionPackManager();
     1014                extPackManager.Install(strFile);
     1015                if (!extPackManager.isOk())
     1016                    vboxProblem().cannotInstallExtPack(strFile, extPackManager, this);
     1017            }
    10111018        }
    10121019    }
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