本文整理汇总了C++中StHandle::getUserDataFolder方法的典型用法代码示例。如果您正苦于以下问题:C++ StHandle::getUserDataFolder方法的具体用法?C++ StHandle::getUserDataFolder怎么用?C++ StHandle::getUserDataFolder使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类StHandle
的用法示例。
在下文中一共展示了StHandle::getUserDataFolder方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: aLock
/**
* Instantiate StApplication.
*/
ST_LOCAL virtual void createApplication() override {
StMutexAuto aLock(myFetchLock);
const StString aFileExtension = StFileNode::getExtension(myCreatePath);
StHandle<StOpenInfo> anInfo = new StOpenInfo();
anInfo->setPath(myDndPath);
myDndPath.clear();
StHandle<StResourceManager> aResMgr = new StResourceManager(myActivity->assetManager);
//StHandle<StResourceManager> aResMgr = new StResourceManager(myActivity->assetManager"com.sview.cad");
aResMgr->setFolder(StResourceManager::FolderId_SdCard,
getStoragePath(myThJniEnv, "sdcard"));
aResMgr->setFolder(StResourceManager::FolderId_Downloads,
getStoragePath(myThJniEnv, "Download"));
aResMgr->setFolder(StResourceManager::FolderId_Pictures,
getStoragePath(myThJniEnv, "Pictures"));
aResMgr->setFolder(StResourceManager::FolderId_Photos,
getStoragePath(myThJniEnv, "DCIM"));
StString anOcctResFolder = aResMgr->getUserDataFolder();
copyResource(aResMgr, "lang", anOcctResFolder, "IGES.us");
copyResource(aResMgr, "lang", anOcctResFolder, "IGES.fr");
copyResource(aResMgr, "lang", anOcctResFolder, "SHAPE.us");
copyResource(aResMgr, "lang", anOcctResFolder, "SHAPE.fr");
copyResource(aResMgr, "lang", anOcctResFolder, "XSTEP.us");
copyResource(aResMgr, "lang", anOcctResFolder, "XSTEP.fr");
copyResource(aResMgr, "lang", anOcctResFolder, "TObj.msg");
copyResource(aResMgr, "res", anOcctResFolder, "Units.dat");
copyResource(aResMgr, "res", anOcctResFolder, "Lexi_Expr.dat");
copyResource(aResMgr, "res", anOcctResFolder, "IGES");
copyResource(aResMgr, "res", anOcctResFolder, "STEP");
//copyResource(aResMgr, "res", anOcctResFolder, "TObj");
//copyResource(aResMgr, "res", anOcctResFolder, "XCAF");
//copyResource(aResMgr, "res", anOcctResFolder, "Plugin");
//copyResource(aResMgr, "res", anOcctResFolder, "Standard");
//copyResource(aResMgr, "res", anOcctResFolder, "StandardLite");
copyResource(aResMgr, "shaders/occt", anOcctResFolder, "Declarations.glsl");
copyResource(aResMgr, "shaders/occt", anOcctResFolder, "DeclarationsImpl.glsl");
StProcess::setEnv("CSF_UnitsLexicon", anOcctResFolder + "/Lexi_Expr.dat");
StProcess::setEnv("CSF_UnitsDefinition", anOcctResFolder + "/Units.dat");
StProcess::setEnv("CSF_ShadersDirectory", anOcctResFolder);
StProcess::setEnv("CSF_SHMessage", anOcctResFolder);
if(myStAppClass.isEmpty()) {
myStAppClass = "cad";
}
if(anInfo->isEmpty()) {
// open recent file by default
StArgumentsMap anArgs = anInfo->getArgumentsMap();
anArgs.set(StDictEntry("last", "true"));
anArgs.set(StDictEntry("toSaveRecent","true"));
anInfo->setArgumentsMap(anArgs);
}
myApp = new StCADViewer(aResMgr, this, anInfo);
}