Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
de2d1e0
commit c73b247
Showing
21 changed files
with
9,761 additions
and
142 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
#pragma once | ||
|
||
class CanvasGdi_Keyboard | ||
{ | ||
CanvasGdi_Keyboard() = delete; | ||
public: | ||
explicit CanvasGdi_Keyboard(HWND hWnd) | ||
: hWnd_(hWnd), | ||
hDC_(BeginPaint(hWnd_, &ps_)) | ||
{} | ||
~CanvasGdi_Keyboard() | ||
{ | ||
EndPaint(hWnd_, &ps_); | ||
} | ||
|
||
operator HDC () const | ||
{ | ||
return hDC_; | ||
} | ||
private: | ||
const HWND hWnd_; | ||
PAINTSTRUCT ps_; | ||
const HDC hDC_; | ||
|
||
CanvasGdi_Keyboard(const CanvasGdi_Keyboard&) = delete; | ||
const CanvasGdi_Keyboard& operator=(const CanvasGdi_Keyboard&) = delete; | ||
}; |
Oops, something went wrong.