<!--
{
  "availability" : [
    "macOS: 10.10.0 - 11.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "NotificationCenter",
  "identifier" : "/documentation/NotificationCenter/NCWidgetListViewDelegate/widgetListPerformAddAction(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Notification Center"
    ],
    "preciseIdentifier" : "c:objc(pl)NCWidgetListViewDelegate(im)widgetListPerformAddAction:"
  },
  "title" : "widgetListPerformAddAction(_:)"
}
-->

# widgetListPerformAddAction(_:)

Asks the delegate to perform an action when the Add (+) button is clicked.

```
optional func widgetListPerformAddAction(_ list: NCWidgetListViewController)
```

## Parameters

`list`

The widget’s list view controller.

## Discussion

When a widget’s list is in editing mode, the list view controller can display an Add (+) button. The button’s action calls `widgetListPerformAddAction:` in the delegate.

If you want to display the default search view in the add action, you can use the `presentViewControllerInWidget:` method of `NSViewController`  to present an [`NCWidgetSearchViewController`](/documentation/NotificationCenter/NCWidgetSearchViewController) instance in the widget’s principal view controller.

---

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)