Fixed issue #220: Enhancement, support creating bare repositories
[TortoiseGit.git] / src / TortoiseProc / ResetDlg.cpp
blob6d563e39d72c9fd4365643e55cc1e4df28604729
1 // ResetDlg.cpp : implementation file
2 //
4 #include "stdafx.h"
5 #include "TortoiseProc.h"
6 #include "ResetDlg.h"
9 // CResetDlg dialog
11 IMPLEMENT_DYNAMIC(CResetDlg, CResizableStandAloneDialog)
13 CResetDlg::CResetDlg(CWnd* pParent /*=NULL*/)
14 : CResizableStandAloneDialog(CResetDlg::IDD, pParent)
15 , m_ResetType(1)
20 CResetDlg::~CResetDlg()
24 void CResetDlg::DoDataExchange(CDataExchange* pDX)
26 CDialog::DoDataExchange(pDX);
30 BEGIN_MESSAGE_MAP(CResetDlg, CResizableStandAloneDialog)
31 END_MESSAGE_MAP()
34 // CResetDlg message handlers
35 BOOL CResetDlg::OnInitDialog()
37 CResizableStandAloneDialog::OnInitDialog();
39 AddAnchor(IDC_RESET_BRANCH_NAME, TOP_LEFT, TOP_RIGHT);
40 AddAnchor(IDC_GROUP_RESET_TYPE, TOP_LEFT,TOP_RIGHT);
42 AddAnchor(IDOK,BOTTOM_RIGHT);
43 AddAnchor(IDCANCEL,BOTTOM_RIGHT);
45 this->CheckRadioButton(IDC_RADIO_RESET_SOFT,IDC_RADIO_RESET_HARD,IDC_RADIO_RESET_SOFT+m_ResetType);
47 return TRUE;
50 void CResetDlg::OnOK()
52 m_ResetType=this->GetCheckedRadioButton(IDC_RADIO_RESET_SOFT,IDC_RADIO_RESET_HARD)-IDC_RADIO_RESET_SOFT;
53 return CResizableStandAloneDialog::OnOK();