2 * Copyright 2000, International Business Machines Corporation and others.
5 * This software has been released under the terms of the IBM Public
6 * License. For details, see the LICENSE file in the top-level source
7 * directory or online at http://www.openafs.org/dl/license10.html
15 #include <afs/param.h>
19 #include "afs_shl_ext.h"
20 #include "results_dlg.h"
25 static char THIS_FILE
[] = __FILE__
;
28 /////////////////////////////////////////////////////////////////////////////
32 CResultsDlg::CResultsDlg(DWORD nHelpID
, CWnd
* pParent
/*=NULL*/)
35 InitModalIndirect (TaLocale_GetDialogResource (CResultsDlg::IDD
), pParent
);
37 //{{AFX_DATA_INIT(CResultsDlg)
38 // NOTE: the ClassWizard will add member initialization here
45 void CResultsDlg::DoDataExchange(CDataExchange
* pDX
)
47 CDialog::DoDataExchange(pDX
);
48 //{{AFX_DATA_MAP(CResultsDlg)
49 DDX_Control(pDX
, IDC_RESULTS_LABEL
, m_ResultsLabel
);
50 DDX_Control(pDX
, IDC_LIST
, m_List
);
54 BEGIN_MESSAGE_MAP(CResultsDlg
, CDialog
)
55 //{{AFX_MSG_MAP(CResultsDlg)
56 ON_BN_CLICKED(IDHELP
, OnHelp
)
60 /////////////////////////////////////////////////////////////////////////////
61 // CResultsDlg message handlers
63 BOOL
CResultsDlg::OnInitDialog()
65 CDialog::OnInitDialog();
67 SetWindowText(m_strDlgTitle
);
68 m_ResultsLabel
.SetWindowText(m_strResultsTitle
);
70 ASSERT(m_Files
.GetSize() == m_Results
.GetSize());
72 m_List
.SetTabStops(118);
74 for (int i
= 0; i
< m_Files
.GetSize(); i
++) {
75 CString strItem
= m_Files
[i
] + "\t" + m_Results
[i
];
76 m_List
.AddString(strItem
);
79 return TRUE
; // return TRUE unless you set the focus to a control
80 // EXCEPTION: OCX Property Pages should return FALSE
83 void CResultsDlg::SetContents(const CString
& strDlgTitle
, const CString
& strResultsTitle
, const CStringArray
& files
, const CStringArray
& results
)
85 m_strDlgTitle
= strDlgTitle
;
86 m_strResultsTitle
= strResultsTitle
;
91 m_Results
.RemoveAll();
92 m_Results
.Copy(results
);
95 void CResultsDlg::OnHelp()
97 ShowHelp(m_hWnd
, m_nHelpID
);