Ejemplo n.º 1
0
UINT DialogThreadFunktion(LPVOID param)
{
    CSettings dialog;
    dialog.DoModal();
    settingdialogopened=false;
    return 0;
}
Ejemplo n.º 2
0
//==========================================
//  Settings menu selected
//==========================================
void CVoiceMView::OnSettings() {
	
	CSettings SetDlg;
	CVoiceMApp *pMyApp;
	pMyApp = (CVoiceMApp*) AfxGetApp();

	//------------------------------------------
	// Init Dialog box with CVoiceMApp varibles
	//------------------------------------------
	SetDlg.m_Rings       = pMyApp->m_Rings;
	SetDlg.m_Seconds     = pMyApp->m_Seconds;
	SetDlg.m_ServerName  = pMyApp->m_ServerName;
	SetDlg.m_MailAddr    = pMyApp->m_MailAddr;
	SetDlg.m_GreetFName  = pMyApp->m_GreetFName;
	SetDlg.m_MsgPath     = pMyApp->m_MsgPath;
	SetDlg.m_bForward    = pMyApp->m_bForward;

	if(SetDlg.DoModal() == IDOK ) {		
		//------------------------------------------
		// Copy back settings to CDoc object
		//------------------------------------------
		pMyApp->m_Rings        = SetDlg.m_Rings;
		pMyApp->m_Seconds      = SetDlg.m_Seconds;
		pMyApp->m_ServerName   = SetDlg.m_ServerName;
		pMyApp->m_MailAddr     = SetDlg.m_MailAddr;
		pMyApp->m_GreetFName   = SetDlg.m_GreetFName;
		pMyApp->m_MsgPath      = SetDlg.m_MsgPath;
		pMyApp->m_bForward	   = SetDlg.m_bForward;

		//-------------------------------------------------
		// if msg path has no '/' or '\', append one,
		//-------------------------------------------------
		if ((pMyApp->m_MsgPath.Right(1) != "\\") && (pMyApp->m_MsgPath.Right(1) != "/")) {
			pMyApp->m_MsgPath = pMyApp->m_MsgPath + "\\"; 		
		}
		FillMsgList();
    }

}