Walmer Castle against Charles' brother, King James II, the townsfolk of Deal seized Walmer Castle on behalf of William III, the Prince of Orange. By the end of the century, however, the castle was increasingly regarded as out of date from a military perspective. In the 18th century, Walmer Castle became the official residence of the Lord Warden of the Cinque Ports. The Lord Warden was originally a medieval title linked to five key ports along the coast of England; the position's prominence had faded, but it still retained important judicial and military functions. When Lionel Sackville, the Duke of Dorset, was
Lord-lieutenant of London and the Warden of the Cinque Ports were "ex-officio" lieutenants for the Tower Hamlets and Cinque Ports respectively, which were treated as counties in legislation regarding lieutenancy and militia affairs. The official title of the office at this time was His or Her Majesty's "Lieutenant for the county of x", but as almost all office-holders were peers of the realm, they were referred to as "Lord-Lieutenant". "An Act to make the Militia of this Kingdom more useful" (Geo 2, c.9) was passed by the Parliament of Ireland in 1715. This provided for the issuing of commissions to appoint