Export changeTab so outline.js can find it.

Move the first use of PREFS after it has been checked for existence.
Merge pull request #10 from burtnoir/master

#7 and export changeTab so outline.js can find it.