Hello, and welcome to TeenHelp!
If your girlfriend was slapped and then forced to kiss her ex, it's definitely important that you tell a trusted adult about the situation. Unfortunately, abuse can occur even after a relationship has ended... and if your girlfriend's ex is coercing her into spending time with him and doing things against her will, it needs to stop.
There is another possibility, which hopefully isn't true... and it's that your girlfriend is starting to concoct a story about how she "had" to spend time with her ex, "had" to kiss him, and eventually, "had" to have sex with him. If she's trying to justify her cheating behavior and manipulate you (vs. the ex manipulating her), then that's something you need to discuss with her. The problem is that you probably won't know if this is true until you deal with the first possibility: that she's being subjected to abuse by her ex. Once the authorities get involved and a restraining order is filed, your girlfriend won't "have" to be around her ex - in fact, her ex would face serious charges if he violated the order. So if she continues to go to him, despite being assured she's protected, then it says one of two things: she's doing this because she wants to, or she's doing this because she's
co-dependent.
So the next possibility is that she's
co-dependent, which can happen with abusive relationships. Even if there's a restraining order, she may continue to spend time around her ex because of the psychological damage he inflicted upon her. She may sleep with him and do any number of things, despite caring about you, because she feels she has to. Unfortunately, aside from continuing to inform trusted adults about the situation, there isn't much you can do to stop her. At that point, you'll need to think about whether or not it's worth staying with her. You may love her deeply, but if she's putting herself in harm's way and isn't turning to you for support, you may want to think about how her actions could eventually cause you to fall apart (or do something you'll regret, in an attempt to "save" her).
So first things first: ask her if she was slapped and forced to kiss him. If she was, discuss going to authorities with her to file a restraining order. If she resists, ask her why. If she wasn't slapped or forced to kiss him, then again, ask her why she did it. Set boundaries, making it clear what you expect from her. You don't want to threaten her, but you DO want to be clear about what will happen if she continues to see her ex (ending the relationship).