Daisy, my 16 week old kitten has a tendency to jump and sit on my keyboard often shutting down programs, renaming files & folders to say the least. After googling a solution I found Cat Nip
a program which, while running, detects “cat-like typing” and locks the keyboard, usually in under a half second. Optionally, CatNip will fade your desktop and display a warning message to your cat (which is of dubious value, since if your cat can read, your cat can probably type, too).
There are mixed reports about whether Cat Nip works on Leopard, but for me so-far-so-good