Even in that sceario (the doom sayers want to entertain so lets, shall we), Nintendo is not freaking Sega. They have ample cash reserves and their handheld business will be a revenue stream for the next 6-7 years even if smart devices continue to chip away at that market.
They would never grovel like Sega and become a common third party.
Microsoft and Sony would have to line up and court them. And they would likely only work with one or the other. Nintendo has all the control here because they are effectively the "king maker" in the game business in this position -- who ever the allign with basically the scales of the console war would tip in their favor.
For starters, if it was Sony, Sony would likely have to give up their handheld business period or simply cede it to Nintendo. So there's that. If it's Microsoft, they would have to offer Nintendo some kind of proposition with Windows Phones I would think.
Third Nintendo would have to be getting a metric ton of money to make up for the royalties they used to make on their own unique console.
Nintendo could also get marketing kick backs (Sony or MS agree to pick up the tab for all of Nintendo's TV marketing for example) and they could also insist on input on any future hardware and perhaps even co-branding.
Personally I think Microsoft would bite and meet Nintendo's terms, leaving Sony out as a loser in the console biz. Mario + Halo + Titanfall + Zelda + all third party support + Gears + DKC + Killer Instinct + Rare returning = game over for Sony. Vice versa if Sony could get them on their side, it would be a similar result, gave over for Microsoft.
So strictly put, in this scenario ... MS/Sony fans shouldn't huff and puff so much -- Nintendo is the one holding all the cards.