In what year did James II die?