I had to pull out my deck to check this one, but I believe you win in this case!
The reason is the wording at the top of every action card (emphasis mine):
"To play this card, do whatever it says, then place it on the discard pile."
So, technically, action cards are still in your hand until you've performed the action they tell you to do. So when you play "Trade Hands" in the situation you describe, what actually happens is:
You and your opponent exchange hands. Both of you still have 10 cards in hand, including "Trade Hands".
You take "Trade Hands" from what is now your opponent's hand and place it on the discard pile. Your opponent now has 9 cards in hand, while you still have 10. You win.
Yeah, that does feel kind of weird, and of course in practice what you'd actually do when playing is set "Trade Hands" aside before passing your hand to your opponent. But technically, according to the rules, it still counts as part of your hand (which becomes your opponent's hand) until the exchange is over.
By the way, if the explicit statement on each action card that I quoted above isn't convincing enough for you, some additional support might be offered by the "Discard & Draw" action card, whose instructions read:
"Discard your entire hand, then draw as many cards as you discarded.
Do not count this card when determining how many replacement cards to draw."
Clearly, if action cards were removed from your hand before they were played, there would be no need (except, admittedly, avoidance of doubt) to include the second sentence on the card at all.
I went through all the other action cards in my basic Fluxx deck, and as far as I can tell, these are the only two actions where this rule could make any direct difference. However, note that following the rule as written does have one non-trivial indirect effect: whenever other cards are discarded as the result of an action, the action card ends up on top of them in the discard pile. I don't think the order of the discard pile actually matters much (if at all) in basic Fluxx, but there are cards in other Fluxx editions for which it does matter, such as, off the top of my head, "Composting" in Eco Fluxx. In any case, the "Let's Do That Again!" action explicitly tells you not to change the order of the discard pile, so clearly it's supposed to be at least potentially significant.