HwndWrapper HwndWrapper HwndWrapper HwndWrapper HwndWrapper HwndWrapper Class

Definition

Represents a disposable wrapper around an HWND that can construct the WNDCLASS and HWND, run the WndProc and dispose of the WNDCLASS and HWND.

public ref class HwndWrapper abstract : Microsoft::VisualStudio::PlatformUI::DisposableObject
[Windows::Foundation::Metadata::WebHostHidden]
public ref class HwndWrapper abstract : Microsoft::VisualStudio::PlatformUI::DisposableObject
[Windows::Foundation::Metadata::WebHostHidden]
class HwndWrapper abstract : Microsoft::VisualStudio::PlatformUI::DisposableObject
public abstract class HwndWrapper : Microsoft.VisualStudio.PlatformUI.DisposableObject
type HwndWrapper = class
    inherit DisposableObject
Public MustInherit Class HwndWrapper
Inherits DisposableObject
Inheritance

Constructors

HwndWrapper() HwndWrapper() HwndWrapper() HwndWrapper() HwndWrapper() HwndWrapper()

Creates a new instance of the class.

Properties

Handle Handle Handle Handle Handle Handle
IsDisposed IsDisposed IsDisposed IsDisposed IsDisposed IsDisposed

Returns whether the object has been disposed once, which protects against double disposal.

(Inherited from DisposableObject)
IsWindowSubclassed IsWindowSubclassed IsWindowSubclassed IsWindowSubclassed IsWindowSubclassed IsWindowSubclassed
WindowClassAtom WindowClassAtom WindowClassAtom WindowClassAtom WindowClassAtom WindowClassAtom

Gets or creates the class atom returned from CreateWindowClassCore().

Methods

CreateWindowClassCore() CreateWindowClassCore() CreateWindowClassCore() CreateWindowClassCore() CreateWindowClassCore() CreateWindowClassCore()

Creates the WNDCLASS atom to use for constructing this window’s handle.

CreateWindowCore() CreateWindowCore() CreateWindowCore() CreateWindowCore() CreateWindowCore() CreateWindowCore()

Creates the handle for the window.

DestroyWindowClassCore() DestroyWindowClassCore() DestroyWindowClassCore() DestroyWindowClassCore() DestroyWindowClassCore() DestroyWindowClassCore()

Destroys the WNDCLASS atom created with CreateWindowClassCore().

DestroyWindowCore() DestroyWindowCore() DestroyWindowCore() DestroyWindowCore() DestroyWindowCore() DestroyWindowCore()

Destroys the window handle created by CreateWindowCore().

Dispose() Dispose() Dispose() Dispose() Dispose() Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

(Inherited from DisposableObject)
Dispose(Boolean) Dispose(Boolean) Dispose(Boolean) Dispose(Boolean) Dispose(Boolean) Dispose(Boolean)

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. Standard virtual overload for IDisposable pattern.

(Inherited from DisposableObject)
DisposeManagedResources() DisposeManagedResources() DisposeManagedResources() DisposeManagedResources() DisposeManagedResources() DisposeManagedResources()

Allows derived classes to provide custom dispose handling for managed resources.

(Inherited from DisposableObject)
DisposeNativeResources() DisposeNativeResources() DisposeNativeResources() DisposeNativeResources() DisposeNativeResources() DisposeNativeResources()

Calls DestroyWindowCore() and DestroyWindowClassCore().

EnsureHandle() EnsureHandle() EnsureHandle() EnsureHandle() EnsureHandle() EnsureHandle()

Ensures that the handle for this window is created (creating the handle if it doesn't already exist). Note that EnsureHandle faisl to create the window's handle if it's called while in the process of creating the handle. In this case, the Handle is left uncreated for the current call.

RegisterClass(String) RegisterClass(String) RegisterClass(String) RegisterClass(String) RegisterClass(String) RegisterClass(String)

Registers a window class with the given name, and with other options set to default values.

ThrowIfDisposed() ThrowIfDisposed() ThrowIfDisposed() ThrowIfDisposed() ThrowIfDisposed() ThrowIfDisposed()

Throws an ObjectDisposedException if this object has been disposed.

(Inherited from DisposableObject)
WndProc(IntPtr, Int32, IntPtr, IntPtr) WndProc(IntPtr, Int32, IntPtr, IntPtr) WndProc(IntPtr, Int32, IntPtr, IntPtr) WndProc(IntPtr, Int32, IntPtr, IntPtr) WndProc(IntPtr, Int32, IntPtr, IntPtr) WndProc(IntPtr, Int32, IntPtr, IntPtr)

Runs the WndProc for this window.

Events

Disposing Disposing Disposing Disposing Disposing Disposing

Raised when the event is being disposed, that is, while it is still accessible.

(Inherited from DisposableObject)

Applies to