The short answer to that question is : almost certainly the Conservative party. At least until Monday morning, the momentum had been running away from the Tories, and even after the U-turn on social care, Theresa May was firmly on the back foot, as witnessed in her interview with Andrew Neil. Since then, simply by doing what any potential Prime Minister (including Jeremy Corbyn) would do in the same situation, she has probably gone some way towards repairing her "strong and stable" brand in the public imagination. And, whatever the rights and wrongs of the decision, the sight of armed forces on the streets will scare the living daylights out of a lot of voters, leading them to prioritise national security over bread-and-butter issues - a shift which is bound to favour the Tories.
There are a few possible counter-arguments to that reading of the situation -
1) A tragedy like the one we've seen this week may bring about an increase in civic-mindedness, and thus boost the turnout. Although the surprise socialist victory in the Spanish election just after the 2004 Madrid bombings was attributed to Aznar's dishonesty in blaming Basque terrorists for the atrocity, it may have had just as much to do with the simple effect of a boost in turnout automatically favouring the parties of the left (ie. because the demographic groups most likely to vote for right-wing parties generally turn out anyway).
2) There may now be a modest UKIP recovery. I've been astonished and dismayed by the number of otherwise sensible people I've seen on Facebook over the last 36 hours calling for mass deportations. UKIP's campaign message may not go quite that far, but it's certainly the closest fit. If UKIP do win some lapsed voters back (and remember they're only standing in roughly half the constituencies this time), it's not clear which party would suffer the most, but it's possible it might be the Tories.
3) Power is somewhat more dispersed in the UK than it used to be, so the politicians in leadership roles who have been making high-profile statements on the Manchester bombing and its implications haven't been confined to the Conservative party. The new directly-elected Mayor of Greater Manchester is of course Andy Burnham, very well known to be a Labour politician. Nicola Sturgeon's statements have been well-publicised in Scotland, and presumably the same is true of Carwyn Jones' statements in Wales. The "clinging to the party of power in a moment of crisis" effect is therefore not quite as clear-cut as it might otherwise be.
4) The longer the campaign is suspended, the less time the Tories have to implement their planned "shock and awe" campaign to destroy the credibility of Jeremy Corbyn.
All of those factors should be taken seriously, but even in combination I don't think they outweigh the advantages that the Conservatives are now gaining. When the next Britain-wide polls are published, I expect to see an increase in the Tory lead.