Moved delegate to be inside program class.