Let me just give you a piece of advice. If you ask a girl out, and she rejects you, but still wants to be your friend. You have to put some barriers up.
Tell her straight up "You didn't want me part of your romantic life, and that's fine, but that means you cannot talk to me about your romantic life." You can still be her friend, talk, hang out, help her through stuff all you want. But lay down the line that you won't be that shoulder to cry on about that jerk she picked over you.
Other than that, try and move on. It hurts, and it sucks, but eventually you will get over her.