I now see that it happens every time the pan / crop / masking window loses focus. If I zoom in on the timeline, then click somewhere outside of the window, the zoom goes back to default = 0. The cursor stays in the same place on the timeline, I have to zoom back in again to the keyframe I am working on. This is especially annoying when I have many keyframes close together, so I have to zoom in to select a precise keyframe. This only happens if the program window itself loses focus (i.e. if I click away to my browser or to another program window). When I bring focus back to Sony Vegas the zoom level on the timeline is back to default. When I spoke of Windows 7 popup notifications, I guess they effected this issue also because they must make the current program window lose focus.
I also notice that while CTRL-RightArrow should advance the cursor to the next keyframe on the timeline, even though it does select the next keyframe it actually advances the cursor to right after the keyframe. Which means that if I make a modification in the masking, it will create a new keyframe in the actual cursor position instead of modifying the one I that is selected. This is a little annoying also, CTRL-RightArrow isn’t much of a shortcut for advancing to the next keyframe if the cursor winds up advancing further than the next keyframe.
Here are a couple of screenshots which further illustrate the issues:
1. Timeline zoomed in

2. Timeline after Sony Vegas loses focus, now zoomed back out to zero:

3. Cursor position after advancing to next keyframe with CTRL-RightArrow shortcut:

As you can see, the next keyframe is selected but the cursor is positioned after the keyframe. So any modification to the masking will not be applied to that keyframe; instead a new keyframe will be created in the current cursor position!