Files
AccompanyCube/ProgressFormUnit.h
T
2026-06-13 00:10:11 +08:00

113 lines
4.0 KiB
C++

//---------------------------------------------------------------------------
#ifndef ProgressFormUnitH
#define ProgressFormUnitH
//---------------------------------------------------------------------------
#include <System.Classes.hpp>
#include <Vcl.Controls.hpp>
#include <Vcl.StdCtrls.hpp>
#include <Vcl.Forms.hpp>
#include <Vcl.ExtCtrls.hpp>
#include <Vcl.Imaging.pngimage.hpp>
#include "PNGButton.hpp"
#include "GlobalUnit.h"
#include <Vcl.Graphics.hpp>
//---------------------------------------------------------------------------
class TProgressForm : public TForm
{
__published: // IDE-managed Components
TImage *m_imgBk;
TLabel *m_lblCaption;
Vcl::Extctrls::TPanel *m_panelProgress;
TPaintBox *m_pbProgress;
TPNGButton *m_btnClose;
void __fastcall ProgressPaint(TObject *Sender);
void __fastcall FormCreate(TObject *Sender);
void __fastcall CloseClick(TObject *Sender);
void __fastcall FormKeyDown(TObject *Sender, WORD &Key, TShiftState Shift);
void __fastcall FormClose(TObject *Sender, TCloseAction &Action);
private: // User declarations
TBitmap *m_bmpTileLeft,
*m_bmpTileRight;
TThread *m_pThread;
TTimer *m_pTimer;
int m_nTileWidth,
m_nTileHeight,
m_nMaxPos,
m_nPos,
m_iOperation,
m_iOperationResult;
TCHAR m_strParam1[256];
char m_strBuff[256];
void* m_pParam1, *m_pParam2;
int m_nNextMinPos,
m_nNextMaxPos;
UINT m_nParam1, m_nParam2;
int *m_pIntParam1, *m_pIntParam2;
//SaveMediaרÓÃ
UINT m_nParam3, m_nParam4;
TThread *m_pConfirmThread;
int m_iSaveState,
m_iConfirmResult,
m_iFileHandle;
void __fastcall TimerProc(TObject* Sender);
void StartConfirm();
void Canceled();
MESSAGE void __fastcall WMNCHitTest(TWMNCHitTest &Msg);
MESSAGE void __fastcall UMOperateFailed(TMessage &Message);
MESSAGE void __fastcall UMOperatePercent(TMessage &Message);
MESSAGE void __fastcall UMOperateComplete(TMessage &Message);
MESSAGE void __fastcall UMOperateNextRange(TMessage &Message);
MESSAGE void __fastcall UMRecordComplete(TMessage &Message);
MESSAGE void __fastcall UMPaymentConfirmed(TMessage &Message);
BEGIN_MESSAGE_MAP
MESSAGE_HANDLER(WM_NCHITTEST, TWMNCHitTest, WMNCHitTest)
MESSAGE_HANDLER(MSG_OPERATE_FAILED, TMessage, UMOperateFailed)
MESSAGE_HANDLER(MSG_OPERATE_PERCENT, TMessage, UMOperatePercent)
MESSAGE_HANDLER(MSG_OPERATE_COMPLETE, TMessage, UMOperateComplete)
MESSAGE_HANDLER(MSG_OPERATE_NEXTRANGE, TMessage, UMOperateNextRange)
MESSAGE_HANDLER(MSG_RECORD_COMPLETE, TMessage, UMRecordComplete)
MESSAGE_HANDLER(MSG_PAYMENTCONFIRMED, TMessage, UMPaymentConfirmed)
END_MESSAGE_MAP(TForm)
public: // User declarations
__fastcall TProgressForm(TComponent* Owner);
__fastcall ~TProgressForm();
int __fastcall MM_SaveMedia( int iSaveType, int iFileType, LPCTSTR strFileName,
int iOp, int nIdCount, UINT aIdStyle[] );
int __fastcall MM_Save( int iSaveType, LPCTSTR strFileName, int iFileType );
int __fastcall MM_Load( LPCTSTR strFileName, int iFileType );
int __fastcall Project_Save( LPCTSTR strFileName );
int __fastcall Project_Load( LPCTSTR strFileName );
int __fastcall User_Register( int isEmailOrMobile );
int __fastcall User_Login();
int __fastcall User_CheckPayment( int iOperation, int nIdCount, UINT aIdStyle[],
int aStyleCost[], int* pCost, int* pBalance );
int __fastcall User_ConfirmPayment( int iOperation, int nIdCount, UINT aIdStyle[],
int* pUserBalance );
int __fastcall User_SubmitQuestin( LPCSTR strQuestion );
int __fastcall User_StyleScore( UINT idStyle, int* pScrUser, int* pScrAverage );//add by laq
int __fastcall User_UploadSong( LPCTSTR strFileName, TSHAREINFO* pShareInfo );
void __fastcall Operation();
void __fastcall SetOperationResult( int iRes ) { m_iOperationResult=iRes; };
int __fastcall GetOpertaionResult() { return m_iOperationResult; };
TMessage m_MsgTransparent;
};
//---------------------------------------------------------------------------
extern PACKAGE TProgressForm *ProgressForm;
//---------------------------------------------------------------------------
#endif