我已经发布“HERe”。不更新子视图的UIView?
和Here actually What I need to Deserve
如果我把代码[self loadLocationView]
这部分UIButton and ViewDidLoad method
,It works fine here.
但每当我选择从TableVeiw的位置,并从configureViewSlider
方法调用,它被调用的方法loadLocationView
但不更新UI。 这里我已经尝试过。
-(void) configureViewSlider
{
if (_detailItem) {
Location=[_detailItem description];
//[self performSelectorOnMainThread:@selector(btnLocations:) withObject:nil waitUntilDone:false];
//[btnLocations sendActionsForControlEvents:UIControlEventTouchDown];
// [self loadLocationView];
[self performSelectorOnMainThread:@selector(loadLocationView) withObject:nil waitUntilDone:NO];
//[self loadView];
NSLog(@"Location %@", Location);
}
}
-(void) loadLocationView
{
_viewLocBangalore.frame= CGRectMake(10, 10, 303,255);
[self.view addSubview:_viewLocBangalore];
// [self.View bringSubviewToFront:_viewlocBangalore];
//[_viewLocBangalore setNeedsDisplay];
}
我还有什么要做到这一点。我尝试过所有可能的方法。但没用。
请至少做一些建议,我准备好接近任何准备值得我的任务的方式(我..我..添加了一个UITableVieContrller有位置,当用户触摸位置时,UIView应该更新)。
通过放置中断点,检查一次您的loadLocationView方法是否正在主线程中调用。 – 2013-05-03 12:19:34
是的,我在问题中也提到过。即使它正在接听并打印Log值。 – 2013-05-03 12:24:00
好的,一旦尝试直接放置视图,无需过渡动画。 – 2013-05-03 12:27:01