Separated UI into new class.