Hoops fans booed co-owners Flavio Briatore and Bernie Ecclestone before kick-off but left satisfied after watching their side mount a stirring comeback.
Ainsworth said: "It was down to a fantastic bunch of lads in the dressing room.
"We dominated the first half and could have been three or four up. All the raised voices at half-time came from Sheffield Wednesday's dressing room.
"We kept calm, knew we were doing the right things and, although I had a little flutter at 2-0 down, I still had faith."
Ainsworth was less forthcoming however on suggestions that it was Briatore who picked the team.
He said: "I'm not commenting on things like that, just the football on the pitch."
Wednesday opened the scoring in the 36th minute when midfielder Gavin Mahon headed an own goal after his team-mates had squandered a host of chances.
Two goals were disallowed for offside, Wayne Routledge and Heidar Helguson both hit a post, Damion Stewart saw a header cleared off the line and Jordi Lopez missed from eight yards when clean through.
Marcus Tudgay made it 2-0 from the penalty spot eight minutes into the second half after Stewart had been adjudged to have barged Leon Clarke over in the box.
Substitute Rowan Vine pulled one back in the 62nd minute after Owls goalkeeper Lee Grant could not hold on to Routledge's angled drive.
It was the forward's first goal following 12 months out recovering from a broken leg.
Mahon headed home Lee Cook's cross in the 74th minute and the comeback was completed with just two minutes remaining when the winger delivered an almost identical ball and Stewart was there to power home a header.
Wednesday manager Brian Laws accused his players of being unprofessional
He said: "We were fortunate to be two goals up. We started nervously and defended like a pub team.
"There were poor performances and they never stopped. Defensively that was the worst I've seen. It was like the Keystone Kops.
"If you do go 2-0 up you should never let it go like that. You could see the writing on the wall and it bitterly disappoints me.
"I'm not going to accept that. If they have switched their minds to holiday mode then they will regret it.
"QPR had more desire to be on the end of balls than we did and it showed with their last two goals. Too many people thought the job had already been done."