\r
\r
BEGIN_MESSAGE_MAP(CSettingGitConfig, CPropertyPage)\r
+ ON_BN_CLICKED(IDC_CHECK_GLOBAL, &CSettingGitConfig::OnBnClickedCheckGlobal)\r
+ ON_EN_CHANGE(IDC_GIT_USERNAME, &CSettingGitConfig::OnEnChangeGitUsername)\r
+ ON_EN_CHANGE(IDC_GIT_USEREMAIL, &CSettingGitConfig::OnEnChangeGitUseremail)\r
END_MESSAGE_MAP()\r
\r
BOOL CSettingGitConfig::OnInitDialog()\r
return TRUE;\r
}\r
// CSettingGitConfig message handlers\r
+\r
+void CSettingGitConfig::OnBnClickedCheckGlobal()\r
+{\r
+ // TODO: Add your control notification handler code here\r
+ SetModified();\r
+}\r
+\r
+void CSettingGitConfig::OnEnChangeGitUsername()\r
+{\r
+ // TODO: If this is a RICHEDIT control, the control will not\r
+ // send this notification unless you override the ISettingsPropPage::OnInitDialog()\r
+ // function and call CRichEditCtrl().SetEventMask()\r
+ // with the ENM_CHANGE flag ORed into the mask.\r
+\r
+ // TODO: Add your control notification handler code here\r
+ SetModified();\r
+}\r
+\r
+void CSettingGitConfig::OnEnChangeGitUseremail()\r
+{\r
+ // TODO: If this is a RICHEDIT control, the control will not\r
+ // send this notification unless you override the ISettingsPropPage::OnInitDialog()\r
+ // function and call CRichEditCtrl().SetEventMask()\r
+ // with the ENM_CHANGE flag ORed into the mask.\r
+\r
+ // TODO: Add your control notification handler code here\r
+ SetModified();\r
+}\r
+\r
+BOOL CSettingGitConfig::OnApply()\r
+{\r
+ CString cmd, out;\r
+ this->UpdateData(FALSE);\r
+\r
+ cmd.Format(_T("git.exe config user.name %s"),this->m_UserName);\r
+ cmd.Format(_T("git.exe config user.email %s"),this->m_UserEmail);\r
+\r
+ SetModified(FALSE);\r
+ return ISettingsPropPage::OnApply();\r
+}
\ No newline at end of file