本文整理汇总了C++中QCoreApplication::setApplicationVersion方法的典型用法代码示例。如果您正苦于以下问题:C++ QCoreApplication::setApplicationVersion方法的具体用法?C++ QCoreApplication::setApplicationVersion怎么用?C++ QCoreApplication::setApplicationVersion使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类QCoreApplication
的用法示例。
在下文中一共展示了QCoreApplication::setApplicationVersion方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: start
void ServiceApp::start()
{
QCoreApplication *app = application();
app->setApplicationName(SCHAT_NAME);
app->setApplicationVersion(SCHAT_VERSION);
app->setOrganizationName(LS("IMPOMEZIA"));
app->setOrganizationDomain(SCHAT_DOMAIN);
m_init = new NodeInit(LS("schatd2"), app);
}
示例2: main
int main(int argc, char *argv[])
{
//Initialization of system functions
InitSystem();
//configure debug output
qInstallMessageHandler(myMessageOutput);
//class for interface windows
gMainInterface = new cInterface;
WriteLog("Prepare QApplication", 2);
QCoreApplication *gCoreApplication = new QCoreApplication(argc, argv);
gCoreApplication->setOrganizationName("Mandelbulber");
gCoreApplication->setApplicationName("Mandelbulber");
gCoreApplication->setApplicationVersion(MANDELBULBER_VERSION_STRING);
UpdateLanguage(gCoreApplication);
cCommandLineInterface commandLineInterface(gApplication);
if (commandLineInterface.isNoGUI())
{
gApplication = qobject_cast<QApplication *>(gCoreApplication);
}
else
{
delete gCoreApplication;
gApplication = new QApplication(argc, argv);
gApplication->setOrganizationName("Mandelbulber");
gApplication->setApplicationName("Mandelbulber");
gApplication->setApplicationVersion(MANDELBULBER_VERSION_STRING);
}
//registering types for queued connections
qRegisterMetaType<cStatistics>("cStatistics");
qRegisterMetaType<QList<QByteArray> >("QList<QByteArray>");
qRegisterMetaType<QList<int> >("QList<int>");
qRegisterMetaType<cParameterContainer>("cParameterContainer");
qRegisterMetaType<cFractalContainer>("cFractalContainer");
qRegisterMetaType<sTextures>("sTextures");
qRegisterMetaType<cProgressText::enumProgressType>("cProgressText::enumProgressType");
qRegisterMetaType<QVector<int> >("QVector<int>");
qRegisterMetaType<CVector2<double> >("CVector2<double>");
qRegisterMetaType<QMessageBox::StandardButtons>("QMessageBox::StandardButtons");
qRegisterMetaType<QMessageBox::StandardButtons*>("QMessageBox::StandardButtons*");
qRegisterMetaType<cErrorMessage::enumMessageType>("cErrorMessage::enumMessageType");
gErrorMessage = new cErrorMessage;
//create default directories and copy all needed files
WriteLog("CreateDefaultFolders()", 2);
if (!CreateDefaultFolders())
{
qCritical() << "Files/directories initialization failed" << endl;
return 73;
}
//create internal database with parameters
gPar = new cParameterContainer;
gParFractal = new cFractalContainer;
//Allocate container for animation frames
gAnimFrames = new cAnimationFrames;
//Allocate container for key frames
gKeyframes = new cKeyframes;
gPar->SetContainerName("main");
InitParams(gPar);
for (int i = 0; i < NUMBER_OF_FRACTALS; i++)
{
gParFractal->at(i).SetContainerName(QString("fractal") + QString::number(i));
InitFractalParams(&gParFractal->at(i));
}
/****************** TEMPORARY CODE FOR MATERIALS *******************/
//InitMaterialParams(1, gPar);
//InitMaterialParams(2, gPar);
//InitMaterialParams(3, gPar);
/*******************************************************************/
//Define list of fractal formulas
DefineFractalList(&fractalList);
//Netrender
gNetRender = new CNetRender(systemData.numberOfThreads);
//loading AppSettings
if (QFile(systemData.dataDirectory + "mandelbulber.ini").exists())
{
cSettings parSettings(cSettings::formatAppSettings);
parSettings.LoadFromFile(systemData.dataDirectory + "mandelbulber.ini");
parSettings.Decode(gPar, gParFractal);
}
systemData.loggingVerbosity = gPar->Get<int>("logging_verbosity");
//.........这里部分代码省略.........