<!--
{
  "availability" : [
    "macCatalyst: 13.1.0 -",
    "macOS: 10.4.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreGraphics",
  "identifier" : "/documentation/CoreGraphics/CGEventSource/getLocalEventsFilterDuringSuppressionState(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Core Graphics",
      "CoreGraphics"
    ],
    "preciseIdentifier" : "c:@F@CGEventSourceGetLocalEventsFilterDuringSuppressionState"
  },
  "title" : "getLocalEventsFilterDuringSuppressionState(_:)"
}
-->

# getLocalEventsFilterDuringSuppressionState(_:)

Returns the mask that indicates which classes of local hardware events are enabled during event suppression.

```
func getLocalEventsFilterDuringSuppressionState(_ state: CGEventSuppressionState) -> CGEventFilterMask
```

## Parameters

`state`

The type of event suppression interval during which the filter is applied. Pass one of the constants listed in [`CGEventSuppressionState`](/documentation/CoreGraphics/CGEventSuppressionState).

## Return Value

A mask that specifies the categories of local hardware events to enable during the event suppression interval. See [`CGEventFilterMask`](/documentation/CoreGraphics/CGEventFilterMask).

## Discussion

You can configure the system to suppress local hardware events from the keyboard or mouse during a short interval after a Quartz event is posted or during a synthetic mouse drag (mouse movement with the left or only mouse button down). For information about setting this local events filter, see [`setLocalEventsFilterDuringSuppressionState(_:state:)`](/documentation/CoreGraphics/CGEventSource/setLocalEventsFilterDuringSuppressionState(_:state:)).

This function lets you specify an event source and a suppression state (event suppression interval or mouse drag), and returns a filter mask of event categories to be passed through during suppression.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)