-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
39 lines (32 loc) · 980 Bytes
/
main.cpp
File metadata and controls
39 lines (32 loc) · 980 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#include "stopmotionanimation.h"
#include <QApplication>
#include <QCoreApplication>
#include <QSplashScreen>
#include <QTime>
#include <QString>
#include <QSettings>
const double SPLASH_SECONDS = 2;
void ConfigureSettings ();
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
QCoreApplication::setOrganizationName("Pioneer Library System");
QCoreApplication::setOrganizationDomain("pioneerlibrarysystem.org");
QCoreApplication::setApplicationName("PLS Stop Motion Creator");
// Show the splashscreen:
QPixmap pixmap(":/images/splashscreen.png");
QSplashScreen splash(pixmap);
splash.show();
a.processEvents();
QTime now;
now.start();
StopMotionAnimation w;
while (now.elapsed() < SPLASH_SECONDS*1000 &&
splash.isVisible()) {
// This is here to handle mouse clicks, which will dismiss the window
a.processEvents();
}
w.show();
splash.finish(&w);
return a.exec();
}