ReactOS  0.4.13-dev-464-g6b95727
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:62

◆ 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:5709
#define LoadIcon
Definition: winuser.h:5679
#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:62

◆ 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:292
LONG left
Definition: windef.h:291
BOOL WINAPI EndPaint(_In_ HWND, _In_ const PAINTSTRUCT *)
LONG right
Definition: windef.h:293
static VOID NTAPI BitBlt(IN ULONG Left, IN ULONG Top, IN ULONG Width, IN ULONG Height, IN PUCHAR Buffer, IN ULONG BitsPerPixel, IN ULONG Delta)
Definition: vga.c:416
int32_t INT
Definition: typedefs.h:56
HDC WINAPI BeginPaint(_In_ HWND, _Out_ LPPAINTSTRUCT)
HDC GetDC()
Definition: history.cpp:219
int GetWidth()
Definition: history.cpp:195
int GetHeight()
Definition: history.cpp:200
ImageModel imageModel
Definition: main.cpp:32
static HDC hDC
Definition: 3dtext.c:33
LONG bottom
Definition: windef.h:294
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
#define SRCCOPY
Definition: wingdi.h:332

◆ 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 }
smooth NULL
Definition: ftsmooth.c:416
#define LoadCursor
Definition: winuser.h:5678
HCURSOR WINAPI SetCursor(_In_opt_ HCURSOR)
#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: