The Dons had been looking to retain second spot in the Scottish Premiership against the bottom-placed Jambos, and had taken the lead through Niall McGinn's 25th-minute strike.
But McGinn saw Jamie Macdonald save his penalty and Dons midfielder Barry Robson was shown a red card for two bookable offences.
"I thought Jamie was fantastic in the second half," said Locke. "He's got that in his locker as he showed earlier in the season.
"Like any young player, he'll take a dip in form but he's responded and I singled him out in the dressing room because I thought he was fantastic.
"It was a great composed finish for the equaliser and a fantastic run for the second goal. We're trying to get more consistency from him and he's upped his work-rate.
"When he's on the ball and running at people, he's hard to play against."
Walker himself was keen to play down his performance.
"The game opened up when Barry was sent off. We had a few chances and managed to take three of them," he said.
"This has given us a massive boost. We've always believed that we can get out of the situation we're in although it's hard when results aren't going your way.
"We go into the Ross County game hoping we can get three points there as well."
Aberdeen captain Russell Anderson was left bemused by some of the decisions that he felt changed the game in Hearts' favour, in particular Robson's dismissal.
He also pointed out that Hearts midfielder Jamie Hammill could have seen red in the early stages.
Not naming Hammill, Anderson said: "The first yellow card, I don't understand. Maybe the referee has told Barry what it was for, but I don't think he did.
"The disappointing thing is Barry's been sent off for two innocuous yellow cards when an awful lot of worse tackles went into the game in the first 20 minutes, and Hearts have still got 11 men on the pitch."
The Dons now lie seven points behind leaders Celtic, but have a chance to close the gap when they head to Parkhead in their first game after the international break.
Anderson added: "Between the last international break and this one, this has been the only blot on our copy. More recently, we've done very well.
"It's a chance to sit down and look at how we've done, regroup and go again. It's always good to go down to Parkhead and test yourself, and this time will be no different."