A speech by the Chief of Navy in Canberra has been disrupted after a rock was reportedly thrown through a nearby window, prompting a short scene of panic.