objective c - View not updating when it's properties change in custom delegate -


i have acpdownloadview instance of appdelegate. it's showing downloading progress. when update it's progress value in view controller, works fine.

appdelegate.downloadvew=[[acpdownloadview alloc] initwithframe:cgrectmake(0, 0, 30, 30)]; appdelegate.downloadvew.backgroundcolor=[uicolor clearcolor]; progressbtn= [[uibarbuttonitem alloc] initwithcustomview:appdelegate.downloadvew]; acpindeterminategooglelayer * layer = [acpindeterminategooglelayer new]; [layer updatecolor:[uicolor bluecolor]]; [appdelegate.downloadvew setindeterminatelayer:layer]; [appdelegate.downloadvew setindicatorstatus:acpdownloadstatusrunning]; [appdelegate.downloadvew setprogress:0.0 animated:no]; 

now, have delegate method called when progress updated.

 -(void)progressaddchannel:(nsprogress *)uploadprogress{        float prog=uploadprogress.fractioncompleted;        [appdelegate.downloadvew setprogress:prog animated:yes];      [appdelegate.downloadvew layoutifneeded];      nslog(@"%f",prog); 

}

this code executes , show correct value of progress. progress not animating on appdelegate.downloadvew. know behavior?

since making ui changes make sure code runs on main thread.


Comments

Popular posts from this blog

Sass watch command compiles .scss files before full sftp upload -

filehandler - java open files not cleaned, even when the process is killed -

gridview - Yii2 DataPorivider $totalSum for a column -