Win32 Custom Draw Treeview Control
问题 I'm trying to customize a treeview control using NM_CUSTOMDRAW messages. I simply want to draw every other visible item with a grey color. Here is code to draw: INT CResourceOutliner::On_WM_NOTIFY( HWND hDlg, WPARAM wParam, LPARAM lParam ) { HWND hTree = GetDlgItem( hDlg, IDC_TREE1 ); switch( ( ( LPNMHDR )lParam )->code ) { ... case NM_CUSTOMDRAW: { LPNMTVCUSTOMDRAW pCustomDraw = ( LPNMTVCUSTOMDRAW )lParam; switch( pCustomDraw->nmcd.dwDrawStage ) { case CDDS_PREPAINT: return CDRF