ReactOS  0.4.15-dev-1384-g878186b
CFullscreenWindow Class Reference

#include <fullscreen.h>

Inheritance diagram for CFullscreenWindow:
Collaboration diagram for CFullscreenWindow:

Public Member Functions

LRESULT OnCreate (UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
 
LRESULT OnCloseOrKeyDownOrLButtonDown (UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
 
LRESULT OnPaint (UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
 
LRESULT OnSize (UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
 
LRESULT OnSetCursor (UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
 
LRESULT OnGetText (UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
 

Detailed Description

Definition at line 11 of file fullscreen.h.

Member Function Documentation

◆ OnCloseOrKeyDownOrLButtonDown()

LRESULT CFullscreenWindow::OnCloseOrKeyDownOrLButtonDown ( UINT  nMsg,
WPARAM  wParam,
LPARAM  lParam,
BOOL bHandled 
)

Definition at line 22 of file fullscreen.cpp.

23 {
26  return 0;
27 }
#define SW_HIDE
Definition: winuser.h:762
BOOL WINAPI ShowWindow(_In_ HWND, _In_ int)
#define SW_SHOW
Definition: winuser.h:769
BOOL ShowWindow(int nCmdShow)
Definition: atlwin.h:1265
CMainWindow mainWindow
Definition: main.cpp:63

◆ OnCreate()

LRESULT CFullscreenWindow::OnCreate ( UINT  nMsg,
WPARAM  wParam,
LPARAM  lParam,
BOOL bHandled 
)

Definition at line 15 of file fullscreen.cpp.

16 {
19  return 0;
20 }
#define MAKEINTRESOURCE
Definition: winuser.h:591
#define ICON_SMALL
Definition: tnclass.cpp:48
LONG_PTR LPARAM
Definition: windef.h:208
HINSTANCE hProgInstance
Definition: main.cpp:50
#define IDI_APPICON
Definition: resource.h:166
#define SendMessage
Definition: winuser.h:5818
#define LoadIcon
Definition: winuser.h:5788
#define ICON_BIG
Definition: tnclass.cpp:51

◆ OnGetText()

LRESULT CFullscreenWindow::OnGetText ( UINT  nMsg,
WPARAM  wParam,
LPARAM  lParam,
BOOL bHandled 
)

Definition at line 57 of file fullscreen.cpp.

58 {
59  // return caption of the main window, instead
60  return mainWindow.SendMessage(nMsg, wParam, lParam);
61 }
WPARAM wParam
Definition: combotst.c:138
LRESULT SendMessage(UINT message, WPARAM wParam=0, LPARAM lParam=0)
Definition: atlwin.h:1048
LPARAM lParam
Definition: combotst.c:139
CMainWindow mainWindow
Definition: main.cpp:63

◆ OnPaint()

LRESULT CFullscreenWindow::OnPaint ( UINT  nMsg,
WPARAM  wParam,
LPARAM  lParam,
BOOL bHandled 
)

Definition at line 29 of file fullscreen.cpp.

30 {
31  PAINTSTRUCT ps;
32  HDC hDC = BeginPaint(&ps);
33  RECT rcWnd;
34  GetWindowRect(&rcWnd);
35  INT cxDest = imageModel.GetWidth();
36  INT cyDest = imageModel.GetHeight();
37  INT xDest = (rcWnd.right - rcWnd.left - cxDest) / 2;
38  INT yDest = (rcWnd.bottom - rcWnd.top - cyDest) / 2;
39  BitBlt(hDC, xDest, yDest, cxDest, cyDest, imageModel.GetDC(), 0, 0, SRCCOPY);
40  EndPaint(&ps);
41  return 0;
42 }
static HDC
Definition: imagelist.c:92
LONG top
Definition: windef.h:307
LONG left
Definition: windef.h:306
BOOL WINAPI EndPaint(_In_ HWND, _In_ const PAINTSTRUCT *)
LONG right
Definition: windef.h:308
int32_t INT
Definition: typedefs.h:58
HDC WINAPI BeginPaint(_In_ HWND, _Out_ LPPAINTSTRUCT)
HDC GetDC()
Definition: history.cpp:218
int GetWidth()
Definition: history.cpp:194
int GetHeight()
Definition: history.cpp:199
ImageModel imageModel
Definition: main.cpp:32
static HDC hDC
Definition: 3dtext.c:33
LONG bottom
Definition: windef.h:309
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
#define SRCCOPY
Definition: wingdi.h:332
static VOID NTAPI BitBlt(_In_ ULONG Left, _In_ ULONG Top, _In_ ULONG Width, _In_ ULONG Height, _In_reads_bytes_(Delta *Height) PUCHAR Buffer, _In_ ULONG BitsPerPixel, _In_ ULONG Delta)
Definition: common.c:49

◆ OnSetCursor()

LRESULT CFullscreenWindow::OnSetCursor ( UINT  nMsg,
WPARAM  wParam,
LPARAM  lParam,
BOOL bHandled 
)

Definition at line 50 of file fullscreen.cpp.

51 {
53  bHandled = FALSE;
54  return 0;
55 }
#define FALSE
Definition: types.h:117
#define LoadCursor
Definition: winuser.h:5787
HCURSOR WINAPI SetCursor(_In_opt_ HCURSOR)
#define NULL
Definition: types.h:112
#define IDC_ARROW
Definition: winuser.h:682

◆ OnSize()

LRESULT CFullscreenWindow::OnSize ( UINT  nMsg,
WPARAM  wParam,
LPARAM  lParam,
BOOL bHandled 
)

Definition at line 44 of file fullscreen.cpp.

45 {
46  Invalidate(TRUE);
47  return 0;
48 }
#define TRUE
Definition: types.h:120

The documentation for this class was generated from the following files: