예제 #1
0
파일: UIPanel.cpp 프로젝트: zhuhuigong/test
void CWarningPanelUI::SetAttribute(LPCTSTR pstrName, LPCTSTR pstrValue)
{
    if (_tcscmp(pstrName, _T("type")) == 0) {
        if (_tcscmp(pstrValue, _T("error")) == 0) SetWarningType(MB_ICONERROR);
        if (_tcscmp(pstrValue, _T("warning")) == 0) SetWarningType(MB_ICONWARNING);
    }
    else CTextPanelUI::SetAttribute(pstrName, pstrValue);
}
예제 #2
0
void WarningPanelUI::SetAttribute(const char* name, const char* value)
{
    if (str::Eq(name, "type"))  {
        if (str::Eq(value, "error"))  SetWarningType(MB_ICONERROR);
        if (str::Eq(value, "warning"))  SetWarningType(MB_ICONWARNING);
    }
    else TextPanelUI::SetAttribute(name, value);
}