This is a Scottish tradition...
I've got branches all over England and Scotland - the English branches don't follow any particular pattern - there are often names passed down, but there is no pattern. In fact, the most common thing I've found is eldest son named after father. The eldest daughter is often named after her mother, but it's just as common for a younger daughter to take the mother's name, and it's also perfectly common for a younger son to take his father's name. As I said, no pattern at all really.
In Scotland, however, it is quite easy to see this pattern. It's a guideline not a rule, but most of my families used it, particularly the first two stages mentioned in each case - third son being named for the father and third daughter for the mother is less predictable. It's more or less died out now - of course, you'll still find children named after older relatives, but it's not in the strict pattern any more. I'm not sure when it died out - in my family, it is still there in my Granny's generation (she was born in 1909), but she and my Grandpa didn't use it when naming their own children...
I was first told about this pattern by the archivist in my home town, some years ago. My home town is almost on the border between England and Scotland, so the records held there are a mixture of English and Scottish, and the people who come to do their research there often have ancestry on both sides of the border (as most people who live there do), so this archivist is something of an expert in English/Scottish differences, and she told me about it as something specific to Scotland. I had never noticed it before, but after she pointed it out, I realised that I had it in virtually every Scottish family on my tree!