UIBarButtons disappeared in iOS 9.2 -
i have upgraded 1 of apps under development ios 9.2
, have found navigationbar uibarbuttons
have disappeared , not shown on navigation bar.
btw: i'm using uibarbutton custom class called bbbadgebarbuttonitem
here
update 1
here snippet code used add uibarbuttonitem
// add search button uiimage* searchbtnimg = [uiimage imagenamed:@"searchbarbutton"]; searchbtnimg = [self ipmaskedimage:searchbtnimg color:[uicolor pddappselectediconcolor]]; cgrect frame = cgrectmake(0, 0,searchbtnimg.size.width,searchbtnimg.size.height); uibutton* searchbtn = [[uibutton alloc] initwithframe:frame]; [searchbtn setbackgroundimage:searchbtnimg forstate:uicontrolstatenormal]; [searchbtn addtarget:self action:@selector(_searchcontent) forcontrolevents:uicontroleventtouchdown]; self.searchbarbuttonitem = [[bbbadgebarbuttonitem alloc] initwithcustomuibutton:searchbtn]; self.searchbarbuttonitem.shouldhidebadgeatzero = yes; self.searchbarbuttonitem.badgevalue = @"0"; self.navigationitem.leftbarbuttonitem = self.searchbarbuttonitem;
update 2
i see following error message <error>: cgcontextsetfillcolorwithcolor: invalid context 0x0. if want see backtrace, please set cg_context_show_backtrace environmental variable.
and answer seems apple bug
i have figure out, imagecatalog
random reason have make custom barbuttonitem unassigned
unknown reason.... stupid thing ;(
also, general note have noticed opening xcode project ios9.1
on newer xcode 7.2
or vice versa got of added images imagecatalog
in unusigned
state , app couldn't see until fix in imagecatalog
.
Comments
Post a Comment