---
title: "flagsChanged(with:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nsresponder/flagschanged(with:)"
---

# flagsChanged(with:)

Informs the receiver that the user has pressed or released a modifier key (Shift, Control, and so on).

## Declaration

```swift
func flagsChanged(with event: NSEvent)
```

## Parameters

- `event`: An object encapsulating information about the modifier-key event.

## Discussion

Discussion The default implementation simply passes this message to the next responder.

## See Also

### Responding to Other Kinds of Events

- [cursorUpdate(with:)](appkit/nsresponder/cursorupdate(with:).md)
- [tabletPoint(with:)](appkit/nsresponder/tabletpoint(with:).md)
- [tabletProximity(with:)](appkit/nsresponder/tabletproximity(with:).md)
- [helpRequested(_:)](appkit/nsresponder/helprequested(_:).md)
- [scrollWheel(with:)](appkit/nsresponder/scrollwheel(with:).md)
- [quickLook(with:)](appkit/nsresponder/quicklook(with:).md)
- [changeMode(with:)](appkit/nsresponder/changemode(with:).md)
