Well perhaps saying "on a whim" seems to make light of the situation, but given the sovereignty of parliament in the British system, I think there isn't much more to it. It is well established that parliament can make any law it likes, including laws that change the constitution.
The law that banned ownership of handguns was made by the then government over and against the advice and recommendation of the commission set up to investigate following the Dunblane tragedy. If disregarding expert advice following thorough investigation is not "on a whim" then it is certainly not a proportionate and considered act.
Regarding speed cameras, how am I misstating the law? You are required to state who was driving the vehicle, particularly if it was yourself (the common case). If you admit it was you driving the vehicle that is taken as evidence of guilt and you are prosecuted on that basis. The only way to defend against conviction is to find some way of casting doubt on the facts, which is not usually possible.
If you decline to state who was driving, you are prosecuted for failing to provide the information required by law, which leads to a stiffer penalty. Therefore the law requires you to incriminate yourself or be penalized for failing to do so.
That your admission of being the driver is the basis of prosecution is clear from the cases where people have successfully argued that "they could not remember" who was driving. In such cases no prosecution has followed and the driver has not been convicted. This circumstance in particular has led to a new generation of cameras that photograph the driver of the vehicle from the front, thus making it possible to prove who was driving from photographic evidence.
That this violates the right to avoid self-incrimination was very clear when the law was made, and it was duly challenged in court. The courts ruled that the benefit to society as a whole outweighed the rights of the individual, and therefore the law was upheld.