Added pin functionality to gui