Index: trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.cpp
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.cpp	(revision 45268)
+++ trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.cpp	(revision 45269)
@@ -284,47 +284,4 @@
 }
 
-bool UIMessageCenter::askForOverridingFile(const QString& strPath, QWidget *pParent /* = NULL */)
-{
-    return messageYesNo(pParent, MessageType_Question, tr("A file named <b>%1</b> already exists. Are you sure you want to replace it?<br /><br />Replacing it will overwrite its contents.").arg(strPath));
-}
-
-bool UIMessageCenter::askForOverridingFiles(const QVector<QString>& strPaths, QWidget *pParent /* = NULL */)
-{
-    if (strPaths.size() == 1)
-        /* If it is only one file use the single question versions above */
-        return askForOverridingFile(strPaths.at(0), pParent);
-    else if (strPaths.size() > 1)
-        return messageYesNo(pParent, MessageType_Question, tr("The following files already exist:<br /><br />%1<br /><br />Are you sure you want to replace them? Replacing them will overwrite their contents.").arg(QStringList(strPaths.toList()).join("<br />")));
-    else
-        return true;
-}
-
-bool UIMessageCenter::askForOverridingFileIfExists(const QString& strPath, QWidget *pParent /* = NULL */)
-{
-    QFileInfo fi(strPath);
-    if (fi.exists())
-        return askForOverridingFile(strPath, pParent);
-    else
-        return true;
-}
-
-bool UIMessageCenter::askForOverridingFilesIfExists(const QVector<QString>& strPaths, QWidget *pParent /* = NULL */)
-{
-    QVector<QString> existingFiles;
-    foreach(const QString &file, strPaths)
-    {
-        QFileInfo fi(file);
-        if (fi.exists())
-            existingFiles << fi.absoluteFilePath();
-    }
-    if (existingFiles.size() == 1)
-        /* If it is only one file use the single question versions above */
-        return askForOverridingFileIfExists(existingFiles.at(0), pParent);
-    else if (existingFiles.size() > 1)
-        return askForOverridingFiles(existingFiles, pParent);
-    else
-        return true;
-}
-
 #ifdef RT_OS_LINUX
 void UIMessageCenter::warnAboutWrongUSBMounted()
@@ -340,5 +297,5 @@
 void UIMessageCenter::cannotStartSelector()
 {
-    message(mainWindowShown(), MessageType_Critical,
+    message(0, MessageType_Critical,
             tr("<p>Cannot start VirtualBox Manager due to local restrictions.</p>"
                "<p>The application will now terminate.</p>"));
@@ -347,16 +304,24 @@
 void UIMessageCenter::showBETAWarning()
 {
-    message
-        (0, MessageType_Warning,
-         tr("You are running a prerelease version of VirtualBox. "
-             "This version is not suitable for production use."));
+    message(0, MessageType_Warning,
+            tr("You are running a prerelease version of VirtualBox. "
+               "This version is not suitable for production use."));
 }
 
 void UIMessageCenter::showBEBWarning()
 {
-    message
-        (0, MessageType_Warning,
-         tr("You are running an EXPERIMENTAL build of VirtualBox. "
-             "This version is not suitable for production use."));
+    message(0, MessageType_Warning,
+            tr("You are running an EXPERIMENTAL build of VirtualBox. "
+               "This version is not suitable for production use."));
+}
+
+void UIMessageCenter::cannotInitUserHome(const QString &strUserHome)
+{
+    message(0, MessageType_Critical,
+            tr("<p>Failed to initialize COM because the VirtualBox global "
+               "configuration directory <b><nobr>%1</nobr></b> is not accessible. "
+               "Please check the permissions of this directory and of its parent directory.</p>"
+               "<p>The application will now terminate.</p>").arg(strUserHome),
+            formatErrorInfo(COMErrorInfo()));
 }
 
@@ -364,48 +329,16 @@
 {
     message(0, MessageType_Critical,
-        tr("<p>Failed to initialize COM or to find the VirtualBox COM server. "
-            "Most likely, the VirtualBox server is not running "
-            "or failed to start.</p>"
-            "<p>The application will now terminate.</p>"),
-        formatErrorInfo(COMErrorInfo(), rc));
-}
-
-void UIMessageCenter::cannotInitUserHome(const QString &strUserHome)
+            tr("<p>Failed to initialize COM or to find the VirtualBox COM server. "
+               "Most likely, the VirtualBox server is not running or failed to start.</p>"
+               "<p>The application will now terminate.</p>"),
+            formatErrorInfo(COMErrorInfo(), rc));
+}
+
+void UIMessageCenter::cannotCreateVirtualBox(const CVirtualBox &vbox)
 {
     message(0, MessageType_Critical,
-        tr("<p>Failed to initialize COM because the VirtualBox global "
-           "configuration directory <b><nobr>%1</nobr></b> is not accessible. "
-           "Please check the permissions of this directory and of its parent "
-           "directory.</p>"
-           "<p>The application will now terminate.</p>").arg(strUserHome),
-        formatErrorInfo(COMErrorInfo()));
-}
-
-void UIMessageCenter::cannotCreateVirtualBox(const CVirtualBox &vbox)
-{
-    message(0, MessageType_Critical,
-        tr("<p>Failed to create the VirtualBox COM object.</p>"
-            "<p>The application will now terminate.</p>"),
-        formatErrorInfo(vbox));
-}
-
-#ifdef Q_WS_X11
-void UIMessageCenter::cannotFindLicenseFiles(const QString &strPath)
-{
-    message
-        (0, MessageType_Error,
-         tr("Failed to find license files in "
-             "<nobr><b>%1</b></nobr>.")
-             .arg(strPath));
-}
-#endif /* Q_WS_X11 */
-
-void UIMessageCenter::cannotOpenLicenseFile(QWidget *pParent, const QString &strPath)
-{
-    message
-        (pParent, MessageType_Error,
-         tr("Failed to open the license file <nobr><b>%1</b></nobr>. "
-             "Check file permissions.")
-             .arg(strPath));
+            tr("<p>Failed to create the VirtualBox COM object.</p>"
+               "<p>The application will now terminate.</p>"),
+            formatErrorInfo(vbox));
 }
 
@@ -2472,4 +2405,61 @@
 }
 
+void UIMessageCenter::cannotOpenLicenseFile(QWidget *pParent, const QString &strPath)
+{
+    message(pParent, MessageType_Error,
+            tr("Failed to open the license file <nobr><b>%1</b></nobr>. "
+               "Check file permissions.").arg(strPath));
+}
+
+bool UIMessageCenter::askForOverridingFile(const QString &strPath, QWidget *pParent /* = 0 */)
+{
+    return messageYesNo(pParent, MessageType_Question,
+                        tr("A file named <b>%1</b> already exists. "
+                           "Are you sure you want to replace it?<br /><br />"
+                           "Replacing it will overwrite its contents.").arg(strPath));
+}
+
+bool UIMessageCenter::askForOverridingFiles(const QVector<QString> &strPaths, QWidget *pParent /* = 0 */)
+{
+    /* If it is only one file use the single question versions above: */
+    if (strPaths.size() == 1)
+        return askForOverridingFile(strPaths.at(0), pParent);
+    else if (strPaths.size() > 1)
+        return messageYesNo(pParent, MessageType_Question,
+                            tr("The following files already exist:<br /><br />%1<br /><br />"
+                               "Are you sure you want to replace them? "
+                               "Replacing them will overwrite their contents.")
+                               .arg(QStringList(strPaths.toList()).join("<br />")));
+    else
+        return true;
+}
+
+bool UIMessageCenter::askForOverridingFileIfExists(const QString &strPath, QWidget *pParent /* = 0 */)
+{
+    QFileInfo fi(strPath);
+    if (fi.exists())
+        return askForOverridingFile(strPath, pParent);
+    else
+        return true;
+}
+
+bool UIMessageCenter::askForOverridingFilesIfExists(const QVector<QString> &strPaths, QWidget *pParent /* = 0 */)
+{
+    QVector<QString> existingFiles;
+    foreach(const QString &file, strPaths)
+    {
+        QFileInfo fi(file);
+        if (fi.exists())
+            existingFiles << fi.absoluteFilePath();
+    }
+    /* If it is only one file use the single question versions above: */
+    if (existingFiles.size() == 1)
+        return askForOverridingFileIfExists(existingFiles.at(0), pParent);
+    else if (existingFiles.size() > 1)
+        return askForOverridingFiles(existingFiles, pParent);
+    else
+        return true;
+}
+
 /* static */
 QString UIMessageCenter::mediumToAccusative(UIMediumType type, bool fIsHostDrive /* = false */)
Index: trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.h
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.h	(revision 45268)
+++ trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.h	(revision 45269)
@@ -184,10 +184,4 @@
     QWidget* networkManagerOrMainMachineWindowShown() const;
 
-    /* API: File read/write overriding stuff: */
-    bool askForOverridingFile(const QString& strPath, QWidget *pParent  = NULL);
-    bool askForOverridingFiles(const QVector<QString>& strPaths, QWidget *pParent = NULL);
-    bool askForOverridingFileIfExists(const QString& strPath, QWidget *pParent = NULL);
-    bool askForOverridingFilesIfExists(const QVector<QString>& strPaths, QWidget *pParent = NULL);
-
     /* API: Main (startup) warnings: */
 #ifdef RT_OS_LINUX
@@ -199,13 +193,7 @@
 
     /* API: COM startup warnings: */
+    void cannotInitUserHome(const QString &strUserHome);
     void cannotInitCOM(HRESULT rc);
-    void cannotInitUserHome(const QString &strUserHome);
     void cannotCreateVirtualBox(const CVirtualBox &vbox);
-
-    /* API: Lincensing warnings: */
-#ifdef Q_WS_X11
-    void cannotFindLicenseFiles(const QString &strPath);
-#endif /* Q_WS_X11 */
-    void cannotOpenLicenseFile(QWidget *pParent, const QString &strPath);
 
     /* API: Global warnings: */
@@ -377,4 +365,13 @@
     void notifyAboutExtPackInstalled(const QString &strPackName, QWidget *pParent);
 
+    /* API: License-viewer warnings: */
+    void cannotOpenLicenseFile(QWidget *pParent, const QString &strPath);
+
+    /* API: File-dialog warnings: */
+    bool askForOverridingFile(const QString &strPath, QWidget *pParent = 0);
+    bool askForOverridingFiles(const QVector<QString> &strPaths, QWidget *pParent = 0);
+    bool askForOverridingFileIfExists(const QString &strPath, QWidget *pParent = 0);
+    bool askForOverridingFilesIfExists(const QVector<QString> &strPaths, QWidget *pParent = 0);
+
     /* Helpers: */
     static QString mediumToAccusative(UIMediumType type, bool fIsHostDrive = false);
Index: trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.cpp
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.cpp	(revision 45268)
+++ trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.cpp	(revision 45269)
@@ -1724,72 +1724,4 @@
     return QString (sTableTpl). arg (report);
 }
-
-#if defined(Q_WS_X11) && !defined(VBOX_OSE)
-double VBoxGlobal::findLicenseFile (const QStringList &aFilesList, QRegExp aPattern, QString &aLicenseFile) const
-{
-    double maxVersionNumber = 0;
-    aLicenseFile = "";
-    for (int index = 0; index < aFilesList.count(); ++ index)
-    {
-        aPattern.indexIn (aFilesList [index]);
-        QString version = aPattern.cap (1);
-        if (maxVersionNumber < version.toDouble())
-        {
-            maxVersionNumber = version.toDouble();
-            aLicenseFile = aFilesList [index];
-        }
-    }
-    return maxVersionNumber;
-}
-
-bool VBoxGlobal::showVirtualBoxLicense()
-{
-    /* get the apps doc path */
-    int size = 256;
-    char *buffer = (char*) RTMemTmpAlloc (size);
-    RTPathAppDocs (buffer, size);
-    QString path (buffer);
-    RTMemTmpFree (buffer);
-    QDir docDir (path);
-    docDir.setFilter (QDir::Files);
-    docDir.setNameFilters (QStringList ("License-*.html"));
-
-    /* Make sure that the language is in two letter code.
-     * Note: if languageId() returns an empty string lang.name() will
-     * return "C" which is an valid language code. */
-    QLocale lang (VBoxGlobal::languageId());
-
-    QStringList filesList = docDir.entryList();
-    QString licenseFile;
-    /* First try to find a localized version of the license file. */
-    double versionNumber = findLicenseFile (filesList, QRegExp (QString ("License-([\\d\\.]+)-%1.html").arg (lang.name())), licenseFile);
-    /* If there wasn't a localized version of the currently selected language,
-     * search for the generic one. */
-    if (versionNumber == 0)
-        versionNumber = findLicenseFile (filesList, QRegExp ("License-([\\d\\.]+).html"), licenseFile);
-    /* Check the version again. */
-    if (!versionNumber)
-    {
-        msgCenter().cannotFindLicenseFiles (path);
-        return false;
-    }
-
-    /* compose the latest license file full path */
-    QString latestVersion = QString::number (versionNumber);
-    QString latestFilePath = docDir.absoluteFilePath (licenseFile);
-
-    /* check for the agreed license version */
-    QStringList strList =  virtualBox().GetExtraData (GUI_LicenseKey).split(",");
-    for (int i=0; i < strList.size(); ++i)
-        if (strList.at(i) == latestVersion)
-            return true;
-
-    VBoxLicenseViewer licenseDialog;
-    bool result = licenseDialog.showLicenseFromFile(latestFilePath) == QDialog::Accepted;
-    if (result)
-        virtualBox().SetExtraData (GUI_LicenseKey, (strList << latestVersion).join(","));
-    return result;
-}
-#endif /* defined(Q_WS_X11) && !defined(VBOX_OSE) */
 
 /**
Index: trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.h
===================================================================
--- trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.h	(revision 45268)
+++ trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.h	(revision 45269)
@@ -237,9 +237,4 @@
 
     /* VirtualBox helpers */
-
-#if defined(Q_WS_X11) && !defined(VBOX_OSE)
-    double findLicenseFile (const QStringList &aFilesList, QRegExp aPattern, QString &aLicenseFile) const;
-    bool showVirtualBoxLicense();
-#endif
 
     CSession openSession(const QString &aId, KLockType aLockType = KLockType_Write);
