source: win32/MainDlg.cpp @ d1d6776

Last change on this file since d1d6776 was d1d6776, checked in by Jelmer Vernooij <jelmer@…>, at 2005-11-07T16:20:37Z

Import win32 branch

  • Property mode set to 100644
File size: 1.5 KB
Line 
1// MainDlg.cpp : implementation file
2//
3
4#define BITLBEE_CORE
5#include "bitlbeewin.h"
6#include "PropUsers.h"
7#include "PropPaths.h"
8#include "PropAccess.h"
9#include "PropLog.h"
10#include "PropConn.h"
11#include "MainDlg.h"
12
13#ifdef _DEBUG
14#define new DEBUG_NEW
15#undef THIS_FILE
16static char THIS_FILE[] = __FILE__;
17#endif
18
19/////////////////////////////////////////////////////////////////////////////
20// CMainDlg
21
22IMPLEMENT_DYNAMIC(CMainDlg, CPropertySheet)
23
24CMainDlg::CMainDlg() : CPropertySheet("Bitlbee for Windows") 
25{
26        AddPage(new CPropPaths());
27        AddPage(new CPropAccess());
28        AddPage(new CPropUsers());
29        AddPage(new CPropLog());
30        AddPage(new CPropertyPage(IDD_PROPPAGE_ABOUT));
31        AddPage(new CPropConn());
32        Create();
33        ShowWindow(SW_HIDE);
34}
35
36CMainDlg::~CMainDlg()
37{
38}
39
40
41BEGIN_MESSAGE_MAP(CMainDlg, CPropertySheet)
42        //{{AFX_MSG_MAP(CMainDlg)
43        ON_WM_CLOSE()
44        //}}AFX_MSG_MAP
45        ON_BN_CLICKED(IDOK, OnOK)
46END_MESSAGE_MAP()
47
48/////////////////////////////////////////////////////////////////////////////
49// CMainDlg message handlers
50
51BOOL CMainDlg::OnInitDialog() 
52{
53        m_bModeless = FALSE;
54        m_nFlags |= WF_CONTINUEMODAL;
55       
56        CPropertySheet::OnInitDialog();
57        GetDlgItem(IDHELP)->ShowWindow(SW_HIDE);
58        GetDlgItem(IDCANCEL)->ShowWindow(SW_HIDE);
59
60        m_bModeless = TRUE;
61        m_nFlags &= WF_CONTINUEMODAL;
62       
63        return TRUE;  // return TRUE unless you set the focus to a control
64                      // EXCEPTION: OCX Property Pages should return FALSE
65}
66
67void CMainDlg::OnOK()
68{
69        PressButton(PSBTN_APPLYNOW);
70        ShowWindow(SW_HIDE);
71}
72
73
74void CMainDlg::OnClose() 
75{
76        ShowWindow(SW_HIDE);
77}
78
Note: See TracBrowser for help on using the repository browser.