Question about claiming unemployment on a previous job one quits.

This question is regarding someone who is not in good standing with the company they're employed by, and knows that they are about to be terminated. If they resign before the company has a chance to actually terminate them (not having another job to go to), and then at a later time get another job and then lose THAT job due to no fault of their own, can they collect on the hours from the previous job they quit? or just the job they last had?

placeholder text for bug in Chrome