From c605ea0545ac22dc328c83d78011e3d18346eb63 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Ankarstr=C3=B6m?= Date: Tue, 15 Feb 2022 16:56:31 +0100 Subject: Show data list view. --- c/datalistview.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) (limited to 'c/datalistview.c') diff --git a/c/datalistview.c b/c/datalistview.c index 43cfeb6..873befc 100644 --- a/c/datalistview.c +++ b/c/datalistview.c @@ -6,10 +6,28 @@ HWND gDlv_hWnd; -void +HWND DlvCreate(HWND hWnd) { + HWND hListView; + LVCOLUMN lvc; + gDlv_hWnd = hWnd; + hListView = LvCreate(hWnd, (HMENU)IDC_DATALISTVIEW); + + lvc.mask = LVCF_WIDTH|LVCF_TEXT|LVCF_SUBITEM; + + lvc.iSubItem = 0; + lvc.pszText = TEXT("Key"); + lvc.cx = 42; + ListView_InsertColumn(hListView, 0, &lvc); + + lvc.iSubItem = 1; + lvc.pszText = TEXT("Value"); + lvc.cx = 500; + ListView_InsertColumn(hListView, 1, &lvc); + + return hListView; } /* Show episode data. */ -- cgit v1.2.3