SendDlgItemMessage (hWndDlg, IDC_STATIC1, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDC_STATIC2, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDC_STATIC3, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDCANCEL, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDPAUSE, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDRESUME, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDC_MESSAGE0, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDC_STATUS_STATUS, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDC_STATUS_FILE, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDC_STATUS_URL, WM_SETFONT, (WPARAM)myGetSysFont(), 0L); SendDlgItemMessage (hWndDlg, IDC_STATUS_TO, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);
SendDlgItemMessage (hWndDlg, IDC_STATIC1, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDC_STATIC2, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDC_STATIC3, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDCANCEL, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDPAUSE, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDRESUME, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDC_MESSAGE0, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDC_STATUS_STATUS, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDC_STATUS_FILE, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDC_STATUS_URL, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L); SendDlgItemMessage (hWndDlg, IDC_STATUS_TO, WM_SETFONT, (WPARAM)sgInstallGui.definedFont, 0L);
DownloadDlgProc(HWND hWndDlg, UINT msg, WPARAM wParam, LPARAM lParam){  switch (msg)  {    case WM_INITDIALOG:      GetPrivateProfileString("Strings",                              "Status File Info",                              "",                              gszFileInfo,                              sizeof(gszFileInfo),                              szFileIniConfig);      DisableSystemMenuItems(hWndDlg, FALSE);      CenterWindow(hWndDlg);      if(gbShowDownloadRetryMsg)        SetDlgItemText(hWndDlg, IDC_MESSAGE0, diDownload.szMessageRetry0);      else        SetDlgItemText(hWndDlg, IDC_MESSAGE0, diDownload.szMessageDownload0);      EnableWindow(GetDlgItem(hWndDlg, IDRESUME), FALSE);      SetDlgItemText(hWndDlg, IDC_STATIC1, sgInstallGui.szStatus);      SetDlgItemText(hWndDlg, IDC_STATIC2, sgInstallGui.szFile);      SetDlgItemText(hWndDlg, IDC_STATIC4, sgInstallGui.szTo);      SetDlgItemText(hWndDlg, IDC_STATIC3, sgInstallGui.szUrl);      SetDlgItemText(hWndDlg, IDCANCEL, sgInstallGui.szCancel_);      SetDlgItemText(hWndDlg, IDPAUSE, sgInstallGui.szPause_);      SetDlgItemText(hWndDlg, IDRESUME, sgInstallGui.szResume_);      SendDlgItemMessage (hWndDlg, IDC_STATIC1, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDC_STATIC2, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDC_STATIC3, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDCANCEL, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDPAUSE, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDRESUME, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDC_MESSAGE0, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDC_STATUS_STATUS, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDC_STATUS_FILE, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDC_STATUS_URL, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      SendDlgItemMessage (hWndDlg, IDC_STATUS_TO, WM_SETFONT, (WPARAM)myGetSysFont(), 0L);      return FALSE;    case WM_SIZE:      switch(wParam)      {        case SIZE_MINIMIZED:          SetMinimizedDownloadTitle((int)GetPercentSoFar());          gbDlgDownloadMinimized = TRUE;          gbDlgDownloadJustMinimized = TRUE;          break;        case SIZE_RESTORED:          SetStatusUrl();          SetRestoredDownloadTitle();          gbDlgDownloadMinimized = FALSE;          break;      }      return(FALSE);    case WM_COMMAND:      switch(LOWORD(wParam))      {        case IDCANCEL:          if(AskCancelDlg(hWndDlg))            gdwDownloadDialogStatus = CS_CANCEL;          break;        case IDPAUSE:          if(!gtiPaused.bTickStarted)          {            gtiPaused.dwTickBegin          = GetTickCount();            gtiPaused.bTickStarted         = TRUE;            gtiPaused.bTickDownloadResumed = FALSE;          }          EnableWindow(GetDlgItem(hWndDlg, IDPAUSE),  FALSE);          EnableWindow(GetDlgItem(hWndDlg, IDRESUME), TRUE);          gdwDownloadDialogStatus = CS_PAUSE;          break;        case IDRESUME:          gtiPaused.dwTickEnd = GetTickCount();          gtiPaused.dwTickDif = GetTickDif(gtiPaused.dwTickEnd,                                           gtiPaused.dwTickBegin);          gtiPaused.bTickDownloadResumed = TRUE;          EnableWindow(GetDlgItem(hWndDlg, IDRESUME), FALSE);          EnableWindow(GetDlgItem(hWndDlg, IDPAUSE),  TRUE);          gdwDownloadDialogStatus = CS_NONE;          break;        default:          break;      }      return(TRUE);  }  return(FALSE);  // didn't handle the message}