Hiding UINavigationItem's bar button

后端 未结 11 1024
粉色の甜心
粉色の甜心 2021-01-04 07:04

I have added a BarButton item to the left of the nav.bar through Interface Builder and in the code I want this only to show in my table view\'s edi

11条回答
  •  慢半拍i
    慢半拍i (楼主)
    2021-01-04 07:29

    To hide/disable

    [self.navigationItem.leftBarButtonItem setEnabled:FALSE];
    

    To show/enable

    [self.navigationItem.leftBarButtonItem setEnabled:TRUE];
    

提交回复
热议问题