Richard S. Madaleno Jr. has been in the Maryland Senate since 2007; before that, he served two terms in the House. (Evelyn Hockstein/For The Washington Post)

Maryland state Sen. Richard S. Madaleno Jr. (D-Montgomery) told a crowd of activists rallying around dedicated Metro funding Sunday that he will seek the Democratic nomination to challenge Gov. Larry Hogan (R) in 2018.

In a soaring speech appealing to the pro-worker crowd, Madaleno said that he supported prioritizing public transit in the D.C. region and that the region must unite to “find bold solutions to solve our problems with the ­Metro system.”

“I’m committed to giving you a new, bold vision for our area — one that focuses on collaboration,” he said. “It is time for a change, which is exactly why I’m running for governor.”

The crowd erupted in applause.

Madaleno, a member of the Senate since 2007, has been a leading liberal critic of Hogan in Annapolis and is vice chair of the powerful Senate Budget and Taxation Committee. He was the first openly gay lawmaker elected to the Senate.

With more than 13 months until the June 26, 2018 primary, he is one of eight Democrats who have expressed interest in the race.

All eight participated in a Western Maryland straw poll of potential Democratic gubernatorial candidates last month. U.S. Rep. John Delaney (Md.), whose district includes Western Maryland, finished first in the poll with 66 votes. Baltimore County Executive Kevin Kamenetz received 41 votes; former NAACP executive director Benjamin Jealous received 22; Baltimore attorney James L. Shea garnered 16; former state attorney general Douglas F. Gansler won 13; and Madaleno and Prince George’s County Executive Rushern Baker III each received 12.

Entrepreneur Alec Ross, the only Democrat who has officially launched his campaign, did not get any votes in the straw poll.

Madaleno served four years in the House of Delegates before joining the Senate. Before that, he was a budget analyst with what is now the state Department of Legislative Services.

He and several of the other hopefuls have been busy in recent weeks, appearing at Democratic gatherings around the state. He told The Washington Post he will make a formal announcement of his candidacy at a later date.

Hogan has said he will seek a second term, but he has not formally launched his campaign.

The governor has recorded ­record-high approval ratings during his first two years in office, although Maryland’s heavily Democratic electorate expressed some doubts in a recent Washington Post-University of Maryland poll about leaving the governor’s office in GOP hands in 2018.

At Sunday’s event, Madaleno said Maryland has had misplaced priorities when it comes to transportation funding. He accused the state of spending too much on road projects at the expense of mass transit. “We can fix [Metro]” he said. “We have the money in the state of Maryland. It’s a question of priorities.”