The hot oil captures the caramelized sugars present in the onion. Once you have that, you can toss the onion.
Oh, now I see! ;0)