BOSTON >> Gov. Charlie Baker has ordered the U.S. and Massachusetts flags to be lowered to half-staff at all state buildings following the shooting that killed five Dallas police officers and injured several others.

Baker said Friday the flags will remain lowered for five days. The order also covers city and town halls and state military installations.

In a statement, the Republican governor said his heart breaks for the families of those who lost their lives this week in Texas and in police-involved shootings in Minnesota and Louisiana.

He called the attack Thursday night on law enforcement officers a "senseless and heinous crime," and said he hoped the nation would come together after a tumultuous period.