I don't think it has to do with whether you leave the page open. I believe the server track if your computer has sent a command to it recently, ie clicked on a link, opened a thread, or post a reply. If it's been to long since you sent an active command, it considers you "logged out". I believe that's how it is with most forums.