Gunman searched for dates of Trump’s public events as well as for the Democratic National Convention, officials say