Fixed restoration of last selections after GUI restart.
Renamed variables and removed dead code