Skip to content

Commit

Permalink
Ajout d'un écran de démarrage
Browse files Browse the repository at this point in the history
  • Loading branch information
cvermot committed Aug 1, 2024
1 parent 0391351 commit 2920d48
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
Binary file added ressources/splash.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion src/AeroDms.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
AeroDms::AeroDms(QWidget* parent) :QMainWindow(parent)
{
QApplication::setApplicationName("AeroDms");
QApplication::setApplicationVersion("4.7");
QApplication::setApplicationVersion("4.8");
QApplication::setWindowIcon(QIcon("./ressources/shield-airplane.svg"));
mainTabWidget = new QTabWidget(this);
setCentralWidget(mainTabWidget);
Expand Down Expand Up @@ -2257,6 +2257,7 @@ void AeroDms::aPropos()
" <a href=\"https://github.com/cvermot/AeroDMS\">GitHub</a>.<br />< br/>"
"Ce programme utilise la libraire <a href=\"https://github.com/podofo/podofo\">PoDoFo</a> 0.10.3.<br />< br/>"
"Les icones sont issues de <a href=\"https://pictogrammers.com/\">pictogrammers.com</a>.< br />< br />"
"L'image de démarrage est génerée avec <a href=\"https://designer.microsoft.com/\">Microsoft Designer</a>.< br />< br />"
"Ce programme inclu du code source inspiré de code sous licence BSD-3-Clause (Copyright (C) The Qt Company Ltd).<br />< br/>"
"Mentions légales : <br />"
" This program is free software: you can redistribute it and/or modify"
Expand Down
7 changes: 7 additions & 0 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@ int main(int argc, char *argv[])
{
QApplication a(argc, argv);

QPixmap pixmap("./ressources/splash.jpg");
QSplashScreen splash(pixmap);
splash.show();
splash.showMessage("Chargement en cours");
a.processEvents();

//originalHandler = qInstallMessageHandler(logToFile);

QTranslator* translator = new QTranslator();
Expand All @@ -47,5 +53,6 @@ int main(int argc, char *argv[])

AeroDms w;
w.show();
splash.finish(&w);
return a.exec();
}

0 comments on commit 2920d48

Please sign in to comment.