home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Media Share 13
/
mediashare_13.zip
/
mediashare_13
/
ZIPPED
/
PROGRAM
/
WTJ9403.ZIP
/
WILDASS
/
SOURCE
/
OPTSDLG.CPP
< prev
next >
Wrap
C/C++ Source or Header
|
1993-08-14
|
3KB
|
99 lines
// optsdlg.cpp : implementation file
//
#include <afxwin.h>
#include <afxext.h>
#include <ctl3d.h>
#include "resource.h"
#include "optsdlg.h"
#include "app.h"
#ifdef _DEBUG
#undef THIS_FILE
static char BASED_CODE THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// COptsDlg dialog
COptsDlg::COptsDlg(CWnd* pParent /*=NULL*/)
: CDialog(COptsDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(COptsDlg)
m_cPixelFrame = 0;
m_fComeUpAllways = FALSE;
m_fStayVisible = FALSE;
//}}AFX_DATA_INIT
}
void COptsDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(COptsDlg)
DDX_Text(pDX, IDC_NUMPIXELFRAME, m_cPixelFrame);
DDV_MinMaxUInt(pDX, m_cPixelFrame, 0, 128);
DDX_Check(pDX, IDC_CHECK1, m_fComeUpAllways);
DDX_Check(pDX, IDC_CHECK2, m_fStayVisible);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(COptsDlg, CDialog)
//{{AFX_MSG_MAP(COptsDlg)
ON_BN_CLICKED(IDC_DESKTOP_ONE, OnClickedDesktopOne)
ON_BN_CLICKED(IDC_DESKTOP_THREE, OnClickedDesktopThree)
ON_BN_CLICKED(IDC_DESKTOP_TWO, OnClickedDesktopTwo)
ON_BN_CLICKED(IDC_HELP, OnClickedHelp)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// COptsDlg message handlers
BOOL COptsDlg::OnInitDialog()
{
// TODO: Add extra initialization here
// Get options settings from the application
CMyApp * pApp = (CMyApp*)AfxGetApp();
m_cPixelFrame = pApp->Settings_PixelFrame();
m_fComeUpAllways = pApp->Settings_ComeUpAllways();
m_fStayVisible = pApp->Settings_StayVisible();
// update data
CDialog::OnInitDialog();
// CenterWindow();
return TRUE; // return TRUE unless you set the focus to a control
}
void COptsDlg::OnClickedDesktopOne()
{
// clean the profile
CString strFile = AfxGetAppName() + CString(".ini");
WritePrivateProfileString( "Desktop1", NULL, NULL, strFile );
}
void COptsDlg::OnClickedDesktopThree()
{
// clean the profile
CString strFile = AfxGetAppName() + CString(".ini");
WritePrivateProfileString( "Desktop2", NULL, NULL, strFile );
}
void COptsDlg::OnClickedDesktopTwo()
{
// clean the profile
CString strFile = AfxGetAppName() + CString(".ini");
WritePrivateProfileString( "Desktop3", NULL, NULL, strFile );
}
void COptsDlg::OnClickedHelp()
{
AfxGetApp()->WinHelp( 0L, HELP_CONTENTS );
}