Called an “absolute hero to the gay community” by gay activists, Massachusetts's House speaker said Sunday he would resign.

Democrat Salvatore DiMasi, the first Italian-American to hold the post in the state, said goodbye in a letter to colleagues.

“No matter what the critics and cynics will say, all my actions as state Representative and as Speaker were based solely on what I thought was in the best interests of my district and the people of the Commonwealth,” DiMasi wrote.

DiMasi resigned amid allegations of impropriety, but has not been accused of any criminal wrongdoing. A close friend, Richard Vitale, who once served as DiMasi's campaign treasurer, is under investigation for using his close ties to the speaker to push favorable ticket-scalping legislation. Vitale is also accused of paying off legal bills for the speaker's in-laws.

“Sal has been an absolute hero to the gay community for the last 25 year,” gay rights activist Arline Isaacson told The Boston Globe. Isaacson, the chairwoman of the Massachusetts Gay & Lesbian Political Caucus, called DiMasi's stance against the 2007 referendum to ban gay marriage in the state by constitutional amendment “absolutely critical.”

A state Supreme Court decision made Massachusetts the first state to recognize gay marriage in 2005, but a 2007 effort to ban gay marriage by calling for a constitutional convention fell short.

DiMasi has served as speaker since 2004, and has been a member of the House since 1979.