SetDlg.cpp
上传用户:kkzhu_0
上传日期:2007-01-05
资源大小:214k
文件大小:3k
源码类别:

棋牌游戏

开发平台:

Visual C++

  1. // SetDlg.cpp : implementation file
  2. //
  3. #include "stdafx.h"
  4. #include "five.h"
  5. #include "SetDlg.h"
  6. #ifdef _DEBUG
  7. #define new DEBUG_NEW
  8. #undef THIS_FILE
  9. static char THIS_FILE[] = __FILE__;
  10. #endif
  11. /////////////////////////////////////////////////////////////////////////////
  12. // CSetDlg dialog
  13. CSetDlg::CSetDlg(CWnd* pParent /*=NULL*/)
  14. : CDialog(CSetDlg::IDD, pParent)
  15. {
  16. //{{AFX_DATA_INIT(CSetDlg)
  17. // NOTE: the ClassWizard will add member initialization here
  18. //}}AFX_DATA_INIT
  19. }
  20. void CSetDlg::DoDataExchange(CDataExchange* pDX)
  21. {
  22. CDialog::DoDataExchange(pDX);
  23. //{{AFX_DATA_MAP(CSetDlg)
  24. // NOTE: the ClassWizard will add DDX and DDV calls here
  25. //}}AFX_DATA_MAP
  26. }
  27. BEGIN_MESSAGE_MAP(CSetDlg, CDialog)
  28. //{{AFX_MSG_MAP(CSetDlg)
  29. ON_BN_CLICKED(IDC_SET_RESET, OnSetReset)
  30. //}}AFX_MSG_MAP
  31. END_MESSAGE_MAP()
  32. /////////////////////////////////////////////////////////////////////////////
  33. // CSetDlg message handlers
  34. BOOL CSetDlg::OnInitDialog() 
  35. {
  36. CDialog::OnInitDialog();
  37. // TODO: Add extra initialization here
  38. SetDlgItemInt( IDC_EDIT_WF0_1,WF0_1 );
  39. SetDlgItemInt( IDC_EDIT_WF0_2,WF0_2 );
  40. SetDlgItemInt( IDC_EDIT_WF0_3,WF0_3 );
  41. SetDlgItemInt( IDC_EDIT_WF0_4,WF0_4 );
  42. SetDlgItemInt( IDC_EDIT_WF1_1,WF1_1 );
  43. SetDlgItemInt( IDC_EDIT_WF1_2,WF1_2 );
  44. SetDlgItemInt( IDC_EDIT_WF1_3,WF1_3 );
  45. SetDlgItemInt( IDC_EDIT_WF1_4,WF1_4 );
  46. SetDlgItemInt( IDC_EDIT_WF2_3,WF2_3 );
  47. SetDlgItemInt( IDC_EDIT_WF2_4,WF2_4 );
  48. SetDlgItemInt( IDC_EDIT_WF5,WF5 );
  49. SetDlgItemInt( IDC_EDIT_BREADTH,Breadth );
  50. SetDlgItemInt( IDC_EDIT_DEEP,Deep );
  51. SetDlgItemInt( IDC_EDIT_THREAD,Thread );
  52. SetDlgItemInt( IDC_EDIT_DELTA,Delta );
  53. return TRUE;  // return TRUE unless you set the focus to a control
  54.               // EXCEPTION: OCX Property Pages should return FALSE
  55. }
  56. void CSetDlg::OnOK() 
  57. {
  58. // TODO: Add extra validation here
  59. WF0_1 = GetDlgItemInt( IDC_EDIT_WF0_1 );
  60. WF0_2 = GetDlgItemInt( IDC_EDIT_WF0_2 );
  61. WF0_3 = GetDlgItemInt( IDC_EDIT_WF0_3 );
  62. WF0_4 = GetDlgItemInt( IDC_EDIT_WF0_4 );
  63. WF1_1 = GetDlgItemInt( IDC_EDIT_WF1_1 );
  64. WF1_2 = GetDlgItemInt( IDC_EDIT_WF1_2 );
  65. WF1_3 = GetDlgItemInt( IDC_EDIT_WF1_3 );
  66. WF1_4 = GetDlgItemInt( IDC_EDIT_WF1_4 );
  67. WF2_3 = GetDlgItemInt( IDC_EDIT_WF2_3 );
  68. WF2_4 = GetDlgItemInt( IDC_EDIT_WF2_4 );
  69. WF5   = GetDlgItemInt( IDC_EDIT_WF5 );
  70. Breadth = GetDlgItemInt( IDC_EDIT_BREADTH );
  71. Deep = GetDlgItemInt( IDC_EDIT_DEEP );
  72. Thread = GetDlgItemInt( IDC_EDIT_THREAD );
  73. Delta = GetDlgItemInt( IDC_EDIT_DELTA );
  74. CDialog::OnOK();
  75. }
  76. void CSetDlg::OnSetReset() 
  77. {
  78. // TODO: Add your control notification handler code here
  79. SetDlgItemInt( IDC_EDIT_WF0_1,2 );
  80. SetDlgItemInt( IDC_EDIT_WF0_2,50 );
  81. SetDlgItemInt( IDC_EDIT_WF0_3,500 );
  82. SetDlgItemInt( IDC_EDIT_WF0_4,5000 );
  83. SetDlgItemInt( IDC_EDIT_WF1_1,1 );
  84. SetDlgItemInt( IDC_EDIT_WF1_2,20 );
  85. SetDlgItemInt( IDC_EDIT_WF1_3,150 );
  86. SetDlgItemInt( IDC_EDIT_WF1_4,600 );
  87. SetDlgItemInt( IDC_EDIT_WF2_3,400 );
  88. SetDlgItemInt( IDC_EDIT_WF2_4,450 );
  89. SetDlgItemInt( IDC_EDIT_WF5,30000 );
  90. SetDlgItemInt( IDC_EDIT_BREADTH,10 );
  91. SetDlgItemInt( IDC_EDIT_DEEP,4 );
  92. SetDlgItemInt( IDC_EDIT_THREAD,0 );
  93. SetDlgItemInt( IDC_EDIT_DELTA,2 );
  94. }