forked from Frieve-A/Frieve-Editor
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathforandomcard.cpp
More file actions
65 lines (62 loc) · 2.18 KB
/
Copy pathforandomcard.cpp
File metadata and controls
65 lines (62 loc) · 2.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
//---------------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include "forandomcard.h"
#include "setting.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TFo_RandomCard *Fo_RandomCard;
//---------------------------------------------------------------------------
__fastcall TFo_RandomCard::TFo_RandomCard(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TFo_RandomCard::FormDeactivate(TObject *Sender)
{
Close();
}
//---------------------------------------------------------------------------
void TFo_RandomCard::SettingToGUI()
{
TB_Cards->Position = SettingView.m_nAnimationRCCards;
TB_CardsChange(this);
TB_Speed->Position = SettingView.m_nAnimationRCSpeed;
SB_Pause->Down = SettingView.m_bAnimationPaused;
}
//---------------------------------------------------------------------------
void __fastcall TFo_RandomCard::TB_CardsChange(TObject *Sender)
{
La_Cards->Caption = TB_Cards->Position;
SettingView.m_nAnimationRCCards = TB_Cards->Position;
}
//---------------------------------------------------------------------------
void __fastcall TFo_RandomCard::TB_SpeedChange(TObject *Sender)
{
SettingView.m_nAnimationRCSpeed = TB_Speed->Position;
}
//---------------------------------------------------------------------------
void __fastcall TFo_RandomCard::SB_StopClick(TObject *Sender)
{
Close();
}
//---------------------------------------------------------------------------
void __fastcall TFo_RandomCard::SB_PauseClick(TObject *Sender)
{
SettingView.m_bAnimationPaused = SB_Pause->Down;
}
//---------------------------------------------------------------------------
void __fastcall TFo_RandomCard::FormShow(TObject *Sender)
{
SettingToGUI();
}
//---------------------------------------------------------------------------
void __fastcall TFo_RandomCard::FormKeyDown(TObject *Sender, WORD &Key,
TShiftState Shift)
{
if (Key == 27){
Close();
}
}
//---------------------------------------------------------------------------