| 184 | template<> SApplication* SSingleton<SApplication>::ms_Singleton = 0; |
| 185 | |
| 186 | SApplication::SApplication(IRenderFactory *pRendFactory,HINSTANCE hInst,LPCTSTR pszHostClassName, ISystemObjectRegister & sysObjRegister,BOOL bImeApp) |
| 187 | :m_hInst(hInst) |
| 188 | ,m_RenderFactory(pRendFactory) |
| 189 | ,m_hMainWnd(NULL) |
| 190 | { |
| 191 | SWndSurface::Init(); |
| 192 | memset(m_pSingletons, 0, sizeof(m_pSingletons)); |
| 193 | _CreateSingletons(hInst,pszHostClassName,bImeApp); |
| 194 | |
| 195 | m_translator.Attach(new SNullTranslator); |
| 196 | m_tooltipFactory.Attach(new SDefToolTipFactory); |
| 197 | m_msgLoopFactory.Attach(new SDefMsgLoopFactory); |
| 198 | |
| 199 | SAppDir appDir(hInst); |
| 200 | m_strAppDir = appDir.AppDir(); |
| 201 | |
| 202 | m_pMsgLoop = GetMsgLoopFactory()->CreateMsgLoop(); |
| 203 | |
| 204 | sysObjRegister.RegisterLayouts(this); |
| 205 | sysObjRegister.RegisterSkins(this); |
| 206 | sysObjRegister.RegisterWindows(this); |
| 207 | sysObjRegister.RegisterInterpolator(this); |
| 208 | } |
| 209 | |
| 210 | SApplication::~SApplication(void) |
| 211 | { |
nothing calls this directly
no test coverage detected