Merge remote-tracking branch 'origin/SP3-1-Rendering' into SP3-1-Rendering

This commit is contained in:
Brandon Mak 2022-10-02 00:00:07 +08:00
commit 32a3cc0674
2 changed files with 13 additions and 4 deletions

View File

@ -378,6 +378,12 @@ namespace SHADE
{
wndData.width = static_cast<unsigned>(size.cx);
wndData.height = static_cast<unsigned>(size.cy);
if (type == SIZE_MINIMIZED)
{
wndData.isMinimised = true;
}
for (auto const& entry : windowResizeCallbacks)
{
entry.second(static_cast<uint32_t>(wndData.width), static_cast<uint32_t>(wndData.height));

View File

@ -61,6 +61,8 @@ namespace SHADE
bool modal = false;
bool isMinimised = false;
std::wstring title = L"SHADE ENGINE";
std::wstring name = L"SHADEEngineApp";
@ -163,6 +165,7 @@ namespace SHADE
void OnSize(UINT msg, UINT type, SIZE size);
void OnPosChange(LPWINDOWPOS pos);
void OnPaint(HDC hdc, LPPAINTSTRUCT paint);
bool IsMinimized() const { return wndData.isMinimised; }
};
static SHWindowMap windowMap;
static SHWindow* windowBeingCreated = nullptr;