Exemple #1
0
int main(int argc, char* argv[])
{
    QApplication application(argc, argv);
    QCoreApplication::setOrganizationName(ORG_KEY);
    QCoreApplication::setApplicationName(APP_KEY);

    /* On Windows msysgit exec directory is set up
     * during installation so to always find git.exe
     * also if not in PATH
     */
    QSettings set;
    GIT_DIR = set.value(GIT_DIR_KEY).toString();

    initMimePix();

    MainImpl *mainWindow = new MainImpl;
    mainWindow->show();

    QObject::connect(&application, SIGNAL(lastWindowClosed()),
                     &application, SLOT(quit()));

    bool ret = application.exec();

    freeMimePix();
    return ret;
}
Exemple #2
0
int main(int argc, char *argv[])
{
    QApplication app(argc, argv);

    MainImpl widget;
    app.setMainWidget(&widget);
    widget.show();

    return app.exec();
}