There are three effective ways for me to context-switch from virtually any distraction to working.
Move Very often my normal workflow is interrupted by others talking to me with random topics. In these scenarios, I simply move. I first move around my workplace (while talking with them) to see if the conversation could end pretty soon. If not, I find an excuse and move to some other places, such as the library or Starbucks, to quickly resume what I was working on before the thoughts are completely gone.
Hoax When I do not have the mood to start work immediately, I just tell myself: let me do this for 10 minutes. I usually end up working on the topic for much longer than that, and sometimes even hours without a stop.
Imagine Sometimes the procrastination just comes from the fact that I do not know how to proceed with the things that I have to do. In this case, it is better to sit back and imagine. Imagine what the final goal is, imagine what the deliverables are, imagine what are the necessary steps, imagine the whole process achieving the final goal, and imagine that I have already started! This makes me resume the working mode pretty quick; works like a charm!