國立暨南國際大學 96 學年度第二學期小考試卷

 
科目名稱:資訊系統 與網路導論 開課系所:資訊工程 學系 任課教師
吳坤熹
系所別:
年級:
學號:
姓名:
考試日期
2008.5.22

(考試時間: 8:10-8:25)
Open book; turn off computer & mobile phone

  1. (10%) Consider the OnUpdateElementRectangle() function in P.699, if we modify its definition as follows, how will the program behave differently?.
    void
        CSketcherDoc::OnUpdateElementRectangle(CCmdUI *pCmdUI)
    {
    if (m_Element == RECTANGLE)
    {
    pCmdUI->SetCheck();
    pCmdUI->SetText(L"RECTANGLE");
    }
    else
    {
    pCmdUI->SetText(L"rectangle");
    }
    }










  2. (10%) Consider the OnUpdateColorBlue() function in P.699, if we modify its definition as follows, how will the program behave differently?

    void CSketcher1Doc::OnUpdateColorBlue(CCmdUI *pCmdUI)
    {
    if (m_Color==BLACK) pCmdUI->Enable(0);
    else pCmdUI->Enable();
    }