made the gui elements a bit more reusable