[uphone] don't block when zip resources loading failed

This commit is contained in:
walzer 2011-01-26 17:08:19 +08:00
parent d243f01b20
commit ead71525e2
2 changed files with 5 additions and 3 deletions

View File

@ -15,8 +15,9 @@ Int32 TG3AppMain(const TUChar * pAppID, UInt32 nCmd, void * pCmdParam)
{ {
AppDelegate app; AppDelegate app;
#ifndef _TRANZDA_VM_ // on uphone emulator, we copy resources files to Work7/TG3/APP/ folder instead of zip file // on uphone emulator, we copy resources files to Work7/TG3/APP/ folder instead of zip file
cocos2d::CCFileUtils::setResource("TestCocos2dx.zip"); #ifndef _TRANZDA_VM_
cocos2d::CCFileUtils::setResource("HelloWorld.zip");
#endif #endif
app.Run(); app.Run();

View File

@ -261,7 +261,8 @@ void setZipFilePath(const char* pZipFileName)
strErr += " not exist!"; strErr += " not exist!";
TUChar szText[EOS_FILE_MAX_PATH] = { 0 }; TUChar szText[EOS_FILE_MAX_PATH] = { 0 };
TUString::StrUtf8ToStrUnicode(szText,(Char*)strErr.c_str()); TUString::StrUtf8ToStrUnicode(szText,(Char*)strErr.c_str());
TApplication::GetCurrentApplication()->MessageBox(szText,NULL,WMB_OK); // TApplication::GetCurrentApplication()->MessageBox(szText,NULL,WMB_OK);
TMessageBox box(szText, NULL, WMB_OK); // to be fix. This line isn't work, but not block
return; return;
} }