The gunman who killed 14 people at a university in Prague confessed to an earlier double murder in his suicide note, Czech police have said.