//--------------------------------------------------------------------------- #include #pragma hdrstop #include "ProgressThreadUnit.h" #include "ProgressFormUnit.h" #include "StylesUpProgressFormUnit.h" #pragma package(smart_init) //--------------------------------------------------------------------------- //--------------------------------------------------------------------------- __fastcall TProgressThread::TProgressThread(bool CreateSuspended, TForm* pForm) : TThread(CreateSuspended) { m_pForm = pForm; } //--------------------------------------------------------------------------- void __fastcall TProgressThread::Execute() { //---- Place thread code here ---- if(m_pForm->Name == L"StylesUpProgressForm") ((TStylesUpProgressForm*)m_pForm)->Operation(); else ((TProgressForm*)m_pForm)->Operation(); } //---------------------------------------------------------------------------