3 Copyright (C) 2010 Christian Pulvermacher
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License along
16 with this program; if not, write to the Free Software Foundation, Inc.,
17 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
19 #include <QApplication>
22 #include "mainwindow.h"
24 int main(int argc, char *argv[])
26 QCoreApplication::setOrganizationName("Presence VNC");
27 QCoreApplication::setApplicationName("Presence VNC");
29 QApplication app(argc, argv);
31 QString url = QString();
33 QStringList arguments = QCoreApplication::arguments();
34 if (arguments.count() > 1) {
35 //Example: vnc://:password@server:1\n"
36 //"Optionally, you can define the quality as second argument (1-3, where 1 is the best). Default is 2.");
38 url = arguments.at(1);
39 if(arguments.count() > 2)
40 quality = arguments.at(2).toInt();
43 MainWindow main(url, quality);