Syncing script makes gui slow in IOS app swift -


i've got method sync app online api. when running sync script reponses of app delayed. tried using:

dispatch_async(dispatch_get_global_queue(dispatch_queue_priority_background, 0), {   self.synceverything()  } 

this doesn't has effect on speed. tell me right approach problem?

edit

i changed code, syncing script using different context context of main thread. when syncing complete, merge contexts. still syncing slowing down gui.

below cpu activity when syncing, mean running on main thread?

enter image description here

in of classes used in "synceverything()" uikit imported, cause of delay?


Comments

Popular posts from this blog

python - TypeError: start must be a integer -

c# - DevExpress RepositoryItemComboBox BackColor property ignored -

django - Creating multiple model instances in DRF3 -