Improved code, small GUI changes