(Re-)moves redundant Swing code