HardwareButtons Class

Definition

Provides access to the phone's hardware buttons.

public ref class HardwareButtons abstract sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Phone.PhoneContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Static(Windows.Phone.UI.Input.IHardwareButtonsStatics, 65536, "Windows.Phone.PhoneContract")]
/// [Windows.Foundation.Metadata.Static(Windows.Phone.UI.Input.IHardwareButtonsStatics2, 65536, "Windows.Phone.PhoneContract")]
class HardwareButtons abstract sealed
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Phone.PhoneContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Static(typeof(Windows.Phone.UI.Input.IHardwareButtonsStatics), 65536, "Windows.Phone.PhoneContract")]
[Windows.Foundation.Metadata.Static(typeof(Windows.Phone.UI.Input.IHardwareButtonsStatics2), 65536, "Windows.Phone.PhoneContract")]
public static class HardwareButtons
Public Class HardwareButtons
Inheritance
HardwareButtons
Attributes

Windows 10 requirements

Device family
Windows Mobile Extension SDK (introduced in 10.0.10240.0)
API contract
Windows.Phone.PhoneContract (introduced in v1.0)

Remarks

Windows Phone 8

This API is supported in native apps only.

Events

BackPressed

Occurs when the user presses the hardware Back button.

CameraHalfPressed

Occurs when the user presses the hardware camera button halfway.

CameraPressed

Occurs when the user presses the hardware camera button.

CameraReleased

Occurs when the user releases the hardware camera button.

Applies to

See also