Richmond, Virginia (CNN) Former President Barack Obama's nine-month break from politics is officially over. And he's not happy with what he sees.

The question is: Are Democrats listening?

In New Jersey and Virginia Thursday to campaign for Democrats ahead of November's state-level elections, Obama drew direct contrasts between his own vision of politics and President Donald Trump.

"We've got folks who are deliberately trying to make folks angry -- to demonize people who have different ideas; to get the base all riled up because it provides a short-term tactical advantage," Obama said, without using Trump's name.

"If you have to win a campaign by dividing people," he added, governing is impossible.

But beyond the raptured crowds in Newark and Richmond, Thursday's events were a reminder of a problem Democrats never overcame during Obama's eight years in office: His popularity didn't transfer down the ticket.

Democrats were clobbered in the 2010 and 2014 midterm elections, turning the full control of Congress that Obama enjoyed in his first two years in office into a Republican wall of opposition that snuffed out most of his priorities in his last six years.

"Off-year elections, midterm elections -- Democrats sometimes, y'all get a little sleepy. You get a little complacent," Obama said in Richmond.

"And so as a consequence, folks wake up and they're surprised -- 'How come we can't get things through Congress? How come we can't get things through the state house?'" Obama said. "Because you slept through the election."

Since leaving office, Obama has paid attention to the mechanics of the electoral process have bedeviled Democrats. His former attorney general, Eric Holder, launched a new organization focused on redistricting, and Obama held his first fundraiser after leaving office to help that group. He also complained about gerrymandering in Virginia on Thursday night.

He said politicians draw districts that reward them for "pandering to the extremes" rather than trying to win persuadable voters.

"We shouldn't have politicians choosing our voters; we should have voters choosing those who would serve them," Obama said. "All these things conspire so that our politics doesn't reflect our values."

'What he's really trying to deliver is fear'

Thursday's events also offered a preview of the post-presidential Obama who could emerge as Democrats' most sought-after surrogate in the 2018 midterms.

He was particularly harsh when it came to Ed Gillespie, the Republican candidate for Virginia governor who is opposing Lt. Gov. Ralph Northam, a pediatric neurologist.

Obama seemed personally annoyed by Gillespie's ads linking Northam's positions on immigration to MS-13 gangs, noting that he catches them on TV in the Washington area.

"I don't think anybody really thinks that somebody who spent his life performing surgeries on soldiers and children is really cozying up to street gangs," Obama said mockingly. "It strains credulity."

He added: "That is distraction. That is phony. That is divisive. It's not true."

"What he's really trying to deliver is fear," Obama said of Gillespie. "What he really believes is if you scare enough voters, you might score just enough votes to win an election. And that's what makes this kind of anything-goes politics just so damaging and corrosive to our democracy."

Obama also waded into Virginia's debate over Confederate monuments. He said Americans "claim all of our history, the good and the bad." Obama also noted that he is a distant relative of Confederate leader Jefferson Davis.

"Think about that," he said. "I'll bet he's spinning in his grave."

Obama was the first Democratic presidential candidate to win Virginia since 1964, and is still an extraordinarily popular figure with Democrats and especially black voters who national party leaders fear are not engaged in this year's local elections.

"Ed Gillespie is treating the president of his party like a communicable disease," said outgoing Virginia Gov. Terry McAuliffe. "We don't do that here. We love Barack Obama."

Pointing to Trump's health care efforts, Northam said, "All they're trying to do is take Barack Obama's name off of everything that he did. We can't let it happen."

In New Jersey, Democrat Phil Murphy, who appeared alongside Obama in Newark on Thursday afternoon, has long held a clear lead in the governor's race. But for Virginia Democrats, Obama's appearance could be a huge boost in a governor's race where polls have consistently shown Northam and Gillespie running close.