I'm using linuxmint 7 (Ubuntu 9.04) with GNOME, and an Nvidia 8600M GT.

I just bumped into this thread looking for a solution to something very similar, which I thought might be helpful!

Basically, I have the same primary display issue when I plug an LCD into my laptop, tick the box to keep my main screen as the primary display, press ok, and accept the changes (it reverts back after 15 seconds otherwise). However, if I press cancel to not accept the changes, then apply again and accept the changes, my primary display is now correctly set!

I have had this bug for a while now, infact doing the above seems to mess up my gnome-panel (moves it to the top of the screen and freezes it). I was looking for a fix, but perhaps the above would help some people who cannot get the correct primary display in the first place,