This would help make the dock a little more like an app switcher. I imagine you can just push running apps to the front (leftmost side) of the list.
Bonus: Also be able to display folders first?
Alternate thought: Separate widgets for "running apps", "dock folders", and "closed apps" all based on the full-featured dock widget might also provide the same sort of functionality, I could just implement it manually.