In the Glorious Revolution , King James II was deposed by his daughter Mary and her husband William III of Orange . The revolution deposed James II and replaced him with his daughter from his first marriage Mary and her husband , William III of Orange .