SwiftParseChat icon indicating copy to clipboard operation
SwiftParseChat copied to clipboard

The number of messages does not refresh automatically

Open humbleProgram opened this issue 10 years ago • 3 comments

Suppose A has sent 4 messages to B. The number of messages does not refresh automatically, it remains as the number last time you tapped Messages tab at the bottom.

You need to tap Message tab at the bottom to get the latest number of messages that you received.

humbleProgram avatar Jun 21 '15 21:06 humbleProgram

could you tell me how you fixed the import error with Alamofire ?

andy-io avatar Jun 24 '15 07:06 andy-io

I have not experienced the import error with Alamofire yet...

humbleProgram avatar Jun 25 '15 02:06 humbleProgram

To fix this problem try this:

Create a NSTimer then add this code in the viewwillappear method: timer = NSTimer.scheduledTimerWithTimeInterval(Refresh Time, target: self, selector: "Your method that loads messages", userInfo: nil, repeats: true)

and to stop the timer when awayy from the page add this to the viewwilldissapear method: timer.invalidate

Jamwesayer avatar Jul 01 '15 08:07 Jamwesayer