In ordinary Newtonian physics, when one changes reference frame, the gravitational potential energy does not change. On the other hand, the total energy of a particle is not the same in two different frames of reference. The kinetic energy does change, when one goes from one frame to another, so the total energy changes by the same amount that the kinetic energy does.
As a check, you can calculate the gravitational potential energy from scratch in each reference frame. This can be obtained from the integral of the force over the distance. It is because the gravitational force does not depend on velocity (in Newtonian physics) that one gets the same answer irrespective of the velocities involved. But see my added note below which qualifies this a bit.
There is a further good take-home message here. Notice that the energy of a particle should not be thought of as a property only to do with the particle, because it is relative. Any statement along the lines of "the particle has energy 1 joule" should be understood as a shorthand for "when observed in such-and-such a frame of reference, the particle has energy 1 joule".
I hit "enter" on the above answer a little too quickly. There is a an important further point. The concept of potential energy only really works as an aid to calcualtion (in a simple way at least), when the potential at a given place is not itself a function of time in the reference frame under consideration. We can still imagine a potential well with the Earth at the middle, for example, but a moving potential well produces time-dependent forces and that means you don't expect that a particle going away and coming back to the same place will have the same change in its kinetic energy. In this sense the force is then "non-conservative". This terminology doesn't mean that energy conservation no longer applies, it does mean that the concept of potential energy no longer offers a quick and easy way to keep track of the energy movements.
Here is another example. There is elastic potential energy in the strings of a tennis racket when it hits a tennis ball. But the change in momentum of the ball, when the racket hits the ball, depends not only on the extension of the strings (which leads to a given force) but also on the total time during which the force is applied. So here again, the concept of potential energy is not enough on its own to tell you how the overall energy conservation works out.
If you want the technical details for this area of physics, then look up "Lagrangian mechanics".