Files
winapp/Chip02FrameUnit.cpp
2026-06-12 22:37:02 +08:00

33 lines
1.0 KiB
C++

//---------------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include "Chip02FrameUnit.h"
#include "GameUnit.h"
#include "PolicyUnit.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TChip02Frame *Chip02Frame = NULL;
//---------------------------------------------------------------------------
__fastcall TChip02Frame::TChip02Frame(TComponent* Owner)
: TFrame(Owner)
{
m_leMinChip->Text = g_RandomChip.minChip;
m_leMaxChip->Text = g_RandomChip.maxChip;
}
//---------------------------------------------------------------------------
void __fastcall TChip02Frame::EditChipExit(TObject *Sender)
{
TEdit* pE = (TEdit*)Sender;
int num;
if(!TryStrToInt(pE->Text, num) || num<g_MinOnBet || num>g_MaxOnBet ){
ShowMessage("×¢Âë½ð¶î²»Äܳ¬¹ýÏÞºì");
pE->Text = pE==m_leMinChip ? "20" : "100";
pE->SetFocus();
}
}
//---------------------------------------------------------------------------