Image copyright AFP

Donald Trump stood on the ninth tee at Turnberry, framed by the famous lighthouse in the background. The sea was flat calm, the sun was shining and he looked pleased with the world.

From tee to green, the ninth is 143 yards - on a still day like today, probably an easy nine iron or maybe a pitching wedge.

From tee to the United States, it is a slightly more challenging 3,000 miles (4,800km) - and with a very big lateral water hazard in the way called the Atlantic Ocean. No free drops or mulligans from there...

But never mind that, the distance in Trump's mind had never seemed closer, because the political upheaval that he is threatening in November in the US had arrived overnight in the UK.

As any golfer knows, it's never about muscle - the key is rhythm and timing. And what exquisite timing it was that Mr Trump had pitched up in the UK to cut the ribbon on his refurbished links course today.

There are some striking parallels. If you look at the forces driving Brexit, they were mass immigration (and a sense it was out of control), insecure borders, interfering bureaucracy, depressed wages, and sovereignty.

Exactly the same concerns that Mr Trump has so brilliantly harnessed in the US. He thought it was anything but a calamity that Britain had left, and told me in the news conference - with a good deal of sang-froid - that yes, Britain's departure could lead to the break-up the EU.

Image copyright Reuters Image caption The media descended on Turnberry for Trump's appearance

Beneath the white cap with Make America Great Again on it, there was very little scowling from Mr Trump, and a huge amount of beaming.

Was he having fun? He was having the time of his life. On about half a dozen occasions he said, "right, final question" only then to go on to answer a fresh volley of inquiries. Some reporters had so many bites of the cherry they must have been chewing on the stone. It was a news conference he hoped would never end.

The thing about golf is that it is a maddening and frustrating game, but hit one perfect seven iron that comes off the centre of the club, soars into the air and lands stone dead within three feet of the pin, and you forget about all the missed putts, the sliced drives, the heavy divots, and the ball that takes four to get out of the bunker. In Trump's head today, every shot was finding the sweet spot.

Not so Barack Obama. He had played a round of golf with David Cameron a couple of months back when the US president was in London.

Image copyright Reuters Image caption Happier times... but bunkers lay ahead

The president loves the game. But his efforts to influence the outcome of the Brexit debate have turned out to be as wayward as a badly hooked drive. He had certainly used muscle to try to influence the outcome of the referendum - and the British people didn't much care for his intervention.

And Hillary Clinton, Trump's likely rival in November's election, was of course firmly in the "remain" camp. She had been unequivocal about the importance of Britain staying in.

But once again the person who had read the mood of the people was Trump - a point of which, you won't be surprised to hear, the presumptive Republican nominee was happy to remind us - more than once...

Politics doesn't always need to be a zero-sum game, but invariably is. And today Trump was up and the political establishment was down.

And as he looked around him - at his gleaming hotel, at his beautiful golf course and his fabulously manicured children, he told the news conference: "If I can fix Turnberry, think what I can do for America."

A reporter had the temerity to ask weren't they slightly different things.

"You'd be amazed how similar it is. It's called a place that has to be fixed," was his response as we sat and listened, perched on the edge of a cliff.

More on the Trump story

Media playback is unsupported on your device Media caption Jon Sopel explains why Donald Trump wants the biker vote

Why we love Trump

Donald Trump's Hispanic voter 'doomsday'

28 things that Donald Trump believes

Donald Trump's foreign policy assessed