2014-06-29 51 views
0

我加入一個UIButton的在視底部 -的UIButton是向上移動時,導航欄隱藏

CGRect frame  = [UIScreen mainScreen].applicationFrame; 

UIButton *menu_btn = [[UIButton alloc] initWithFrame:CGRectMake(xOffset, frame.size.height - 55, 55, 55)]; 
[self.view addSubview:menu_btn]; 

並在視圖我有UITableView的,我躲在列表中向下滾動,並且當uinavigation酒吧顯示滾動時的情況。

menu_btn隨着列表上下移動,我想修復這個按鈕。

任何人都請建議我,我怎麼能做到這一點?

回答

0

我添加在navigationController.view和它的工作正常。多謝你們。

CGRect frame  = [UIScreen mainScreen].applicationFrame; 
UIButton *menu_btn = [[UIButton alloc] initWithFrame:CGRectMake(xOffset, frame.size.height - 55, 55, 55)]; 
[self.navigationController.view addSubview:menu_btn];