In this dialogue, Nico Robin says that Davy Jones was the boatswain of a certain pirate crew.
Since we know that Davy Jones was a pirate who lived 800 years ago, and that the first pirate in history, who also lived 800 years ago, was Joyboy, it’s natural to assume they were part of the same crew (Joyboy was the captain). This would also explain why Davy Jones carries the D. in his name.
Emet apologizes to Joyboy for not being able to make him king.
According to Xebec, Davy Jones was the previous king of the world.
When Xebec says this to Imu, he completely loses his composure and claims that someone like him was never truly king.
Xebec also mentions a promise between Imu and Davy Jones that was never fulfilled.
This is how I think things went: Davy Jones betrayed Joyboy, making a deal with Imu to seize the throne of the world.
Joyboy fails, Davy Jones becomes king of the world, but in the end Imu betrays him and gets rid of both of his enemies in one move.
From that moment on, Davy Jones swears revenge, promising that one day a descendant of his will return to reclaim what was promised to him.
That descendant is Blackbeard.
He will be the one to absorb Imu and the devil, completing that revenge.
And at that point, the final conflict will be between Luffy and Blackbeard for the One Piece. Whoever finds it will decide the fate of the world.