Class SafeIconHandle
A SafeHandle class implementation for the hIcon
Inheritance
System.Object
SafeIconHandle
Namespace: Dapplo.Windows.User32.SafeHandles
Assembly: Dapplo.Windows.User32.dll
Syntax
public class SafeIconHandle : SafeHandleZeroOrMinusOneIsInvalid
Constructors
| Improve this Doc View SourceSafeIconHandle()
Default constructor is needed to support marshalling!!
Declaration
public SafeIconHandle()
SafeIconHandle(Bitmap)
Create a SafeIconHandle from a bitmap by calling GetHicon
Declaration
public SafeIconHandle(Bitmap bitmap)
Parameters
Type | Name | Description |
---|---|---|
Bitmap | bitmap | Bitmap |
SafeIconHandle(IntPtr)
Create a SafeIconHandle from a hIcon
Declaration
public SafeIconHandle(IntPtr hIcon)
Parameters
Type | Name | Description |
---|---|---|
IntPtr | hIcon | IntPtr to an icon |
Methods
| Improve this Doc View SourceReleaseHandle()
Call destroy icon
Declaration
protected override bool ReleaseHandle()
Returns
Type | Description |
---|---|
System.Boolean | true if this worked |