view src/win32/MaxScale.cpp @ 4:5f6f2134e8ce

apu appears to not be used
author Robert McIntyre <rlm@mit.edu>
date Sat, 03 Mar 2012 10:35:58 -0600
parents f9f4f1b99eed
children
line wrap: on
line source
1 // MaxScale.cpp : implementation file
2 //
4 #include "stdafx.h"
5 #include "resource.h"
6 #include "MaxScale.h"
7 #include "VBA.h"
9 /////////////////////////////////////////////////////////////////////////////
10 // MaxScale dialog
12 MaxScale::MaxScale(CWnd*pParent /*=NULL*/)
13 : CDialog(MaxScale::IDD, pParent)
14 {
15 //{{AFX_DATA_INIT(MaxScale)
16 // NOTE: the ClassWizard will add member initialization here
17 //}}AFX_DATA_INIT
18 }
20 void MaxScale::DoDataExchange(CDataExchange*pDX)
21 {
22 CDialog::DoDataExchange(pDX);
23 //{{AFX_DATA_MAP(MaxScale)
24 DDX_Control(pDX, IDC_VALUE, m_value);
25 //}}AFX_DATA_MAP
26 }
28 BEGIN_MESSAGE_MAP(MaxScale, CDialog)
29 //{{AFX_MSG_MAP(MaxScale)
30 ON_BN_CLICKED(ID_OK, OnOk)
31 ON_BN_CLICKED(ID_CANCEL, OnCancel)
32 //}}AFX_MSG_MAP
33 END_MESSAGE_MAP()
35 /////////////////////////////////////////////////////////////////////////////
36 // MaxScale message handlers
38 void MaxScale::OnCancel()
39 {
40 EndDialog(FALSE);
41 }
43 void MaxScale::OnOk()
44 {
45 CString tmp;
46 m_value.GetWindowText(tmp);
47 theApp.fsMaxScale = atoi(tmp);
48 EndDialog(TRUE);
49 }
51 BOOL MaxScale::OnInitDialog()
52 {
53 CDialog::OnInitDialog();
55 CString temp;
57 temp.Format("%d", theApp.fsMaxScale);
59 m_value.SetWindowText(temp);
61 return TRUE; // return TRUE unless you set the focus to a control
62 // EXCEPTION: OCX Property Pages should return FALSE
63 }