working with a master detail layout in IOS