The reason for this period of longevity isn't that Apple dedicated itself to supporting these legacy systems, that's a decidedly unApple thing to do. When Apple adopts a new technology that changes something fundamental about their operating system (e.g. PPC->x86, 32bit->64bit), they dump support for legacy systems in 1 or 2 versions. The reason for this long period of stability is that hardware performance reached a plateau and the focus shifted towards smaller and lighter systems with increasingly longer lasting batteries.
Let's also remember that if you counted up every Apple Mac regardless of OS, they would account for less of the PC market than the number of machines running Windows XP (a 14 year old OS that Microsoft still supports). Or that Microsoft Windows 10 can run on any x86 or x64 CPU 1Ghz with 1GB RAM made in the last 15 years.