int main(int argc, char *argv[]) {
#if defined Q_WS_MAC
localedirfile
= QString("%1/locale/edit_%2.qm").
arg(WORK_CACHEDIR
).
arg(UserLanguage
());
#endif
#if defined Q_WS_WIN
#endif
#if defined Q_WS_X11
localedirfile
= QString("%1/locale/edit_%2.qm").
arg(WORK_CACHEDIR
).
arg(UserLanguage
());
#endif
translator.load(localedirfile);
a.installTranslator(&translator);
if (!NetworkEnable()) {
QMessageBox::warning(0,
"NetworkInterface",
"Check Your Network! SQL DB get data........");
return 0;
}
Preload *splash = new Preload(1400,LICENCE); /* animated painter dialog widget loading msec */
splash->exec();
Gui_Main::self()->setWindowTitle( _PROGRAM_TITLE_ );
if (soko.size() > 0 ) {
if (soko == "NorwegianWood") {
a.setStyle(new NorwegianWoodStyle);
} else if (soko == "ArthurStyle") {
#ifdef QT_OPENGL_SUPPORT
QStyle *arthurStyle
= new ArthurStyle
();
QList<QWidget *> widgets = qFindChildren<QWidget *>(Gui_Main::self());
w->setStyle(arthurStyle);
}
a.setStyle(arthurStyle);
#endif
} else if (soko == "QWindowsVistaStyle") {
#if defined Q_WS_WIN
a.setStyle(new QWindowsVistaStyle);
#endif
} else {
}
///////////a.setPalette(QApplication::style()->standardPalette());
}
argument_1
= QString::fromLatin1(argv
[1]);
if (argument_1.contains(".chre")) {
Gui_Main
::self()->setOpen
(QUrl(argument_1
));
}
Gui_Main::self()->show();
///////// splash self close /////
a.connect( &a, SIGNAL( lastWindowClosed() ), &a, SLOT( quit() ) );
return a.exec();
};