Added connection class to handle qt connect and disconnect functions.