<div class='type'>Compose Modifier</div>

<a id='references'></a>


<h2 id="onrotaryscrollevent-onrotaryscrollevent">onRotaryScrollEvent</h2>

<div class='sourceset sourceset-common'>Common</div>


```kotlin
fun Modifier.onRotaryScrollEvent(onRotaryScrollEvent: (RotaryScrollEvent) -> Boolean): Modifier
```


Adding this `modifier` to the `modifier` parameter of a component will allow
it to intercept `RotaryScrollEvent`s if it (or one of its children) is focused.


Here is an example of a scrollable container that scrolls in response to `RotaryScrollEvent`s.


This sample demonstrates how a parent can add an `onRotaryScrollEvent` modifier to gain access to
a `RotaryScrollEvent` when a child does not consume it:

#### Parameters

| | |
| --- | --- |
| onRotaryScrollEvent | This callback is invoked when the user interacts with the rotary side button or the bezel on a wear device. While implementing this callback, return true to stop propagation of this event. If you return false, the event will be sent to this `onRotaryScrollEvent`'s parent. |


#### Returns

| | |
| --- | --- |
|  | true if the event is consumed, false otherwise. |