Both Cora and Pink have done this, Pink first with one leg and then the other. All three were x-rayed; all three were some sort of soft tissue injury. Cora's affected a muscle she needed to push up, so getting up and climbing stairs etc. were agonizing (I think it was a minor injury until she went up stairs and really wrecked it; the examination and x-rays made it even worse). Pink's second one (not sure about the first) seemed to be more in the front of her leg--sort of where a human's quads are located. She'd been a bit sore off and on for a while, but last week it got dramatically worse for no apparent reason.
With Cora, we used an NSAID and rest. It took months. Ditto with Pink's first injury, although the recovery didn't take as long as Cora's. With Pink's more recent injury, we hit it harder: an NSAID, Tramadol, methocarbamol (muscle relaxant), and laser. She's infinitely better after just a week.
I suspect that sometimes they injure themselves in the yard and the problem is minor until they move in a way that aggravates it.