Skip to content

Commit

Permalink
Progress on #17: we have listview with items, beginning context menu …
Browse files Browse the repository at this point in the history
…implementation, just need to be able to execute the items and then remove groups and items, as well as give icons to all of the items, we are so close!!!
  • Loading branch information
freedom7341 committed Oct 11, 2023
1 parent ea0c077 commit ab9e9d9
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions progmgr/group.c
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,10 @@ LRESULT CALLBACK GroupWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
{
switch (message)
{
HWND hWndListView = NULL;

// find the listview control
hWndListView = FindWindowEx(hWnd, NULL, WC_LISTVIEW, NULL);

case WM_CREATE:
{
Expand All @@ -393,6 +397,17 @@ LRESULT CALLBACK GroupWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
return TRUE;
}

case WM_CONTEXTMENU:
{
POINT pt = { NULL, NULL };
HMENU hMenu = NULL;
BOOL bPopup = NULL;

pt.x = GET_X_LPARAM(lParam);
pt.y = GET_Y_LPARAM(lParam);
break;
}

case WM_CLOSE:
return ShowWindow(hWnd, SW_MINIMIZE);

Expand All @@ -403,9 +418,6 @@ LRESULT CALLBACK GroupWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa

// get the group window rect
GetClientRect(hWnd, &rcGroupWindow);

// find the listview control
hWndListView = FindWindowEx(hWnd, NULL, WC_LISTVIEW, NULL);
if (hWndListView == NULL)
break;

Expand Down

0 comments on commit ab9e9d9

Please sign in to comment.