Skeleton code for some event handling.