102 references to Handle
System.Windows.Forms (27)
System\Windows\Forms\Controls\ImageList\ImageList.cs (1)
761internal HIMAGELIST HIMAGELIST => (HIMAGELIST)Handle;
System\Windows\Forms\Controls\ImageList\ImageListStreamer.cs (1)
116handle = new(_imageList, (HIMAGELIST)_imageList.Handle);
System\Windows\Forms\Controls\ListView\ListView.cs (14)
559PInvokeCore.SendMessage(this, PInvoke.LVM_SETIMAGELIST, (WPARAM)PInvoke.LVSIL_STATE, (LPARAM)_imageListState.Handle); 956(LPARAM)(value is null ? 0 : value.Handle)); 1220(LPARAM)(value?.Handle ?? 0)); 1455PInvokeCore.SendMessage(this, PInvoke.LVM_SETIMAGELIST, (WPARAM)PInvoke.LVSIL_SMALL, (LPARAM)(value?.Handle ?? 0)); 1563(LPARAM)(value?.Handle ?? 0)); 1600(_imageListState is null || _imageListState.Images.Count == 0) ? 0 : _imageListState.Handle); 3693nint handle = (GroupImageList is null) ? 0 : GroupImageList.Handle; 4293nint handle = (LargeImageList is null) ? 0 : LargeImageList.Handle; 4950PInvokeCore.SendMessage(this, PInvoke.LVM_SETIMAGELIST, (WPARAM)PInvoke.LVSIL_NORMAL, (LPARAM)_imageListLarge.Handle); 4955PInvokeCore.SendMessage(this, PInvoke.LVM_SETIMAGELIST, (WPARAM)PInvoke.LVSIL_SMALL, (LPARAM)_imageListSmall.Handle); 4960PInvokeCore.SendMessage(this, PInvoke.LVM_SETIMAGELIST, (WPARAM)PInvoke.LVSIL_STATE, (LPARAM)_imageListState.Handle); 4965PInvokeCore.SendMessage(this, PInvoke.LVM_SETIMAGELIST, (WPARAM)PInvoke.LVSIL_GROUPHEADER, (LPARAM)_imageListGroup.Handle); 5512nint handle = (SmallImageList is null) ? 0 : SmallImageList.Handle; 5545nint handle = (StateImageList is null) ? 0 : StateImageList.Handle;
System\Windows\Forms\Controls\TabControl\TabControl.cs (3)
472IntPtr handle = (value is not null) ? value.Handle : IntPtr.Zero; 1142PInvokeCore.SendMessage(this, PInvoke.TCM_SETIMAGELIST, 0, ImageList!.Handle); 1249PInvokeCore.SendMessage(this, PInvoke.TCM_SETIMAGELIST, 0, _imageList.Handle);
System\Windows\Forms\Controls\TreeView\TreeView.cs (8)
630PInvokeCore.SendMessage(this, PInvoke.TVM_SETIMAGELIST, 0, value is null ? 0 : value.Handle); 633SetStateImageList(_internalStateImageList.Handle); 1693IntPtr handle = (ImageList is null) ? IntPtr.Zero : ImageList.Handle; 1749handle = _internalStateImageList.Handle; 1797SetStateImageList(_internalStateImageList.Handle); 1906PInvokeCore.SendMessage(this, PInvoke.TVM_SETIMAGELIST, 0, _imageList.Handle); 1991PInvokeCore.SendMessage(this, PInvoke.TVM_SETIMAGELIST, (WPARAM)PInvoke.TVSIL_STATE, (LPARAM)newImageList.Handle); 2632SetStateImageList(_internalStateImageList.Handle);
System.Windows.Forms.Tests (75)
System\Windows\Forms\ButtonBaseTests.cs (2)
2588Assert.NotEqual(IntPtr.Zero, imageList1.Handle); 2618Assert.NotEqual(IntPtr.Zero, imageList1.Handle);
System\Windows\Forms\ImageList.ImageCollectionTests.cs (20)
18Assert.NotEqual(IntPtr.Zero, list.Handle); 28Assert.NotEqual(IntPtr.Zero, list.Handle); 110Assert.NotEqual(IntPtr.Zero, list.Handle); 286Assert.NotEqual(IntPtr.Zero, list.Handle); 488Assert.NotEqual(IntPtr.Zero, list.Handle); 557Assert.NotEqual(IntPtr.Zero, list.Handle); 626Assert.NotEqual(IntPtr.Zero, list.Handle); 703Assert.NotEqual(IntPtr.Zero, list.Handle); 772Assert.NotEqual(IntPtr.Zero, list.Handle); 845Assert.NotEqual(IntPtr.Zero, list.Handle); 927Assert.NotEqual(IntPtr.Zero, list.Handle); 1015Assert.NotEqual(IntPtr.Zero, list.Handle); 1038Assert.NotEqual(IntPtr.Zero, list.Handle); 1136Assert.NotEqual(IntPtr.Zero, list.Handle); 1199Assert.NotEqual(IntPtr.Zero, list.Handle); 1351Assert.NotEqual(IntPtr.Zero, list.Handle); 1455Assert.NotEqual(IntPtr.Zero, list.Handle); 1507Assert.NotEqual(IntPtr.Zero, list.Handle); 1569Assert.NotEqual(IntPtr.Zero, list.Handle); 1659Assert.NotEqual(IntPtr.Zero, list.Handle);
System\Windows\Forms\ImageListTests.cs (30)
109Assert.NotEqual(IntPtr.Zero, list.Handle); 125Assert.NotEqual(IntPtr.Zero, list.Handle); 140Assert.NotEqual(IntPtr.Zero, list.Handle); 147Assert.NotEqual(IntPtr.Zero, list.Handle); 154IntPtr handle3 = list.Handle; 155Assert.NotEqual(IntPtr.Zero, list.Handle); 163Assert.NotEqual(IntPtr.Zero, list.Handle); 212IntPtr handle = list.Handle; 215Assert.Equal(handle, list.Handle); 290Assert.NotEqual(IntPtr.Zero, list.Handle); 306Assert.NotEqual(IntPtr.Zero, list.Handle); 321Assert.NotEqual(IntPtr.Zero, list.Handle); 328Assert.NotEqual(IntPtr.Zero, list.Handle); 335Assert.NotEqual(IntPtr.Zero, list.Handle); 342Assert.NotEqual(IntPtr.Zero, list.Handle); 349Assert.NotEqual(IntPtr.Zero, list.Handle); 357Assert.NotEqual(IntPtr.Zero, list.Handle); 527Assert.NotEqual(IntPtr.Zero, sourceList.Handle); 552Assert.NotEqual(IntPtr.Zero, sourceList.Handle); 556Assert.NotEqual(IntPtr.Zero, list.Handle); 604Assert.NotEqual(IntPtr.Zero, list.Handle); 635Assert.NotEqual(IntPtr.Zero, list.Handle); 643Assert.NotEqual(IntPtr.Zero, list.Handle); 730Assert.NotEqual(IntPtr.Zero, list.Handle); 746Assert.NotEqual(IntPtr.Zero, list.Handle); 872Assert.NotEqual(IntPtr.Zero, list.Handle); 891Assert.NotEqual(IntPtr.Zero, list.Handle); 943Assert.NotEqual(IntPtr.Zero, list.Handle); 972Assert.NotEqual(IntPtr.Zero, list.Handle); 1010Assert.NotEqual(IntPtr.Zero, list.Handle);
System\Windows\Forms\ListViewGroupTests.cs (4)
219Assert.Equal(groupImageList.Handle, 220PInvokeCore.SendMessage(listView, PInvoke.LVM_SETIMAGELIST, (WPARAM)PInvoke.LVSIL_GROUPHEADER, groupImageList.Handle)); 359Assert.Equal(groupImageList.Handle, 360PInvokeCore.SendMessage(listView, PInvoke.LVM_SETIMAGELIST, (WPARAM)PInvoke.LVSIL_GROUPHEADER, groupImageList.Handle));
System\Windows\Forms\TabControlTests.cs (4)
1026Assert.Equal(imageList.Handle, (nint)PInvokeCore.SendMessage(control, PInvoke.TCM_GETIMAGELIST)); 1301Assert.Equal(imageList.Handle, (nint)PInvokeCore.SendMessage(control, PInvoke.TCM_GETIMAGELIST)); 1422Assert.Equal(imageList1.Handle, (nint)PInvokeCore.SendMessage(control, PInvoke.TCM_GETIMAGELIST)); 1433Assert.Equal(imageList2.Handle, (nint)PInvokeCore.SendMessage(control, PInvoke.TCM_GETIMAGELIST));
System\Windows\Forms\TreeViewTests.cs (15)
2200Assert.NotEqual(IntPtr.Zero, imageList.Handle); 2589Assert.NotEqual(IntPtr.Zero, imageList.Handle); 2602Assert.NotEqual(IntPtr.Zero, imageList.Handle); 2614Assert.NotEqual(IntPtr.Zero, imageList.Handle); 2617Assert.NotEqual(IntPtr.Zero, imageList.Handle); 2630Assert.NotEqual(IntPtr.Zero, imageList.Handle); 2633Assert.NotEqual(IntPtr.Zero, imageList.Handle); 3560Assert.NotEqual(IntPtr.Zero, imageList.Handle); 4566Assert.NotEqual(IntPtr.Zero, imageList.Handle); 4579Assert.NotEqual(IntPtr.Zero, imageList.Handle); 4591Assert.NotEqual(IntPtr.Zero, imageList.Handle); 4594Assert.NotEqual(IntPtr.Zero, imageList.Handle); 4607Assert.NotEqual(IntPtr.Zero, imageList.Handle); 4610Assert.NotEqual(IntPtr.Zero, imageList.Handle); 6258Assert.NotEqual(IntPtr.Zero, imageList.Handle);