I actually really like the AmigaOS way. Where all windows have this behaviour. In fact, bringing something to the foreground is an explicit action. Sounds weird, but it allows you to, for example, drag something from a background window to the foreground one, or have a background window in focus.