+static FORCE_INLINE QString getExecutableName(int &argc, char **argv)
+{
+ if(argc >= 1)
+ {
+ const char *argv0 = argv[0];
+ for (int i = 0; i < 2; i++)
+ {
+ static const char SEP[2] = { '/', '\\' };
+ if (const char *const ptr = strrchr(argv0, SEP[i]))
+ {
+ argv0 = ptr + 1;
+ }
+ }
+ if(strlen(argv0) > 1)
+ {
+ return QString::fromLatin1(argv0);
+ }
+ }
+ return QLatin1String("Program.exe");
+}
+
+static FORCE_INLINE void qt_registry_cleanup(void)
+{
+ static const wchar_t *const QT_JUNK_KEY = L"Software\\Trolltech\\OrganizationDefaults";
+ MUtils::Registry::reg_key_delete(MUtils::Registry::root_user, MUTILS_QSTR(QT_JUNK_KEY), true, true);
+}
+
+QApplication *MUtils::Startup::create_qt(int &argc, char **argv, const QString &appName, const QString &appAuthor, const QString &appDomain)