-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathSplashDlg.cpp
86 lines (66 loc) · 2.22 KB
/
SplashDlg.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
// *****************************************************************************
//
// Copyright (c) 2010, Pleora Technologies Inc., All rights reserved.
//
// *****************************************************************************
#include "stdafx.h"
#include "SplashDlg.h"
#include <PvVersion.h>
#ifdef _PT_DEBUG_
#pragma warning ( push )
#pragma warning ( disable : 4100 )
#endif // _PT_DEBUG_
BEGIN_MESSAGE_MAP( SplashDlg, CDialog )
ON_WM_TIMER()
END_MESSAGE_MAP()
// ==========================================================================
void SplashDlg::Show()
{
SplashDlg lDlg;
lDlg.DoModal();
}
#ifdef _PT_DEBUG_
#pragma warning( pop )
#endif // _PT_DEBUG_
// ==========================================================================
SplashDlg::SplashDlg( CWnd* pParent /*=NULL*/ )
: CDialog( SplashDlg::IDD, pParent )
{
}
// ==========================================================================
SplashDlg::~SplashDlg()
{
}
// =============================================================================
void SplashDlg::DoDataExchange( CDataExchange* pDX )
{
CDialog::DoDataExchange( pDX );
DDX_Control(pDX, IDC_APPNAME, mAppNameLabel);
DDX_Control(pDX, IDC_PRODUCTNAME, mProductNameLabel);
DDX_Control(pDX, IDC_COPYRIGHT, mCopyrightLabel);
DDX_Control(pDX, IDC_COMPANY, mCompanyLabel);
}
// ==========================================================================
void SplashDlg::OnTimer( UINT_PTR aEvent )
{
KillTimer( aEvent );
ShowWindow( SW_HIDE );
EndDialog( IDOK );
}
// ==========================================================================
BOOL SplashDlg::OnInitDialog()
{
CDialog::OnInitDialog();
SetTimer( 0, 2500, NULL );
// Create bold font
LOGFONT lLogFont;
mAppNameLabel.GetFont()->GetLogFont( &lLogFont );
lLogFont.lfWeight = FW_BOLD;
mBoldFont.CreateFontIndirect( &lLogFont );
mAppNameLabel.SetFont( &mBoldFont );
mAppNameLabel.SetWindowText( _T( "eBUS Player" ) );
mProductNameLabel.SetWindowText( CString( _T( "eBUS SDK Version " ) ) + CString( NVERSION_STRING ) );
mCopyrightLabel.SetWindowText( _T( VERSION_COPYRIGHT ) );
mCompanyLabel.SetWindowText( _T( VERSION_COMPANY_NAME ) );
return TRUE;
}