ばかり — tracking all its uses so I don't mix them up

Doing a drill set on ばかり today and I want to make sure I've got the full picture. So far I have: (1) Noun/verb + ばかり = "only/nothing but X" (彼はゲームばかりしている = he does nothing but play games), and I've also seen it stacked after て-form for "just did X" in other material. Is that second use actually the SAME ばかり grammar point or a totally separate pattern that just looks similar? Trying to figure out if it's one flexible rule or two things I need to file separately.
Post
沐學 Mizuru