The Chairboys came back from 2-1 down to win thanks to two second-half headers from Paris Cowan-Hall.
Wycombe's triumph was all the more impressive given that four of Ainsworth's players had earlier pulled out of the game through illness.
"Jo Kuffour actually played with an illness so I think there's something going around here and energy levels are down. But we've proved we have a team of real workers and togetherness and I thought we thoroughly deserved the win.
On Cowan-Hall, who has now scored three goals in five league appearances for Wycombe, Ainsworth said: "I brought him here as a wide right predominantly because we were 4-4-2 and that brought us a lot of success last season.
"But this season he can play down the middle. As a forward he's a nuisance. He's got pace he's got tricks and he can pop up anywhere.
"I know how good he is in the air, that's why I brought him here, I saw that at Plymouth last year. I was so pleased when we acquired him and I think Paris will be a big player for us this season."
Wycombe currently sit ninth in the League Two table.