//--------------------------------------------------------------------------- void __fastcall TTVPMainForm::PopupMenuPopup(TObject *Sender) { ShowOnTopMenuItem->Checked = FormStyle == fsStayOnTop; ShowScriptEditorMenuItem->Checked = GetScriptEditorVisible(); ShowWatchMenuItem->Checked = GetWatchVisible(); ShowConsoleMenuItem->Checked = GetConsoleVisible(); EnableEventMenuItem->Checked = EventButton->Down; }
void BaseApp::Draw() { #ifdef _DEBUG //LogMsg("**********FRAME START"); #endif VariantList vList(Variant(0,0)); m_sig_render(&vList); if (GetFPSVisible()) { char stTemp[256]; sprintf(stTemp, "fps: %d - M: %.2f, T: %.2f A: %.2f F: %.2f", m_gameTimer.GetFPS(), (float(m_memUsed)/1024)/1024, (float(m_texMemUsed)/1024)/1024, float(GetAudioManager()->GetMemoryUsed()/1024)/ 1024, float(GetFreeMemory()/1024)/ 1024); #ifdef _IRR_STATIC_LIB_ int prims = 0; if (GetIrrlichtManager()->GetDriver()) { prims = GetIrrlichtManager()->GetDriver()->getPrimitiveCountDrawn(); } char stExtra[256]; sprintf(stExtra, " Prims: %d", prims); strcat(stTemp, stExtra); #endif #ifdef PLATFORM_FLASH char stExtra[256]; sprintf(stExtra, " Flash: %.2f", float(GetNativeMemoryUsed())/1024/1024); strcat(stTemp, stExtra); #endif if (GetFont(FONT_SMALL)->IsLoaded()) { GetFont(FONT_SMALL)->DrawScaled(3,3, stTemp, 0.7f); } } //draw the console messages? if (GetConsoleVisible()) { DrawConsole(); } switch (GetLastError()) { case ERROR_MEM: GetFont(FONT_SMALL)->DrawScaled(2,14, "LOW MEM!", 0.7f); break; case ERROR_SPACE: GetFont(FONT_SMALL)->DrawScaled(2,14, "LOW STORAGE SPACE!", 0.7f); break; case ERROR_NONE: break; } SetupOrtho(); g_globalBatcher.Flush(); }