How to deal with fixation towards an old relationship? I broke up with my girlfriend a couple of years ago. We haven't talked to each other since then. A few months back we met at a job interview. We spoke to each other and she was very friendly. I thought she is no longer mad at me. Few days ago I came to know that we both got the job. I texted her to congratulate. She has seen it but hasn't replied. Now I can't stop checking my messages on the phone to see if she has replied. I know this is fixation but just don't know how to deal with it. What could be a way out of this?
Now I can't stop checking my messages on the phone to see if she has replied. I know this is fixation but just don't know how to deal with it. What could be a way out of this?

Not much else to do other than to be mindful of it. You see the mind works in the way of habits. The more time spent on something, e.g. thinking about the past or future, that will incline the mind more towards that direction.
When being mindful of the (compulsive) thinking process it will interrupt it. Instead of enforcing the feed-back loop, mindfulness will momentarily break it.
Since we are working with habits, the mind will soon fall into this way of thinking about past and future again when mindfulness is absent. That's when one must apply mindfulness again. When doing this over and over the mind will slowly begin to incline itself towards that direction - the direction of mindfulness, wakefulness and clarity of mind. When that happens compulsive thinking will stop. It cannot go on since it's not being fed anymore. There's no fuel to burn.
In short, just be mindful of these thoughts when they happen. Do that again and again until you can be free from them. That is the only way one can go about this.
Pinning them down with willpower will only suppress them and cause them to erupt violently later. Shifting attention away from them will only bring temporarily relief.
If you want to become free from them for good, you need to observe them with mindfulness until they change, become exhausted and pass away.
May you be well and happy.