Graphics Reference
In-Depth Information
// Microsoft Visual C++ generated include file.
// Used by MFC
_
SimpleDialog.RC
//
.
Source file.
Resource.h
file
in the
Header
file folder of the
MFC
_
SimpleDialog
project.
#define
IDD
_
MFC
_
SIMPLEDIALOG
_
DIALOG
102
.
Listing 2.2.
Snippet from
Resource.h
file (Tutorial 2.1).
class
CTutorialApp :
public
CWinApp {
.
virtual BOOL
InitInstance();
};
.
theApp:
this is the abstraction of our application.
CTutorialApp theApp;
// The one and only CTutorialApp object
.
Source file.
TutorialApp.h/cpp
file in the
Source
and
Header
file folders of the
MFC
_
SimpleDialog
project.
BOOL
CTutorialApp::InitInstance() {
.
// Code for intialization
// Create and show our dialog
CTutorialDlg dlg;
// This is the our
main application window
m
_
pMainWnd = &dlg;
.
// display the main application window, when the application
// window quits, the application should terminate.
.
}
Listing 2.3.
The
CTutorialApp
class (Tutorial 2.1).
ing 2.1, the
MFC
_
SimpleDialog.rc
file includes the
Resource.h
file to
define the
IDD
_
MFC
_
SIMPLEDIALOG
_
DIALOG
symbol.
•
StdAfx.h/.cpp
. These two files contain precompile header information.
They help speed up the compilation process. These two files are important
Search WWH ::
Custom Search