我按时收到了服务器的响应,但是成功响应后,UI却显示晚了

时间:2019-07-17 07:48:46

标签: swift

我按时收到了服务器的响应,但是成功响应后我的UI却没有显示。需要花费很多时间来显示。我使用dispatch Queue.main.a sync,但是它没用,我该怎么办?

DispatchQueue.main.async {[weak self] in
        self?.view.setNeedsDisplay()
      self?.alertLbl.text = "There are no Artist scheduled for today. Try again later with another Radio Station"
     print("There are no Artist scheduled for today. Try again later with another Radio Station")

      }

 DispatchQueue.main.async {[weak self] in
            self?.view.setNeedsDisplay()
          self?.alertLbl.text = "There are no Artist scheduled for today. Try again later with another Radio Station"
         print("There are no Artist scheduled for today. Try again later with another Radio Station")
          }

0 个答案:

没有答案