Maybe its not so strange at all... LockPubScreen() locks the screen bitmap, and it does so even for Intuition. If Intuition tries to draw the mouse pointer, it is blocked for the time you hold the lock to the screen.
I dont know much about internal workings, but it seems to me that Intuition (due to its higher priority) first redraws the mouse pointer (and traverses the display refresh lists) before it gives control back to your code.
For Intuition screens its not very wise to get the screen dimensions repeatedly, as long as your program has control over this particular screen. It wont close or change dimensions until you tell Intuition to do so
Maybe some cache mechanism would do the trick, but this might be not as portable as it should be, as most GUI systems lack certain Intuition features...