To put it simply, they broke him down, breaking his will and mind. Through a very slow, drawn-out process of starvation, mind-control, physical abuse and violence, threats and drilled backwards-reasoning, Winston's power of reasoning, self-dignity, individuality and self worth were stripped from him. What was left was a robotic shell that was the perfect vessel for Party propaganda and servitude.
O'Brien would come in and state illogical things like "2 plus 2 equals 5," and beat and argue with Winston, starving him and humiliating him until Winston admitted that that was indeed a true statement, and actually partially believed it himself. Through this process, anything that made Winston an individual, or gave him a sense of identity, was taken away from him. He holds on to one thing until the very end, and that is his love for Julia. He clings to that, vowing that they can't take that away. But, through the use of playing on Winston's terror of rats, he ends up betraying her also, begging them to put her in his place for the torture. After Winston gets out, he meets Julia and finds that she betrayed him too--it's what the Party does, and both of them, along with their entire society, has fallen victim to it.
Winston emerges an automaton, a perfect servant for the party, not only in body, but in mind and soul too. I hope that those thoughts helped; good luck!
Do you mean that you want to explain how it happened or why it happened?
The how is that Winston was was in a cafe when he heard from the telescreen of a victory by Oceania in their war. Amid the victory celebration, Winston realizes that he really loves Big Brother.
The why is a bit harder. Winston is tortured, but he doesn't reintegrate until after the torture is done. To me, what has happened is that all the times he "broke" under torture have undermined his free will. He has betrayed his own ideas so much that he no longer really has any ideas or any sense of who he is. He lives a pointless life between the time the torture ends and his reintegration.
Since he'd lost his individuality anyway, it was just a matter of time before he came to love Big Brother just like everyone else.