aboutsummaryrefslogtreecommitdiff
path: root/src-qt5/desktop-utils/lumina-photo/main.cpp
blob: faf919bef3b404e7937d116814da1d91acb8b4f3 (plain)
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
40
41
42
//===========================================
//  Lumina-DE source code
//  Copyright (c) 2016, Ken Moore
//  Available under the 3-clause BSD license
//  See the LICENSE file for full details
//===========================================
#include <QApplication>
#include <QDebug>

#include <LUtils.h>
#include <LuminaSingleApplication.h>
#include <LuminaThemes.h>

#include "mainUI.h"

int main (int argc, char *argv[])
{
    LTHEME::LoadCustomEnvSettings ();
    LSingleApplication a (argc, argv, "l-photo");
    if (!a.isPrimaryProcess ())
    {
        return 0;
    }
    // Now go ahead and setup the app
    QStringList args;
    for (int i = 1; i < argc; i++)
    {
        if (QString (argv[i]).startsWith ("--"))
        {
            args << QString (argv[i]);
        }
        else
        {
            args << LUtils::PathToAbsolute (QString (argv[i]));
        }
    }
    // Now start the window
    MainUI W;
    W.loadArguments (args);
    W.show ();
    return a.exec ();
}
bgstack15