ReactOS 0.4.16-dev-338-g34e76ad
lanconnectui.cpp File Reference
#include "precomp.h"
Include dependency graph for lanconnectui.cpp:

Go to the source code of this file.

Functions

VOID AddItemToListView (HWND hDlgCtrl, PNET_ITEM pItem, LPWSTR szName, BOOL bChecked, UINT Image)
 

Function Documentation

◆ AddItemToListView()

VOID AddItemToListView ( HWND  hDlgCtrl,
PNET_ITEM  pItem,
LPWSTR  szName,
BOOL  bChecked,
UINT  Image 
)

Definition at line 29 of file lanconnectui.cpp.

30{
31 LVITEMW lvItem;
32
34 lvItem.pszText = szName;
35 lvItem.lParam = (LPARAM)pItem;
36 lvItem.iImage = Image;
37 lvItem.iItem = 0x7fffffff; // Append at the end of the list.
38 lvItem.iSubItem = 0;
39 lvItem.iItem = SendMessageW(hDlgCtrl, LVM_INSERTITEMW, 0, (LPARAM)&lvItem);
40 ListView_SetCheckState(hDlgCtrl, lvItem.iItem, bChecked);
41}
static const WCHAR szName[]
Definition: powrprof.c:45
#define ListView_SetCheckState(hwndLV, i, fCheck)
Definition: commctrl.h:2679
#define LVIF_PARAM
Definition: commctrl.h:2316
#define LVIF_TEXT
Definition: commctrl.h:2314
#define LVIF_IMAGE
Definition: commctrl.h:2315
#define LVM_INSERTITEMW
Definition: commctrl.h:2409
LPWSTR pszText
Definition: commctrl.h:2370
int iSubItem
Definition: commctrl.h:2367
UINT mask
Definition: commctrl.h:2365
LPARAM lParam
Definition: commctrl.h:2373
int iImage
Definition: commctrl.h:2372
LONG_PTR LPARAM
Definition: windef.h:208
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)

Referenced by CNetConnectionPropertyUi::EnumComponents().