President Obama, with his snubbing of Russian President Vladimir Putin, showcased one of the more glaring shifts between candidate and commander in chief: Talks with foreign leaders come with preconditions.

Ahead of 2008's presidential election, Obama, the junior senator from Illinois, praised Presidents Kennedy and Reagan for speaking with the Soviet Union at the height of tensions between the two countries. He vowed to meet with leaders from Iran, Syria, Venezuela and North Korea in Washington without any kind of terms.

That never happened.

And after Putin decided to grant National Security Agency leaker Edward Snowden temporary asylum, Obama pulled the plug on direct talks in Moscow, hoping to send a clear message to Russian officials who have consistently ignored U.S. demands.

Sen. Obama would have doubted the effectiveness of such a move.

"The notion that somehow not talking to countries is punishment to them — which has been the guiding diplomatic principle of [the George W. Bush] administration — is ridiculous," Obama declared in a July 2007 Democratic presidential debate.

Then-campaign rival Hillary Clinton accused Obama of inflating his own abilities to talk adversarial nations down from rigid positions. Republicans echoed her complaints, saying such a policy was naive.

In the years since, as evidenced by the clash with Putin, the president has backed away from that approach to diplomacy.

"That's the White House versus the campaign trail in a nutshell," said a foreign policy adviser to a Democratic senator closely aligned with Obama. "I think what you saw then was a bit of naivety. He's obviously jettisoned that view."

It's not just Russia on which the White House has placed clear terms on talks. For example, when Iranian President Hassan Rouhani was inaugurated this week, the Obama administration said it would pursue discussions with Rouhani, who has more moderate views than former president Mahmoud Ahmadinejad, only if the Iranian regime committed to a "peaceful solution" for their nuclear ambitions.

The White House isn't abandoning all communication with Russia, however. Administration officials point out that Secretary of State John Kerry and Defense Secretary Chuck Hagel will meet with their Russian counterparts Friday and that Obama will still attend the G-20 summit in St. Petersburg next month. But those meetings have been almost entirely overshadowed by the standoff between Obama and Putin.

Some who advised Obama on foreign affairs during the 2008 campaign don't see a contradiction between his latest approach to Putin and his previous call for talks without preconditions.

"I don't think he was ever naive," said Jordan Tama, a professor at American University and intelligence and counterterrorism policy adviser to Obama's 2008 presidential campaign. "He thought it was worth making the effort, reaching out to countries we've had strained relations with — it's just there hasn't been a reciprocal response in some cases."

Tama added that he didn't think canceling the meeting with Putin would have long-term repercussions for either side, considering the array of issues they face.

Some Republicans say Obama is attempting to have it both ways. He is trying to simultaneously look tough with Russia, while framing himself as a champion of unrestrained dialogue between governments sharing a mutual disdain.

"On the one hand the administration has an idealistic vision that they're going to get these [Russian] negotiations done, but they keep stubbing their toe on reality," said one Republican Senate foreign policy staffer. "They end up sending a really mixed message."