Files
Program-Manager-II/progmgr/group.c
2023-08-02 00:59:58 -06:00

66 lines
1.3 KiB
C

/* * * * * * * *\
GROUP.C -
Copyright (c) 2023 freedom7341, Vortesys
DESCRIPTION -
Group window and program item functions.
LICENSE INFORMATION -
MIT License, see LICENSE.txt in the root folder
\* * * * * * * */
/* Headers */
#include "progmgr.h"
#include "group.h"
#include "resource.h"
#include "registry.h"
// #define WIN32_LEAN_AND_MEAN
#include <Windows.h>
/* Functions */
/* * * *\
GroupWndProc -
Group window procedure.
RETURNS -
Zero if nothing, otherwise returns the good stuff.
\* * * */
LRESULT CALLBACK GroupWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
switch (message)
{
case WM_CREATE:
{
break;
}
default:
GrpProcDefault:
return DefMDIChildProc(hWnd, message, wParam, lParam);
}
return 0;
}
/* * * *\
TempCreateGroup -
th
RETURNS -
handle to window
\* * * */
HWND TempCreateGroup(HWND hMDIClient)
{
MDICREATESTRUCT mcs;
HWND hChild;
mcs.szTitle = L"[Untitled]";
mcs.szClass = szGrpClass;
mcs.hOwner = GetModuleHandle(NULL);
mcs.x = mcs.cx = CW_USEDEFAULT;
mcs.y = mcs.cy = CW_USEDEFAULT;
mcs.style = MDIS_ALLCHILDSTYLES;
hChild = (HWND)SendMessage(hMDIClient, WM_MDICREATE, 0, (LONG)&mcs);
if (!hChild)
{
MessageBox(hMDIClient, L"MDI Child creation failed.", L"Oh Oh...",
MB_ICONEXCLAMATION | MB_OK);
}
return hChild;
}