/* ============================================================ * The rekonq project * ============================================================ * SPDX-License-Identifier: GPL-2.0-or-later * Copyright (C) 2008-2013 by Andrea Diamantini * SPDX-License-Identifier: GPL-3.0-only * Copyright (C) 2022 aqua * ============================================================ * Description: Application Entry Point * ============================================================ */ #include "application.hpp" #include int main(int argc, char **argv) { #ifdef QT_DEBUG spdlog::set_level(spdlog::level::debug); #endif // When loading QtWebEngine from a plugin, set Qt::AA_ShareOpenGLContexts using QCoreApplication::setAttribute QCoreApplication::setAttribute(Qt::AA_ShareOpenGLContexts, true); Application app(argc, argv); // Set application data QCoreApplication::setApplicationName(QL1S("rekonq")); QCoreApplication::setApplicationVersion(REKONQ_VERSION); if (app.isSecondary()) { app.sendMessage(Application::arguments().join('\n').toUtf8()); return 0; } else app.parseCommandLine(app.instanceId(), {}); /* if (app.isSessionRestored()) { for (int i = 1; RekonqWindow::canBeRestored(i); i++) { RekonqWindow * newRekonqWindow = app.newWindow(false); if (newRekonqWindow->restore(i)) SessionManager::self()->restoreWindow(newRekonqWindow); } } */ return Application::exec(); }