1 /*
2     Certain enhancements (www.xtuple.com/trojita-enhancements)
3     are copyright © 2010 by OpenMFG LLC, dba xTuple.  All rights reserved.
4 
5     Redistribution and use in source and binary forms, with or without
6     modification, are permitted provided that the following conditions are met:
7 
8     - Redistributions of source code must retain the above copyright notice, this
9     list of conditions and the following disclaimer.
10     - Redistributions in binary form must reproduce the above copyright notice,
11     this list of conditions and the following disclaimer in the documentation
12     and/or other materials provided with the distribution.
13     - Neither the name of xTuple nor the names of its contributors may be used to
14     endorse or promote products derived from this software without specific prior
15     written permission.
16 
17     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
18     AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19     IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
20     DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
21     ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
22     (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
23     LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
24     ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25     (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
26     SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 
28 */
29 #include <QCoreApplication>
30 #include <QSettings>
31 #include "XtConnect.h"
32 #include "AppVersion/SetCoreApplication.h"
33 #include "Common/Application.h"
34 #include "Common/MetaTypes.h"
35 
main(int argc,char ** argv)36 int main( int argc, char** argv) {
37     Common::registerMetaTypes();
38     QCoreApplication app( argc, argv );
39     Common::Application::name = QString::fromAscii("xtconnect-trojita");
40     AppVersion::setGitVersion();
41     AppVersion::setCoreApplicationData();
42     QCoreApplication::setOrganizationDomain( QString::fromAscii("xtuple.com") );
43     QCoreApplication::setOrganizationName( QString::fromAscii("xtuple.com") );
44     QSettings s(QSettings::UserScope, QString::fromAscii("xTuple.com"), QString::fromAscii("xTuple"));
45     XtConnect::XtConnect conn(0, &s);
46     return app.exec();
47 }
48