Пример #1
0
void CConfigWizard::AddBoard(LPRECT lpRect, LPCTSTR desc)
{
	CDialog *pDlg = new T;
	pDlg->Create(T::IDD, &m_bnBoardPlace);
	pDlg->MoveWindow(lpRect);
	pDlg->SetWindowText(desc);
	m_wizards.push_back(pDlg);
	m_lbStep.AddItem(0, desc);
}
Пример #2
0
void Languages::Translate(CDialog& dialog, UINT nResourceID)
{
    //set translated text for every know control ID
    for (int iID = 0; iID < _APS_NEXT_CONTROL_VALUE; iID++)
    {
        mapitem_t::iterator ite = m_mItems.find(iID);
        if(ite != m_mItems.end() && dialog.GetDlgItem(iID))
        {
            dialog.SetDlgItemText(iID, ite->second);
        }
    }

    //set translated text on the dialog
    mapitem_t::iterator ite = m_mItems.find(nResourceID);
    if(ite != m_mItems.end())
        dialog.SetWindowText(ite->second);
    //else
    //    TRACE(_T("Missing Item ID %d\n"), nResourceID);

    CMenu* menu = dialog.GetMenu();
    if(menu)
        Translate(*menu);
}