Odd gull behaviour

Hello everyone - New to this chat so not sure if my question has been answered in history.

Near to me is a large oak tree, about ten to fifteen minutes before sunset around half a dozen gulls arrive and start to circle the tree, they then fly over the tree and drop their legs hitting the topmost branches.

Through my binoculars I can see this disturbs and sets flying what appear to be a lot of moths (Oak Moths?) The gulls then set about snapping them up for five minutes until the sun sets.

I have witnessed this on a half dozen occasions in the last month. We have lived in this house with a good view of the tree for seven years and never seen it before.

What are they eating and how did they learn this behaviour - I imagine the roosting 'moths' would have been out of sight under the leaves.

Look forward to your enlightening answers.

Kevin